Open lrkwz opened 3 years ago
I was able to "fix" this by
[
'@vuepress/medium-zoom',
{
selector: '.content__default :not(a) > img',
}
],
and
$page.path
in the GlobalLayout and using that to fire this.updateZoom() from the medium-zoom plugin
watch: {
'$page.path' () {
this.updateZoom()
},
},
Bug report
I've configured medium-zoom as documented but it doesn't work at first page load, you need to press the reload button to make it work. No errors in console
Steps to reproduce
[X] I prepared a reproduction repo, here is the reproduction repo: https://gitlab.com/lrkwz/lrkwz.gitlab.io/
[ ] This issue doesn't need a reproduction repro, here is the steps to reproduce
Demo it at https://lrkwz.gitlab.io/2021/04/02/lambrate/
What is expected?
The lents cursor should appear hovering on the images. Clicking the image should zoom it.
What is actually happening?
Cursor doesn't change shape and no click event is fired.
Other relevant information
npx vuepress info
:Environment Info:
System: OS: Linux 5.4 Ubuntu 20.04.2 LTS (Focal Fossa) CPU: (16) x64 Intel(R) Core(TM) i9-9980HK CPU @ 2.40GHz Binaries: Node: 10.23.3 - ~/.nvm/versions/node/v10.23.3/bin/node Yarn: 1.22.5 - /usr/bin/yarn npm: 6.14.11 - ~/.nvm/versions/node/v10.23.3/bin/npm Browsers: Chrome: Not Found Firefox: 87.0 npmPackages: @vuepress/core: 1.8.2 @vuepress/theme-default: 1.8.2 vuepress: ^1.8.0 => 1.8.2 npmGlobalPackages: vuepress: Not Found