Repository navigation
Commit f0c985d
authored
[material_ui] Don't clip MenuItemButton.leadingIcon (flutter#12986)
`_MenuItemLabel` wrapped the leading `Row` in a hard-coded `ClipRect` when `overflowAxis` is vertical, which clipped `leadingIcon` to its own bounds. This clips any decoration painting outside those bounds, such as a `Badge`.
This PR is to remove the `ClipRect` so leading icons won't be incorrectly clipped.
Fixes flutter#192732
Before
<img width="158" height="196" alt="badge_before_real" src="https://github.com/user-attachments/assets/4f1a5121-3908-4f5b-b1ea-f78803da7540" />
After
<img width="158" height="196" alt="badge_after_real" src="https://github.com/user-attachments/assets/8c302692-5dcf-40d7-92bf-111a72437cfc" />
## Pre-Review Checklist1 parent 5eb35f5 commit f0c985d
3 files changed
Lines changed: 61 additions & 16 deletions
File tree
- packages/material_ui
- lib/src
- pending_changelogs
- test
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
3327 | 3327 | | |
3328 | 3328 | | |
3329 | 3329 | | |
3330 | | - | |
3331 | | - | |
3332 | | - | |
3333 | | - | |
3334 | | - | |
3335 | | - | |
3336 | | - | |
3337 | | - | |
3338 | | - | |
3339 | | - | |
3340 | | - | |
3341 | | - | |
3342 | | - | |
3343 | | - | |
| 3330 | + | |
| 3331 | + | |
| 3332 | + | |
| 3333 | + | |
| 3334 | + | |
| 3335 | + | |
| 3336 | + | |
| 3337 | + | |
| 3338 | + | |
| 3339 | + | |
| 3340 | + | |
| 3341 | + | |
3344 | 3342 | | |
3345 | 3343 | | |
3346 | | - | |
3347 | | - | |
| 3344 | + | |
| 3345 | + | |
3348 | 3346 | | |
3349 | 3347 | | |
3350 | 3348 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
3337 | 3337 | | |
3338 | 3338 | | |
3339 | 3339 | | |
| 3340 | + | |
| 3341 | + | |
| 3342 | + | |
| 3343 | + | |
| 3344 | + | |
| 3345 | + | |
| 3346 | + | |
| 3347 | + | |
| 3348 | + | |
| 3349 | + | |
| 3350 | + | |
| 3351 | + | |
| 3352 | + | |
| 3353 | + | |
| 3354 | + | |
| 3355 | + | |
| 3356 | + | |
| 3357 | + | |
| 3358 | + | |
| 3359 | + | |
| 3360 | + | |
| 3361 | + | |
| 3362 | + | |
| 3363 | + | |
| 3364 | + | |
| 3365 | + | |
| 3366 | + | |
| 3367 | + | |
| 3368 | + | |
| 3369 | + | |
| 3370 | + | |
| 3371 | + | |
| 3372 | + | |
| 3373 | + | |
| 3374 | + | |
| 3375 | + | |
| 3376 | + | |
| 3377 | + | |
| 3378 | + | |
| 3379 | + | |
| 3380 | + | |
| 3381 | + | |
| 3382 | + | |
| 3383 | + | |
3340 | 3384 | | |
3341 | 3385 | | |
3342 | 3386 | | |
| |||
0 commit comments