Add wrapper element in markup #1995
Unanswered
silentbugs
asked this question in
Q&A
Replies: 1 comment
-
|
You'll need to either entirely override the content, as shown here https://photoswipe.com/custom-content/ Or you can preventDefault |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
I'm trying to add an element between
pswp__zoom-wrapandpswp__imgelements, so that I can style it and position it since styling/positioning thepswp__zoom-wrapelement seems to break some things.Is there some easy way to do this without providing an entirely custom markup?
My approach (possibly bad):
I tried to use
loadCompleteevent and append all elements (currently just thepswp__imgelement) ofslide.containerto another element, and then append that element toslide.container.This seems to work fine within the callback function of the
loadCompleteevent, but as soon as photoswipe fully loads, the child element ofpswp__slide-wrapperbecomes its sibling.During
loadComplete:After
loadComplete:Beta Was this translation helpful? Give feedback.
All reactions