Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Dialog doesn't render in Responsive when loaded from mobile view #5662

Closed
dinohorvat opened this issue May 1, 2018 · 1 comment
Closed
Assignees
Labels
Type: Bug Issue contains a bug related to a specific component. Something about the component is not working
Milestone

Comments

@dinohorvat
Copy link

dinohorvat commented May 1, 2018

I'm filling the content of dynamically when ever I press some button. It works smooth, how ever if I open my application in responsive mode (mobile view), the dialog will not be rendered as responsive.

<p-dialog appendTo="body" header="{{selectedResult.attacktype1_txt}}" [(visible)]="display" modal="modal" [responsive]="true"
          [width]="800" [minWidth]="200" [minY]="70">

screen shot 2018-05-01 at 19 03 01

If I would resize the window, the dialog would instantly render correctly.
I've fixed the problem by triggering the resize event.

  showDialog() {
    this.display = true;
    setTimeout(function(){
      window.dispatchEvent(new Event('resize'));
      }, 1);
  }

It's definitely something to take a look at.

@dinohorvat dinohorvat changed the title Dialog doesn't trigger Responsive when loaded from mobile view Dialog doesn't render in Responsive when loaded from mobile view May 1, 2018
@jsilveira2
Copy link

Same problem for me. If someone has a solution, please share it.

@cagataycivici cagataycivici self-assigned this Dec 26, 2018
@cagataycivici cagataycivici added the Type: Bug Issue contains a bug related to a specific component. Something about the component is not working label Dec 26, 2018
@cagataycivici cagataycivici added this to the 7.0.4 milestone Dec 26, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Type: Bug Issue contains a bug related to a specific component. Something about the component is not working
Projects
None yet
Development

No branches or pull requests

3 participants