This commit is contained in:
2022-05-22 16:52:40 +08:00
parent fce02585b1
commit 5993d86ef9
269 changed files with 22392 additions and 118 deletions
@@ -0,0 +1,846 @@
body.compensate-for-scrollbar {
overflow: hidden
}
.fancybox-active {
height: auto
}
.fancybox-is-hidden {
left: -9999px;
margin: 0;
position: absolute !important;
top: -9999px;
visibility: hidden
}
.fancybox-container {
-webkit-backface-visibility: hidden;
height: 100%;
left: 0;
outline: none;
position: fixed;
-webkit-tap-highlight-color: transparent;
top: 0;
-ms-touch-action: manipulation;
touch-action: manipulation;
transform: translateZ(0);
width: 100%;
z-index: 99992
}
.fancybox-container * {
box-sizing: border-box
}
.fancybox-bg,
.fancybox-inner,
.fancybox-outer,
.fancybox-stage {
bottom: 0;
left: 0;
position: absolute;
right: 0;
top: 0
}
.fancybox-outer {
-webkit-overflow-scrolling: touch;
overflow-y: auto
}
.fancybox-bg {
background: #1e1e1e;
opacity: 0;
transition-duration: inherit;
transition-property: opacity;
transition-timing-function: cubic-bezier(.47, 0, .74, .71)
}
.fancybox-is-open .fancybox-bg {
opacity: .9;
transition-timing-function: cubic-bezier(.22, .61, .36, 1)
}
.fancybox-caption,
.fancybox-infobar,
.fancybox-navigation .fancybox-button,
.fancybox-toolbar {
direction: ltr;
opacity: 0;
position: absolute;
transition: opacity .25s ease, visibility 0s ease .25s;
visibility: hidden;
z-index: 99997
}
.fancybox-show-caption .fancybox-caption,
.fancybox-show-infobar .fancybox-infobar,
.fancybox-show-nav .fancybox-navigation .fancybox-button,
.fancybox-show-toolbar .fancybox-toolbar {
opacity: 1;
transition: opacity .25s ease 0s, visibility 0s ease 0s;
visibility: visible
}
.fancybox-infobar {
color: #ccc;
font-size: 13px;
-webkit-font-smoothing: subpixel-antialiased;
height: 44px;
left: 0;
line-height: 44px;
min-width: 44px;
mix-blend-mode: difference;
padding: 0 10px;
pointer-events: none;
top: 0;
-webkit-touch-callout: none;
-webkit-user-select: none;
-moz-user-select: none;
-ms-user-select: none;
user-select: none
}
.fancybox-toolbar {
right: 0;
top: 0
}
.fancybox-stage {
direction: ltr;
overflow: visible;
transform: translateZ(0);
z-index: 99994
}
.fancybox-is-open .fancybox-stage {
overflow: hidden
}
.fancybox-slide {
-webkit-backface-visibility: hidden;
display: none;
height: 100%;
left: 0;
outline: none;
overflow: auto;
-webkit-overflow-scrolling: touch;
padding: 44px;
position: absolute;
text-align: center;
top: 0;
transition-property: transform, opacity;
white-space: normal;
width: 100%;
z-index: 99994
}
.fancybox-slide:before {
content: "";
display: inline-block;
font-size: 0;
height: 100%;
vertical-align: middle;
width: 0
}
.fancybox-is-sliding .fancybox-slide,
.fancybox-slide--current,
.fancybox-slide--next,
.fancybox-slide--previous {
display: block
}
.fancybox-slide--image {
overflow: hidden;
padding: 44px 0
}
.fancybox-slide--image:before {
display: none
}
.fancybox-slide--html {
padding: 6px
}
.fancybox-content {
background: #fff;
display: inline-block;
margin: 0;
max-width: 100%;
overflow: auto;
-webkit-overflow-scrolling: touch;
padding: 44px;
position: relative;
text-align: left;
vertical-align: middle
}
.fancybox-slide--image .fancybox-content {
animation-timing-function: cubic-bezier(.5, 0, .14, 1);
-webkit-backface-visibility: hidden;
background: transparent;
background-repeat: no-repeat;
background-size: 100% 100%;
left: 0;
max-width: none;
overflow: visible;
padding: 0;
position: absolute;
top: 0;
transform-origin: top left;
transition-property: transform, opacity;
-webkit-user-select: none;
-moz-user-select: none;
-ms-user-select: none;
user-select: none;
z-index: 99995
}
.fancybox-can-zoomOut .fancybox-content {
cursor: zoom-out
}
.fancybox-can-zoomIn .fancybox-content {
cursor: zoom-in
}
.fancybox-can-pan .fancybox-content,
.fancybox-can-swipe .fancybox-content {
cursor: grab
}
.fancybox-is-grabbing .fancybox-content {
cursor: grabbing
}
.fancybox-container [data-selectable=true] {
cursor: text
}
.fancybox-image,
.fancybox-spaceball {
background: transparent;
border: 0;
height: 100%;
left: 0;
margin: 0;
max-height: none;
max-width: none;
padding: 0;
position: absolute;
top: 0;
-webkit-user-select: none;
-moz-user-select: none;
-ms-user-select: none;
user-select: none;
width: 100%
}
.fancybox-spaceball {
z-index: 1
}
.fancybox-slide--iframe .fancybox-content,
.fancybox-slide--map .fancybox-content,
.fancybox-slide--pdf .fancybox-content,
.fancybox-slide--video .fancybox-content {
height: 100%;
overflow: visible;
padding: 0;
width: 100%
}
.fancybox-slide--video .fancybox-content {
background: #000
}
.fancybox-slide--map .fancybox-content {
background: #e5e3df
}
.fancybox-slide--iframe .fancybox-content {
background: #fff
}
.fancybox-iframe,
.fancybox-video {
background: transparent;
border: 0;
display: block;
height: 100%;
margin: 0;
overflow: hidden;
padding: 0;
width: 100%
}
.fancybox-iframe {
left: 0;
position: absolute;
top: 0
}
.fancybox-error {
background: #fff;
cursor: default;
max-width: 400px;
padding: 40px;
width: 100%
}
.fancybox-error p {
color: #444;
font-size: 16px;
line-height: 20px;
margin: 0;
padding: 0
}
.fancybox-button {
background: rgba(30, 30, 30, .6);
border: 0;
border-radius: 0;
box-shadow: none;
cursor: pointer;
display: inline-block;
height: 44px;
margin: 0;
padding: 10px;
position: relative;
transition: color .2s;
vertical-align: top;
visibility: inherit;
width: 44px
}
.fancybox-button,
.fancybox-button:link,
.fancybox-button:visited {
color: #ccc
}
.fancybox-button:hover {
color: #fff
}
.fancybox-button:focus {
outline: none
}
.fancybox-button.fancybox-focus {
outline: 1px dotted
}
.fancybox-button[disabled],
.fancybox-button[disabled]:hover {
color: #888;
cursor: default;
outline: none
}
.fancybox-button div {
height: 100%
}
.fancybox-button svg {
display: block;
height: 100%;
overflow: visible;
position: relative;
width: 100%
}
.fancybox-button svg path {
fill: currentColor;
stroke-width: 0
}
.fancybox-button--fsenter svg:nth-child(2),
.fancybox-button--fsexit svg:first-child,
.fancybox-button--pause svg:first-child,
.fancybox-button--play svg:nth-child(2) {
display: none
}
.fancybox-progress {
background: #ff5268;
height: 2px;
left: 0;
position: absolute;
right: 0;
top: 0;
transform: scaleX(0);
transform-origin: 0;
transition-property: transform;
transition-timing-function: linear;
z-index: 99998
}
.fancybox-close-small {
background: transparent;
border: 0;
border-radius: 0;
color: #ccc;
cursor: pointer;
opacity: .8;
padding: 8px;
position: absolute;
right: -12px;
top: -44px;
z-index: 401
}
.fancybox-close-small:hover {
color: #fff;
opacity: 1
}
.fancybox-slide--html .fancybox-close-small {
color: currentColor;
padding: 10px;
right: 0;
top: 0
}
.fancybox-slide--image.fancybox-is-scaling .fancybox-content {
overflow: hidden
}
.fancybox-is-scaling .fancybox-close-small,
.fancybox-is-zoomable.fancybox-can-pan .fancybox-close-small {
display: none
}
.fancybox-navigation .fancybox-button {
background-clip: content-box;
height: 100px;
opacity: 0;
position: absolute;
top: calc(50% - 50px);
width: 70px
}
.fancybox-navigation .fancybox-button div {
padding: 7px
}
.fancybox-navigation .fancybox-button--arrow_left {
left: 0;
left: env(safe-area-inset-left);
padding: 31px 26px 31px 6px
}
.fancybox-navigation .fancybox-button--arrow_right {
padding: 31px 6px 31px 26px;
right: 0;
right: env(safe-area-inset-right)
}
.fancybox-caption {
background: linear-gradient(0deg, rgba(0, 0, 0, .85) 0, rgba(0, 0, 0, .3) 50%, rgba(0, 0, 0, .15) 65%, rgba(0, 0, 0, .075) 75.5%, rgba(0, 0, 0, .037) 82.85%, rgba(0, 0, 0, .019) 88%, transparent);
bottom: 0;
color: #eee;
font-size: 14px;
font-weight: 400;
left: 0;
line-height: 1.5;
padding: 75px 44px 25px;
pointer-events: none;
right: 0;
text-align: center;
z-index: 99996
}
@supports (padding:max(0px)) {
.fancybox-caption {
padding: 75px max(44px, env(safe-area-inset-right)) max(25px, env(safe-area-inset-bottom)) max(44px, env(safe-area-inset-left))
}
}
.fancybox-caption--separate {
margin-top: -50px
}
.fancybox-caption__body {
max-height: 50vh;
overflow: auto;
pointer-events: all
}
.fancybox-caption a,
.fancybox-caption a:link,
.fancybox-caption a:visited {
color: #ccc;
text-decoration: none
}
.fancybox-caption a:hover {
color: #fff;
text-decoration: underline
}
.fancybox-loading {
animation: a 1s linear infinite;
background: transparent;
border: 4px solid #888;
border-bottom-color: #fff;
border-radius: 50%;
height: 50px;
left: 50%;
margin: -25px 0 0 -25px;
opacity: .7;
padding: 0;
position: absolute;
top: 50%;
width: 50px;
z-index: 99999
}
@keyframes a {
to {
transform: rotate(1turn)
}
}
.fancybox-animated {
transition-timing-function: cubic-bezier(0, 0, .25, 1)
}
.fancybox-fx-slide.fancybox-slide--previous {
opacity: 0;
transform: translate3d(-100%, 0, 0)
}
.fancybox-fx-slide.fancybox-slide--next {
opacity: 0;
transform: translate3d(100%, 0, 0)
}
.fancybox-fx-slide.fancybox-slide--current {
opacity: 1;
transform: translateZ(0)
}
.fancybox-fx-fade.fancybox-slide--next,
.fancybox-fx-fade.fancybox-slide--previous {
opacity: 0;
transition-timing-function: cubic-bezier(.19, 1, .22, 1)
}
.fancybox-fx-fade.fancybox-slide--current {
opacity: 1
}
.fancybox-fx-zoom-in-out.fancybox-slide--previous {
opacity: 0;
transform: scale3d(1.5, 1.5, 1.5)
}
.fancybox-fx-zoom-in-out.fancybox-slide--next {
opacity: 0;
transform: scale3d(.5, .5, .5)
}
.fancybox-fx-zoom-in-out.fancybox-slide--current {
opacity: 1;
transform: scaleX(1)
}
.fancybox-fx-rotate.fancybox-slide--previous {
opacity: 0;
transform: rotate(-1turn)
}
.fancybox-fx-rotate.fancybox-slide--next {
opacity: 0;
transform: rotate(1turn)
}
.fancybox-fx-rotate.fancybox-slide--current {
opacity: 1;
transform: rotate(0deg)
}
.fancybox-fx-circular.fancybox-slide--previous {
opacity: 0;
transform: scale3d(0, 0, 0) translate3d(-100%, 0, 0)
}
.fancybox-fx-circular.fancybox-slide--next {
opacity: 0;
transform: scale3d(0, 0, 0) translate3d(100%, 0, 0)
}
.fancybox-fx-circular.fancybox-slide--current {
opacity: 1;
transform: scaleX(1) translateZ(0)
}
.fancybox-fx-tube.fancybox-slide--previous {
transform: translate3d(-100%, 0, 0) scale(.1) skew(-10deg)
}
.fancybox-fx-tube.fancybox-slide--next {
transform: translate3d(100%, 0, 0) scale(.1) skew(10deg)
}
.fancybox-fx-tube.fancybox-slide--current {
transform: translateZ(0) scale(1)
}
@media (max-height:576px) {
.fancybox-slide {
padding-left: 6px;
padding-right: 6px
}
.fancybox-slide--image {
padding: 6px 0
}
.fancybox-close-small {
right: -6px
}
.fancybox-slide--image .fancybox-close-small {
background: #4e4e4e;
color: #f2f4f6;
height: 36px;
opacity: 1;
padding: 6px;
right: 0;
top: 0;
width: 36px
}
.fancybox-caption {
padding-left: 12px;
padding-right: 12px
}
@supports (padding:max(0px)) {
.fancybox-caption {
padding-left: max(12px, env(safe-area-inset-left));
padding-right: max(12px, env(safe-area-inset-right))
}
}
}
.fancybox-share {
background: #f4f4f4;
border-radius: 3px;
max-width: 90%;
padding: 30px;
text-align: center
}
.fancybox-share h1 {
color: #222;
font-size: 35px;
font-weight: 700;
margin: 0 0 20px
}
.fancybox-share p {
margin: 0;
padding: 0
}
.fancybox-share__button {
border: 0;
border-radius: 3px;
display: inline-block;
font-size: 14px;
font-weight: 700;
line-height: 40px;
margin: 0 5px 10px;
min-width: 130px;
padding: 0 15px;
text-decoration: none;
transition: all .2s;
-webkit-user-select: none;
-moz-user-select: none;
-ms-user-select: none;
user-select: none;
white-space: nowrap
}
.fancybox-share__button:link,
.fancybox-share__button:visited {
color: #fff
}
.fancybox-share__button:hover {
text-decoration: none
}
.fancybox-share__button--fb {
background: #3b5998
}
.fancybox-share__button--fb:hover {
background: #344e86
}
.fancybox-share__button--pt {
background: #bd081d
}
.fancybox-share__button--pt:hover {
background: #aa0719
}
.fancybox-share__button--tw {
background: #1da1f2
}
.fancybox-share__button--tw:hover {
background: #0d95e8
}
.fancybox-share__button svg {
height: 25px;
margin-right: 7px;
position: relative;
top: -1px;
vertical-align: middle;
width: 25px
}
.fancybox-share__button svg path {
fill: #fff
}
.fancybox-share__input {
background: transparent;
border: 0;
border-bottom: 1px solid #d7d7d7;
border-radius: 0;
color: #5d5b5b;
font-size: 14px;
margin: 10px 0 0;
outline: none;
padding: 10px 15px;
width: 100%
}
.fancybox-thumbs {
background: #ddd;
bottom: 0;
display: none;
margin: 0;
-webkit-overflow-scrolling: touch;
-ms-overflow-style: -ms-autohiding-scrollbar;
padding: 2px 2px 4px;
position: absolute;
right: 0;
-webkit-tap-highlight-color: rgba(0, 0, 0, 0);
top: 0;
width: 212px;
z-index: 99995
}
.fancybox-thumbs-x {
overflow-x: auto;
overflow-y: hidden
}
.fancybox-show-thumbs .fancybox-thumbs {
display: block
}
.fancybox-show-thumbs .fancybox-inner {
right: 212px
}
.fancybox-thumbs__list {
font-size: 0;
height: 100%;
list-style: none;
margin: 0;
overflow-x: hidden;
overflow-y: auto;
padding: 0;
position: absolute;
position: relative;
white-space: nowrap;
width: 100%
}
.fancybox-thumbs-x .fancybox-thumbs__list {
overflow: hidden
}
.fancybox-thumbs-y .fancybox-thumbs__list::-webkit-scrollbar {
width: 7px
}
.fancybox-thumbs-y .fancybox-thumbs__list::-webkit-scrollbar-track {
background: #fff;
border-radius: 10px;
box-shadow: inset 0 0 6px rgba(0, 0, 0, .3)
}
.fancybox-thumbs-y .fancybox-thumbs__list::-webkit-scrollbar-thumb {
background: #2a2a2a;
border-radius: 10px
}
.fancybox-thumbs__list a {
-webkit-backface-visibility: hidden;
backface-visibility: hidden;
background-color: rgba(0, 0, 0, .1);
background-position: 50%;
background-repeat: no-repeat;
background-size: cover;
cursor: pointer;
float: left;
height: 75px;
margin: 2px;
max-height: calc(100% - 8px);
max-width: calc(50% - 4px);
outline: none;
overflow: hidden;
padding: 0;
position: relative;
-webkit-tap-highlight-color: transparent;
width: 100px
}
.fancybox-thumbs__list a:before {
border: 6px solid #ff5268;
bottom: 0;
content: "";
left: 0;
opacity: 0;
position: absolute;
right: 0;
top: 0;
transition: all .2s cubic-bezier(.25, .46, .45, .94);
z-index: 99991
}
.fancybox-thumbs__list a:focus:before {
opacity: .5
}
.fancybox-thumbs__list a.fancybox-thumbs-active:before {
opacity: 1
}
@media (max-width:576px) {
.fancybox-thumbs {
width: 110px
}
.fancybox-show-thumbs .fancybox-inner {
right: 110px
}
.fancybox-thumbs__list a {
max-width: calc(100% - 10px)
}
}
File diff suppressed because it is too large Load Diff
@@ -0,0 +1,760 @@
/*!
* justifiedGallery - v3.7.0
* http://miromannino.github.io/Justified-Gallery/
* Copyright (c) 2018 Miro Mannino
* Licensed under the MIT license.
*/
!(function (e) {
"function" == typeof define && define.amd
? define(["jquery"], e)
: "object" == typeof module && module.exports
? (module.exports = function (t, i) {
return (
void 0 === i &&
(i =
"undefined" != typeof window
? require("jquery")
: require("jquery")(t)),
e(i),
i
);
})
: e(jQuery);
})(function (g) {
var r = function (t, i) {
(this.settings = i),
this.checkSettings(),
(this.imgAnalyzerTimeout = null),
(this.entries = null),
(this.buildingRow = {
entriesBuff: [],
width: 0,
height: 0,
aspectRatio: 0,
}),
(this.lastFetchedEntry = null),
(this.lastAnalyzedIndex = -1),
(this.yield = { every: 2, flushed: 0 }),
(this.border = 0 <= i.border ? i.border : i.margins),
(this.maxRowHeight = this.retrieveMaxRowHeight()),
(this.suffixRanges = this.retrieveSuffixRanges()),
(this.offY = this.border),
(this.rows = 0),
(this.spinner = {
phase: 0,
timeSlot: 150,
$el: g(
'<div class="spinner"><span></span><span></span><span></span></div>'
),
intervalId: null,
}),
(this.scrollBarOn = !1),
(this.checkWidthIntervalId = null),
(this.galleryWidth = t.width()),
(this.$gallery = t);
};
(r.prototype.getSuffix = function (t, i) {
var e, s;
for (e = i < t ? t : i, s = 0; s < this.suffixRanges.length; s++)
if (e <= this.suffixRanges[s])
return this.settings.sizeRangeSuffixes[this.suffixRanges[s]];
return this.settings.sizeRangeSuffixes[this.suffixRanges[s - 1]];
}),
(r.prototype.removeSuffix = function (t, i) {
return t.substring(0, t.length - i.length);
}),
(r.prototype.endsWith = function (t, i) {
return -1 !== t.indexOf(i, t.length - i.length);
}),
(r.prototype.getUsedSuffix = function (t) {
for (var i in this.settings.sizeRangeSuffixes)
if (this.settings.sizeRangeSuffixes.hasOwnProperty(i)) {
if (0 === this.settings.sizeRangeSuffixes[i].length) continue;
if (this.endsWith(t, this.settings.sizeRangeSuffixes[i]))
return this.settings.sizeRangeSuffixes[i];
}
return "";
}),
(r.prototype.newSrc = function (t, i, e, s) {
var n;
if (this.settings.thumbnailPath)
n = this.settings.thumbnailPath(t, i, e, s);
else {
var r = t.match(this.settings.extension),
o = null !== r ? r[0] : "";
(n = t.replace(this.settings.extension, "")),
(n = this.removeSuffix(n, this.getUsedSuffix(n))),
(n += this.getSuffix(i, e) + o);
}
return n;
}),
(r.prototype.showImg = function (t, i) {
this.settings.cssAnimation
? (t.addClass("entry-visible"), i && i())
: (t.stop().fadeTo(this.settings.imagesAnimationDuration, 1, i),
t
.find(this.settings.imgSelector)
.stop()
.fadeTo(this.settings.imagesAnimationDuration, 1, i));
}),
(r.prototype.extractImgSrcFromImage = function (t) {
var i =
void 0 !== t.data("safe-src") ? t.data("safe-src") : t.attr("src");
return t.data("jg.originalSrc", i), i;
}),
(r.prototype.imgFromEntry = function (t) {
var i = t.find(this.settings.imgSelector);
return 0 === i.length ? null : i;
}),
(r.prototype.captionFromEntry = function (t) {
var i = t.find("> .caption");
return 0 === i.length ? null : i;
}),
(r.prototype.displayEntry = function (t, i, e, s, n, r) {
t.width(s), t.height(r), t.css("top", e), t.css("left", i);
var o = this.imgFromEntry(t);
if (null !== o) {
o.css("width", s),
o.css("height", n),
o.css("margin-left", -s / 2),
o.css("margin-top", -n / 2);
var a = o.attr("src"),
h = this.newSrc(a, s, n, o[0]);
o.one("error", function () {
o.attr("src", o.data("jg.originalSrc"));
});
var l = function () {
a !== h && o.attr("src", h);
};
"skipped" === t.data("jg.loaded")
? this.onImageEvent(
a,
g.proxy(function () {
this.showImg(t, l), t.data("jg.loaded", !0);
}, this)
)
: this.showImg(t, l);
} else this.showImg(t);
this.displayEntryCaption(t);
}),
(r.prototype.displayEntryCaption = function (t) {
var i = this.imgFromEntry(t);
if (null !== i && this.settings.captions) {
var e = this.captionFromEntry(t);
if (null === e) {
var s = i.attr("alt");
this.isValidCaption(s) || (s = t.attr("title")),
this.isValidCaption(s) &&
((e = g('<div class="caption">' + s + "</div>")),
t.append(e),
t.data("jg.createdCaption", !0));
}
null !== e &&
(this.settings.cssAnimation ||
e.stop().fadeTo(0, this.settings.captionSettings.nonVisibleOpacity),
this.addCaptionEventsHandlers(t));
} else this.removeCaptionEventsHandlers(t);
}),
(r.prototype.isValidCaption = function (t) {
return void 0 !== t && 0 < t.length;
}),
(r.prototype.onEntryMouseEnterForCaption = function (t) {
var i = this.captionFromEntry(g(t.currentTarget));
this.settings.cssAnimation
? i.addClass("caption-visible").removeClass("caption-hidden")
: i
.stop()
.fadeTo(
this.settings.captionSettings.animationDuration,
this.settings.captionSettings.visibleOpacity
);
}),
(r.prototype.onEntryMouseLeaveForCaption = function (t) {
var i = this.captionFromEntry(g(t.currentTarget));
this.settings.cssAnimation
? i.removeClass("caption-visible").removeClass("caption-hidden")
: i
.stop()
.fadeTo(
this.settings.captionSettings.animationDuration,
this.settings.captionSettings.nonVisibleOpacity
);
}),
(r.prototype.addCaptionEventsHandlers = function (t) {
var i = t.data("jg.captionMouseEvents");
void 0 === i &&
((i = {
mouseenter: g.proxy(this.onEntryMouseEnterForCaption, this),
mouseleave: g.proxy(this.onEntryMouseLeaveForCaption, this),
}),
t.on("mouseenter", void 0, void 0, i.mouseenter),
t.on("mouseleave", void 0, void 0, i.mouseleave),
t.data("jg.captionMouseEvents", i));
}),
(r.prototype.removeCaptionEventsHandlers = function (t) {
var i = t.data("jg.captionMouseEvents");
void 0 !== i &&
(t.off("mouseenter", void 0, i.mouseenter),
t.off("mouseleave", void 0, i.mouseleave),
t.removeData("jg.captionMouseEvents"));
}),
(r.prototype.clearBuildingRow = function () {
(this.buildingRow.entriesBuff = []),
(this.buildingRow.aspectRatio = 0),
(this.buildingRow.width = 0);
}),
(r.prototype.prepareBuildingRow = function (t) {
var i,
e,
s,
n,
r,
o = !0,
a = 0,
h =
this.galleryWidth -
2 * this.border -
(this.buildingRow.entriesBuff.length - 1) * this.settings.margins,
l = h / this.buildingRow.aspectRatio,
g = this.settings.rowHeight,
u = this.buildingRow.width / h > this.settings.justifyThreshold;
if (t && "hide" === this.settings.lastRow && !u) {
for (i = 0; i < this.buildingRow.entriesBuff.length; i++)
(e = this.buildingRow.entriesBuff[i]),
this.settings.cssAnimation
? e.removeClass("entry-visible")
: (e.stop().fadeTo(0, 0.1),
e.find("> img, > a > img").fadeTo(0, 0));
return -1;
}
for (
t &&
!u &&
"justify" !== this.settings.lastRow &&
"hide" !== this.settings.lastRow &&
((o = !1),
0 < this.rows &&
(o =
((g =
(this.offY - this.border - this.settings.margins * this.rows) /
this.rows) *
this.buildingRow.aspectRatio) /
h >
this.settings.justifyThreshold)),
i = 0;
i < this.buildingRow.entriesBuff.length;
i++
)
(s =
(e = this.buildingRow.entriesBuff[i]).data("jg.width") /
e.data("jg.height")),
o
? ((n = i === this.buildingRow.entriesBuff.length - 1 ? h : l * s),
(r = l))
: ((n = g * s), (r = g)),
(h -= Math.round(n)),
e.data("jg.jwidth", Math.round(n)),
e.data("jg.jheight", Math.ceil(r)),
(0 === i || r < a) && (a = r);
return (this.buildingRow.height = a), o;
}),
(r.prototype.flushRow = function (t) {
var i,
e,
s,
n = this.settings,
r = this.border;
if (
((e = this.prepareBuildingRow(t)),
t && "hide" === n.lastRow && -1 === e)
)
this.clearBuildingRow();
else {
if (
(this.maxRowHeight &&
this.maxRowHeight < this.buildingRow.height &&
(this.buildingRow.height = this.maxRowHeight),
t && ("center" === n.lastRow || "right" === n.lastRow))
) {
var o =
this.galleryWidth -
2 * this.border -
(this.buildingRow.entriesBuff.length - 1) * n.margins;
for (s = 0; s < this.buildingRow.entriesBuff.length; s++)
o -= (i = this.buildingRow.entriesBuff[s]).data("jg.jwidth");
"center" === n.lastRow
? (r += o / 2)
: "right" === n.lastRow && (r += o);
}
var a = this.buildingRow.entriesBuff.length - 1;
for (s = 0; s <= a; s++)
(i = this.buildingRow.entriesBuff[this.settings.rtl ? a - s : s]),
this.displayEntry(
i,
r,
this.offY,
i.data("jg.jwidth"),
i.data("jg.jheight"),
this.buildingRow.height
),
(r += i.data("jg.jwidth") + n.margins);
(this.galleryHeightToSet =
this.offY + this.buildingRow.height + this.border),
this.setGalleryTempHeight(
this.galleryHeightToSet + this.getSpinnerHeight()
),
(!t || (this.buildingRow.height <= n.rowHeight && e)) &&
((this.offY += this.buildingRow.height + n.margins),
(this.rows += 1),
this.clearBuildingRow(),
this.settings.triggerEvent.call(this, "jg.rowflush"));
}
});
var i = 0;
function e() {
return g("body").height() > g(window).height();
}
(r.prototype.rememberGalleryHeight = function () {
(i = this.$gallery.height()), this.$gallery.height(i);
}),
(r.prototype.setGalleryTempHeight = function (t) {
(i = Math.max(t, i)), this.$gallery.height(i);
}),
(r.prototype.setGalleryFinalHeight = function (t) {
(i = t), this.$gallery.height(t);
}),
(r.prototype.checkWidth = function () {
this.checkWidthIntervalId = setInterval(
g.proxy(function () {
if (this.$gallery.is(":visible")) {
var t = parseFloat(this.$gallery.width());
e() === this.scrollBarOn
? Math.abs(t - this.galleryWidth) >
this.settings.refreshSensitivity &&
((this.galleryWidth = t),
this.rewind(),
this.rememberGalleryHeight(),
this.startImgAnalyzer(!0))
: ((this.scrollBarOn = e()), (this.galleryWidth = t));
}
}, this),
this.settings.refreshTime
);
}),
(r.prototype.isSpinnerActive = function () {
return null !== this.spinner.intervalId;
}),
(r.prototype.getSpinnerHeight = function () {
return this.spinner.$el.innerHeight();
}),
(r.prototype.stopLoadingSpinnerAnimation = function () {
clearInterval(this.spinner.intervalId),
(this.spinner.intervalId = null),
this.setGalleryTempHeight(
this.$gallery.height() - this.getSpinnerHeight()
),
this.spinner.$el.detach();
}),
(r.prototype.startLoadingSpinnerAnimation = function () {
var t = this.spinner,
i = t.$el.find("span");
clearInterval(t.intervalId),
this.$gallery.append(t.$el),
this.setGalleryTempHeight(
this.offY + this.buildingRow.height + this.getSpinnerHeight()
),
(t.intervalId = setInterval(function () {
t.phase < i.length
? i.eq(t.phase).fadeTo(t.timeSlot, 1)
: i.eq(t.phase - i.length).fadeTo(t.timeSlot, 0),
(t.phase = (t.phase + 1) % (2 * i.length));
}, t.timeSlot));
}),
(r.prototype.rewind = function () {
(this.lastFetchedEntry = null),
(this.lastAnalyzedIndex = -1),
(this.offY = this.border),
(this.rows = 0),
this.clearBuildingRow();
}),
(r.prototype.updateEntries = function (t) {
var i;
return (
t && null != this.lastFetchedEntry
? (i = g(this.lastFetchedEntry)
.nextAll(this.settings.selector)
.toArray())
: ((this.entries = []),
(i = this.$gallery.children(this.settings.selector).toArray())),
0 < i.length &&
(g.isFunction(this.settings.sort)
? (i = this.sortArray(i))
: this.settings.randomize && (i = this.shuffleArray(i)),
(this.lastFetchedEntry = i[i.length - 1]),
this.settings.filter
? (i = this.filterArray(i))
: this.resetFilters(i)),
(this.entries = this.entries.concat(i)),
!0
);
}),
(r.prototype.insertToGallery = function (t) {
var i = this;
g.each(t, function () {
g(this).appendTo(i.$gallery);
});
}),
(r.prototype.shuffleArray = function (t) {
var i, e, s;
for (i = t.length - 1; 0 < i; i--)
(e = Math.floor(Math.random() * (i + 1))),
(s = t[i]),
(t[i] = t[e]),
(t[e] = s);
return this.insertToGallery(t), t;
}),
(r.prototype.sortArray = function (t) {
return t.sort(this.settings.sort), this.insertToGallery(t), t;
}),
(r.prototype.resetFilters = function (t) {
for (var i = 0; i < t.length; i++) g(t[i]).removeClass("jg-filtered");
}),
(r.prototype.filterArray = function (t) {
var e = this.settings;
if ("string" === g.type(e.filter))
return t.filter(function (t) {
var i = g(t);
return i.is(e.filter)
? (i.removeClass("jg-filtered"), !0)
: (i.addClass("jg-filtered").removeClass("jg-visible"), !1);
});
if (g.isFunction(e.filter)) {
for (var i = t.filter(e.filter), s = 0; s < t.length; s++)
-1 === i.indexOf(t[s])
? g(t[s]).addClass("jg-filtered").removeClass("jg-visible")
: g(t[s]).removeClass("jg-filtered");
return i;
}
}),
(r.prototype.destroy = function () {
clearInterval(this.checkWidthIntervalId),
g.each(
this.entries,
g.proxy(function (t, i) {
var e = g(i);
e.css("width", ""),
e.css("height", ""),
e.css("top", ""),
e.css("left", ""),
e.data("jg.loaded", void 0),
e.removeClass("jg-entry");
var s = this.imgFromEntry(e);
s.css("width", ""),
s.css("height", ""),
s.css("margin-left", ""),
s.css("margin-top", ""),
s.attr("src", s.data("jg.originalSrc")),
s.data("jg.originalSrc", void 0),
this.removeCaptionEventsHandlers(e);
var n = this.captionFromEntry(e);
e.data("jg.createdCaption")
? (e.data("jg.createdCaption", void 0), null !== n && n.remove())
: null !== n && n.fadeTo(0, 1);
}, this)
),
this.$gallery.css("height", ""),
this.$gallery.removeClass("justified-gallery"),
this.$gallery.data("jg.controller", void 0);
}),
(r.prototype.analyzeImages = function (t) {
for (var i = this.lastAnalyzedIndex + 1; i < this.entries.length; i++) {
var e = g(this.entries[i]);
if (!0 === e.data("jg.loaded") || "skipped" === e.data("jg.loaded")) {
var s =
this.galleryWidth -
2 * this.border -
(this.buildingRow.entriesBuff.length - 1) * this.settings.margins,
n = e.data("jg.width") / e.data("jg.height");
if (
s / (this.buildingRow.aspectRatio + n) < this.settings.rowHeight &&
(this.flushRow(!1), ++this.yield.flushed >= this.yield.every)
)
return void this.startImgAnalyzer(t);
this.buildingRow.entriesBuff.push(e),
(this.buildingRow.aspectRatio += n),
(this.buildingRow.width += n * this.settings.rowHeight),
(this.lastAnalyzedIndex = i);
} else if ("error" !== e.data("jg.loaded")) return;
}
0 < this.buildingRow.entriesBuff.length && this.flushRow(!0),
this.isSpinnerActive() && this.stopLoadingSpinnerAnimation(),
this.stopImgAnalyzerStarter(),
this.settings.triggerEvent.call(this, t ? "jg.resize" : "jg.complete"),
this.setGalleryFinalHeight(this.galleryHeightToSet);
}),
(r.prototype.stopImgAnalyzerStarter = function () {
(this.yield.flushed = 0),
null !== this.imgAnalyzerTimeout &&
(clearTimeout(this.imgAnalyzerTimeout),
(this.imgAnalyzerTimeout = null));
}),
(r.prototype.startImgAnalyzer = function (t) {
var i = this;
this.stopImgAnalyzerStarter(),
(this.imgAnalyzerTimeout = setTimeout(function () {
i.analyzeImages(t);
}, 0.001));
}),
(r.prototype.onImageEvent = function (t, i, e) {
if (i || e) {
var s = new Image(),
n = g(s);
i &&
n.one("load", function () {
n.off("load error"), i(s);
}),
e &&
n.one("error", function () {
n.off("load error"), e(s);
}),
(s.src = t);
}
}),
(r.prototype.init = function () {
var a = !1,
h = !1,
l = this;
g.each(this.entries, function (t, i) {
var e = g(i),
s = l.imgFromEntry(e);
if (
(e.addClass("jg-entry"),
!0 !== e.data("jg.loaded") && "skipped" !== e.data("jg.loaded"))
)
if (
(null !== l.settings.rel && e.attr("rel", l.settings.rel),
null !== l.settings.target && e.attr("target", l.settings.target),
null !== s)
) {
var n = l.extractImgSrcFromImage(s);
if ((s.attr("src", n), !1 === l.settings.waitThumbnailsLoad)) {
var r = parseFloat(s.prop("width")),
o = parseFloat(s.prop("height"));
if (!isNaN(r) && !isNaN(o))
return (
e.data("jg.width", r),
e.data("jg.height", o),
e.data("jg.loaded", "skipped"),
(h = !0),
l.startImgAnalyzer(!1),
!0
);
}
e.data("jg.loaded", !1),
(a = !0),
l.isSpinnerActive() || l.startLoadingSpinnerAnimation(),
l.onImageEvent(
n,
function (t) {
e.data("jg.width", t.width),
e.data("jg.height", t.height),
e.data("jg.loaded", !0),
l.startImgAnalyzer(!1);
},
function () {
e.data("jg.loaded", "error"), l.startImgAnalyzer(!1);
}
);
} else
e.data("jg.loaded", !0),
e.data("jg.width", e.width() | parseFloat(e.css("width")) | 1),
e.data("jg.height", e.height() | parseFloat(e.css("height")) | 1);
}),
a || h || this.startImgAnalyzer(!1),
this.checkWidth();
}),
(r.prototype.checkOrConvertNumber = function (t, i) {
if (
("string" === g.type(t[i]) && (t[i] = parseFloat(t[i])),
"number" !== g.type(t[i]))
)
throw i + " must be a number";
if (isNaN(t[i])) throw "invalid number for " + i;
}),
(r.prototype.checkSizeRangesSuffixes = function () {
if ("object" !== g.type(this.settings.sizeRangeSuffixes))
throw "sizeRangeSuffixes must be defined and must be an object";
var t = [];
for (var i in this.settings.sizeRangeSuffixes)
this.settings.sizeRangeSuffixes.hasOwnProperty(i) && t.push(i);
for (var e = { 0: "" }, s = 0; s < t.length; s++)
if ("string" === g.type(t[s]))
try {
e[parseInt(t[s].replace(/^[a-z]+/, ""), 10)] =
this.settings.sizeRangeSuffixes[t[s]];
} catch (t) {
throw (
"sizeRangeSuffixes keys must contains correct numbers (" + t + ")"
);
}
else e[t[s]] = this.settings.sizeRangeSuffixes[t[s]];
this.settings.sizeRangeSuffixes = e;
}),
(r.prototype.retrieveMaxRowHeight = function () {
var t = null,
i = this.settings.rowHeight;
if ("string" === g.type(this.settings.maxRowHeight))
t = this.settings.maxRowHeight.match(/^[0-9]+%$/)
? (i *
parseFloat(this.settings.maxRowHeight.match(/^([0-9]+)%$/)[1])) /
100
: parseFloat(this.settings.maxRowHeight);
else {
if ("number" !== g.type(this.settings.maxRowHeight)) {
if (
!1 === this.settings.maxRowHeight ||
null == this.settings.maxRowHeight
)
return null;
throw "maxRowHeight must be a number or a percentage";
}
t = this.settings.maxRowHeight;
}
if (isNaN(t)) throw "invalid number for maxRowHeight";
return t < i && (t = i), t;
}),
(r.prototype.checkSettings = function () {
this.checkSizeRangesSuffixes(),
this.checkOrConvertNumber(this.settings, "rowHeight"),
this.checkOrConvertNumber(this.settings, "margins"),
this.checkOrConvertNumber(this.settings, "border");
var t = ["justify", "nojustify", "left", "center", "right", "hide"];
if (-1 === t.indexOf(this.settings.lastRow))
throw "lastRow must be one of: " + t.join(", ");
if (
(this.checkOrConvertNumber(this.settings, "justifyThreshold"),
this.settings.justifyThreshold < 0 ||
1 < this.settings.justifyThreshold)
)
throw "justifyThreshold must be in the interval [0,1]";
if ("boolean" !== g.type(this.settings.cssAnimation))
throw "cssAnimation must be a boolean";
if ("boolean" !== g.type(this.settings.captions))
throw "captions must be a boolean";
if (
(this.checkOrConvertNumber(
this.settings.captionSettings,
"animationDuration"
),
this.checkOrConvertNumber(
this.settings.captionSettings,
"visibleOpacity"
),
this.settings.captionSettings.visibleOpacity < 0 ||
1 < this.settings.captionSettings.visibleOpacity)
)
throw "captionSettings.visibleOpacity must be in the interval [0, 1]";
if (
(this.checkOrConvertNumber(
this.settings.captionSettings,
"nonVisibleOpacity"
),
this.settings.captionSettings.nonVisibleOpacity < 0 ||
1 < this.settings.captionSettings.nonVisibleOpacity)
)
throw "captionSettings.nonVisibleOpacity must be in the interval [0, 1]";
if (
(this.checkOrConvertNumber(this.settings, "imagesAnimationDuration"),
this.checkOrConvertNumber(this.settings, "refreshTime"),
this.checkOrConvertNumber(this.settings, "refreshSensitivity"),
"boolean" !== g.type(this.settings.randomize))
)
throw "randomize must be a boolean";
if ("string" !== g.type(this.settings.selector))
throw "selector must be a string";
if (!1 !== this.settings.sort && !g.isFunction(this.settings.sort))
throw "sort must be false or a comparison function";
if (
!1 !== this.settings.filter &&
!g.isFunction(this.settings.filter) &&
"string" !== g.type(this.settings.filter)
)
throw "filter must be false, a string or a filter function";
}),
(r.prototype.retrieveSuffixRanges = function () {
var t = [];
for (var i in this.settings.sizeRangeSuffixes)
this.settings.sizeRangeSuffixes.hasOwnProperty(i) &&
t.push(parseInt(i, 10));
return (
t.sort(function (t, i) {
return i < t ? 1 : t < i ? -1 : 0;
}),
t
);
}),
(r.prototype.updateSettings = function (t) {
(this.settings = g.extend({}, this.settings, t)),
this.checkSettings(),
(this.border =
0 <= this.settings.border
? this.settings.border
: this.settings.margins),
(this.maxRowHeight = this.retrieveMaxRowHeight()),
(this.suffixRanges = this.retrieveSuffixRanges());
}),
(r.prototype.defaults = {
sizeRangeSuffixes: {},
thumbnailPath: void 0,
rowHeight: 120,
maxRowHeight: !1,
margins: 1,
border: -1,
lastRow: "nojustify",
justifyThreshold: 0.9,
waitThumbnailsLoad: !0,
captions: !0,
cssAnimation: !0,
imagesAnimationDuration: 500,
captionSettings: {
animationDuration: 500,
visibleOpacity: 0.7,
nonVisibleOpacity: 0,
},
rel: null,
target: null,
extension: /\.[^.\\/]+$/,
refreshTime: 200,
refreshSensitivity: 0,
randomize: !1,
rtl: !1,
sort: !1,
filter: !1,
selector: "a, div:not(.spinner)",
imgSelector: "> img, > a > img",
triggerEvent: function (t) {
this.$gallery.trigger(t);
},
}),
(g.fn.justifiedGallery = function (n) {
return this.each(function (t, i) {
var e = g(i);
e.addClass("justified-gallery");
var s = e.data("jg.controller");
if (void 0 === s) {
if (null != n && "object" !== g.type(n)) {
if ("destroy" === n) return;
throw "The argument must be an object";
}
(s = new r(e, g.extend({}, r.prototype.defaults, n))),
e.data("jg.controller", s);
} else if ("norewind" === n);
else {
if ("destroy" === n) return void s.destroy();
s.updateSettings(n), s.rewind();
}
s.updateEntries("norewind" === n) && s.init();
});
});
});
@@ -0,0 +1,111 @@
/*!
* justifiedGallery - v3.7.0
* http://miromannino.github.io/Justified-Gallery/
* Copyright (c) 2018 Miro Mannino
* Licensed under the MIT license.
*/
.justified-gallery {
width: 100%;
position: relative;
overflow: hidden;
}
.justified-gallery>a,
.justified-gallery>div,
.justified-gallery>figure {
position: absolute;
display: inline-block;
overflow: hidden;
/* background: #888888; To have gray placeholders while the gallery is loading with waitThumbnailsLoad = false */
filter: "alpha(opacity=10)";
opacity: 0.1;
margin: 0;
padding: 0;
}
.justified-gallery>a>img,
.justified-gallery>div>img,
.justified-gallery>figure>img,
.justified-gallery>a>a>img,
.justified-gallery>div>a>img,
.justified-gallery>figure>a>img {
position: absolute;
top: 50%;
left: 50%;
margin: 0;
padding: 0;
border: none;
filter: "alpha(opacity=0)";
opacity: 0;
}
.justified-gallery>a>.caption,
.justified-gallery>div>.caption,
.justified-gallery>figure>.caption {
display: none;
position: absolute;
bottom: 0;
padding: 5px;
background-color: #000000;
left: 0;
right: 0;
margin: 0;
color: white;
font-size: 12px;
font-weight: 300;
font-family: sans-serif;
}
.justified-gallery>a>.caption.caption-visible,
.justified-gallery>div>.caption.caption-visible,
.justified-gallery>figure>.caption.caption-visible {
display: initial;
filter: "alpha(opacity=70)";
opacity: 0.7;
-webkit-transition: opacity 500ms ease-in;
-moz-transition: opacity 500ms ease-in;
-o-transition: opacity 500ms ease-in;
transition: opacity 500ms ease-in;
}
.justified-gallery>.entry-visible {
filter: "alpha(opacity=100)";
opacity: 1;
background: none;
}
.justified-gallery>.entry-visible>img,
.justified-gallery>.entry-visible>a>img {
filter: "alpha(opacity=100)";
opacity: 1;
-webkit-transition: opacity 500ms ease-in;
-moz-transition: opacity 500ms ease-in;
-o-transition: opacity 500ms ease-in;
transition: opacity 500ms ease-in;
}
.justified-gallery>.jg-filtered {
display: none;
}
.justified-gallery>.spinner {
position: absolute;
bottom: 0;
margin-left: -24px;
padding: 10px 0 10px 0;
left: 50%;
filter: "alpha(opacity=100)";
opacity: 1;
overflow: initial;
}
.justified-gallery>.spinner>span {
display: inline-block;
filter: "alpha(opacity=0)";
opacity: 0;
width: 8px;
height: 8px;
margin: 0 4px 0 4px;
background-color: #000;
border-radius: 6px;
}
File diff suppressed because one or more lines are too long
File diff suppressed because it is too large Load Diff
File diff suppressed because it is too large Load Diff
Binary file not shown.

Before

Width:  |  Height:  |  Size: 33 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 27 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 127 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 119 KiB