Skip to content

Commit

Permalink
fix: viewer
Browse files Browse the repository at this point in the history
  • Loading branch information
lh1me committed Oct 8, 2021
1 parent 27817ef commit dc48781
Showing 1 changed file with 9 additions and 4 deletions.
13 changes: 9 additions & 4 deletions source/javascripts/custom.js
Original file line number Diff line number Diff line change
Expand Up @@ -218,9 +218,6 @@ import { addNewClass, removeClass, throttle } from './class-module'
next: true,
},
keyboard: false,
url(image) {
return image.dataset.original
},
}
const galleryViewer = $('.article-gallery')
if (galleryViewer && galleryViewer.length > 0) {
Expand All @@ -232,7 +229,15 @@ import { addNewClass, removeClass, throttle } from './class-module'
}
const photographyViewer = $('.photography-item')
if (photographyViewer && photographyViewer.length > 0) {
photographyViewer.viewer(viewerConfig)
const temp = Object.assign(
{
url(image) {
return image.dataset.original
},
},
viewerConfig
)
photographyViewer.viewer(temp)
}

// Plyr
Expand Down

0 comments on commit dc48781

Please sign in to comment.