Commit e5f970d
[9.2] [SideNav] Reduce re-renders on resize and items change (elastic#239888) (elastic#240884)
# Backport
This will backport the following commits from `main` to `9.2`:
- [[SideNav] Reduce re-renders on resize and items change
(elastic#239888)](elastic#239888)
<!--- Backport version: 9.6.6 -->
### Questions ?
Please refer to the [Backport tool
documentation](https://github.com/sorenlouv/backport)
<!--BACKPORT [{"author":{"name":"Anton
Dosov","email":"[email protected]"},"sourceCommit":{"committedDate":"2025-10-27T18:10:49Z","message":"[SideNav]
Reduce re-renders on resize and items change (elastic#239888)\n\n##
Summary\n\nResolves https://github.com/elastic/kibana/issues/239331\n\nI
noticed that when nav present the window resizing becomes
sluggish.\nThis was caused by height recalcs in resize observable. it is
especially\nnoticeable on 4x slowdown.\n\nRe-renders before (see just
number of renders around the
nav)\n\n\nhttps://github.com/user-attachments/assets/4bf99d8d-eeca-4a5b-8e3f-578b20c0e4e3\n\nRe-renders
after (see just number of renders around the
nav)\n\n\nhttps://github.com/user-attachments/assets/db68007b-792e-499c-bcb0-259a3cd433c9\n\n---------\n\nCo-authored-by:
Weronika Olejniczak
<[email protected]>\nCo-authored-by:
kibanamachine
<[email protected]>","sha":"29b3a5d8fb82723ab94b5d85f5c248808e737be4","branchLabelMapping":{"^v9.3.0$":"main","^v(\\d+).(\\d+).\\d+$":"$1.$2"}},"sourcePullRequest":{"labels":["release_note:fix","Team:SharedUX","backport:version","v9.2.0","v9.3.0"],"title":"[SideNav]
Reduce re-renders on resize and items change
","number":239888,"url":"https://github.com/elastic/kibana/pull/239888","mergeCommit":{"message":"[SideNav]
Reduce re-renders on resize and items change (elastic#239888)\n\n##
Summary\n\nResolves https://github.com/elastic/kibana/issues/239331\n\nI
noticed that when nav present the window resizing becomes
sluggish.\nThis was caused by height recalcs in resize observable. it is
especially\nnoticeable on 4x slowdown.\n\nRe-renders before (see just
number of renders around the
nav)\n\n\nhttps://github.com/user-attachments/assets/4bf99d8d-eeca-4a5b-8e3f-578b20c0e4e3\n\nRe-renders
after (see just number of renders around the
nav)\n\n\nhttps://github.com/user-attachments/assets/db68007b-792e-499c-bcb0-259a3cd433c9\n\n---------\n\nCo-authored-by:
Weronika Olejniczak
<[email protected]>\nCo-authored-by:
kibanamachine
<[email protected]>","sha":"29b3a5d8fb82723ab94b5d85f5c248808e737be4"}},"sourceBranch":"main","suggestedTargetBranches":["9.2"],"targetPullRequestStates":[{"branch":"9.2","label":"v9.2.0","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"},{"branch":"main","label":"v9.3.0","branchLabelMappingKey":"^v9.3.0$","isSourceBranch":true,"state":"MERGED","url":"https://github.com/elastic/kibana/pull/239888","number":239888,"mergeCommit":{"message":"[SideNav]
Reduce re-renders on resize and items change (elastic#239888)\n\n##
Summary\n\nResolves https://github.com/elastic/kibana/issues/239331\n\nI
noticed that when nav present the window resizing becomes
sluggish.\nThis was caused by height recalcs in resize observable. it is
especially\nnoticeable on 4x slowdown.\n\nRe-renders before (see just
number of renders around the
nav)\n\n\nhttps://github.com/user-attachments/assets/4bf99d8d-eeca-4a5b-8e3f-578b20c0e4e3\n\nRe-renders
after (see just number of renders around the
nav)\n\n\nhttps://github.com/user-attachments/assets/db68007b-792e-499c-bcb0-259a3cd433c9\n\n---------\n\nCo-authored-by:
Weronika Olejniczak
<[email protected]>\nCo-authored-by:
kibanamachine
<[email protected]>","sha":"29b3a5d8fb82723ab94b5d85f5c248808e737be4"}}]}]
BACKPORT-->
Co-authored-by: Anton Dosov <[email protected]>
Co-authored-by: Weronika Olejniczak <[email protected]>1 parent 8636e4f commit e5f970d
File tree
5 files changed
+174
-88
lines changed5 files changed
+174
-88
lines changedLines changed: 17 additions & 15 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
510 | 510 | | |
511 | 511 | | |
512 | 512 | | |
513 | | - | |
514 | | - | |
515 | | - | |
| 513 | + | |
| 514 | + | |
| 515 | + | |
| 516 | + | |
516 | 517 | | |
517 | | - | |
| 518 | + | |
| 519 | + | |
518 | 520 | | |
519 | 521 | | |
520 | 522 | | |
| |||
559 | 561 | | |
560 | 562 | | |
561 | 563 | | |
562 | | - | |
| 564 | + | |
563 | 565 | | |
564 | 566 | | |
565 | 567 | | |
| |||
602 | 604 | | |
603 | 605 | | |
604 | 606 | | |
605 | | - | |
| 607 | + | |
606 | 608 | | |
607 | 609 | | |
608 | 610 | | |
| |||
644 | 646 | | |
645 | 647 | | |
646 | 648 | | |
647 | | - | |
| 649 | + | |
648 | 650 | | |
649 | 651 | | |
650 | 652 | | |
| |||
1294 | 1296 | | |
1295 | 1297 | | |
1296 | 1298 | | |
1297 | | - | |
| 1299 | + | |
1298 | 1300 | | |
1299 | 1301 | | |
1300 | 1302 | | |
| |||
1335 | 1337 | | |
1336 | 1338 | | |
1337 | 1339 | | |
1338 | | - | |
| 1340 | + | |
1339 | 1341 | | |
1340 | 1342 | | |
1341 | 1343 | | |
| |||
1365 | 1367 | | |
1366 | 1368 | | |
1367 | 1369 | | |
1368 | | - | |
| 1370 | + | |
1369 | 1371 | | |
1370 | 1372 | | |
1371 | 1373 | | |
| |||
1399 | 1401 | | |
1400 | 1402 | | |
1401 | 1403 | | |
1402 | | - | |
| 1404 | + | |
1403 | 1405 | | |
1404 | 1406 | | |
1405 | 1407 | | |
| |||
1435 | 1437 | | |
1436 | 1438 | | |
1437 | 1439 | | |
1438 | | - | |
| 1440 | + | |
1439 | 1441 | | |
1440 | 1442 | | |
1441 | 1443 | | |
| |||
1471 | 1473 | | |
1472 | 1474 | | |
1473 | 1475 | | |
1474 | | - | |
| 1476 | + | |
1475 | 1477 | | |
1476 | 1478 | | |
1477 | 1479 | | |
| |||
1538 | 1540 | | |
1539 | 1541 | | |
1540 | 1542 | | |
1541 | | - | |
| 1543 | + | |
1542 | 1544 | | |
1543 | 1545 | | |
1544 | 1546 | | |
| |||
1574 | 1576 | | |
1575 | 1577 | | |
1576 | 1578 | | |
1577 | | - | |
| 1579 | + | |
1578 | 1580 | | |
1579 | 1581 | | |
1580 | 1582 | | |
| |||
Lines changed: 6 additions & 6 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
386 | 386 | | |
387 | 387 | | |
388 | 388 | | |
389 | | - | |
| 389 | + | |
390 | 390 | | |
391 | 391 | | |
392 | 392 | | |
393 | 393 | | |
394 | 394 | | |
395 | | - | |
| 395 | + | |
396 | 396 | | |
397 | 397 | | |
398 | 398 | | |
| |||
410 | 410 | | |
411 | 411 | | |
412 | 412 | | |
413 | | - | |
| 413 | + | |
414 | 414 | | |
415 | 415 | | |
416 | 416 | | |
| |||
440 | 440 | | |
441 | 441 | | |
442 | 442 | | |
443 | | - | |
| 443 | + | |
444 | 444 | | |
445 | 445 | | |
446 | 446 | | |
| |||
491 | 491 | | |
492 | 492 | | |
493 | 493 | | |
494 | | - | |
| 494 | + | |
495 | 495 | | |
496 | 496 | | |
497 | 497 | | |
| |||
539 | 539 | | |
540 | 540 | | |
541 | 541 | | |
542 | | - | |
| 542 | + | |
543 | 543 | | |
544 | 544 | | |
545 | 545 | | |
| |||
Lines changed: 4 additions & 4 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
385 | 385 | | |
386 | 386 | | |
387 | 387 | | |
388 | | - | |
| 388 | + | |
389 | 389 | | |
390 | 390 | | |
391 | 391 | | |
| |||
421 | 421 | | |
422 | 422 | | |
423 | 423 | | |
424 | | - | |
| 424 | + | |
425 | 425 | | |
426 | 426 | | |
427 | 427 | | |
| |||
490 | 490 | | |
491 | 491 | | |
492 | 492 | | |
493 | | - | |
| 493 | + | |
494 | 494 | | |
495 | 495 | | |
496 | 496 | | |
| |||
538 | 538 | | |
539 | 539 | | |
540 | 540 | | |
541 | | - | |
| 541 | + | |
542 | 542 | | |
543 | 543 | | |
544 | 544 | | |
| |||
Lines changed: 44 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
0 commit comments