Skip to content

Expansion panel FOUC when contained in dialog #13870

Description

@SamuelMS

I'm submitting a...


[x] Regression (a behavior that used to work and stopped working in a new release)
[ ] Bug report  
[ ] Performance issue
[ ] Feature request
[ ] Documentation issue or request
[ ] Support request => Please do not submit support request here, instead see https://github.com/angular/angular/blob/master/CONTRIBUTING.md#question
[ ] Other... Please describe:

Current behavior

Expansion panels currently render with a flash of unstyled content (FOUC) when nested in a dialog -- they always temporarily appear as expanded, regardless of what the "expanded" attribute is set to. After a moment, all expansion panels that have been explicitly set to closed collapse.

This only occurs in Angular / Material 7.

Expected behavior

Expansion panels should appear as collapsed when the dialog opens when expanded=false instead of briefly appearing as expanded, then collapsing after a delay.

Minimal reproduction of the problem with instructions

Click the button and note the flash of unstyled content in the dialog in Angular 7.

Angular 7 (bugged): https://angular-egzwfw.stackblitz.io
Angular 6 (correct): https://angular-eepzxs.stackblitz.io

What is the motivation / use case for changing the behavior?

Flashes of unstyled content are jarring and feel very buggy.

Environment


Angular version: 7.0.1
Material version: 7.0.2
TypeScript: 3.1.1


Browser:
- [x] Chrome (desktop) version XX
- [ ] Chrome (Android) version XX
- [ ] Chrome (iOS) version XX
- [x] Firefox version XX
- [x] Safari (desktop) version XX
- [ ] Safari (iOS) version XX
- [ ] IE version XX
- [ ] Edge version XX

Activity

  1. added
    P4
    animation
    on Oct 30, 2018
  2. crisbeto commented on Oct 30, 2018

    @crisbeto
    Member

    Might potentially be solved by #11778.

  3. crisbeto commented on Oct 30, 2018

    @crisbeto
    Member

    I tried it out and it doesn't look like it'll be fixed by #11778.

  4. added a commit that references this issue on Oct 30, 2018
    6fa7c18
  5. self-assigned this
    on Oct 30, 2018
  6. added a commit that references this issue on Nov 3, 2018
    235add9
  7. added a commit that references this issue on Nov 5, 2018
    c8ec073
  8. added a commit that references this issue on Nov 6, 2018
    e5afa48
  9. josephperrott commented on Nov 20, 2018

    @josephperrott
    Member

    Reopening as the fix was reverted.

    This seems to be a larger issue across our library as our components use animations to set state quite frequently.

  10. crisbeto commented on Nov 20, 2018

    @crisbeto
    Member

    @josephperrott I've opened #14127 which should fix the issue and avoid the presubmit issues.

  11. 33 remaining items

  12. vgt-benjaminh commented on Dec 8, 2021

    @vgt-benjaminh

    Also happens when the expansion panel is placed inside a stepper using Angular Material 11.2.13

  13. pranav-js commented on Feb 14, 2022

    @pranav-js

    give this issue some attention please. this is serious glitch and I spent so much time thinking I was doing something wrong! but it seems to be there since 2018!

  14. steffenhees commented on Feb 20, 2022

    @steffenhees

    If this is not fixed yet, please fix it!!! Thank you!!!

    Had the same problem. With the workaround from @dcrouch79 it works for now. Thanks!

  15. added
    P2
    and removed
    P4
    on Mar 6, 2022
  16. added 2 commits that reference this issue on Mar 6, 2022
    2cc2083
    8ec5832
  17. added 2 commits that reference this issue on Mar 6, 2022
    6ee0089
    5edcc68
  18. added a commit that references this issue on Apr 3, 2022
    843e145
  19. angular-automatic-lock-bot commented on Apr 6, 2022

    @angular-automatic-lock-bot

    This issue has been automatically locked due to inactivity.
    Please file a new issue if you are encountering a similar or related problem.

    Read more about our automatic conversation locking policy.

    This action has been performed automatically by a bot.

  20. locked and limited conversation to collaborators on Apr 6, 2022
  21. added a commit that references this issue on Nov 5, 2026
    cd44252
  22. added a commit that references this issue on Nov 20, 2026
    47ba993
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

P2animationarea: material/dialogarea: material/expansion

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions