kibana/examples/grid_example/public
Kibana Machine 56c022371e
[8.x] [kbn-grid-layout][dashboard] Basic keyboard interaction (#208286) (#216603)
# Backport

This will backport the following commits from `main` to `8.x`:
- [[kbn-grid-layout][dashboard] Basic keyboard interaction
(#208286)](https://github.com/elastic/kibana/pull/208286)

<!--- Backport version: 9.6.6 -->

### Questions ?
Please refer to the [Backport tool
documentation](https://github.com/sorenlouv/backport)

<!--BACKPORT [{"author":{"name":"Marta
Bondyra","email":"4283304+mbondyra@users.noreply.github.com"},"sourceCommit":{"committedDate":"2025-04-01T09:29:02Z","message":"[kbn-grid-layout][dashboard]
Basic keyboard interaction (#208286)\n\n## Summary\nAdds keyboard
navigation for drag-and-drop interactions\nFixes
https://github.com/elastic/kibana/issues/211925\nFixes
https://github.com/elastic/kibana/issues/190448\n\n### Supported
features \n1. Resize
panels\n\n\nhttps://github.com/user-attachments/assets/ba7add16-a0c6-4f15-9f3b-0f8ef7caf8ac\n\n2.
Drag panels within the same section (dragging between sections
is\npending)\n\n\nhttps://github.com/user-attachments/assets/a1fd80af-63ca-4fa2-bded-3db9968a8366\n\n3.
Move rows
up/down\n\n\nhttps://github.com/user-attachments/assets/8d7e8d7d-b1bf-4abe-9cc2-28eeea9b43f8\n\n###
Interaction Flow\n\n1. Start interaction with `Space` or `Enter`\n2.
Move using arrow keys\n3. Finish by confirming (`Enter`/`Space`) or
canceling (`Escape`)\n(blurring also confirms the changes)\n\n###
Scrolling Behavior:\n* Default browser scrolling is disabled in
interaction mode to avoid\nunexpected behavior and edge cases that would
overcomplicate this simple\nimplementation.\n* Scrolling occurs when the
user reaches the edge of the screen while\nresizing or dragging,
allowing them to continue the interaction\nsmoothly.\n* When the
operation is confirmed, we also scroll to the element to make\nsure it's
in view.\n\n### Missing (planned for another PR):\n* A11y announcements
\n* Dragging between sections\n* This feature is not well unit-tested,
but it's very difficult to do it\nwithout mocking the crucial pieces of
functionality. I'd vote to leave\nit for now and add a few functional
tests once we decide a strategy for\nit, since drag and drop
interactions are anyway quite difficult to\nunit-test reliably
anyway.\n\n---------\n\nCo-authored-by: kibanamachine
<42973632+kibanamachine@users.noreply.github.com>","sha":"f5b185a28f9b1af41ca6a36f010b50b470e34ddb","branchLabelMapping":{"^v9.1.0$":"main","^v8.19.0$":"8.x","^v(\\d+).(\\d+).\\d+$":"$1.$2"}},"sourcePullRequest":{"labels":["Feature:Dashboard","Team:Presentation","loe:large","impact:medium","release_note:feature","Project:Collapsable
Panels","backport:version","v9.1.0","v8.19.0"],"title":"[kbn-grid-layout][dashboard]
Basic keyboard
interaction","number":208286,"url":"https://github.com/elastic/kibana/pull/208286","mergeCommit":{"message":"[kbn-grid-layout][dashboard]
Basic keyboard interaction (#208286)\n\n## Summary\nAdds keyboard
navigation for drag-and-drop interactions\nFixes
https://github.com/elastic/kibana/issues/211925\nFixes
https://github.com/elastic/kibana/issues/190448\n\n### Supported
features \n1. Resize
panels\n\n\nhttps://github.com/user-attachments/assets/ba7add16-a0c6-4f15-9f3b-0f8ef7caf8ac\n\n2.
Drag panels within the same section (dragging between sections
is\npending)\n\n\nhttps://github.com/user-attachments/assets/a1fd80af-63ca-4fa2-bded-3db9968a8366\n\n3.
Move rows
up/down\n\n\nhttps://github.com/user-attachments/assets/8d7e8d7d-b1bf-4abe-9cc2-28eeea9b43f8\n\n###
Interaction Flow\n\n1. Start interaction with `Space` or `Enter`\n2.
Move using arrow keys\n3. Finish by confirming (`Enter`/`Space`) or
canceling (`Escape`)\n(blurring also confirms the changes)\n\n###
Scrolling Behavior:\n* Default browser scrolling is disabled in
interaction mode to avoid\nunexpected behavior and edge cases that would
overcomplicate this simple\nimplementation.\n* Scrolling occurs when the
user reaches the edge of the screen while\nresizing or dragging,
allowing them to continue the interaction\nsmoothly.\n* When the
operation is confirmed, we also scroll to the element to make\nsure it's
in view.\n\n### Missing (planned for another PR):\n* A11y announcements
\n* Dragging between sections\n* This feature is not well unit-tested,
but it's very difficult to do it\nwithout mocking the crucial pieces of
functionality. I'd vote to leave\nit for now and add a few functional
tests once we decide a strategy for\nit, since drag and drop
interactions are anyway quite difficult to\nunit-test reliably
anyway.\n\n---------\n\nCo-authored-by: kibanamachine
<42973632+kibanamachine@users.noreply.github.com>","sha":"f5b185a28f9b1af41ca6a36f010b50b470e34ddb"}},"sourceBranch":"main","suggestedTargetBranches":["8.x"],"targetPullRequestStates":[{"branch":"main","label":"v9.1.0","branchLabelMappingKey":"^v9.1.0$","isSourceBranch":true,"state":"MERGED","url":"https://github.com/elastic/kibana/pull/208286","number":208286,"mergeCommit":{"message":"[kbn-grid-layout][dashboard]
Basic keyboard interaction (#208286)\n\n## Summary\nAdds keyboard
navigation for drag-and-drop interactions\nFixes
https://github.com/elastic/kibana/issues/211925\nFixes
https://github.com/elastic/kibana/issues/190448\n\n### Supported
features \n1. Resize
panels\n\n\nhttps://github.com/user-attachments/assets/ba7add16-a0c6-4f15-9f3b-0f8ef7caf8ac\n\n2.
Drag panels within the same section (dragging between sections
is\npending)\n\n\nhttps://github.com/user-attachments/assets/a1fd80af-63ca-4fa2-bded-3db9968a8366\n\n3.
Move rows
up/down\n\n\nhttps://github.com/user-attachments/assets/8d7e8d7d-b1bf-4abe-9cc2-28eeea9b43f8\n\n###
Interaction Flow\n\n1. Start interaction with `Space` or `Enter`\n2.
Move using arrow keys\n3. Finish by confirming (`Enter`/`Space`) or
canceling (`Escape`)\n(blurring also confirms the changes)\n\n###
Scrolling Behavior:\n* Default browser scrolling is disabled in
interaction mode to avoid\nunexpected behavior and edge cases that would
overcomplicate this simple\nimplementation.\n* Scrolling occurs when the
user reaches the edge of the screen while\nresizing or dragging,
allowing them to continue the interaction\nsmoothly.\n* When the
operation is confirmed, we also scroll to the element to make\nsure it's
in view.\n\n### Missing (planned for another PR):\n* A11y announcements
\n* Dragging between sections\n* This feature is not well unit-tested,
but it's very difficult to do it\nwithout mocking the crucial pieces of
functionality. I'd vote to leave\nit for now and add a few functional
tests once we decide a strategy for\nit, since drag and drop
interactions are anyway quite difficult to\nunit-test reliably
anyway.\n\n---------\n\nCo-authored-by: kibanamachine
<42973632+kibanamachine@users.noreply.github.com>","sha":"f5b185a28f9b1af41ca6a36f010b50b470e34ddb"}},{"branch":"8.x","label":"v8.19.0","branchLabelMappingKey":"^v8.19.0$","isSourceBranch":false,"state":"NOT_CREATED"}]}]
BACKPORT-->

Co-authored-by: Marta Bondyra <4283304+mbondyra@users.noreply.github.com>
2025-04-02 11:45:24 +01:00
..
app.tsx [8.x] [kbn-grid-layout][dashboard] Basic keyboard interaction (#208286) (#216603) 2025-04-02 11:45:24 +01:00
get_panel_id.tsx [8.x] Preparation for High Contrast Mode, Analytics Experience domains (#202608) (#204120) 2024-12-12 15:08:55 -06:00
grid_layout_options.tsx [8.x] [kbn-grid-layout] Add ability to create, edit, and delete rows (#209193) (#212307) 2025-02-24 22:16:26 +00:00
index.ts Adds AGPL 3.0 license (#192025) 2024-09-06 19:02:41 -06:00
logs_dashboard_panels.json [8.x] [kbn-grid-layout] Store rows in object instead of array (#212965) (#213162) 2025-03-04 23:30:11 +01:00
plugin.ts [8.x] [Dashboard] [Collapsable Panels] Add embeddable support (#198413) (#203652) 2024-12-10 13:12:29 -06:00
serialized_grid_layout.ts [8.x] [kbn-grid-layout] Store rows in object instead of array (#212965) (#213162) 2025-03-04 23:30:11 +01:00
types.ts [8.x] [kbn-grid-layout] Store rows in object instead of array (#212965) (#213162) 2025-03-04 23:30:11 +01:00
use_mock_dashboard_api.tsx [8.x] [kbn-grid-layout] Store rows in object instead of array (#212965) (#213162) 2025-03-04 23:30:11 +01:00
utils.ts [8.x] [kbn-grid-layout] Store rows in object instead of array (#212965) (#213162) 2025-03-04 23:30:11 +01:00