updates readme

This commit is contained in:
buttle 2021-04-19 16:28:59 +02:00
parent b717d24c9e
commit d88f3edc0c
2 changed files with 6 additions and 3 deletions

View File

@ -1,7 +1,8 @@
# ImageViewer media for Omeka S
[ImageViewer] is a module for [Omeka S] that optionally enables [wheelzoom],
a script for zooming IMG elements with the mousewheel/trackpad.
a script for zooming IMG elements with the mousewheel/trackpad and [zoom],
a script to enlarge images on touch, click, or mouseover.
## Install
@ -18,6 +19,7 @@ The module is released under the [MIT] License.
[arc-hive]: https://arc-hive.zone/
[wheelzoom]: https://github.com/jackmoore/wheelzoom
[zoom]: https://github.com/jackmoore/zoom
[Omeka S]: https://omeka.org/s
[ImageViewer]: https://git.hangar.org/arcHIVE-tech/ImageViewer
[MIT]: http://opensource.org/licenses/MIT

View File

@ -8,12 +8,13 @@
if ($zoom_type == "zoom") {
$this->headScript()->appendFile($this->assetUrl('vendor/zoom/jquery.zoom.min.js',
'ImageViewer'));
}
if ($zoom_type == "zoom" || $zoom_type == "wheelzoom") {
$this->headLink()->appendStylesheet($this->assetUrl('css/zoom.css',
'ImageViewer'));
}
?>
<?php
if ($title !== false && $title !== "") {
$title = sprintf('<p id="wheelzoom-title">%s</p>', $title);
@ -29,7 +30,7 @@
</div>
<script>
$(document).ready(function(){
$('#<?= $id ?>').zoom({on:'grab', 'duration': 200});
$('#<?= $id ?>').zoom({on:'grab', 'duration': 200, 'magnify': 1.5});
});
</script>
<?php } ?>