From dc0b02889a881965a145aaf9e904c02b09d5153f Mon Sep 17 00:00:00 2001 From: nzbin Date: Fri, 19 Oct 2018 23:36:30 +0800 Subject: [PATCH] chore(release): v1.3.0 --- dist/jquery.magnify.css | 108 +++++++++++++++++++++++++++++--- dist/jquery.magnify.css.map | 2 +- dist/jquery.magnify.js | 2 +- dist/jquery.magnify.min.css | 4 +- dist/jquery.magnify.min.css.map | 2 +- dist/jquery.magnify.min.js | 6 +- docs/css/jquery.magnify.css | 108 +++++++++++++++++++++++++++++--- docs/js/jquery.magnify.js | 2 +- package.json | 2 +- src/js/intro.js | 2 +- src/sass/magnify.scss | 2 +- 11 files changed, 212 insertions(+), 28 deletions(-) diff --git a/dist/jquery.magnify.css b/dist/jquery.magnify.css index 2fa39b4..845ad4d 100644 --- a/dist/jquery.magnify.css +++ b/dist/jquery.magnify.css @@ -6,7 +6,7 @@ * | | | | _ | \_/ | |\ |_| |_| | | | * |__| |__|__| |__|\____/|_|__| \__|_____|__| |__| * - * jquery.magnify - v1.2.0 + * jquery.magnify - v1.3.0 * A jQuery plugin to view images just like in windows * https://github.com/nzbin/magnify#readme * @@ -21,7 +21,8 @@ height: 320px; background-color: #111; background-color: rgba(0, 0, 0, 0.85); - box-shadow: 0 0 3px 1px rgba(0, 0, 0, 0.3); + -webkit-box-shadow: 0 0 3px 1px rgba(0, 0, 0, 0.3); + box-shadow: 0 0 3px 1px rgba(0, 0, 0, 0.3); cursor: default; } @@ -54,7 +55,10 @@ line-height: 1; white-space: nowrap; text-overflow: ellipsis; - user-select: none; + -webkit-user-select: none; + -moz-user-select: none; + -ms-user-select: none; + user-select: none; overflow: hidden; } @@ -101,7 +105,8 @@ display: inline-block; width: 40px; height: 40px; - box-sizing: border-box; + -webkit-box-sizing: border-box; + box-sizing: border-box; margin: 0; padding: 10px; font-size: 14px; @@ -158,12 +163,14 @@ position: relative; width: 36px; height: 36px; - box-sizing: border-box; + -webkit-box-sizing: border-box; + box-sizing: border-box; border-width: 5px; border-style: solid; border-color: rgba(0, 0, 0, 0.5) rgba(0, 0, 0, 0.5) rgba(0, 0, 0, 0.5) rgba(255, 255, 255, 0.5); border-radius: 100%; - animation: magnifyLoading 1s infinite linear; + -webkit-animation: magnifyLoading 1s infinite linear; + animation: magnifyLoading 1s infinite linear; } .magnify-loader::after { @@ -175,12 +182,25 @@ overflow: hidden; } +@-webkit-keyframes magnifyLoading { + 0% { + -webkit-transform: rotateZ(0deg) translate3d(0, 0, 0); + transform: rotateZ(0deg) translate3d(0, 0, 0); + } + 100% { + -webkit-transform: rotateZ(360deg) translate3d(0, 0, 0); + transform: rotateZ(360deg) translate3d(0, 0, 0); + } +} + @keyframes magnifyLoading { 0% { - transform: rotateZ(0deg) translate3d(0, 0, 0); + -webkit-transform: rotateZ(0deg) translate3d(0, 0, 0); + transform: rotateZ(0deg) translate3d(0, 0, 0); } 100% { - transform: rotateZ(360deg) translate3d(0, 0, 0); + -webkit-transform: rotateZ(360deg) translate3d(0, 0, 0); + transform: rotateZ(360deg) translate3d(0, 0, 0); } } @@ -353,6 +373,27 @@ background-color: #000; } +:-webkit-full-screen { + top: 0 !important; + left: 0 !important; + width: 100% !important; + height: 100% !important; +} + +:-moz-full-screen { + top: 0 !important; + left: 0 !important; + width: 100% !important; + height: 100% !important; +} + +:-ms-fullscreen { + top: 0 !important; + left: 0 !important; + width: 100% !important; + height: 100% !important; +} + :fullscreen { top: 0 !important; left: 0 !important; @@ -360,12 +401,57 @@ height: 100% !important; } +:-webkit-full-screen .magnify-header, +:-webkit-full-screen .magnify-footer, +:-webkit-full-screen .magnify-resizable-handle { + display: none; +} + +:-moz-full-screen .magnify-header, +:-moz-full-screen .magnify-footer, +:-moz-full-screen .magnify-resizable-handle { + display: none; +} + +:-ms-fullscreen .magnify-header, +:-ms-fullscreen .magnify-footer, +:-ms-fullscreen .magnify-resizable-handle { + display: none; +} + :fullscreen .magnify-header, :fullscreen .magnify-footer, :fullscreen .magnify-resizable-handle { display: none; } +:-webkit-full-screen .magnify-stage { + top: 0; + right: 0; + bottom: 0; + left: 0; + border-width: 0; + background-color: #000; +} + +:-moz-full-screen .magnify-stage { + top: 0; + right: 0; + bottom: 0; + left: 0; + border-width: 0; + background-color: #000; +} + +:-ms-fullscreen .magnify-stage { + top: 0; + right: 0; + bottom: 0; + left: 0; + border-width: 0; + background-color: #000; +} + :fullscreen .magnify-stage { top: 0; right: 0; @@ -375,6 +461,10 @@ background-color: #000; } +::-webkit-backdrop { + background-color: #000; +} + ::backdrop { background-color: #000; } @@ -394,3 +484,5 @@ cursor: -webkit-grabbing; cursor: grabbing; } + +/*# sourceMappingURL=jquery.magnify.css.map */ \ No newline at end of file diff --git a/dist/jquery.magnify.css.map b/dist/jquery.magnify.css.map index 0c86735..c8b43d2 100644 --- a/dist/jquery.magnify.css.map +++ b/dist/jquery.magnify.css.map @@ -1 +1 @@ -{"version":3,"sources":["jquery.magnify.css"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;GAeG;AACH;EACE,mBAAmB;EACnB,cAAc;EACd,aAAa;EACb,cAAc;EACd,uBAAuB;EACvB,sCAAsC;EACtC,mDAA2C;UAA3C,2CAA2C;EAC3C,gBAAgB;CACjB;;AAED;EACE,gBAAgB;EAChB,OAAO;EACP,QAAQ;EACR,YAAY;EACZ,aAAa;CACd;;AAED;EACE,aAAa;CACd;;AAED;EACE,mBAAmB;EACnB,WAAW;EACX,aAAa;EACb,YAAY;CACb;;AAED;EACE,aAAa;CACd;;AAED;EACE,mBAAmB;EACnB,gBAAgB;EAChB,eAAe;EACf,oBAAoB;EACpB,wBAAwB;EACxB,0BAAkB;KAAlB,uBAAkB;MAAlB,sBAAkB;UAAlB,kBAAkB;EAClB,iBAAiB;CAClB;;AAED;EACE,mBAAmB;EACnB,UAAU;EACV,YAAY;EACZ,aAAa;EACb,WAAW;EACX,WAAW;EACX,uBAAuB;EACvB,iBAAiB;CAClB;;AAED;EACE,mBAAmB;CACpB;;AAED;EACE,mBAAmB;EACnB,sBAAsB;CACvB;;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;EACV,QAAQ;EACR,gBAAgB;EAChB,uBAAuB;CACxB;;AAED;EACE,kBAAkB;EAClB,mBAAmB;EACnB,uBAAuB;EACvB,wBAAwB;CACzB;;AALD;EACE,kBAAkB;EAClB,mBAAmB;EACnB,uBAAuB;EACvB,wBAAwB;CACzB;;AALD;EACE,kBAAkB;EAClB,mBAAmB;EACnB,uBAAuB;EACvB,wBAAwB;CACzB;;AALD;EACE,kBAAkB;EAClB,mBAAmB;EACnB,uBAAuB;EACvB,wBAAwB;CACzB;;AAED;;;EAGE,cAAc;CACf;;AAJD;;;EAGE,cAAc;CACf;;AAJD;;;EAGE,cAAc;CACf;;AAJD;;;EAGE,cAAc;CACf;;AAED;EACE,OAAO;EACP,SAAS;EACT,UAAU;EACV,QAAQ;EACR,gBAAgB;EAChB,uBAAuB;CACxB;;AAPD;EACE,OAAO;EACP,SAAS;EACT,UAAU;EACV,QAAQ;EACR,gBAAgB;EAChB,uBAAuB;CACxB;;AAPD;EACE,OAAO;EACP,SAAS;EACT,UAAU;EACV,QAAQ;EACR,gBAAgB;EAChB,uBAAuB;CACxB;;AAPD;EACE,OAAO;EACP,SAAS;EACT,UAAU;EACV,QAAQ;EACR,gBAAgB;EAChB,uBAAuB;CACxB;;AAED;EACE,uBAAuB;CACxB;;AAFD;EACE,uBAAuB;CACxB;;AAED;EACE,uBAAuB;CACxB;;AAED;EACE,aAAa;EACb,qBAAqB;EACrB,aAAa;CACd;;AAED;EACE,aAAa;EACb,yBAAyB;EACzB,iBAAiB;CAClB","file":"jquery.magnify.css","sourcesContent":["/*!\n * ___ ___ _____ ______ __ __ _____ ______ __ __\n * | \\/ |/ _ \\ / __ \\| \\ | |_ _| ___| \\ / |\n * | | / \\ | | \\__| \\| | | | | |__ \\ \\/ /\n * | |\\/| | |_| | | ___ | | | | __| \\ /\n * | | | | _ | \\_/ | |\\ |_| |_| | | |\n * |__| |__|__| |__|\\____/|_|__| \\__|_____|__| |__|\n *\n * jquery.magnify - v1.2.0\n * A jQuery plugin to view images just like in windows\n * https://github.com/nzbin/magnify#readme\n *\n * Copyright (c) 2017 nzbin\n * Released under the MIT License\n *\n */\n.magnify-modal {\n position: absolute;\n z-index: 1090;\n width: 320px;\n height: 320px;\n background-color: #111;\n background-color: rgba(0, 0, 0, 0.85);\n box-shadow: 0 0 3px 1px rgba(0, 0, 0, 0.3);\n cursor: default;\n}\n\n.magnify-maximize {\n position: fixed;\n top: 0;\n left: 0;\n width: 100%;\n height: 100%;\n}\n\n.magnify-toolbar {\n font-size: 0;\n}\n\n.magnify-header {\n position: relative;\n z-index: 2;\n height: 40px;\n color: #fff;\n}\n\n.magnify-header .magnify-toolbar {\n float: right;\n}\n\n.magnify-title {\n padding: 13px 10px;\n font-size: 14px;\n line-height: 1;\n white-space: nowrap;\n text-overflow: ellipsis;\n user-select: none;\n overflow: hidden;\n}\n\n.magnify-stage {\n position: absolute;\n top: 40px;\n right: 10px;\n bottom: 40px;\n left: 10px;\n z-index: 1;\n border: 1px solid #ccc;\n overflow: hidden;\n}\n\n.magnify-stage.stage-ready {\n text-align: center;\n}\n\n.magnify-image {\n position: relative;\n display: inline-block;\n}\n\n.magnify-image.image-ready {\n max-width: 100%;\n max-height: 100%;\n}\n\n.magnify-footer {\n position: absolute;\n bottom: 0;\n z-index: 2;\n width: 100%;\n height: 40px;\n color: #fff;\n text-align: center;\n}\n\n.magnify-footer .magnify-toolbar {\n display: inline-block;\n}\n\n.magnify-button {\n display: inline-block;\n width: 40px;\n height: 40px;\n box-sizing: border-box;\n margin: 0;\n padding: 10px;\n font-size: 14px;\n color: #ccc;\n line-height: 1;\n text-align: center;\n background: none;\n border-width: 0;\n border-radius: 0;\n cursor: pointer;\n outline: none;\n}\n\n.magnify-button:hover {\n color: #fff;\n}\n\n.magnify-button-close:hover {\n background-color: #ff4545;\n}\n\n.magnify-button-maximize:hover {\n background-color: #525252;\n}\n\n.magnify-button-minimize:hover {\n background-color: #525252;\n}\n\n.magnify-loader {\n position: absolute;\n top: 0;\n left: 0;\n right: 0;\n bottom: 0;\n z-index: 2;\n text-align: center;\n background-color: rgba(0, 0, 0, 0.3);\n color: #333;\n}\n\n.magnify-loader::before {\n content: '';\n display: inline-block;\n position: relative;\n width: 36px;\n height: 36px;\n box-sizing: border-box;\n border-width: 5px;\n border-style: solid;\n border-color: rgba(0, 0, 0, 0.5) rgba(0, 0, 0, 0.5) rgba(0, 0, 0, 0.5) rgba(255, 255, 255, 0.5);\n border-radius: 100%;\n animation: magnifyLoading 1s infinite linear;\n}\n\n.magnify-loader::after {\n content: '';\n display: inline-block;\n width: 0;\n height: 100%;\n vertical-align: middle;\n overflow: hidden;\n}\n\n@keyframes magnifyLoading {\n 0% {\n transform: rotateZ(0deg) translate3d(0, 0, 0);\n }\n 100% {\n transform: rotateZ(360deg) translate3d(0, 0, 0);\n }\n}\n\n.magnify-resizable-handle {\n position: absolute;\n z-index: 10;\n}\n\n.magnify-resizable-handle-e {\n top: 0;\n right: -5px;\n bottom: 0;\n left: auto;\n width: 10px;\n cursor: e-resize;\n}\n\n.magnify-resizable-handle-s {\n top: auto;\n right: 0;\n bottom: -5px;\n left: 0;\n height: 10px;\n cursor: s-resize;\n}\n\n.magnify-resizable-handle-w {\n top: 0;\n right: auto;\n bottom: 0;\n left: -5px;\n width: 10px;\n cursor: w-resize;\n}\n\n.magnify-resizable-handle-n {\n top: -5px;\n right: 0;\n bottom: auto;\n left: 0;\n height: 10px;\n cursor: n-resize;\n}\n\n.magnify-resizable-handle-se {\n top: auto;\n right: -5px;\n bottom: -5px;\n left: auto;\n width: 10px;\n height: 10px;\n cursor: se-resize;\n}\n\n.magnify-resizable-handle-sw {\n top: auto;\n right: auto;\n bottom: -5px;\n left: -5px;\n width: 10px;\n height: 10px;\n cursor: sw-resize;\n}\n\n.magnify-resizable-handle-nw {\n top: -5px;\n right: auto;\n bottom: auto;\n left: -5px;\n width: 10px;\n height: 10px;\n cursor: nw-resize;\n}\n\n.magnify-resizable-handle-ne {\n top: -5px;\n right: -5px;\n bottom: auto;\n left: auto;\n width: 10px;\n height: 10px;\n cursor: ne-resize;\n}\n\n:-webkit-full-screen {\n top: 0 !important;\n left: 0 !important;\n width: 100% !important;\n height: 100% !important;\n}\n\n:-webkit-full-screen .magnify-header,\n:-webkit-full-screen .magnify-footer,\n:-webkit-full-screen .magnify-resizable-handle {\n display: none;\n}\n\n:-webkit-full-screen .magnify-stage {\n top: 0;\n right: 0;\n bottom: 0;\n left: 0;\n border-width: 0;\n background-color: #000;\n}\n\n:-moz-full-screen {\n top: 0 !important;\n left: 0 !important;\n width: 100% !important;\n height: 100% !important;\n}\n\n:-moz-full-screen .magnify-header,\n:-moz-full-screen .magnify-footer,\n:-moz-full-screen .magnify-resizable-handle {\n display: none;\n}\n\n:-moz-full-screen .magnify-stage {\n top: 0;\n right: 0;\n bottom: 0;\n left: 0;\n border-width: 0;\n background-color: #000;\n}\n\n:-ms-fullscreen {\n top: 0 !important;\n left: 0 !important;\n width: 100% !important;\n height: 100% !important;\n}\n\n:-ms-fullscreen .magnify-header,\n:-ms-fullscreen .magnify-footer,\n:-ms-fullscreen .magnify-resizable-handle {\n display: none;\n}\n\n:-ms-fullscreen .magnify-stage {\n top: 0;\n right: 0;\n bottom: 0;\n left: 0;\n border-width: 0;\n background-color: #000;\n}\n\n:full-screen {\n top: 0 !important;\n left: 0 !important;\n width: 100% !important;\n height: 100% !important;\n}\n\n:full-screen .magnify-header,\n:full-screen .magnify-footer,\n:full-screen .magnify-resizable-handle {\n display: none;\n}\n\n:full-screen .magnify-stage {\n top: 0;\n right: 0;\n bottom: 0;\n left: 0;\n border-width: 0;\n background-color: #000;\n}\n\n:fullscreen {\n top: 0 !important;\n left: 0 !important;\n width: 100% !important;\n height: 100% !important;\n}\n\n:fullscreen .magnify-header,\n:fullscreen .magnify-footer,\n:fullscreen .magnify-resizable-handle {\n display: none;\n}\n\n:fullscreen .magnify-stage {\n top: 0;\n right: 0;\n bottom: 0;\n left: 0;\n border-width: 0;\n background-color: #000;\n}\n\n::backdrop {\n background-color: #000;\n}\n\n::-ms-backdrop {\n background-color: #000;\n}\n\n.is-grab {\n cursor: move;\n cursor: -webkit-grab;\n cursor: grab;\n}\n\n.is-grabbing {\n cursor: move;\n cursor: -webkit-grabbing;\n cursor: grabbing;\n}\n"]} \ No newline at end of file +{"version":3,"sources":["jquery.magnify.css"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;GAeG;AACH;EACE,mBAAmB;EACnB,cAAc;EACd,aAAa;EACb,cAAc;EACd,uBAAuB;EACvB,sCAAsC;EACtC,mDAA2C;UAA3C,2CAA2C;EAC3C,gBAAgB;CACjB;;AAED;EACE,gBAAgB;EAChB,OAAO;EACP,QAAQ;EACR,YAAY;EACZ,aAAa;CACd;;AAED;EACE,aAAa;CACd;;AAED;EACE,mBAAmB;EACnB,WAAW;EACX,aAAa;EACb,YAAY;CACb;;AAED;EACE,aAAa;CACd;;AAED;EACE,mBAAmB;EACnB,gBAAgB;EAChB,eAAe;EACf,oBAAoB;EACpB,wBAAwB;EACxB,0BAAkB;KAAlB,uBAAkB;MAAlB,sBAAkB;UAAlB,kBAAkB;EAClB,iBAAiB;CAClB;;AAED;EACE,mBAAmB;EACnB,UAAU;EACV,YAAY;EACZ,aAAa;EACb,WAAW;EACX,WAAW;EACX,uBAAuB;EACvB,iBAAiB;CAClB;;AAED;EACE,mBAAmB;CACpB;;AAED;EACE,mBAAmB;EACnB,sBAAsB;CACvB;;AAED;EACE,gBAAgB;EAChB,iBAAiB;CAClB;;AAED;EACE,mBAAmB;EACnB,UAAU;EACV,WAAW;EACX,YAAY;EACZ,aAAa;EACb,YAAY;EACZ,mBAAmB;CACpB;;AAED;EACE,sBAAsB;CACvB;;AAED;EACE,sBAAsB;EACtB,YAAY;EACZ,aAAa;EACb,+BAAuB;UAAvB,uBAAuB;EACvB,UAAU;EACV,cAAc;EACd,gBAAgB;EAChB,YAAY;EACZ,eAAe;EACf,mBAAmB;EACnB,iBAAiB;EACjB,gBAAgB;EAChB,iBA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;AALD;EACE,kBAAkB;EAClB,mBAAmB;EACnB,uBAAuB;EACvB,wBAAwB;CACzB;;AAED;;;EAGE,cAAc;CACf;;AAJD;;;EAGE,cAAc;CACf;;AAJD;;;EAGE,cAAc;CACf;;AAJD;;;EAGE,cAAc;CACf;;AAED;EACE,OAAO;EACP,SAAS;EACT,UAAU;EACV,QAAQ;EACR,gBAAgB;EAChB,uBAAuB;CACxB;;AAPD;EACE,OAAO;EACP,SAAS;EACT,UAAU;EACV,QAAQ;EACR,gBAAgB;EAChB,uBAAuB;CACxB;;AAPD;EACE,OAAO;EACP,SAAS;EACT,UAAU;EACV,QAAQ;EACR,gBAAgB;EAChB,uBAAuB;CACxB;;AAPD;EACE,OAAO;EACP,SAAS;EACT,UAAU;EACV,QAAQ;EACR,gBAAgB;EAChB,uBAAuB;CACxB;;AAED;EACE,uBAAuB;CACxB;;AAFD;EACE,uBAAuB;CACxB;;AAED;EACE,uBAAuB;CACxB;;AAED;EACE,aAAa;EACb,qBAAqB;EACrB,aAAa;CACd;;AAED;EACE,aAAa;EACb,yBAAyB;EACzB,iBAAiB;CAClB","file":"jquery.magnify.css","sourcesContent":["/*!\n * ___ ___ _____ ______ __ __ _____ ______ __ __\n * | \\/ |/ _ \\ / __ \\| \\ | |_ _| ___| \\ / |\n * | | / \\ | | \\__| \\| | | | | |__ \\ \\/ /\n * | |\\/| | |_| | | ___ | | | | __| \\ /\n * | | | | _ | \\_/ | |\\ |_| |_| | | |\n * |__| |__|__| |__|\\____/|_|__| \\__|_____|__| |__|\n *\n * jquery.magnify - v1.3.0\n * A jQuery plugin to view images just like in windows\n * https://github.com/nzbin/magnify#readme\n *\n * Copyright (c) 2017 nzbin\n * Released under the MIT License\n *\n */\n.magnify-modal {\n position: absolute;\n z-index: 1090;\n width: 320px;\n height: 320px;\n background-color: #111;\n background-color: rgba(0, 0, 0, 0.85);\n box-shadow: 0 0 3px 1px rgba(0, 0, 0, 0.3);\n cursor: default;\n}\n\n.magnify-maximize {\n position: fixed;\n top: 0;\n left: 0;\n width: 100%;\n height: 100%;\n}\n\n.magnify-toolbar {\n font-size: 0;\n}\n\n.magnify-header {\n position: relative;\n z-index: 2;\n height: 40px;\n color: #fff;\n}\n\n.magnify-header .magnify-toolbar {\n float: right;\n}\n\n.magnify-title {\n padding: 13px 10px;\n font-size: 14px;\n line-height: 1;\n white-space: nowrap;\n text-overflow: ellipsis;\n user-select: none;\n overflow: hidden;\n}\n\n.magnify-stage {\n position: absolute;\n top: 40px;\n right: 10px;\n bottom: 40px;\n left: 10px;\n z-index: 1;\n border: 1px solid #ccc;\n overflow: hidden;\n}\n\n.magnify-stage.stage-ready {\n text-align: center;\n}\n\n.magnify-image {\n position: relative;\n display: inline-block;\n}\n\n.magnify-image.image-ready {\n max-width: 100%;\n max-height: 100%;\n}\n\n.magnify-footer {\n position: absolute;\n bottom: 0;\n z-index: 2;\n width: 100%;\n height: 40px;\n color: #fff;\n text-align: center;\n}\n\n.magnify-footer .magnify-toolbar {\n display: inline-block;\n}\n\n.magnify-button {\n display: inline-block;\n width: 40px;\n height: 40px;\n box-sizing: border-box;\n margin: 0;\n padding: 10px;\n font-size: 14px;\n color: #ccc;\n line-height: 1;\n text-align: center;\n background: none;\n border-width: 0;\n border-radius: 0;\n cursor: pointer;\n outline: none;\n}\n\n.magnify-button:hover {\n color: #fff;\n}\n\n.magnify-button svg {\n display: inline-block;\n font-size: inherit;\n width: 1em;\n height: 1em;\n overflow: visible;\n vertical-align: -.125em;\n}\n\n.magnify-button-close:hover {\n background-color: #ff4545;\n}\n\n.magnify-button-maximize:hover {\n background-color: #525252;\n}\n\n.magnify-button-minimize:hover {\n background-color: #525252;\n}\n\n.magnify-loader {\n position: absolute;\n top: 0;\n left: 0;\n right: 0;\n bottom: 0;\n z-index: 2;\n text-align: center;\n background-color: rgba(0, 0, 0, 0.3);\n color: #333;\n}\n\n.magnify-loader::before {\n content: '';\n display: inline-block;\n position: relative;\n width: 36px;\n height: 36px;\n box-sizing: border-box;\n border-width: 5px;\n border-style: solid;\n border-color: rgba(0, 0, 0, 0.5) rgba(0, 0, 0, 0.5) rgba(0, 0, 0, 0.5) rgba(255, 255, 255, 0.5);\n border-radius: 100%;\n animation: magnifyLoading 1s infinite linear;\n}\n\n.magnify-loader::after {\n content: '';\n display: inline-block;\n width: 0;\n height: 100%;\n vertical-align: middle;\n overflow: hidden;\n}\n\n@keyframes magnifyLoading {\n 0% {\n transform: rotateZ(0deg) translate3d(0, 0, 0);\n }\n 100% {\n transform: rotateZ(360deg) translate3d(0, 0, 0);\n }\n}\n\n.magnify-resizable-handle {\n position: absolute;\n z-index: 10;\n}\n\n.magnify-resizable-handle-e {\n top: 0;\n right: -5px;\n bottom: 0;\n left: auto;\n width: 10px;\n cursor: e-resize;\n}\n\n.magnify-resizable-handle-s {\n top: auto;\n right: 0;\n bottom: -5px;\n left: 0;\n height: 10px;\n cursor: s-resize;\n}\n\n.magnify-resizable-handle-w {\n top: 0;\n right: auto;\n bottom: 0;\n left: -5px;\n width: 10px;\n cursor: w-resize;\n}\n\n.magnify-resizable-handle-n {\n top: -5px;\n right: 0;\n bottom: auto;\n left: 0;\n height: 10px;\n cursor: n-resize;\n}\n\n.magnify-resizable-handle-se {\n top: auto;\n right: -5px;\n bottom: -5px;\n left: auto;\n width: 10px;\n height: 10px;\n cursor: se-resize;\n}\n\n.magnify-resizable-handle-sw {\n top: auto;\n right: auto;\n bottom: -5px;\n left: -5px;\n width: 10px;\n height: 10px;\n cursor: sw-resize;\n}\n\n.magnify-resizable-handle-nw {\n top: -5px;\n right: auto;\n bottom: auto;\n left: -5px;\n width: 10px;\n height: 10px;\n cursor: nw-resize;\n}\n\n.magnify-resizable-handle-ne {\n top: -5px;\n right: -5px;\n bottom: auto;\n left: auto;\n width: 10px;\n height: 10px;\n cursor: ne-resize;\n}\n\n:-webkit-full-screen {\n top: 0 !important;\n left: 0 !important;\n width: 100% !important;\n height: 100% !important;\n}\n\n:-webkit-full-screen .magnify-header,\n:-webkit-full-screen .magnify-footer,\n:-webkit-full-screen .magnify-resizable-handle {\n display: none;\n}\n\n:-webkit-full-screen .magnify-stage {\n top: 0;\n right: 0;\n bottom: 0;\n left: 0;\n border-width: 0;\n background-color: #000;\n}\n\n:-moz-full-screen {\n top: 0 !important;\n left: 0 !important;\n width: 100% !important;\n height: 100% !important;\n}\n\n:-moz-full-screen .magnify-header,\n:-moz-full-screen .magnify-footer,\n:-moz-full-screen .magnify-resizable-handle {\n display: none;\n}\n\n:-moz-full-screen .magnify-stage {\n top: 0;\n right: 0;\n bottom: 0;\n left: 0;\n border-width: 0;\n background-color: #000;\n}\n\n:-ms-fullscreen {\n top: 0 !important;\n left: 0 !important;\n width: 100% !important;\n height: 100% !important;\n}\n\n:-ms-fullscreen .magnify-header,\n:-ms-fullscreen .magnify-footer,\n:-ms-fullscreen .magnify-resizable-handle {\n display: none;\n}\n\n:-ms-fullscreen .magnify-stage {\n top: 0;\n right: 0;\n bottom: 0;\n left: 0;\n border-width: 0;\n background-color: #000;\n}\n\n:full-screen {\n top: 0 !important;\n left: 0 !important;\n width: 100% !important;\n height: 100% !important;\n}\n\n:full-screen .magnify-header,\n:full-screen .magnify-footer,\n:full-screen .magnify-resizable-handle {\n display: none;\n}\n\n:full-screen .magnify-stage {\n top: 0;\n right: 0;\n bottom: 0;\n left: 0;\n border-width: 0;\n background-color: #000;\n}\n\n:fullscreen {\n top: 0 !important;\n left: 0 !important;\n width: 100% !important;\n height: 100% !important;\n}\n\n:fullscreen .magnify-header,\n:fullscreen .magnify-footer,\n:fullscreen .magnify-resizable-handle {\n display: none;\n}\n\n:fullscreen .magnify-stage {\n top: 0;\n right: 0;\n bottom: 0;\n left: 0;\n border-width: 0;\n background-color: #000;\n}\n\n::backdrop {\n background-color: #000;\n}\n\n::-ms-backdrop {\n background-color: #000;\n}\n\n.is-grab {\n cursor: move;\n cursor: -webkit-grab;\n cursor: grab;\n}\n\n.is-grabbing {\n cursor: move;\n cursor: -webkit-grabbing;\n cursor: grabbing;\n}\n"]} \ No newline at end of file diff --git a/dist/jquery.magnify.js b/dist/jquery.magnify.js index 1620375..d82b983 100644 --- a/dist/jquery.magnify.js +++ b/dist/jquery.magnify.js @@ -6,7 +6,7 @@ * | | | | _ | \_/ | |\ |_| |_| | | | * |__| |__|__| |__|\____/|_|__| \__|_____|__| |__| * - * jquery.magnify - v1.2.0 + * jquery.magnify - v1.3.0 * A jQuery plugin to view images just like in windows * https://github.com/nzbin/magnify#readme * diff --git a/dist/jquery.magnify.min.css b/dist/jquery.magnify.min.css index c548610..0929a4a 100644 --- a/dist/jquery.magnify.min.css +++ b/dist/jquery.magnify.min.css @@ -6,13 +6,13 @@ * | | | | _ | \_/ | |\ |_| |_| | | | * |__| |__|__| |__|\____/|_|__| \__|_____|__| |__| * - * jquery.magnify - v1.2.0 + * jquery.magnify - v1.3.0 * A jQuery plugin to view images just like in windows * https://github.com/nzbin/magnify#readme * * Copyright (c) 2017 nzbin * Released under the MIT License * - */.magnify-modal{position:absolute;z-index:1090;width:320px;height:320px;background-color:#111;background-color:rgba(0,0,0,0.85);-webkit-box-shadow:0 0 3px 1px rgba(0,0,0,0.3);box-shadow:0 0 3px 1px rgba(0,0,0,0.3);cursor:default}.magnify-maximize{position:fixed;top:0;left:0;width:100%;height:100%}.magnify-toolbar{font-size:0}.magnify-header{position:relative;z-index:2;height:40px;color:#fff}.magnify-header .magnify-toolbar{float:right}.magnify-title{padding:13px 10px;font-size:14px;line-height:1;white-space:nowrap;text-overflow:ellipsis;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;overflow:hidden}.magnify-stage{position:absolute;top:40px;right:10px;bottom:40px;left:10px;z-index:1;border:1px solid #ccc;overflow:hidden}.magnify-stage.stage-ready{text-align:center}.magnify-image{position:relative;display:inline-block}.magnify-image.image-ready{max-width:100%;max-height:100%}.magnify-footer{position:absolute;bottom:0;z-index:2;width:100%;height:40px;color:#fff;text-align:center}.magnify-footer .magnify-toolbar{display:inline-block}.magnify-button{display:inline-block;width:40px;height:40px;-webkit-box-sizing:border-box;box-sizing:border-box;margin:0;padding:10px;font-size:14px;color:#ccc;line-height:1;text-align:center;background:none;border-width:0;border-radius:0;cursor:pointer;outline:none}.magnify-button:hover{color:#fff}.magnify-button-close:hover{background-color:#ff4545}.magnify-button-maximize:hover{background-color:#525252}.magnify-button-minimize:hover{background-color:#525252}.magnify-loader{position:absolute;top:0;left:0;right:0;bottom:0;z-index:2;text-align:center;background-color:rgba(0,0,0,0.3);color:#333}.magnify-loader::before{content:'';display:inline-block;position:relative;width:36px;height:36px;-webkit-box-sizing:border-box;box-sizing:border-box;border-width:5px;border-style:solid;border-color:rgba(0,0,0,0.5) rgba(0,0,0,0.5) rgba(0,0,0,0.5) rgba(255,255,255,0.5);border-radius:100%;-webkit-animation:magnifyLoading 1s infinite linear;animation:magnifyLoading 1s infinite linear}.magnify-loader::after{content:'';display:inline-block;width:0;height:100%;vertical-align:middle;overflow:hidden}@-webkit-keyframes magnifyLoading{0%{-webkit-transform:rotateZ(0deg) translate3d(0, 0, 0);transform:rotateZ(0deg) translate3d(0, 0, 0)}100%{-webkit-transform:rotateZ(360deg) translate3d(0, 0, 0);transform:rotateZ(360deg) translate3d(0, 0, 0)}}@keyframes magnifyLoading{0%{-webkit-transform:rotateZ(0deg) translate3d(0, 0, 0);transform:rotateZ(0deg) translate3d(0, 0, 0)}100%{-webkit-transform:rotateZ(360deg) translate3d(0, 0, 0);transform:rotateZ(360deg) translate3d(0, 0, 0)}}.magnify-resizable-handle{position:absolute;z-index:10}.magnify-resizable-handle-e{top:0;right:-5px;bottom:0;left:auto;width:10px;cursor:e-resize}.magnify-resizable-handle-s{top:auto;right:0;bottom:-5px;left:0;height:10px;cursor:s-resize}.magnify-resizable-handle-w{top:0;right:auto;bottom:0;left:-5px;width:10px;cursor:w-resize}.magnify-resizable-handle-n{top:-5px;right:0;bottom:auto;left:0;height:10px;cursor:n-resize}.magnify-resizable-handle-se{top:auto;right:-5px;bottom:-5px;left:auto;width:10px;height:10px;cursor:se-resize}.magnify-resizable-handle-sw{top:auto;right:auto;bottom:-5px;left:-5px;width:10px;height:10px;cursor:sw-resize}.magnify-resizable-handle-nw{top:-5px;right:auto;bottom:auto;left:-5px;width:10px;height:10px;cursor:nw-resize}.magnify-resizable-handle-ne{top:-5px;right:-5px;bottom:auto;left:auto;width:10px;height:10px;cursor:ne-resize}:-webkit-full-screen{top:0 !important;left:0 !important;width:100% !important;height:100% !important}:-webkit-full-screen .magnify-header,:-webkit-full-screen .magnify-footer,:-webkit-full-screen .magnify-resizable-handle{display:none}:-webkit-full-screen .magnify-stage{top:0;right:0;bottom:0;left:0;border-width:0;background-color:#000}:-moz-full-screen{top:0 !important;left:0 !important;width:100% !important;height:100% !important}:-moz-full-screen .magnify-header,:-moz-full-screen .magnify-footer,:-moz-full-screen .magnify-resizable-handle{display:none}:-moz-full-screen .magnify-stage{top:0;right:0;bottom:0;left:0;border-width:0;background-color:#000}:-ms-fullscreen{top:0 !important;left:0 !important;width:100% !important;height:100% !important}:-ms-fullscreen .magnify-header,:-ms-fullscreen .magnify-footer,:-ms-fullscreen .magnify-resizable-handle{display:none}:-ms-fullscreen .magnify-stage{top:0;right:0;bottom:0;left:0;border-width:0;background-color:#000}:full-screen{top:0 !important;left:0 !important;width:100% !important;height:100% !important}:full-screen .magnify-header,:full-screen .magnify-footer,:full-screen .magnify-resizable-handle{display:none}:full-screen .magnify-stage{top:0;right:0;bottom:0;left:0;border-width:0;background-color:#000}:-webkit-full-screen{top:0 !important;left:0 !important;width:100% !important;height:100% !important}:-moz-full-screen{top:0 !important;left:0 !important;width:100% !important;height:100% !important}:-ms-fullscreen{top:0 !important;left:0 !important;width:100% !important;height:100% !important}:fullscreen{top:0 !important;left:0 !important;width:100% !important;height:100% !important}:-webkit-full-screen .magnify-header,:-webkit-full-screen .magnify-footer,:-webkit-full-screen .magnify-resizable-handle{display:none}:-moz-full-screen .magnify-header,:-moz-full-screen .magnify-footer,:-moz-full-screen .magnify-resizable-handle{display:none}:-ms-fullscreen .magnify-header,:-ms-fullscreen .magnify-footer,:-ms-fullscreen .magnify-resizable-handle{display:none}:fullscreen .magnify-header,:fullscreen .magnify-footer,:fullscreen .magnify-resizable-handle{display:none}:-webkit-full-screen .magnify-stage{top:0;right:0;bottom:0;left:0;border-width:0;background-color:#000}:-moz-full-screen .magnify-stage{top:0;right:0;bottom:0;left:0;border-width:0;background-color:#000}:-ms-fullscreen .magnify-stage{top:0;right:0;bottom:0;left:0;border-width:0;background-color:#000}:fullscreen .magnify-stage{top:0;right:0;bottom:0;left:0;border-width:0;background-color:#000}::-webkit-backdrop{background-color:#000}::backdrop{background-color:#000}::-ms-backdrop{background-color:#000}.is-grab{cursor:move;cursor:-webkit-grab;cursor:grab}.is-grabbing{cursor:move;cursor:-webkit-grabbing;cursor:grabbing} + */.magnify-modal{position:absolute;z-index:1090;width:320px;height:320px;background-color:#111;background-color:rgba(0,0,0,0.85);-webkit-box-shadow:0 0 3px 1px rgba(0,0,0,0.3);box-shadow:0 0 3px 1px rgba(0,0,0,0.3);cursor:default}.magnify-maximize{position:fixed;top:0;left:0;width:100%;height:100%}.magnify-toolbar{font-size:0}.magnify-header{position:relative;z-index:2;height:40px;color:#fff}.magnify-header .magnify-toolbar{float:right}.magnify-title{padding:13px 10px;font-size:14px;line-height:1;white-space:nowrap;text-overflow:ellipsis;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;overflow:hidden}.magnify-stage{position:absolute;top:40px;right:10px;bottom:40px;left:10px;z-index:1;border:1px solid #ccc;overflow:hidden}.magnify-stage.stage-ready{text-align:center}.magnify-image{position:relative;display:inline-block}.magnify-image.image-ready{max-width:100%;max-height:100%}.magnify-footer{position:absolute;bottom:0;z-index:2;width:100%;height:40px;color:#fff;text-align:center}.magnify-footer .magnify-toolbar{display:inline-block}.magnify-button{display:inline-block;width:40px;height:40px;-webkit-box-sizing:border-box;box-sizing:border-box;margin:0;padding:10px;font-size:14px;color:#ccc;line-height:1;text-align:center;background:none;border-width:0;border-radius:0;cursor:pointer;outline:none}.magnify-button:hover{color:#fff}.magnify-button svg{display:inline-block;font-size:inherit;width:1em;height:1em;overflow:visible;vertical-align:-.125em}.magnify-button-close:hover{background-color:#ff4545}.magnify-button-maximize:hover{background-color:#525252}.magnify-button-minimize:hover{background-color:#525252}.magnify-loader{position:absolute;top:0;left:0;right:0;bottom:0;z-index:2;text-align:center;background-color:rgba(0,0,0,0.3);color:#333}.magnify-loader::before{content:'';display:inline-block;position:relative;width:36px;height:36px;-webkit-box-sizing:border-box;box-sizing:border-box;border-width:5px;border-style:solid;border-color:rgba(0,0,0,0.5) rgba(0,0,0,0.5) rgba(0,0,0,0.5) rgba(255,255,255,0.5);border-radius:100%;-webkit-animation:magnifyLoading 1s infinite linear;animation:magnifyLoading 1s infinite linear}.magnify-loader::after{content:'';display:inline-block;width:0;height:100%;vertical-align:middle;overflow:hidden}@-webkit-keyframes magnifyLoading{0%{-webkit-transform:rotateZ(0deg) translate3d(0, 0, 0);transform:rotateZ(0deg) translate3d(0, 0, 0)}100%{-webkit-transform:rotateZ(360deg) translate3d(0, 0, 0);transform:rotateZ(360deg) translate3d(0, 0, 0)}}@keyframes magnifyLoading{0%{-webkit-transform:rotateZ(0deg) translate3d(0, 0, 0);transform:rotateZ(0deg) translate3d(0, 0, 0)}100%{-webkit-transform:rotateZ(360deg) translate3d(0, 0, 0);transform:rotateZ(360deg) translate3d(0, 0, 0)}}.magnify-resizable-handle{position:absolute;z-index:10}.magnify-resizable-handle-e{top:0;right:-5px;bottom:0;left:auto;width:10px;cursor:e-resize}.magnify-resizable-handle-s{top:auto;right:0;bottom:-5px;left:0;height:10px;cursor:s-resize}.magnify-resizable-handle-w{top:0;right:auto;bottom:0;left:-5px;width:10px;cursor:w-resize}.magnify-resizable-handle-n{top:-5px;right:0;bottom:auto;left:0;height:10px;cursor:n-resize}.magnify-resizable-handle-se{top:auto;right:-5px;bottom:-5px;left:auto;width:10px;height:10px;cursor:se-resize}.magnify-resizable-handle-sw{top:auto;right:auto;bottom:-5px;left:-5px;width:10px;height:10px;cursor:sw-resize}.magnify-resizable-handle-nw{top:-5px;right:auto;bottom:auto;left:-5px;width:10px;height:10px;cursor:nw-resize}.magnify-resizable-handle-ne{top:-5px;right:-5px;bottom:auto;left:auto;width:10px;height:10px;cursor:ne-resize}:-webkit-full-screen{top:0 !important;left:0 !important;width:100% !important;height:100% !important}:-webkit-full-screen .magnify-header,:-webkit-full-screen .magnify-footer,:-webkit-full-screen .magnify-resizable-handle{display:none}:-webkit-full-screen .magnify-stage{top:0;right:0;bottom:0;left:0;border-width:0;background-color:#000}:-moz-full-screen{top:0 !important;left:0 !important;width:100% !important;height:100% !important}:-moz-full-screen .magnify-header,:-moz-full-screen .magnify-footer,:-moz-full-screen .magnify-resizable-handle{display:none}:-moz-full-screen .magnify-stage{top:0;right:0;bottom:0;left:0;border-width:0;background-color:#000}:-ms-fullscreen{top:0 !important;left:0 !important;width:100% !important;height:100% !important}:-ms-fullscreen .magnify-header,:-ms-fullscreen .magnify-footer,:-ms-fullscreen .magnify-resizable-handle{display:none}:-ms-fullscreen .magnify-stage{top:0;right:0;bottom:0;left:0;border-width:0;background-color:#000}:full-screen{top:0 !important;left:0 !important;width:100% !important;height:100% !important}:full-screen .magnify-header,:full-screen .magnify-footer,:full-screen .magnify-resizable-handle{display:none}:full-screen .magnify-stage{top:0;right:0;bottom:0;left:0;border-width:0;background-color:#000}:-webkit-full-screen{top:0 !important;left:0 !important;width:100% !important;height:100% !important}:-moz-full-screen{top:0 !important;left:0 !important;width:100% !important;height:100% !important}:-ms-fullscreen{top:0 !important;left:0 !important;width:100% !important;height:100% !important}:fullscreen{top:0 !important;left:0 !important;width:100% !important;height:100% !important}:-webkit-full-screen .magnify-header,:-webkit-full-screen .magnify-footer,:-webkit-full-screen .magnify-resizable-handle{display:none}:-moz-full-screen .magnify-header,:-moz-full-screen .magnify-footer,:-moz-full-screen .magnify-resizable-handle{display:none}:-ms-fullscreen .magnify-header,:-ms-fullscreen .magnify-footer,:-ms-fullscreen .magnify-resizable-handle{display:none}:fullscreen .magnify-header,:fullscreen .magnify-footer,:fullscreen .magnify-resizable-handle{display:none}:-webkit-full-screen .magnify-stage{top:0;right:0;bottom:0;left:0;border-width:0;background-color:#000}:-moz-full-screen .magnify-stage{top:0;right:0;bottom:0;left:0;border-width:0;background-color:#000}:-ms-fullscreen .magnify-stage{top:0;right:0;bottom:0;left:0;border-width:0;background-color:#000}:fullscreen .magnify-stage{top:0;right:0;bottom:0;left:0;border-width:0;background-color:#000}::-webkit-backdrop{background-color:#000}::backdrop{background-color:#000}::-ms-backdrop{background-color:#000}.is-grab{cursor:move;cursor:-webkit-grab;cursor:grab}.is-grabbing{cursor:move;cursor:-webkit-grabbing;cursor:grabbing} /*# sourceMappingURL=jquery.magnify.min.css.map */ \ No newline at end of file diff --git a/dist/jquery.magnify.min.css.map b/dist/jquery.magnify.min.css.map index c9abe93..f42976e 100644 --- a/dist/jquery.magnify.min.css.map +++ b/dist/jquery.magnify.min.css.map @@ -1 +1 @@ -{"version":3,"sources":["jquery.magnify.min.css"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;GAeG,eAAe,kBAAkB,aAAa,YAAY,aAAa,sBAAsB,kCAAkC,+CAAuC,AAAvC,uCAAuC,cAAc,CAAC,kBAAkB,eAAe,MAAM,OAAO,WAAW,WAAW,CAAC,iBAAiB,WAAW,CAAC,gBAAgB,kBAAkB,UAAU,YAAY,UAAU,CAAC,iCAAiC,WAAW,CAAC,eAAe,kBAAkB,eAAe,cAAc,mBAAmB,uBAAuB,yBAAiB,AAAjB,sBAAiB,AAAjB,qBAAiB,AAAjB,iBAAiB,eAAe,CAAC,eAAe,kBAAkB,SAAS,WAAW,YAAY,UAAU,UAAU,sBAAsB,eAAe,CAAC,2BAA2B,iBAAiB,CAAC,eAAe,kBAAkB,oBAAoB,CAAC,2BAA2B,eAAe,eAAe,CAAC,gBAAgB,kBAAkB,SAAS,UAAU,WAAW,YA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 / |\n * | | / \\ | | \\__| \\| | | | | |__ \\ \\/ /\n * | |\\/| | |_| | | ___ | | | | __| \\ /\n * | | | | _ | \\_/ | |\\ |_| |_| | | |\n * |__| |__|__| |__|\\____/|_|__| \\__|_____|__| |__|\n *\n * jquery.magnify - v1.2.0\n * A jQuery plugin to view images just like in windows\n * https://github.com/nzbin/magnify#readme\n *\n * Copyright (c) 2017 nzbin\n * Released under the MIT License\n *\n */.magnify-modal{position:absolute;z-index:1090;width:320px;height:320px;background-color:#111;background-color:rgba(0,0,0,0.85);box-shadow:0 0 3px 1px rgba(0,0,0,0.3);cursor:default}.magnify-maximize{position:fixed;top:0;left:0;width:100%;height:100%}.magnify-toolbar{font-size:0}.magnify-header{position:relative;z-index:2;height:40px;color:#fff}.magnify-header .magnify-toolbar{float:right}.magnify-title{padding:13px 10px;font-size:14px;line-height:1;white-space:nowrap;text-overflow:ellipsis;user-select:none;overflow:hidden}.magnify-stage{position:absolute;top:40px;right:10px;bottom:40px;left:10px;z-index:1;border:1px solid #ccc;overflow:hidden}.magnify-stage.stage-ready{text-align:center}.magnify-image{position:relative;display:inline-block}.magnify-image.image-ready{max-width:100%;max-height:100%}.magnify-footer{position:absolute;bottom:0;z-index:2;width:100%;height:40px;color:#fff;text-align:center}.magnify-footer .magnify-toolbar{display:inline-block}.magnify-button{display:inline-block;width:40px;height:40px;box-sizing:border-box;margin:0;padding:10px;font-size:14px;color:#ccc;line-height:1;text-align:center;background:none;border-width:0;border-radius:0;cursor:pointer;outline:none}.magnify-button:hover{color:#fff}.magnify-button-close:hover{background-color:#ff4545}.magnify-button-maximize:hover{background-color:#525252}.magnify-button-minimize:hover{background-color:#525252}.magnify-loader{position:absolute;top:0;left:0;right:0;bottom:0;z-index:2;text-align:center;background-color:rgba(0,0,0,0.3);color:#333}.magnify-loader::before{content:'';display:inline-block;position:relative;width:36px;height:36px;box-sizing:border-box;border-width:5px;border-style:solid;border-color:rgba(0,0,0,0.5) rgba(0,0,0,0.5) rgba(0,0,0,0.5) rgba(255,255,255,0.5);border-radius:100%;animation:magnifyLoading 1s infinite linear}.magnify-loader::after{content:'';display:inline-block;width:0;height:100%;vertical-align:middle;overflow:hidden}@keyframes magnifyLoading{0%{transform:rotateZ(0deg) translate3d(0, 0, 0)}100%{transform:rotateZ(360deg) translate3d(0, 0, 0)}}.magnify-resizable-handle{position:absolute;z-index:10}.magnify-resizable-handle-e{top:0;right:-5px;bottom:0;left:auto;width:10px;cursor:e-resize}.magnify-resizable-handle-s{top:auto;right:0;bottom:-5px;left:0;height:10px;cursor:s-resize}.magnify-resizable-handle-w{top:0;right:auto;bottom:0;left:-5px;width:10px;cursor:w-resize}.magnify-resizable-handle-n{top:-5px;right:0;bottom:auto;left:0;height:10px;cursor:n-resize}.magnify-resizable-handle-se{top:auto;right:-5px;bottom:-5px;left:auto;width:10px;height:10px;cursor:se-resize}.magnify-resizable-handle-sw{top:auto;right:auto;bottom:-5px;left:-5px;width:10px;height:10px;cursor:sw-resize}.magnify-resizable-handle-nw{top:-5px;right:auto;bottom:auto;left:-5px;width:10px;height:10px;cursor:nw-resize}.magnify-resizable-handle-ne{top:-5px;right:-5px;bottom:auto;left:auto;width:10px;height:10px;cursor:ne-resize}:-webkit-full-screen{top:0 !important;left:0 !important;width:100% !important;height:100% !important}:-webkit-full-screen .magnify-header,:-webkit-full-screen .magnify-footer,:-webkit-full-screen .magnify-resizable-handle{display:none}:-webkit-full-screen .magnify-stage{top:0;right:0;bottom:0;left:0;border-width:0;background-color:#000}:-moz-full-screen{top:0 !important;left:0 !important;width:100% !important;height:100% !important}:-moz-full-screen .magnify-header,:-moz-full-screen .magnify-footer,:-moz-full-screen .magnify-resizable-handle{display:none}:-moz-full-screen .magnify-stage{top:0;right:0;bottom:0;left:0;border-width:0;background-color:#000}:-ms-fullscreen{top:0 !important;left:0 !important;width:100% !important;height:100% !important}:-ms-fullscreen .magnify-header,:-ms-fullscreen .magnify-footer,:-ms-fullscreen .magnify-resizable-handle{display:none}:-ms-fullscreen .magnify-stage{top:0;right:0;bottom:0;left:0;border-width:0;background-color:#000}:full-screen{top:0 !important;left:0 !important;width:100% !important;height:100% !important}:full-screen .magnify-header,:full-screen .magnify-footer,:full-screen .magnify-resizable-handle{display:none}:full-screen .magnify-stage{top:0;right:0;bottom:0;left:0;border-width:0;background-color:#000}:fullscreen{top:0 !important;left:0 !important;width:100% !important;height:100% !important}:fullscreen .magnify-header,:fullscreen .magnify-footer,:fullscreen .magnify-resizable-handle{display:none}:fullscreen .magnify-stage{top:0;right:0;bottom:0;left:0;border-width:0;background-color:#000}::backdrop{background-color:#000}::-ms-backdrop{background-color:#000}.is-grab{cursor:move;cursor:-webkit-grab;cursor:grab}.is-grabbing{cursor:move;cursor:-webkit-grabbing;cursor:grabbing}\n"]} \ No newline at end of file +{"version":3,"sources":["jquery.magnify.min.css"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;GAeG,eAAe,kBAAkB,aAAa,YAAY,aAAa,sBAAsB,kCAAkC,+CAAuC,AAAvC,uCAAuC,cAAc,CAAC,kBAAkB,eAAe,MAAM,OAAO,WAAW,WAAW,CAAC,iBAAiB,WAAW,CAAC,gBAAgB,kBAAkB,UAAU,YAAY,UAAU,CAAC,iCAAiC,WAAW,CAAC,eAAe,kBAAkB,eAAe,cAAc,mBAAmB,uBAAuB,yBAAiB,AAAjB,sBAAiB,AAAjB,qBAAiB,AAAjB,iBAAiB,eAAe,CAAC,eAAe,kBAAkB,SAAS,WAAW,YAAY,UAAU,UAAU,sBAAsB,eAAe,CAAC,2BAA2B,iBAAiB,CAAC,eAAe,kBAAkB,oBAAoB,CAAC,2BAA2B,eAAe,eAAe,CAAC,gBAAgB,kBAAkB,SAAS,UAAU,WAAW,YAAY,WAAW,iBAAiB,CAAC,iCAAiC,oBAAoB,CAAC,gBAAgB,qBAAqB,WAAW,YAAY,8BAAsB,AAAtB,sBAAsB,SAAS,aAAa,eAAe,WAAW,cAAc,kBAAkB,gBAAgB,eAAe,gBAAgB,eAAe,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| | | |\n * |__| |__|__| |__|\\____/|_|__| \\__|_____|__| |__|\n *\n * jquery.magnify - v1.3.0\n * A jQuery plugin to view images just like in windows\n * https://github.com/nzbin/magnify#readme\n *\n * Copyright (c) 2017 nzbin\n * Released under the MIT License\n *\n */.magnify-modal{position:absolute;z-index:1090;width:320px;height:320px;background-color:#111;background-color:rgba(0,0,0,0.85);box-shadow:0 0 3px 1px rgba(0,0,0,0.3);cursor:default}.magnify-maximize{position:fixed;top:0;left:0;width:100%;height:100%}.magnify-toolbar{font-size:0}.magnify-header{position:relative;z-index:2;height:40px;color:#fff}.magnify-header .magnify-toolbar{float:right}.magnify-title{padding:13px 10px;font-size:14px;line-height:1;white-space:nowrap;text-overflow:ellipsis;user-select:none;overflow:hidden}.magnify-stage{position:absolute;top:40px;right:10px;bottom:40px;left:10px;z-index:1;border:1px solid #ccc;overflow:hidden}.magnify-stage.stage-ready{text-align:center}.magnify-image{position:relative;display:inline-block}.magnify-image.image-ready{max-width:100%;max-height:100%}.magnify-footer{position:absolute;bottom:0;z-index:2;width:100%;height:40px;color:#fff;text-align:center}.magnify-footer .magnify-toolbar{display:inline-block}.magnify-button{display:inline-block;width:40px;height:40px;box-sizing:border-box;margin:0;padding:10px;font-size:14px;color:#ccc;line-height:1;text-align:center;background:none;border-width:0;border-radius:0;cursor:pointer;outline:none}.magnify-button:hover{color:#fff}.magnify-button svg{display:inline-block;font-size:inherit;width:1em;height:1em;overflow:visible;vertical-align:-.125em}.magnify-button-close:hover{background-color:#ff4545}.magnify-button-maximize:hover{background-color:#525252}.magnify-button-minimize:hover{background-color:#525252}.magnify-loader{position:absolute;top:0;left:0;right:0;bottom:0;z-index:2;text-align:center;background-color:rgba(0,0,0,0.3);color:#333}.magnify-loader::before{content:'';display:inline-block;position:relative;width:36px;height:36px;box-sizing:border-box;border-width:5px;border-style:solid;border-color:rgba(0,0,0,0.5) rgba(0,0,0,0.5) rgba(0,0,0,0.5) rgba(255,255,255,0.5);border-radius:100%;animation:magnifyLoading 1s infinite linear}.magnify-loader::after{content:'';display:inline-block;width:0;height:100%;vertical-align:middle;overflow:hidden}@keyframes magnifyLoading{0%{transform:rotateZ(0deg) translate3d(0, 0, 0)}100%{transform:rotateZ(360deg) translate3d(0, 0, 0)}}.magnify-resizable-handle{position:absolute;z-index:10}.magnify-resizable-handle-e{top:0;right:-5px;bottom:0;left:auto;width:10px;cursor:e-resize}.magnify-resizable-handle-s{top:auto;right:0;bottom:-5px;left:0;height:10px;cursor:s-resize}.magnify-resizable-handle-w{top:0;right:auto;bottom:0;left:-5px;width:10px;cursor:w-resize}.magnify-resizable-handle-n{top:-5px;right:0;bottom:auto;left:0;height:10px;cursor:n-resize}.magnify-resizable-handle-se{top:auto;right:-5px;bottom:-5px;left:auto;width:10px;height:10px;cursor:se-resize}.magnify-resizable-handle-sw{top:auto;right:auto;bottom:-5px;left:-5px;width:10px;height:10px;cursor:sw-resize}.magnify-resizable-handle-nw{top:-5px;right:auto;bottom:auto;left:-5px;width:10px;height:10px;cursor:nw-resize}.magnify-resizable-handle-ne{top:-5px;right:-5px;bottom:auto;left:auto;width:10px;height:10px;cursor:ne-resize}:-webkit-full-screen{top:0 !important;left:0 !important;width:100% !important;height:100% !important}:-webkit-full-screen .magnify-header,:-webkit-full-screen .magnify-footer,:-webkit-full-screen .magnify-resizable-handle{display:none}:-webkit-full-screen .magnify-stage{top:0;right:0;bottom:0;left:0;border-width:0;background-color:#000}:-moz-full-screen{top:0 !important;left:0 !important;width:100% !important;height:100% !important}:-moz-full-screen .magnify-header,:-moz-full-screen .magnify-footer,:-moz-full-screen .magnify-resizable-handle{display:none}:-moz-full-screen .magnify-stage{top:0;right:0;bottom:0;left:0;border-width:0;background-color:#000}:-ms-fullscreen{top:0 !important;left:0 !important;width:100% !important;height:100% !important}:-ms-fullscreen .magnify-header,:-ms-fullscreen .magnify-footer,:-ms-fullscreen .magnify-resizable-handle{display:none}:-ms-fullscreen .magnify-stage{top:0;right:0;bottom:0;left:0;border-width:0;background-color:#000}:full-screen{top:0 !important;left:0 !important;width:100% !important;height:100% !important}:full-screen .magnify-header,:full-screen .magnify-footer,:full-screen .magnify-resizable-handle{display:none}:full-screen .magnify-stage{top:0;right:0;bottom:0;left:0;border-width:0;background-color:#000}:fullscreen{top:0 !important;left:0 !important;width:100% !important;height:100% !important}:fullscreen .magnify-header,:fullscreen .magnify-footer,:fullscreen .magnify-resizable-handle{display:none}:fullscreen .magnify-stage{top:0;right:0;bottom:0;left:0;border-width:0;background-color:#000}::backdrop{background-color:#000}::-ms-backdrop{background-color:#000}.is-grab{cursor:move;cursor:-webkit-grab;cursor:grab}.is-grabbing{cursor:move;cursor:-webkit-grabbing;cursor:grabbing}\n"]} \ No newline at end of file diff --git a/dist/jquery.magnify.min.js b/dist/jquery.magnify.min.js index 24a59e0..068b900 100644 --- a/dist/jquery.magnify.min.js +++ b/dist/jquery.magnify.min.js @@ -6,7 +6,7 @@ * | | | | _ | \_/ | |\ |_| |_| | | | * |__| |__|__| |__|\____/|_|__| \__|_____|__| |__| * - * jquery.magnify - v1.2.0 + * jquery.magnify - v1.3.0 * A jQuery plugin to view images just like in windows * https://github.com/nzbin/magnify#readme * @@ -14,7 +14,7 @@ * Released under the MIT License * */ -!function(t){"function"==typeof define&&define.amd?define(["jquery"],t):t("object"==typeof exports?require("jquery"):jQuery)}(function(t){"use strict";function i(i){return t(i).attr("data-src")?t(i).attr("data-src"):t(i).attr("href")}function e(t){var i=t.match(/\d+/g);return parseFloat(i[0])}function a(t,i,e,a){var s=a?t.h:t.w,o=a?t.w:t.h;(o>i.h||s>i.w)&&e.addClass("is-grab"),o<=i.h&&s<=i.w&&e.removeClass("is-grab")}function s(){return!!("ontouchstart"in window||window.DocumentTouch&&document instanceof DocumentTouch)}function o(){return"Microsoft Internet Explorer"==navigator.appName&&navigator.appVersion.indexOf("MSIE 8.0")>0||"Microsoft Internet Explorer"==navigator.appName&&navigator.appVersion.indexOf("MSIE 7.0")>0}var n=t(window),h=t(document),r=s()?"touchstart":"mousedown",l=s()?"touchmove":"mousemove",g=s()?"touchend":"mouseup",m=".magnify",f={draggable:!0,resizable:!0,movable:!0,keyboard:!0,title:!0,modalWidth:320,modalHeight:320,fixedContent:!0,fixedModalSize:!1,initMaximized:!1,gapThreshold:.02,ratioThreshold:.1,minRatio:.1,maxRatio:16,headToolbar:["maximize","close"],footToolbar:["zoomIn","zoomOut","prev","fullscreen","next","actualSize","rotateRight"],icons:{minimize:"fa fa-window-minimize",maximize:"fa fa-window-maximize",close:"fa fa-close",zoomIn:"fa fa-search-plus",zoomOut:"fa fa-search-minus",prev:"fa fa-arrow-left",next:"fa fa-arrow-right",fullscreen:"fa fa-photo",actualSize:"fa fa-arrows-alt",rotateLeft:"fa fa-rotate-left",rotateRight:"fa fa-rotate-right"},i18n:{minimize:"minimize",maximize:"maximize",close:"close",zoomIn:"zoom-in(+)",zoomOut:"zoom-out(-)",prev:"prev(←)",next:"next(→)",fullscreen:"fullscreen",actualSize:"actual-size(Ctrl+Alt+0)",rotateLeft:"rotate-left(Ctrl+,)",rotateRight:"rotate-right(Ctrl+.)"},multiInstances:!0,initEvent:"click",initAnimation:!0,fixedModalPos:!1,zIndex:1090,dragHandle:!1,callbacks:{beforeOpen:t.noop,opened:t.noop,beforeClose:t.noop,closed:t.noop,beforeChange:t.noop,changed:t.noop}},d={isMoving:!1,isResizing:!1,zIndex:f.zIndex},c=null,p=function(i,e){this.options=t.extend(!0,{},f,e),e&&t.isArray(e.footToolbar)&&(this.options.footToolbar=e.footToolbar),e&&t.isArray(e.headToolbar)&&(this.options.headToolbar=e.headToolbar),this.$el=t(i),this.isOpened=!1,this.isMaximized=!1,this.isRotated=!1,this.rotateAngle=0,this.imageData={},this.modalData={width:null,height:null,left:null,top:null},this.init(i,this.options)};p.prototype={init:function(e,a){var s=i(e);this.groupName=null;var n=t(e).attr("data-group"),r=h.find('[data-group="'+n+'"]');void 0!==n?(this.groupName=n,this.getImgGroup(r,s)):this.getImgGroup(c.not("[data-group]"),s),this.open(),this.loadImg(s),a.draggable&&this.draggable(this.$magnify,this.dragHandle,".magnify-button"),a.movable&&this.movable(this.$stage,o()?".magnify-image":this.$image),a.resizable&&this.resizable(this.$magnify,this.$stage,o()?".magnify-image":this.$image,a.modalWidth,a.modalHeight)},_creatBtns:function(i,e){var a="";return t.each(i,function(t,i){a+=e[i]}),a},_creatTitle:function(){return this.options.title?'
':""},creatDOM:function(){var t={minimize:'',maximize:'',close:'',zoomIn:'',zoomOut:'',prev:'',next:'',fullscreen:'',actualSize:'',rotateLeft:'',rotateRight:''};return'
'+this._creatBtns(this.options.headToolbar,t)+"
"+this._creatTitle()+'
"},build:function(){var i=this.creatDOM(),e=t(i);this.$magnify=e,this.$header=e.find(".magnify-header"),this.$headToolbar=e.find(".magnify-head-toolbar"),this.$footer=e.find(".magnify-footer"),this.$footToolbar=e.find(".magnify-foot-toolbar"),this.$stage=e.find(".magnify-stage"),this.$title=e.find(".magnify-title"),this.$image=e.find(".magnify-image"),this.$close=e.find(".magnify-button-close"),this.$maximize=e.find(".magnify-button-maximize"),this.$minimize=e.find(".magnify-button-minimize"),this.$zoomIn=e.find(".magnify-button-zoom-in"),this.$zoomOut=e.find(".magnify-button-zoom-out"),this.$actualSize=e.find(".magnify-button-actual-size"),this.$fullscreen=e.find(".magnify-button-fullscreen"),this.$rotateLeft=e.find(".magnify-button-rotate-left"),this.$rotateRight=e.find(".magnify-button-rotate-right"),this.$prev=e.find(".magnify-button-prev"),this.$next=e.find(".magnify-button-next"),this.$stage.addClass("stage-ready"),this.$image.addClass("image-ready"),this.$magnify.css("z-index",d.zIndex),this.options.dragHandle&&".magnify-modal"!==this.options.dragHandle?this.dragHandle=this.$magnify.find(this.options.dragHandle):this.dragHandle=this.$magnify},open:function(){if(this.options.multiInstances||t(".magnify-modal").eq(0).remove(),!t(".magnify-modal").length&&this.options.fixedContent&&(t("html").css({overflow:"hidden"}),document.body.scrollHeight>(window.innerHeight||document.documentElement.clientHeight))){var i=function(){var t=document.createElement("div");t.style.cssText="width: 99px; height: 99px; overflow: scroll; position: absolute; top: -9999px;",document.body.appendChild(t);var i=t.offsetWidth-t.clientWidth;return document.body.removeChild(t),i}();i&&t("html").css({"padding-right":i})}this.build(),this._triggerHook("beforeOpen",this.$el),t("body").append(this.$magnify),this.addEvents(),this.setModalPos(this.$magnify),this._triggerHook("opened",this.$el)},close:function(i){this._triggerHook("beforeClose",this.$el),this.$magnify.remove(),this.isOpened=!1,this.isMaximized=!1,this.isRotated=!1,this.rotateAngle=0;var e=!t(".magnify-modal").length;e&&this.options.fixedContent&&t("html").css({overflow:"","padding-right":""}),e&&this.options.multiInstances&&(d.zIndex=this.options.zIndex),t(".magnify-modal").length||(h.off("keydown.magnify"),n.off("resize.magnify")),this._triggerHook("closed",this.$el)},setModalPos:function(t){var i=n.width(),e=n.height(),a=h.scrollLeft(),s=h.scrollTop(),o=this.options.modalWidth,r=this.options.modalHeight;this.options.initMaximized?(t.addClass("magnify-maximize"),t.css({width:"100%",height:"100%",left:0,top:0}),this.isOpened=!0,this.isMaximized=!0):t.css({width:o,height:r,left:(i-o)/2+a+"px",top:(e-r)/2+s+"px"})},setModalSize:function(t){var i=this,a=n.width(),s=n.height(),o=h.scrollLeft(),r=h.scrollTop(),l={left:this.$stage.css("left"),right:this.$stage.css("right"),top:this.$stage.css("top"),bottom:this.$stage.css("bottom"),borderLeft:this.$stage.css("border-left-width"),borderRight:this.$stage.css("border-right-width"),borderTop:this.$stage.css("border-top-width"),borderBottom:this.$stage.css("border-bottom-width")},g=t.width+e(l.left)+e(l.right)+e(l.borderLeft)+e(l.borderRight),m=t.height+e(l.top)+e(l.bottom)+e(l.borderTop)+e(l.borderBottom),f=(this.options.gapThreshold>0?this.options.gapThreshold:0)+1,d=Math.min(a/(g*f),s/(m*f),1),c=Math.max(g*d,this.options.modalWidth),p=Math.max(m*d,this.options.modalHeight),u={width:(c=this.options.fixedModalSize?this.options.modalWidth:Math.round(c))+"px",height:(p=this.options.fixedModalSize?this.options.modalHeight:Math.round(p))+"px",left:(a-c)/2+o+"px",top:(s-p)/2+r+"px"};this.options.initAnimation?this.$magnify.animate(u,function(){i.setImageSize(t)}):(this.$magnify.css(u),this.setImageSize(t)),this.isOpened=!0},setImageSize:function(i){var e=o()?this.$stage.find(".magnify-image"):this.$image,s={w:this.$stage.width(),h:this.$stage.height()},n=1;n=this.isRotated?Math.min(s.w/i.height,s.h/i.width,1):Math.min(s.w/i.width,s.h/i.height,1),e.css({width:Math.ceil(i.width*n)+"px",height:Math.ceil(i.height*n)+"px",left:(s.w-Math.ceil(i.width*n))/2+"px",top:(s.h-Math.ceil(i.height*n))/2+"px"}),o()&&e.find("group").css({width:Math.floor(i.width*n)+"px",height:Math.floor(i.height*n)+"px"}),t.extend(this.imageData,{width:i.width*n,height:i.height*n,left:(s.w-i.width*n)/2,top:(s.h-i.height*n)/2}),a({w:e.width(),h:e.height()},{w:this.$stage.width(),h:this.$stage.height()},this.$stage,this.isRotated),this.$magnify.find(".magnify-loader").remove(),this.options.initAnimation&&e.fadeIn()},loadImg:function(t){var i=this;this.$magnify.append('
'),this.options.initAnimation&&this.$image.hide(),o()?this.$stage.html(''):this.$image.attr("src",t),function(t,i,e){var a=new Image;a.onload=function(){i(a)},a.onerror=function(){e(a)},a.src=t}(t,function(t){i.imageData={originalWidth:t.width,originalHeight:t.height},i.isMaximized||i.isOpened&&i.options.fixedModalPos?i.setImageSize(t):i.setModalSize(t),i.$stage.removeClass("stage-ready"),i.$image.removeClass("image-ready")},function(){i.$magnify.find(".magnify-loader").remove()}),this.options.title&&this.setImgTitle(t)},getImgGroup:function(e,a){var s=this;s.groupData=[],t(e).each(function(e,o){var n=i(this);s.groupData.push({src:n,caption:t(this).attr("data-caption")}),a===n&&(s.groupIndex=e)})},setImgTitle:function(t){var i=this.groupIndex,e=(e=this.groupData[i].caption)||function(t){return t.replace(/^.*?\/*([^/?]*)\.[a-z]+(\?.+|$)/gi,"$1")}(t);this.$title.html(e)},jump:function(t){this.groupIndex=this.groupIndex+t,this.jumpTo(this.groupIndex)},jumpTo:function(t){(t%=this.groupData.length)>=0?t%=this.groupData.length:t<0&&(t=(this.groupData.length+t)%this.groupData.length),this.groupIndex=t,this._triggerHook("beforeChange",t),this.loadImg(this.groupData[t].src),this._triggerHook("changed",t)},wheel:function(t){t.preventDefault();var i=1;t.originalEvent.deltaY?i=t.originalEvent.deltaY>0?1:-1:t.originalEvent.wheelDelta?i=-t.originalEvent.wheelDelta/120:t.originalEvent.detail&&(i=t.originalEvent.detail>0?1:-1);var e=-i*this.options.ratioThreshold,a={x:t.originalEvent.clientX-this.$stage.offset().left+h.scrollLeft(),y:t.originalEvent.clientY-this.$stage.offset().top+h.scrollTop()};this.zoom(e,a,t)},zoom:function(t,i,e){this.$image=o()?this.$stage.find(".magnify-image"):this.$image,(t=t<0?1/(1-t):1+t)>.95&&t<1.05&&(t=1),t=this.$image.width()/this.imageData.originalWidth*t,t=Math.max(t,this.options.minRatio),t=Math.min(t,this.options.maxRatio),this.zoomTo(t,i,e)},zoomTo:function(i,e,s){var n=o()?this.$stage.find(".magnify-image"):this.$image,h=this.$stage,r={w:this.imageData.width,h:this.imageData.height,x:this.imageData.left,y:this.imageData.top},l={w:h.width(),h:h.height(),x:h.offset().left,y:h.offset().top},g=this.imageData.originalWidth*i,m=this.imageData.originalHeight*i,f=e.x-(e.x-r.x)/r.w*g,d=e.y-(e.y-r.y)/r.h*m,c=this.isRotated?(g-m)/2:0,p=this.isRotated?m:g,u=this.isRotated?g:m,y=l.w-g,_=l.h-m; +!function(t){"function"==typeof define&&define.amd?define(["jquery"],t):t("object"==typeof exports?require("jquery"):jQuery)}(function(t){"use strict";function i(i){return t(i).attr("data-src")?t(i).attr("data-src"):t(i).attr("href")}function e(t){var i=t.match(/\d+/g);return parseFloat(i[0])}function a(t,i,e,a){var s=a?t.h:t.w,o=a?t.w:t.h;(o>i.h||s>i.w)&&e.addClass("is-grab"),o<=i.h&&s<=i.w&&e.removeClass("is-grab")}function s(){return!!("ontouchstart"in window||window.DocumentTouch&&document instanceof DocumentTouch)}function o(){return"Microsoft Internet Explorer"==navigator.appName&&navigator.appVersion.indexOf("MSIE 8.0")>0||"Microsoft Internet Explorer"==navigator.appName&&navigator.appVersion.indexOf("MSIE 7.0")>0}var n=t(window),h=t(document),r=s()?"touchstart":"mousedown",l=s()?"touchmove":"mousemove",g=s()?"touchend":"mouseup",c=".magnify",m={draggable:!0,resizable:!0,movable:!0,keyboard:!0,title:!0,modalWidth:320,modalHeight:320,fixedContent:!0,fixedModalSize:!1,initMaximized:!1,gapThreshold:.02,ratioThreshold:.1,minRatio:.1,maxRatio:16,headToolbar:["maximize","close"],footToolbar:["zoomIn","zoomOut","prev","fullscreen","next","actualSize","rotateRight"],icons:{minimize:' ',maximize:' ',close:' ',zoomIn:' ',zoomOut:' ',prev:' ',next:' ',fullscreen:' ',actualSize:' ',rotateLeft:' ',rotateRight:' '},i18n:{minimize:"minimize",maximize:"maximize",close:"close",zoomIn:"zoom-in(+)",zoomOut:"zoom-out(-)",prev:"prev(←)",next:"next(→)",fullscreen:"fullscreen",actualSize:"actual-size(Ctrl+Alt+0)",rotateLeft:"rotate-left(Ctrl+,)",rotateRight:"rotate-right(Ctrl+.)"},multiInstances:!0,initEvent:"click",initAnimation:!0,fixedModalPos:!1,zIndex:1090,dragHandle:!1,callbacks:{beforeOpen:t.noop,opened:t.noop,beforeClose:t.noop,closed:t.noop,beforeChange:t.noop,changed:t.noop}},f={isMoving:!1,isResizing:!1,zIndex:m.zIndex},d=null,p=function(i,e){this.options=t.extend(!0,{},m,e),e&&t.isArray(e.footToolbar)&&(this.options.footToolbar=e.footToolbar),e&&t.isArray(e.headToolbar)&&(this.options.headToolbar=e.headToolbar),this.$el=t(i),this.isOpened=!1,this.isMaximized=!1,this.isRotated=!1,this.rotateAngle=0,this.imageData={},this.modalData={width:null,height:null,left:null,top:null},this.init(i,this.options)};p.prototype={init:function(e,a){var s=i(e);this.groupName=null;var n=t(e).attr("data-group"),r=h.find('[data-group="'+n+'"]');void 0!==n?(this.groupName=n,this.getImgGroup(r,s)):this.getImgGroup(d.not("[data-group]"),s),this.open(),this.loadImg(s),a.draggable&&this.draggable(this.$magnify,this.dragHandle,".magnify-button"),a.movable&&this.movable(this.$stage,o()?".magnify-image":this.$image),a.resizable&&this.resizable(this.$magnify,this.$stage,o()?".magnify-image":this.$image,a.modalWidth,a.modalHeight)},_creatBtns:function(i,e){var a="";return t.each(i,function(t,i){a+=e[i]}),a},_creatTitle:function(){return this.options.title?'
':""},creatDOM:function(){var t={minimize:'",maximize:'",close:'",zoomIn:'",zoomOut:'",prev:'",next:'",fullscreen:'",actualSize:'",rotateLeft:'",rotateRight:'"};return'
'+this._creatBtns(this.options.headToolbar,t)+"
"+this._creatTitle()+'
"},build:function(){var i=this.creatDOM(),e=t(i);this.$magnify=e,this.$header=e.find(".magnify-header"),this.$headToolbar=e.find(".magnify-head-toolbar"),this.$footer=e.find(".magnify-footer"),this.$footToolbar=e.find(".magnify-foot-toolbar"),this.$stage=e.find(".magnify-stage"),this.$title=e.find(".magnify-title"),this.$image=e.find(".magnify-image"),this.$close=e.find(".magnify-button-close"),this.$maximize=e.find(".magnify-button-maximize"),this.$minimize=e.find(".magnify-button-minimize"),this.$zoomIn=e.find(".magnify-button-zoom-in"),this.$zoomOut=e.find(".magnify-button-zoom-out"),this.$actualSize=e.find(".magnify-button-actual-size"),this.$fullscreen=e.find(".magnify-button-fullscreen"),this.$rotateLeft=e.find(".magnify-button-rotate-left"),this.$rotateRight=e.find(".magnify-button-rotate-right"),this.$prev=e.find(".magnify-button-prev"),this.$next=e.find(".magnify-button-next"),this.$stage.addClass("stage-ready"),this.$image.addClass("image-ready"),this.$magnify.css("z-index",f.zIndex),this.options.dragHandle&&".magnify-modal"!==this.options.dragHandle?this.dragHandle=this.$magnify.find(this.options.dragHandle):this.dragHandle=this.$magnify},open:function(){if(this.options.multiInstances||t(".magnify-modal").eq(0).remove(),!t(".magnify-modal").length&&this.options.fixedContent&&(t("html").css({overflow:"hidden"}),document.body.scrollHeight>(window.innerHeight||document.documentElement.clientHeight))){var i=function(){var t=document.createElement("div");t.style.cssText="width: 99px; height: 99px; overflow: scroll; position: absolute; top: -9999px;",document.body.appendChild(t);var i=t.offsetWidth-t.clientWidth;return document.body.removeChild(t),i}();i&&t("html").css({"padding-right":i})}this.build(),this._triggerHook("beforeOpen",this.$el),t("body").append(this.$magnify),this.addEvents(),this.setModalPos(this.$magnify),this._triggerHook("opened",this.$el)},close:function(i){this._triggerHook("beforeClose",this.$el),this.$magnify.remove(),this.isOpened=!1,this.isMaximized=!1,this.isRotated=!1,this.rotateAngle=0;var e=!t(".magnify-modal").length;e&&this.options.fixedContent&&t("html").css({overflow:"","padding-right":""}),e&&this.options.multiInstances&&(f.zIndex=this.options.zIndex),t(".magnify-modal").length||(h.off("keydown.magnify"),n.off("resize.magnify")),this._triggerHook("closed",this.$el)},setModalPos:function(t){var i=n.width(),e=n.height(),a=h.scrollLeft(),s=h.scrollTop(),o=this.options.modalWidth,r=this.options.modalHeight;this.options.initMaximized?(t.addClass("magnify-maximize"),t.css({width:"100%",height:"100%",left:0,top:0}),this.isOpened=!0,this.isMaximized=!0):t.css({width:o,height:r,left:(i-o)/2+a+"px",top:(e-r)/2+s+"px"})},setModalSize:function(t){var i=this,a=n.width(),s=n.height(),o=h.scrollLeft(),r=h.scrollTop(),l={left:this.$stage.css("left"),right:this.$stage.css("right"),top:this.$stage.css("top"),bottom:this.$stage.css("bottom"),borderLeft:this.$stage.css("border-left-width"),borderRight:this.$stage.css("border-right-width"),borderTop:this.$stage.css("border-top-width"),borderBottom:this.$stage.css("border-bottom-width")},g=t.width+e(l.left)+e(l.right)+e(l.borderLeft)+e(l.borderRight),c=t.height+e(l.top)+e(l.bottom)+e(l.borderTop)+e(l.borderBottom),m=(this.options.gapThreshold>0?this.options.gapThreshold:0)+1,f=Math.min(a/(g*m),s/(c*m),1),d=Math.max(g*f,this.options.modalWidth),p=Math.max(c*f,this.options.modalHeight),u={width:(d=this.options.fixedModalSize?this.options.modalWidth:Math.round(d))+"px",height:(p=this.options.fixedModalSize?this.options.modalHeight:Math.round(p))+"px",left:(a-d)/2+o+"px",top:(s-p)/2+r+"px"};this.options.initAnimation?this.$magnify.animate(u,function(){i.setImageSize(t)}):(this.$magnify.css(u),this.setImageSize(t)),this.isOpened=!0},setImageSize:function(i){var e=o()?this.$stage.find(".magnify-image"):this.$image,s={w:this.$stage.width(),h:this.$stage.height()},n=1;n=this.isRotated?Math.min(s.w/i.height,s.h/i.width,1):Math.min(s.w/i.width,s.h/i.height,1),e.css({width:Math.ceil(i.width*n)+"px",height:Math.ceil(i.height*n)+"px",left:(s.w-Math.ceil(i.width*n))/2+"px",top:(s.h-Math.ceil(i.height*n))/2+"px"}),o()&&e.find("group").css({width:Math.floor(i.width*n)+"px",height:Math.floor(i.height*n)+"px"}),t.extend(this.imageData,{width:i.width*n,height:i.height*n,left:(s.w-i.width*n)/2,top:(s.h-i.height*n)/2}),a({w:e.width(),h:e.height()},{w:this.$stage.width(),h:this.$stage.height()},this.$stage,this.isRotated),this.$magnify.find(".magnify-loader").remove(),this.options.initAnimation&&e.fadeIn()},loadImg:function(t){var i=this;this.$magnify.append('
'),this.options.initAnimation&&this.$image.hide(),o()?this.$stage.html(''):this.$image.attr("src",t),function(t,i,e){var a=new Image;a.onload=function(){i(a)},a.onerror=function(){e(a)},a.src=t}(t,function(t){i.imageData={originalWidth:t.width,originalHeight:t.height},i.isMaximized||i.isOpened&&i.options.fixedModalPos?i.setImageSize(t):i.setModalSize(t),i.$stage.removeClass("stage-ready"),i.$image.removeClass("image-ready")},function(){i.$magnify.find(".magnify-loader").remove()}),this.options.title&&this.setImgTitle(t)},getImgGroup:function(e,a){var s=this;s.groupData=[],t(e).each(function(e,o){var n=i(this);s.groupData.push({src:n,caption:t(this).attr("data-caption")}),a===n&&(s.groupIndex=e)})},setImgTitle:function(t){var i=this.groupIndex,e=(e=this.groupData[i].caption)||function(t){return t.replace(/^.*?\/*([^/?]*)\.[a-z]+(\?.+|$)/gi,"$1")}(t);this.$title.html(e)},jump:function(t){this.groupIndex=this.groupIndex+t,this.jumpTo(this.groupIndex)},jumpTo:function(t){(t%=this.groupData.length)>=0?t%=this.groupData.length:t<0&&(t=(this.groupData.length+t)%this.groupData.length),this.groupIndex=t,this._triggerHook("beforeChange",t),this.loadImg(this.groupData[t].src),this._triggerHook("changed",t)},wheel:function(t){t.preventDefault();var i=1;t.originalEvent.deltaY?i=t.originalEvent.deltaY>0?1:-1:t.originalEvent.wheelDelta?i=-t.originalEvent.wheelDelta/120:t.originalEvent.detail&&(i=t.originalEvent.detail>0?1:-1);var e=-i*this.options.ratioThreshold,a={x:t.originalEvent.clientX-this.$stage.offset().left+h.scrollLeft(),y:t.originalEvent.clientY-this.$stage.offset().top+h.scrollTop()};this.zoom(e,a,t)},zoom:function(t,i,e){this.$image=o()?this.$stage.find(".magnify-image"):this.$image,(t=t<0?1/(1-t):1+t)>.95&&t<1.05&&(t=1),t=this.$image.width()/this.imageData.originalWidth*t,t=Math.max(t,this.options.minRatio),t=Math.min(t,this.options.maxRatio),this.zoomTo(t,i,e)},zoomTo:function(i,e,s){var n=o()?this.$stage.find(".magnify-image"):this.$image,h=this.$stage,r={w:this.imageData.width,h:this.imageData.height,x:this.imageData.left,y:this.imageData.top},l={w:h.width(),h:h.height(),x:h.offset().left,y:h.offset().top},g=this.imageData.originalWidth*i,c=this.imageData.originalHeight*i,m=e.x-(e.x-r.x)/r.w*g,f=e.y-(e.y-r.y)/r.h*c,d=this.isRotated?(g-c)/2:0,p=this.isRotated?c:g,u=this.isRotated?g:c,v=l.w-g,y=l.h-c; // The conditions with image rotate 90 degree drive me crazy alomst! -d=u<=l.h?(l.h-m)/2:d>c?c:d>_-c?d:_-c,f=p<=l.w?(l.w-g)/2:f>-c?-c:f>y+c?f:y+c,n.css({width:Math.round(g)+"px",height:Math.round(m)+"px",left:Math.round(f)+"px",top:Math.round(d)+"px"}),o()&&n.find("group").css({width:Math.ceil(g)+"px",height:Math.ceil(m)+"px"}),t.extend(this.imageData,{width:g,height:m,left:f,top:d}),a({w:Math.round(p),h:Math.round(u)},{w:l.w,h:l.h},this.$stage)},rotate:function(t){this.rotateAngle=this.rotateAngle+t,this.rotateAngle/90%2==0?this.isRotated=!1:this.isRotated=!0,this.rotateTo(this.rotateAngle)},rotateTo:function(t){(o()?this.$stage.find(".magnify-image"):this.$image).rotate({angle:t}),this.setImageSize({width:this.imageData.originalWidth,height:this.imageData.originalHeight}),this.$stage.removeClass("is-grab")},resize:function(){var t=this;return function(t,i){var e=null;return function(){var a=this,s=arguments;clearTimeout(e),e=setTimeout(function(){t.apply(a,s)},i)}}(function(){t.isOpened&&(t.isMaximized?t.setImageSize({width:t.imageData.originalWidth,height:t.imageData.originalHeight}):t.setModalSize({width:t.imageData.originalWidth,height:t.imageData.originalHeight}))},500)},maximize:function(){this.isMaximized?(this.$magnify.removeClass("magnify-maximize"),this.$magnify.css({width:this.modalData.width?this.modalData.width:this.options.modalWidth,height:this.modalData.height?this.modalData.height:this.options.modalHeight,left:this.modalData.left?this.modalData.left:(n.width()-this.options.modalWidth)/2+h.scrollLeft(),top:this.modalData.top?this.modalData.top:(n.height()-this.options.modalHeight)/2+h.scrollTop()}),this.isMaximized=!1):(this.modalData={width:this.$magnify.width(),height:this.$magnify.height(),left:this.$magnify.offset().left,top:this.$magnify.offset().top},this.$magnify.addClass("magnify-maximize"),this.$magnify.css({width:"100%",height:"100%",left:0,top:0}),this.isMaximized=!0),this.setImageSize({width:this.imageData.originalWidth,height:this.imageData.originalHeight})},fullscreen:function(){!function(t){t.requestFullscreen?t.requestFullscreen():t.mozRequestFullScreen?t.mozRequestFullScreen():t.webkitRequestFullscreen?t.webkitRequestFullscreen():t.msRequestFullscreen&&t.msRequestFullscreen()}(this.$magnify[0])},keydown:function(t){if(!this.options.keyboard)return!1;var i=t.keyCode||t.which||t.charCode,e=t.ctrlKey||t.metaKey,a=t.altKey||t.metaKey;switch(i){case 37:this.jump(-1);break;case 39:this.jump(1);break;case 187:this.zoom(3*this.options.ratioThreshold,{x:this.$stage.width()/2,y:this.$stage.height()/2},t);break;case 189:this.zoom(3*-this.options.ratioThreshold,{x:this.$stage.width()/2,y:this.$stage.height()/2},t);break;case 61:this.zoom(3*this.options.ratioThreshold,{x:this.$stage.width()/2,y:this.$stage.height()/2},t);break;case 173:this.zoom(3*-this.options.ratioThreshold,{x:this.$stage.width()/2,y:this.$stage.height()/2},t);break;case 48:e&&a&&this.zoomTo(1,{x:this.$stage.width()/2,y:this.$stage.height()/2},t);break;case 188:e&&this.rotate(-90);break;case 190:e&&this.rotate(90)}},addEvents:function(){var t=this;this.$close.off("click.magnify").on("click.magnify",function(i){t.close()}),this.$stage.off("wheel mousewheel DOMMouseScroll.magnify").on("wheel mousewheel DOMMouseScroll.magnify",function(i){t.wheel(i)}),this.$zoomIn.off("click.magnify").on("click.magnify",function(i){t.zoom(3*t.options.ratioThreshold,{x:t.$stage.width()/2,y:t.$stage.height()/2},i)}),this.$zoomOut.off("click.magnify").on("click.magnify",function(i){t.zoom(3*-t.options.ratioThreshold,{x:t.$stage.width()/2,y:t.$stage.height()/2},i)}),this.$actualSize.off("click.magnify").on("click.magnify",function(i){t.zoomTo(1,{x:t.$stage.width()/2,y:t.$stage.height()/2},i)}),this.$prev.off("click.magnify").on("click.magnify",function(){t.jump(-1)}),this.$fullscreen.off("click.magnify").on("click.magnify",function(){t.fullscreen()}),this.$next.off("click.magnify").on("click.magnify",function(){t.jump(1)}),this.$rotateLeft.off("click.magnify").on("click.magnify",function(){t.rotate(-90)}),this.$rotateRight.off("click.magnify").on("click.magnify",function(){t.rotate(90)}),this.$maximize.off("click.magnify").on("click.magnify",function(){t.maximize()}),h.off("keydown.magnify").on("keydown.magnify",function(i){t.keydown(i)}),n.on("resize.magnify",t.resize())},_triggerHook:function(i,e){this.options.callbacks[i]&&this.options.callbacks[i].apply(this,t.isArray(e)?e:[e])}},t.fn.magnify=function(i){c=t(this);for(var e in i)"string"!=typeof i[e]||isNaN(i[e])||(i[e]=parseFloat(i[e]));var a=t.extend(!0,{},f,i);return d.zIndex=a.zIndex,"string"==typeof i||("dblclick"===a.initEvent&&c.off("click.magnify").on("click.magnify",function(t){t.preventDefault(),t.stopPropagation()}),c.off(a.initEvent+m).on(a.initEvent+m,function(e){e.preventDefault(),e.stopPropagation(),t(this).data("magnify",new p(this,i))})),c},h.on("click.magnify","[data-magnify]",function(i){c=t("[data-magnify]"),i.preventDefault(),t(this).data("magnify",new p(this,f))});t.extend(p.prototype,{draggable:function(i,e,a){var s=this,o=!1,n=0,f=0,c=0,p=0,u=function(e){if((e=e||window.event).preventDefault(),o&&!d.isMoving&&!d.isResizing&&!s.isMaximized){var a="touchmove"===e.type?e.originalEvent.targetTouches[0].pageX:e.clientX,h="touchmove"===e.type?e.originalEvent.targetTouches[0].pageY:e.clientY,r=a-n,l=h-f;t(i).css({left:r+c+"px",top:l+p+"px"})}},y=function(t){h.off(l+m,u).off(g+m,y),o=!1};t(e).on(r+m,function(e){if(e=e||window.event,s.options.multiInstances&&i.css("z-index",++d.zIndex),t(e.target).closest(a).length)return!0;o=!0,n="touchstart"===e.type?e.originalEvent.targetTouches[0].pageX:e.clientX,f="touchstart"===e.type?e.originalEvent.targetTouches[0].pageY:e.clientY,c=t(i).offset().left,p=t(i).offset().top,h.on(l+m,u).on(g+m,y)})}});t.extend(p.prototype,{movable:function(i,e){var a=this,s=!1,n=0,f=0,c=0,p=0,u=0,y=0,_=0,v=function(h){(h=h||window.event).preventDefault();var r=o()?t(i).find(e):t(e);if(s){var l="touchmove"===h.type?h.originalEvent.targetTouches[0].pageX:h.clientX,g="touchmove"===h.type?h.originalEvent.targetTouches[0].pageY:h.clientY,m=l-n,d=g-f,v=m+c,b=d+p;y>0?d+p>_?b=_:d+p<-y+_&&(b=-y+_):b=p,u>0?m+c>-_?v=-_:m+c<-u-_&&(v=-u-_):v=c,r.css({left:v+"px",top:b+"px"}),t.extend(a.imageData,{left:v,top:b})}},b=function(i){h.off(l+m,v).off(g+m,b),s=!1,d.isMoving=!1,t("html,body,.magnify-modal,.magnify-stage,.magnify-button,.magnify-resizable-handle").removeClass("is-grabbing")};t(i).on(r+m,function(r){(r=r||window.event).preventDefault();var x=o()?t(i).find(e):t(e),w=x.width(),z=x.height(),$=t(i).width(),T=t(i).height();n="touchstart"===r.type?r.originalEvent.targetTouches[0].pageX:r.clientX,f="touchstart"===r.type?r.originalEvent.targetTouches[0].pageY:r.clientY,_=a.isRotated?(w-z)/2:0,u=a.isRotated?z-$:w-$,y=a.isRotated?w-T:z-T,s=u>0||y>0,d.isMoving=u>0||y>0,c=x.position().left-(o()?0:_),p=x.position().top+(o()?0:_),i.hasClass("is-grab")&&t("html,body,.magnify-modal,.magnify-stage,.magnify-button,.magnify-resizable-handle").addClass("is-grabbing"),h.on(l+m,v).on(g+m,b)})}});t.extend(p.prototype,{resizable:function(i,e,s,n,f){var c=this,p=t('
'),u=t('
'),y=t('
'),_=t('
'),v=t('
'),b=t('
'),x=t('
'),w=t('
'),z={e:p,s:y,se:v,n:_,w:u,nw:w,ne:x,sw:b};t(i).append(p,u,y,_,v,b,x,w);var $=!1,T=0,M=0,k={w:0,h:0,l:0,t:0},C={w:0,h:0,l:0,t:0},D={w:0,h:0,l:0,t:0},S=0,E=0,I=0,O="",W=function(a,n){(n=n||window.event).preventDefault();var r=o()?t(e).find(s):t(s);$=!0,d.isResizing=!0,T="touchstart"===n.type?n.originalEvent.targetTouches[0].pageX:n.clientX,M="touchstart"===n.type?n.originalEvent.targetTouches[0].pageY:n.clientY,k={w:t(i).width(),h:t(i).height(),l:t(i).offset().left,t:t(i).offset().top},C={w:t(e).width(),h:t(e).height(),l:t(e).offset().left,t:t(e).offset().top},D={w:r.width(),h:r.height(),l:r.position().left,t:r.position().top},S=c.isRotated?(D.w-D.h)/2:0,E=c.isRotated?D.h:D.w,I=c.isRotated?D.w:D.h,O=a,t("html,body,.magnify-modal,.magnify-stage,.magnify-button").css("cursor",a+"-resize"),h.on(l+m,H).on(g+m,R)},H=function(a){(a=a||window.event).preventDefault();var h=o()?t(e).find(s):t(s);if($&&!c.isMaximized){var r="touchmove"===a.type?a.originalEvent.targetTouches[0].pageX:a.clientX,l="touchmove"===a.type?a.originalEvent.targetTouches[0].pageY:a.clientY,g=r-T,m=l-M,d=function(t,i,e){var a=-i+k.w>n?i+k.l:k.l+k.w-n,s=-e+k.h>f?e+k.t:k.t+k.h-f;return{e:{width:Math.max(i+k.w,n)+"px"},s:{height:Math.max(e+k.h,f)+"px"},se:{width:Math.max(i+k.w,n)+"px",height:Math.max(e+k.h,f)+"px"},w:{width:Math.max(-i+k.w,n)+"px",left:a+"px"},n:{height:Math.max(-e+k.h,f)+"px",top:s+"px"},nw:{width:Math.max(-i+k.w,n)+"px",height:Math.max(-e+k.h,f)+"px",top:s+"px",left:a+"px"},ne:{width:Math.max(i+k.w,n)+"px",height:Math.max(-e+k.h,f)+"px",top:s+"px"},sw:{width:Math.max(-i+k.w,n)+"px",height:Math.max(e+k.h,f)+"px",left:a+"px"}}[t]}(O,g,m);t(i).css(d);var p=function(i,a,h){var r=o()?t(e).find(s):t(s),l=o()?r.position().left+S:r.position().left,g=o()?r.position().top-S:r.position().top,m=a+k.w>n?C.w-E+a-S:n-(k.w-C.w)-E-S,d=h+k.h>f?C.h-I+h+S:f-(k.h-C.h)-I+S,c=-a+k.w>n?C.w-E-a-S:n-(k.w-C.w)-E-S,p=-h+k.h>f?C.h-I-h+S:f-(k.h-C.h)-I+S,u=(m>0?l:l<0?l:0)-S,y=(d>0?g:g<0?g:0)+S,_=(c>0?l:l<0?l:0)-S,v=(p>0?g:g<0?g:0)+S;return{e:{left:m>=-S?(m-S)/2+"px":u>m?u+"px":m+"px"},s:{top:d>=S?(d+S)/2+"px":y>d?y+"px":d+"px"},se:{top:d>=S?(d+S)/2+"px":y>d?y+"px":d+"px",left:m>=-S?(m-S)/2+"px":u>m?u+"px":m+"px"},w:{left:c>=-S?(c-S)/2+"px":_>c?_+"px":c+"px"},n:{top:p>=S?(p+S)/2+"px":v>p?v+"px":p+"px"},nw:{top:p>=S?(p+S)/2+"px":v>p?v+"px":p+"px",left:c>=-S?(c-S)/2+"px":_>c?_+"px":c+"px"},ne:{top:p>=S?(p+S)/2+"px":v>p?v+"px":p+"px",left:m>=-S?(m-S)/2+"px":u>m?u+"px":m+"px"},sw:{top:d>=S?(d+S)/2+"px":y>d?y+"px":d+"px",left:c>=-S?(c-S)/2+"px":_>c?_+"px":c+"px"}}[i]}(O,g,m);h.css(p)}},R=function(i){h.off(l+m,H).off(g+m,R),d.isResizing&&a({w:E,h:I},{w:t(e).width(),h:t(e).height()},e),$=!1,d.isResizing=!1,t("html,body,.magnify-modal,.magnify-stage,.magnify-button").css("cursor","")};t.each(z,function(t,i){i.on(r+m,function(i){W(t,i)})})}})}),function($){for(var supportedCSS,supportedCSSOrigin,styles=document.getElementsByTagName("head")[0].style,toCheck="transformProperty WebkitTransform OTransform msTransform MozTransform".split(" "),a=0;ad?d:f>y-d?f:y-d,m=p<=l.w?(l.w-g)/2:m>-d?-d:m>v+d?m:v+d,n.css({width:Math.round(g)+"px",height:Math.round(c)+"px",left:Math.round(m)+"px",top:Math.round(f)+"px"}),o()&&n.find("group").css({width:Math.ceil(g)+"px",height:Math.ceil(c)+"px"}),t.extend(this.imageData,{width:g,height:c,left:m,top:f}),a({w:Math.round(p),h:Math.round(u)},{w:l.w,h:l.h},this.$stage)},rotate:function(t){this.rotateAngle=this.rotateAngle+t,this.rotateAngle/90%2==0?this.isRotated=!1:this.isRotated=!0,this.rotateTo(this.rotateAngle)},rotateTo:function(t){(o()?this.$stage.find(".magnify-image"):this.$image).rotate({angle:t}),this.setImageSize({width:this.imageData.originalWidth,height:this.imageData.originalHeight}),this.$stage.removeClass("is-grab")},resize:function(){var t=this;return function(t,i){var e=null;return function(){var a=this,s=arguments;clearTimeout(e),e=setTimeout(function(){t.apply(a,s)},i)}}(function(){t.isOpened&&(t.isMaximized?t.setImageSize({width:t.imageData.originalWidth,height:t.imageData.originalHeight}):t.setModalSize({width:t.imageData.originalWidth,height:t.imageData.originalHeight}))},500)},maximize:function(){this.isMaximized?(this.$magnify.removeClass("magnify-maximize"),this.$magnify.css({width:this.modalData.width?this.modalData.width:this.options.modalWidth,height:this.modalData.height?this.modalData.height:this.options.modalHeight,left:this.modalData.left?this.modalData.left:(n.width()-this.options.modalWidth)/2+h.scrollLeft(),top:this.modalData.top?this.modalData.top:(n.height()-this.options.modalHeight)/2+h.scrollTop()}),this.isMaximized=!1):(this.modalData={width:this.$magnify.width(),height:this.$magnify.height(),left:this.$magnify.offset().left,top:this.$magnify.offset().top},this.$magnify.addClass("magnify-maximize"),this.$magnify.css({width:"100%",height:"100%",left:0,top:0}),this.isMaximized=!0),this.setImageSize({width:this.imageData.originalWidth,height:this.imageData.originalHeight})},fullscreen:function(){!function(t){t.requestFullscreen?t.requestFullscreen():t.mozRequestFullScreen?t.mozRequestFullScreen():t.webkitRequestFullscreen?t.webkitRequestFullscreen():t.msRequestFullscreen&&t.msRequestFullscreen()}(this.$magnify[0])},keydown:function(t){if(!this.options.keyboard)return!1;var i=t.keyCode||t.which||t.charCode,e=t.ctrlKey||t.metaKey,a=t.altKey||t.metaKey;switch(i){case 37:this.jump(-1);break;case 39:this.jump(1);break;case 187:this.zoom(3*this.options.ratioThreshold,{x:this.$stage.width()/2,y:this.$stage.height()/2},t);break;case 189:this.zoom(3*-this.options.ratioThreshold,{x:this.$stage.width()/2,y:this.$stage.height()/2},t);break;case 61:this.zoom(3*this.options.ratioThreshold,{x:this.$stage.width()/2,y:this.$stage.height()/2},t);break;case 173:this.zoom(3*-this.options.ratioThreshold,{x:this.$stage.width()/2,y:this.$stage.height()/2},t);break;case 48:e&&a&&this.zoomTo(1,{x:this.$stage.width()/2,y:this.$stage.height()/2},t);break;case 188:e&&this.rotate(-90);break;case 190:e&&this.rotate(90)}},addEvents:function(){var t=this;this.$close.off("click.magnify").on("click.magnify",function(i){t.close()}),this.$stage.off("wheel mousewheel DOMMouseScroll.magnify").on("wheel mousewheel DOMMouseScroll.magnify",function(i){t.wheel(i)}),this.$zoomIn.off("click.magnify").on("click.magnify",function(i){t.zoom(3*t.options.ratioThreshold,{x:t.$stage.width()/2,y:t.$stage.height()/2},i)}),this.$zoomOut.off("click.magnify").on("click.magnify",function(i){t.zoom(3*-t.options.ratioThreshold,{x:t.$stage.width()/2,y:t.$stage.height()/2},i)}),this.$actualSize.off("click.magnify").on("click.magnify",function(i){t.zoomTo(1,{x:t.$stage.width()/2,y:t.$stage.height()/2},i)}),this.$prev.off("click.magnify").on("click.magnify",function(){t.jump(-1)}),this.$fullscreen.off("click.magnify").on("click.magnify",function(){t.fullscreen()}),this.$next.off("click.magnify").on("click.magnify",function(){t.jump(1)}),this.$rotateLeft.off("click.magnify").on("click.magnify",function(){t.rotate(-90)}),this.$rotateRight.off("click.magnify").on("click.magnify",function(){t.rotate(90)}),this.$maximize.off("click.magnify").on("click.magnify",function(){t.maximize()}),h.off("keydown.magnify").on("keydown.magnify",function(i){t.keydown(i)}),n.on("resize.magnify",t.resize())},_triggerHook:function(i,e){this.options.callbacks[i]&&this.options.callbacks[i].apply(this,t.isArray(e)?e:[e])}},t.fn.magnify=function(i){d=t(this);for(var e in i)"string"!=typeof i[e]||isNaN(i[e])||(i[e]=parseFloat(i[e]));var a=t.extend(!0,{},m,i);return f.zIndex=a.zIndex,"string"==typeof i||("dblclick"===a.initEvent&&d.off("click.magnify").on("click.magnify",function(t){t.preventDefault(),t.stopPropagation()}),d.off(a.initEvent+c).on(a.initEvent+c,function(e){e.preventDefault(),e.stopPropagation(),t(this).data("magnify",new p(this,i))})),d},h.on("click.magnify","[data-magnify]",function(i){d=t("[data-magnify]"),i.preventDefault(),t(this).data("magnify",new p(this,m))});t.extend(p.prototype,{draggable:function(i,e,a){var s=this,o=!1,n=0,m=0,d=0,p=0,u=function(e){if((e=e||window.event).preventDefault(),o&&!f.isMoving&&!f.isResizing&&!s.isMaximized){var a="touchmove"===e.type?e.originalEvent.targetTouches[0].pageX:e.clientX,h="touchmove"===e.type?e.originalEvent.targetTouches[0].pageY:e.clientY,r=a-n,l=h-m;t(i).css({left:r+d+"px",top:l+p+"px"})}},v=function(t){h.off(l+c,u).off(g+c,v),o=!1};t(e).on(r+c,function(e){if(e=e||window.event,s.options.multiInstances&&i.css("z-index",++f.zIndex),t(e.target).closest(a).length)return!0;o=!0,n="touchstart"===e.type?e.originalEvent.targetTouches[0].pageX:e.clientX,m="touchstart"===e.type?e.originalEvent.targetTouches[0].pageY:e.clientY,d=t(i).offset().left,p=t(i).offset().top,h.on(l+c,u).on(g+c,v)})}});t.extend(p.prototype,{movable:function(i,e){var a=this,s=!1,n=0,m=0,d=0,p=0,u=0,v=0,y=0,_=function(h){(h=h||window.event).preventDefault();var r=o()?t(i).find(e):t(e);if(s){var l="touchmove"===h.type?h.originalEvent.targetTouches[0].pageX:h.clientX,g="touchmove"===h.type?h.originalEvent.targetTouches[0].pageY:h.clientY,c=l-n,f=g-m,_=c+d,b=f+p;v>0?f+p>y?b=y:f+p<-v+y&&(b=-v+y):b=p,u>0?c+d>-y?_=-y:c+d<-u-y&&(_=-u-y):_=d,r.css({left:_+"px",top:b+"px"}),t.extend(a.imageData,{left:_,top:b})}},b=function(i){h.off(l+c,_).off(g+c,b),s=!1,f.isMoving=!1,t("html,body,.magnify-modal,.magnify-stage,.magnify-button,.magnify-resizable-handle").removeClass("is-grabbing")};t(i).on(r+c,function(r){(r=r||window.event).preventDefault();var x=o()?t(i).find(e):t(e),w=x.width(),z=x.height(),$=t(i).width(),M=t(i).height();n="touchstart"===r.type?r.originalEvent.targetTouches[0].pageX:r.clientX,m="touchstart"===r.type?r.originalEvent.targetTouches[0].pageY:r.clientY,y=a.isRotated?(w-z)/2:0,u=a.isRotated?z-$:w-$,v=a.isRotated?w-M:z-M,s=u>0||v>0,f.isMoving=u>0||v>0,d=x.position().left-(o()?0:y),p=x.position().top+(o()?0:y),i.hasClass("is-grab")&&t("html,body,.magnify-modal,.magnify-stage,.magnify-button,.magnify-resizable-handle").addClass("is-grabbing"),h.on(l+c,_).on(g+c,b)})}});t.extend(p.prototype,{resizable:function(i,e,s,n,m){var d=this,p=t('
'),u=t('
'),v=t('
'),y=t('
'),_=t('
'),b=t('
'),x=t('
'),w=t('
'),z={e:p,s:v,se:_,n:y,w:u,nw:w,ne:x,sw:b};t(i).append(p,u,v,y,_,b,x,w);var $=!1,M=0,T=0,C={w:0,h:0,l:0,t:0},k={w:0,h:0,l:0,t:0},D={w:0,h:0,l:0,t:0},S=0,E=0,I=0,O="",W=function(a,n){(n=n||window.event).preventDefault();var r=o()?t(e).find(s):t(s);$=!0,f.isResizing=!0,M="touchstart"===n.type?n.originalEvent.targetTouches[0].pageX:n.clientX,T="touchstart"===n.type?n.originalEvent.targetTouches[0].pageY:n.clientY,C={w:t(i).width(),h:t(i).height(),l:t(i).offset().left,t:t(i).offset().top},k={w:t(e).width(),h:t(e).height(),l:t(e).offset().left,t:t(e).offset().top},D={w:r.width(),h:r.height(),l:r.position().left,t:r.position().top},S=d.isRotated?(D.w-D.h)/2:0,E=d.isRotated?D.h:D.w,I=d.isRotated?D.w:D.h,O=a,t("html,body,.magnify-modal,.magnify-stage,.magnify-button").css("cursor",a+"-resize"),h.on(l+c,H).on(g+c,R)},H=function(a){(a=a||window.event).preventDefault();var h=o()?t(e).find(s):t(s);if($&&!d.isMaximized){var r="touchmove"===a.type?a.originalEvent.targetTouches[0].pageX:a.clientX,l="touchmove"===a.type?a.originalEvent.targetTouches[0].pageY:a.clientY,g=r-M,c=l-T,f=function(t,i,e){var a=-i+C.w>n?i+C.l:C.l+C.w-n,s=-e+C.h>m?e+C.t:C.t+C.h-m;return{e:{width:Math.max(i+C.w,n)+"px"},s:{height:Math.max(e+C.h,m)+"px"},se:{width:Math.max(i+C.w,n)+"px",height:Math.max(e+C.h,m)+"px"},w:{width:Math.max(-i+C.w,n)+"px",left:a+"px"},n:{height:Math.max(-e+C.h,m)+"px",top:s+"px"},nw:{width:Math.max(-i+C.w,n)+"px",height:Math.max(-e+C.h,m)+"px",top:s+"px",left:a+"px"},ne:{width:Math.max(i+C.w,n)+"px",height:Math.max(-e+C.h,m)+"px",top:s+"px"},sw:{width:Math.max(-i+C.w,n)+"px",height:Math.max(e+C.h,m)+"px",left:a+"px"}}[t]}(O,g,c);t(i).css(f);var p=function(i,a,h){var r=o()?t(e).find(s):t(s),l=o()?r.position().left+S:r.position().left,g=o()?r.position().top-S:r.position().top,c=a+C.w>n?k.w-E+a-S:n-(C.w-k.w)-E-S,f=h+C.h>m?k.h-I+h+S:m-(C.h-k.h)-I+S,d=-a+C.w>n?k.w-E-a-S:n-(C.w-k.w)-E-S,p=-h+C.h>m?k.h-I-h+S:m-(C.h-k.h)-I+S,u=(c>0?l:l<0?l:0)-S,v=(f>0?g:g<0?g:0)+S,y=(d>0?l:l<0?l:0)-S,_=(p>0?g:g<0?g:0)+S;return{e:{left:c>=-S?(c-S)/2+"px":u>c?u+"px":c+"px"},s:{top:f>=S?(f+S)/2+"px":v>f?v+"px":f+"px"},se:{top:f>=S?(f+S)/2+"px":v>f?v+"px":f+"px",left:c>=-S?(c-S)/2+"px":u>c?u+"px":c+"px"},w:{left:d>=-S?(d-S)/2+"px":y>d?y+"px":d+"px"},n:{top:p>=S?(p+S)/2+"px":_>p?_+"px":p+"px"},nw:{top:p>=S?(p+S)/2+"px":_>p?_+"px":p+"px",left:d>=-S?(d-S)/2+"px":y>d?y+"px":d+"px"},ne:{top:p>=S?(p+S)/2+"px":_>p?_+"px":p+"px",left:c>=-S?(c-S)/2+"px":u>c?u+"px":c+"px"},sw:{top:f>=S?(f+S)/2+"px":v>f?v+"px":f+"px",left:d>=-S?(d-S)/2+"px":y>d?y+"px":d+"px"}}[i]}(O,g,c);h.css(p)}},R=function(i){h.off(l+c,H).off(g+c,R),f.isResizing&&a({w:E,h:I},{w:t(e).width(),h:t(e).height()},e),$=!1,f.isResizing=!1,t("html,body,.magnify-modal,.magnify-stage,.magnify-button").css("cursor","")};t.each(z,function(t,i){i.on(r+c,function(i){W(t,i)})})}})}),function($){for(var supportedCSS,supportedCSSOrigin,styles=document.getElementsByTagName("head")[0].style,toCheck="transformProperty WebkitTransform OTransform msTransform MozTransform".split(" "),a=0;athis._parameters.duration;if(i&&!this._parameters.animatedGif)clearTimeout(this._timer);else{if(this._canvas||this._vimage||this._img){var e=this._parameters.easing(0,t-this._animateStartTime,this._animateStartAngle,this._parameters.animateTo-this._animateStartAngle,this._parameters.duration);this._rotate(~~(10*e)/10)}this._parameters.step&&this._parameters.step(this._angle);var a=this;this._timer=setTimeout(function(){a._animate.call(a)},10)}this._parameters.callback&&i&&(this._angle=this._parameters.animateTo,this._rotate(this._angle),this._parameters.callback.call(this._rootObj))},_rotate:function(){var t=Math.PI/180;return IE?function(t){this._angle=t,this._container.style.rotation=t%360+"deg",this._vimage.style.top=-(this._rotationCenterY-this._imgHeight/2)+"px",this._vimage.style.left=-(this._rotationCenterX-this._imgWidth/2)+"px",this._container.style.top=this._rotationCenterY-this._imgHeight/2+"px",this._container.style.left=this._rotationCenterX-this._imgWidth/2+"px"}:supportedCSS?function(t){this._angle=t,this._img.style[supportedCSS]="rotate("+t%360+"deg)",this._img.style[supportedCSSOrigin]=this._parameters.center.join(" ")}:function(i){this._angle=i,i=i%360*t,this._canvas.width=this._width,this._canvas.height=this._height,this._cnv.translate(this._imgWidth*this._aspectW,this._imgHeight*this._aspectH),this._cnv.translate(this._rotationCenterX,this._rotationCenterY),this._cnv.rotate(i),this._cnv.translate(-this._rotationCenterX,-this._rotationCenterY),this._cnv.scale(this._aspectW,this._aspectH),this._cnv.drawImage(this._img,0,0)}}()},IE&&(Wilq32.PhotoEffect.prototype.createVMLNode=function(){document.createStyleSheet().addRule(".rvml","behavior:url(#default#VML)");try{return!document.namespaces.rvml&&document.namespaces.add("rvml","urn:schemas-microsoft-com:vml"),function(t){return document.createElement("')}}catch(t){return function(t){return document.createElement("<"+t+' xmlns="urn:schemas-microsoft.com:vml" class="rvml">')}}}())}(jQuery); \ No newline at end of file diff --git a/docs/css/jquery.magnify.css b/docs/css/jquery.magnify.css index 2fa39b4..845ad4d 100644 --- a/docs/css/jquery.magnify.css +++ b/docs/css/jquery.magnify.css @@ -6,7 +6,7 @@ * | | | | _ | \_/ | |\ |_| |_| | | | * |__| |__|__| |__|\____/|_|__| \__|_____|__| |__| * - * jquery.magnify - v1.2.0 + * jquery.magnify - v1.3.0 * A jQuery plugin to view images just like in windows * https://github.com/nzbin/magnify#readme * @@ -21,7 +21,8 @@ height: 320px; background-color: #111; background-color: rgba(0, 0, 0, 0.85); - box-shadow: 0 0 3px 1px rgba(0, 0, 0, 0.3); + -webkit-box-shadow: 0 0 3px 1px rgba(0, 0, 0, 0.3); + box-shadow: 0 0 3px 1px rgba(0, 0, 0, 0.3); cursor: default; } @@ -54,7 +55,10 @@ line-height: 1; white-space: nowrap; text-overflow: ellipsis; - user-select: none; + -webkit-user-select: none; + -moz-user-select: none; + -ms-user-select: none; + user-select: none; overflow: hidden; } @@ -101,7 +105,8 @@ display: inline-block; width: 40px; height: 40px; - box-sizing: border-box; + -webkit-box-sizing: border-box; + box-sizing: border-box; margin: 0; padding: 10px; font-size: 14px; @@ -158,12 +163,14 @@ position: relative; width: 36px; height: 36px; - box-sizing: border-box; + -webkit-box-sizing: border-box; + box-sizing: border-box; border-width: 5px; border-style: solid; border-color: rgba(0, 0, 0, 0.5) rgba(0, 0, 0, 0.5) rgba(0, 0, 0, 0.5) rgba(255, 255, 255, 0.5); border-radius: 100%; - animation: magnifyLoading 1s infinite linear; + -webkit-animation: magnifyLoading 1s infinite linear; + animation: magnifyLoading 1s infinite linear; } .magnify-loader::after { @@ -175,12 +182,25 @@ overflow: hidden; } +@-webkit-keyframes magnifyLoading { + 0% { + -webkit-transform: rotateZ(0deg) translate3d(0, 0, 0); + transform: rotateZ(0deg) translate3d(0, 0, 0); + } + 100% { + -webkit-transform: rotateZ(360deg) translate3d(0, 0, 0); + transform: rotateZ(360deg) translate3d(0, 0, 0); + } +} + @keyframes magnifyLoading { 0% { - transform: rotateZ(0deg) translate3d(0, 0, 0); + -webkit-transform: rotateZ(0deg) translate3d(0, 0, 0); + transform: rotateZ(0deg) translate3d(0, 0, 0); } 100% { - transform: rotateZ(360deg) translate3d(0, 0, 0); + -webkit-transform: rotateZ(360deg) translate3d(0, 0, 0); + transform: rotateZ(360deg) translate3d(0, 0, 0); } } @@ -353,6 +373,27 @@ background-color: #000; } +:-webkit-full-screen { + top: 0 !important; + left: 0 !important; + width: 100% !important; + height: 100% !important; +} + +:-moz-full-screen { + top: 0 !important; + left: 0 !important; + width: 100% !important; + height: 100% !important; +} + +:-ms-fullscreen { + top: 0 !important; + left: 0 !important; + width: 100% !important; + height: 100% !important; +} + :fullscreen { top: 0 !important; left: 0 !important; @@ -360,12 +401,57 @@ height: 100% !important; } +:-webkit-full-screen .magnify-header, +:-webkit-full-screen .magnify-footer, +:-webkit-full-screen .magnify-resizable-handle { + display: none; +} + +:-moz-full-screen .magnify-header, +:-moz-full-screen .magnify-footer, +:-moz-full-screen .magnify-resizable-handle { + display: none; +} + +:-ms-fullscreen .magnify-header, +:-ms-fullscreen .magnify-footer, +:-ms-fullscreen .magnify-resizable-handle { + display: none; +} + :fullscreen .magnify-header, :fullscreen .magnify-footer, :fullscreen .magnify-resizable-handle { display: none; } +:-webkit-full-screen .magnify-stage { + top: 0; + right: 0; + bottom: 0; + left: 0; + border-width: 0; + background-color: #000; +} + +:-moz-full-screen .magnify-stage { + top: 0; + right: 0; + bottom: 0; + left: 0; + border-width: 0; + background-color: #000; +} + +:-ms-fullscreen .magnify-stage { + top: 0; + right: 0; + bottom: 0; + left: 0; + border-width: 0; + background-color: #000; +} + :fullscreen .magnify-stage { top: 0; right: 0; @@ -375,6 +461,10 @@ background-color: #000; } +::-webkit-backdrop { + background-color: #000; +} + ::backdrop { background-color: #000; } @@ -394,3 +484,5 @@ cursor: -webkit-grabbing; cursor: grabbing; } + +/*# sourceMappingURL=jquery.magnify.css.map */ \ No newline at end of file diff --git a/docs/js/jquery.magnify.js b/docs/js/jquery.magnify.js index 1620375..d82b983 100644 --- a/docs/js/jquery.magnify.js +++ b/docs/js/jquery.magnify.js @@ -6,7 +6,7 @@ * | | | | _ | \_/ | |\ |_| |_| | | | * |__| |__|__| |__|\____/|_|__| \__|_____|__| |__| * - * jquery.magnify - v1.2.0 + * jquery.magnify - v1.3.0 * A jQuery plugin to view images just like in windows * https://github.com/nzbin/magnify#readme * diff --git a/package.json b/package.json index 8deffa9..98dc8fe 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "jquery.magnify", - "version": "1.2.0", + "version": "1.3.0", "description": "A jQuery plugin to view images just like in Windows", "main": "magnify.js", "homepage": "https://github.com/nzbin/magnify#readme", diff --git a/src/js/intro.js b/src/js/intro.js index 3a0ef11..206e2dc 100644 --- a/src/js/intro.js +++ b/src/js/intro.js @@ -6,7 +6,7 @@ * | | | | _ | \_/ | |\ |_| |_| | | | * |__| |__|__| |__|\____/|_|__| \__|_____|__| |__| * - * jquery.magnify - v1.2.0 + * jquery.magnify - v1.3.0 * A jQuery plugin to view images just like in windows * https://github.com/nzbin/magnify#readme * diff --git a/src/sass/magnify.scss b/src/sass/magnify.scss index aebe7a1..d227512 100644 --- a/src/sass/magnify.scss +++ b/src/sass/magnify.scss @@ -6,7 +6,7 @@ * | | | | _ | \_/ | |\ |_| |_| | | | * |__| |__|__| |__|\____/|_|__| \__|_____|__| |__| * - * jquery.magnify - v1.2.0 + * jquery.magnify - v1.3.0 * A jQuery plugin to view images just like in windows * https://github.com/nzbin/magnify#readme *