[Index Management] Align elements with 400% zoom#258405
[Index Management] Align elements with 400% zoom#258405SoniaSanzV merged 6 commits intoelastic:mainfrom
Conversation
|
Pinging @elastic/kibana-management (Team:Kibana Management) |
📝 WalkthroughWalkthroughThis pull request addresses a 400% zoom accessibility issue in the Index Management plugin by modifying CSS sizing behavior and flex layout properties across four components. Changes replace fixed heights with minimum heights, add flex wrapping, implement responsive styling, and enhance popover positioning. Changes
Estimated code review effort🎯 2 (Simple) | ⏱️ ~12 minutes Suggested labels
Suggested reviewers
🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
Warning Tools execution failed with the following error: Failed to run tools: 13 INTERNAL: Received RST_STREAM with code 2 (Internal server error) Comment Tip CodeRabbit can use TruffleHog to scan for secrets in your code with verification capabilities.Add a TruffleHog config file (e.g. trufflehog-config.yml, trufflehog.yml) to your project to customize detectors and scanning behavior. The tool runs only when a config file is present. |
There was a problem hiding this comment.
🧹 Nitpick comments (1)
x-pack/platform/plugins/shared/index_management/public/application/sections/home/index_list/details_page/details_page_mappings_content.tsx (1)
375-382:useEuiBreakpointmust be called at the component's top level.The
useEuiBreakpointhook is being called inside acsstemplate literal, which itself is inside the component body but not at the top level. While this currently works because it's being called unconditionally during render, React hooks should be called at the top level of the component for clarity and to avoid future issues if this code is refactored.Consider extracting the breakpoint value:
♻️ Suggested refactor
+ const mediumBreakpoint = useEuiBreakpoint(['m', 'l', 'xl']); + const mappingsListPanelStyles = css` min-width: 0; width: 100%; height: 100%; - ${useEuiBreakpoint(['m', 'l', 'xl'])} { + ${mediumBreakpoint} { min-width: 600px; } `;🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed. In `@x-pack/platform/plugins/shared/index_management/public/application/sections/home/index_list/details_page/details_page_mappings_content.tsx` around lines 375 - 382, The css block calls useEuiBreakpoint inside a template literal which violates hook top-level rules; move the hook call out of the css by invoking useEuiBreakpoint at the top of the component (e.g., const isAtLeastM = useEuiBreakpoint(['m','l','xl']) or similar) and then reference that boolean/value inside mappingsListPanelStyles instead of calling useEuiBreakpoint inline; update mappingsListPanelStyles to use the precomputed variable so the hook is only called at the component top level.
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.
Nitpick comments:
In
`@x-pack/platform/plugins/shared/index_management/public/application/sections/home/index_list/details_page/details_page_mappings_content.tsx`:
- Around line 375-382: The css block calls useEuiBreakpoint inside a template
literal which violates hook top-level rules; move the hook call out of the css
by invoking useEuiBreakpoint at the top of the component (e.g., const isAtLeastM
= useEuiBreakpoint(['m','l','xl']) or similar) and then reference that
boolean/value inside mappingsListPanelStyles instead of calling useEuiBreakpoint
inline; update mappingsListPanelStyles to use the precomputed variable so the
hook is only called at the component top level.
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yml
Review profile: CHILL
Plan: Pro
Run ID: ffa7749f-6ba7-4ba1-bf5c-705d63664f28
📒 Files selected for processing (4)
x-pack/platform/plugins/shared/index_management/public/application/components/mappings_editor/components/document_fields/common/listItemStyle.tsx-pack/platform/plugins/shared/index_management/public/application/components/mappings_editor/components/document_fields/fields/fields_list_item.tsxx-pack/platform/plugins/shared/index_management/public/application/sections/home/index_list/details_page/details_page_mappings_content.tsxx-pack/platform/plugins/shared/index_management/public/application/sections/home/index_list/index_actions_context_menu/index_actions_context_menu.tsx
|
Hi @SoniaSanzV, looking at the issue description shouldn't the icon be inline or below the text?
|
|
Thank you @damian-polewski! Fixed with 747cb38 |
💔 Build Failed
Failed CI Steps
Test Failures
Metrics [docs]Async chunks
History
cc @SoniaSanzV |
...plication/sections/home/index_list/index_actions_context_menu/index_actions_context_menu.tsx
Outdated
Show resolved
Hide resolved
…tion/sections/home/index_list/index_actions_context_menu/index_actions_context_menu.tsx Co-authored-by: Damian Polewski <125268832+damian-polewski@users.noreply.github.com>
damian-polewski
left a comment
There was a problem hiding this comment.
Thank you for addressing my feedback! Retested the flow and everything is working as expected. LGTM!
|
Starting backport for target branches: 8.19, 9.2, 9.3 https://github.com/elastic/kibana/actions/runs/23482243167 |
Closes elastic#242866 ## Summary - Fix Index Management reflow issues at high zoom (WCAG 2.2 SC 1.4.10 Reflow): - Ensure **Manage index** popover stays within the viewport and scrolls internally instead of clipping/overflowing. - Ensure Mappings field rows wrap cleanly at 400% zoom (no crowded/overlapping layout). ### Test plan - Manual (macOS + Chrome): - Index details → Overview → open **Manage index** at 400% zoom; verify title/first item visible, no horizontal overflow, and page content remains visible while menu is open. - Index details → **Mappings** tab at 400% zoom; verify field rows wrap and icons don’t overlap text. ### Screenshots <img width="1489" height="806" alt="Screenshot 2026-03-18 at 17 27 13" src="https://github.com/user-attachments/assets/145f9efc-bf8e-4f30-a092-d2ad9cba8b11" /> <img width="1427" height="423" alt="Screenshot 2026-03-18 at 17 28 35" src="https://github.com/user-attachments/assets/ca001ce5-b71f-409c-811c-acfa9bcbb072" /> <img width="1475" height="796" alt="Screenshot 2026-03-20 at 16 40 54" src="https://github.com/user-attachments/assets/f181c689-061b-4ee0-9318-2a9e15c53894" /> **Accessibility notes** - WCAG: 1.4.10 Reflow (AA) <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit * **Bug Fixes** * Fixed layout sizing for document field mappings to improve content flow and responsiveness. * **Style** * Enhanced responsive design for the mappings list panel with improved breakpoint handling. * Improved popover positioning and styling in the index actions menu with better theme integration and dynamic resizing. * **Accessibility** * Improved semantic markup for multi-field indicators. <!-- end of auto-generated comment: release notes by coderabbit.ai --> --------- Co-authored-by: Damian Polewski <125268832+damian-polewski@users.noreply.github.com> (cherry picked from commit 5eb933c)
💔 Some backports could not be created
Note: Successful backport PRs will be merged automatically after passing CI. Manual backportTo create the backport manually run: Questions ?Please refer to the Backport tool documentation |
…9281) # Backport This will backport the following commits from `main` to `9.3`: - [[Index Management] Align elements with 400% zoom (#258405)](#258405) <!--- Backport version: 9.6.6 --> ### Questions ? Please refer to the [Backport tool documentation](https://github.com/sorenlouv/backport) <!--BACKPORT [{"author":{"name":"Sonia Sanz Vivas","email":"sonia.sanzvivas@elastic.co"},"sourceCommit":{"committedDate":"2026-03-24T09:25:41Z","message":"[Index Management] Align elements with 400% zoom (#258405)\n\nCloses https://github.com/elastic/kibana/issues/242866\n\n## Summary\n- Fix Index Management reflow issues at high zoom (WCAG 2.2 SC 1.4.10\nReflow):\n- Ensure **Manage index** popover stays within the viewport and scrolls\ninternally instead of clipping/overflowing.\n- Ensure Mappings field rows wrap cleanly at 400% zoom (no\ncrowded/overlapping layout).\n\n### Test plan\n- Manual (macOS + Chrome):\n- Index details → Overview → open **Manage index** at 400% zoom; verify\ntitle/first item visible, no horizontal overflow, and page content\nremains visible while menu is open.\n- Index details → **Mappings** tab at 400% zoom; verify field rows wrap\nand icons don’t overlap text.\n \n ### Screenshots\n<img width=\"1489\" height=\"806\" alt=\"Screenshot 2026-03-18 at 17 27 13\"\nsrc=\"https://github.com/user-attachments/assets/145f9efc-bf8e-4f30-a092-d2ad9cba8b11\"\n/>\n<img width=\"1427\" height=\"423\" alt=\"Screenshot 2026-03-18 at 17 28 35\"\nsrc=\"https://github.com/user-attachments/assets/ca001ce5-b71f-409c-811c-acfa9bcbb072\"\n/>\n<img width=\"1475\" height=\"796\" alt=\"Screenshot 2026-03-20 at 16 40 54\"\nsrc=\"https://github.com/user-attachments/assets/f181c689-061b-4ee0-9318-2a9e15c53894\"\n/>\n\n\n**Accessibility notes**\n- WCAG: 1.4.10 Reflow (AA)\n\n\n\n## Summary by CodeRabbit\n\n* **Bug Fixes**\n* Fixed layout sizing for document field mappings to improve content\nflow and responsiveness.\n\n* **Style**\n* Enhanced responsive design for the mappings list panel with improved\nbreakpoint handling.\n* Improved popover positioning and styling in the index actions menu\nwith better theme integration and dynamic resizing.\n\n* **Accessibility**\n * Improved semantic markup for multi-field indicators.\n\n\n\n---------\n\nCo-authored-by: Damian Polewski <125268832+damian-polewski@users.noreply.github.com>","sha":"5eb933c38ea8f926b9d62a882199e9c55e4479c5","branchLabelMapping":{"^v9.4.0$":"main","^v(\\d+).(\\d+).\\d+$":"$1.$2"}},"sourcePullRequest":{"labels":["Feature:Index Management","Team:Kibana Management","release_note:skip","backport:all-open","v9.4.0"],"title":"[Index Management] Align elements with 400% zoom","number":258405,"url":"https://github.com/elastic/kibana/pull/258405","mergeCommit":{"message":"[Index Management] Align elements with 400% zoom (#258405)\n\nCloses https://github.com/elastic/kibana/issues/242866\n\n## Summary\n- Fix Index Management reflow issues at high zoom (WCAG 2.2 SC 1.4.10\nReflow):\n- Ensure **Manage index** popover stays within the viewport and scrolls\ninternally instead of clipping/overflowing.\n- Ensure Mappings field rows wrap cleanly at 400% zoom (no\ncrowded/overlapping layout).\n\n### Test plan\n- Manual (macOS + Chrome):\n- Index details → Overview → open **Manage index** at 400% zoom; verify\ntitle/first item visible, no horizontal overflow, and page content\nremains visible while menu is open.\n- Index details → **Mappings** tab at 400% zoom; verify field rows wrap\nand icons don’t overlap text.\n \n ### Screenshots\n<img width=\"1489\" height=\"806\" alt=\"Screenshot 2026-03-18 at 17 27 13\"\nsrc=\"https://github.com/user-attachments/assets/145f9efc-bf8e-4f30-a092-d2ad9cba8b11\"\n/>\n<img width=\"1427\" height=\"423\" alt=\"Screenshot 2026-03-18 at 17 28 35\"\nsrc=\"https://github.com/user-attachments/assets/ca001ce5-b71f-409c-811c-acfa9bcbb072\"\n/>\n<img width=\"1475\" height=\"796\" alt=\"Screenshot 2026-03-20 at 16 40 54\"\nsrc=\"https://github.com/user-attachments/assets/f181c689-061b-4ee0-9318-2a9e15c53894\"\n/>\n\n\n**Accessibility notes**\n- WCAG: 1.4.10 Reflow (AA)\n\n\n\n## Summary by CodeRabbit\n\n* **Bug Fixes**\n* Fixed layout sizing for document field mappings to improve content\nflow and responsiveness.\n\n* **Style**\n* Enhanced responsive design for the mappings list panel with improved\nbreakpoint handling.\n* Improved popover positioning and styling in the index actions menu\nwith better theme integration and dynamic resizing.\n\n* **Accessibility**\n * Improved semantic markup for multi-field indicators.\n\n\n\n---------\n\nCo-authored-by: Damian Polewski <125268832+damian-polewski@users.noreply.github.com>","sha":"5eb933c38ea8f926b9d62a882199e9c55e4479c5"}},"sourceBranch":"main","suggestedTargetBranches":[],"targetPullRequestStates":[{"branch":"main","label":"v9.4.0","branchLabelMappingKey":"^v9.4.0$","isSourceBranch":true,"state":"MERGED","url":"https://github.com/elastic/kibana/pull/258405","number":258405,"mergeCommit":{"message":"[Index Management] Align elements with 400% zoom (#258405)\n\nCloses https://github.com/elastic/kibana/issues/242866\n\n## Summary\n- Fix Index Management reflow issues at high zoom (WCAG 2.2 SC 1.4.10\nReflow):\n- Ensure **Manage index** popover stays within the viewport and scrolls\ninternally instead of clipping/overflowing.\n- Ensure Mappings field rows wrap cleanly at 400% zoom (no\ncrowded/overlapping layout).\n\n### Test plan\n- Manual (macOS + Chrome):\n- Index details → Overview → open **Manage index** at 400% zoom; verify\ntitle/first item visible, no horizontal overflow, and page content\nremains visible while menu is open.\n- Index details → **Mappings** tab at 400% zoom; verify field rows wrap\nand icons don’t overlap text.\n \n ### Screenshots\n<img width=\"1489\" height=\"806\" alt=\"Screenshot 2026-03-18 at 17 27 13\"\nsrc=\"https://github.com/user-attachments/assets/145f9efc-bf8e-4f30-a092-d2ad9cba8b11\"\n/>\n<img width=\"1427\" height=\"423\" alt=\"Screenshot 2026-03-18 at 17 28 35\"\nsrc=\"https://github.com/user-attachments/assets/ca001ce5-b71f-409c-811c-acfa9bcbb072\"\n/>\n<img width=\"1475\" height=\"796\" alt=\"Screenshot 2026-03-20 at 16 40 54\"\nsrc=\"https://github.com/user-attachments/assets/f181c689-061b-4ee0-9318-2a9e15c53894\"\n/>\n\n\n**Accessibility notes**\n- WCAG: 1.4.10 Reflow (AA)\n\n\n\n## Summary by CodeRabbit\n\n* **Bug Fixes**\n* Fixed layout sizing for document field mappings to improve content\nflow and responsiveness.\n\n* **Style**\n* Enhanced responsive design for the mappings list panel with improved\nbreakpoint handling.\n* Improved popover positioning and styling in the index actions menu\nwith better theme integration and dynamic resizing.\n\n* **Accessibility**\n * Improved semantic markup for multi-field indicators.\n\n\n\n---------\n\nCo-authored-by: Damian Polewski <125268832+damian-polewski@users.noreply.github.com>","sha":"5eb933c38ea8f926b9d62a882199e9c55e4479c5"}}]}] BACKPORT--> Co-authored-by: Sonia Sanz Vivas <sonia.sanzvivas@elastic.co> Co-authored-by: Damian Polewski <125268832+damian-polewski@users.noreply.github.com>
Closes elastic#242866 ## Summary - Fix Index Management reflow issues at high zoom (WCAG 2.2 SC 1.4.10 Reflow): - Ensure **Manage index** popover stays within the viewport and scrolls internally instead of clipping/overflowing. - Ensure Mappings field rows wrap cleanly at 400% zoom (no crowded/overlapping layout). ### Test plan - Manual (macOS + Chrome): - Index details → Overview → open **Manage index** at 400% zoom; verify title/first item visible, no horizontal overflow, and page content remains visible while menu is open. - Index details → **Mappings** tab at 400% zoom; verify field rows wrap and icons don’t overlap text. ### Screenshots <img width="1489" height="806" alt="Screenshot 2026-03-18 at 17 27 13" src="https://github.com/user-attachments/assets/145f9efc-bf8e-4f30-a092-d2ad9cba8b11" /> <img width="1427" height="423" alt="Screenshot 2026-03-18 at 17 28 35" src="https://github.com/user-attachments/assets/ca001ce5-b71f-409c-811c-acfa9bcbb072" /> <img width="1475" height="796" alt="Screenshot 2026-03-20 at 16 40 54" src="https://github.com/user-attachments/assets/f181c689-061b-4ee0-9318-2a9e15c53894" /> **Accessibility notes** - WCAG: 1.4.10 Reflow (AA) <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit * **Bug Fixes** * Fixed layout sizing for document field mappings to improve content flow and responsiveness. * **Style** * Enhanced responsive design for the mappings list panel with improved breakpoint handling. * Improved popover positioning and styling in the index actions menu with better theme integration and dynamic resizing. * **Accessibility** * Improved semantic markup for multi-field indicators. <!-- end of auto-generated comment: release notes by coderabbit.ai --> --------- Co-authored-by: Damian Polewski <125268832+damian-polewski@users.noreply.github.com>


Closes #242866
Summary
Test plan
Screenshots
Accessibility notes
Summary by CodeRabbit
Bug Fixes
Style
Accessibility