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

Instant loading makes print dialog autoclose #2261

Closed
5 tasks done
majkinetor opened this issue Jan 31, 2021 · 9 comments
Closed
5 tasks done

Instant loading makes print dialog autoclose #2261

majkinetor opened this issue Jan 31, 2021 · 9 comments
Labels
bug Issue reports a bug resolved Issue is resolved, yet unreleased if open

Comments

@majkinetor
Copy link
Contributor

majkinetor commented Jan 31, 2021

When I add navigation.instant theme option CTRL + P dialog closes on any page. The problem is gone when I remove that option.

To reproduce

  1. Go to https://majkinetor.github.io/mm-docs-template/
  2. Hit CTRL + P wait 2 seconds
  3. Print dialog should close by itself

Sometimes CTRL + P works the first time but just hitting F5 or ctrl + F5 and then doing it again can change the outcome.

  • I've read the [contribution guidelines][1] and agree with them

I've found a bug and checked that ...

  • ... the problem doesn't occur with the default MkDocs template
  • ... the problem is not in any of my customizations (CSS, JS, template)
  • ... the documentation does not mention anything about my problem
  • ... there are no open or closed issues that are related to my problem

Package versions

  • Python: 3.6
  • MkDocs: 1.1.2
  • Material: 6.2.6

Project configuration

System information

  • Windows 10 10.0.19042 N/A Build 19042
  • Chrome 88.0.4324.104 (sometimes work, mostly doesn't)
  • Edge 88.0.705.56 (never works)
@squidfunk squidfunk added the needs investigation Issue must be investigated by the maintainers label Feb 1, 2021
@squidfunk
Copy link
Owner

Please provide more details - browser, operating system..., basically everything that is listed in the issue template. It does not reproduce in Chrome 88 on macOS.

@squidfunk squidfunk added needs input Issue needs further input by the reporter needs reproduction Issue lacks a minimal reproduction .zip file and removed needs investigation Issue must be investigated by the maintainers labels Feb 1, 2021
@majkinetor
Copy link
Contributor Author

Sorry for being hasty. Added everything in original post, and animated gif.

@squidfunk
Copy link
Owner

So it seems that this only happens when you activate instant loading, load the page and hit CMD+P immediately. As soon as you navigate and instant loading kicks in, the print modal remains open (at least for me). Can you confirm?

@squidfunk squidfunk added bug Issue reports a bug and removed needs input Issue needs further input by the reporter needs reproduction Issue lacks a minimal reproduction .zip file labels Feb 2, 2021
@squidfunk
Copy link
Owner

squidfunk commented Feb 2, 2021

Potential fix in e3c608a. Interestingly it seems to be related to scroll restoration. Could you check the latest master?

@squidfunk squidfunk added the resolved Issue is resolved, yet unreleased if open label Feb 2, 2021
@majkinetor
Copy link
Contributor Author

majkinetor commented Feb 2, 2021

So it seems that this only happens when you activate instant loading, load the page and hit CMD+P immediately. As soon as you navigate and instant loading kicks in, the print modal remains open (at least for me). Can you confirm?

No. Any time, no matter how long I am on the page, after I CTRL + P it gets shut down ASAP. If it doesn't happen the first time, I CTRL + F5, then it happens.

Could you check the latest master?

I can't do it fast but can get you back on that later (I keep all this in container its not that easy to just pip it from github.

@squidfunk
Copy link
Owner

No worries. If you can verify before the weekend, that would be awesome, as the fix would be part of the next release.

@majkinetor
Copy link
Contributor Author

No problem. Thanks.

@majkinetor
Copy link
Contributor Author

I can confirm that master works.

@squidfunk
Copy link
Owner

Released as part of 6.2.8!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment