add files
This commit is contained in:
188
assets/js/vendor/customselect/css/jquery.custom-select.css
vendored
Normal file
188
assets/js/vendor/customselect/css/jquery.custom-select.css
vendored
Normal file
@@ -0,0 +1,188 @@
|
||||
/*
|
||||
* Custom Select jQuery Plugin Base
|
||||
*/
|
||||
.custom-select {
|
||||
position: relative;
|
||||
}
|
||||
|
||||
.custom-select__option {
|
||||
overflow: hidden;
|
||||
box-sizing: border-box;
|
||||
display: block;
|
||||
width: 100%;
|
||||
padding: 0;
|
||||
background-color: transparent;
|
||||
border: 0;
|
||||
border-radius: 0;
|
||||
font-family: inherit;
|
||||
white-space: nowrap;
|
||||
text-align: left;
|
||||
text-overflow: ellipsis;
|
||||
cursor: pointer;
|
||||
user-select: none;
|
||||
-webkit-appearance: none;
|
||||
-moz-appearance: none;
|
||||
appearance: none;
|
||||
}
|
||||
|
||||
.custom-select__option-wrap {
|
||||
position: relative;
|
||||
}
|
||||
|
||||
.custom-select__input {
|
||||
box-sizing: border-box;
|
||||
display: block;
|
||||
width: 100%;
|
||||
padding: 0;
|
||||
border-width: 1px 0;
|
||||
border-style: solid;
|
||||
border-radius: 0;
|
||||
font-family: inherit;
|
||||
-webkit-appearance: none;
|
||||
-moz-appearance: none;
|
||||
appearance: none;
|
||||
}
|
||||
|
||||
.custom-select__dropdown {
|
||||
position: absolute;
|
||||
box-sizing: border-box;
|
||||
width: 100%;
|
||||
top: 100%;
|
||||
left: 0;
|
||||
}
|
||||
|
||||
.custom-select--dropup .custom-select__dropdown {
|
||||
top: auto;
|
||||
bottom: 100%;
|
||||
}
|
||||
|
||||
/*
|
||||
* Custom Select jQuery Plugin Theme
|
||||
*/
|
||||
.custom-select__option {
|
||||
position: relative;
|
||||
padding: 0.375rem 0.75rem;
|
||||
font-size: 1rem;
|
||||
color: #212121;
|
||||
line-height: 1.5;
|
||||
}
|
||||
|
||||
.custom-select__option:focus {
|
||||
outline: none;
|
||||
}
|
||||
|
||||
.custom-select__option:hover, .custom-select__option:focus {
|
||||
background-color: #f9f9f9;
|
||||
}
|
||||
|
||||
.custom-select__option--value {
|
||||
padding-right: 1.875rem;
|
||||
background-color: #fff;
|
||||
border: 1px solid #e6e6e6;
|
||||
border-radius: 0.25rem;
|
||||
}
|
||||
|
||||
.custom-select__option--value::after {
|
||||
position: absolute;
|
||||
box-sizing: border-box;
|
||||
width: 0;
|
||||
height: 0;
|
||||
top: 50%;
|
||||
right: 0.75rem;
|
||||
border-width: 0.3rem;
|
||||
border-bottom-width: 0;
|
||||
border-style: solid;
|
||||
border-color: currentColor transparent;
|
||||
transform: translateY(-50%);
|
||||
content: "";
|
||||
}
|
||||
|
||||
.custom-select--active .custom-select__option--value::after {
|
||||
transform: translateY(-50%) rotate(-180deg);
|
||||
}
|
||||
|
||||
.custom-select--active .custom-select__option--value {
|
||||
border-bottom-color: transparent;
|
||||
border-radius: 0.25rem 0.25rem 0 0;
|
||||
}
|
||||
|
||||
.custom-select--active .custom-select__option--value:hover, .custom-select--active .custom-select__option--value:focus {
|
||||
background-color: #fff;
|
||||
}
|
||||
|
||||
.custom-select--dropup.custom-select--active .custom-select__option--value {
|
||||
border-top-color: transparent;
|
||||
border-bottom-color: #e6e6e6;
|
||||
border-radius: 0 0 0.25rem 0.25rem;
|
||||
}
|
||||
|
||||
.custom-select__option--selected {
|
||||
background-color: #fcfcfc;
|
||||
}
|
||||
|
||||
.custom-select__option[disabled] {
|
||||
color: #a1a1a1;
|
||||
cursor: default;
|
||||
}
|
||||
|
||||
.custom-select__option[disabled]:hover, .custom-select__option[disabled]:focus {
|
||||
background-color: transparent;
|
||||
}
|
||||
|
||||
.custom-select__option-wrap {
|
||||
overflow-y: auto;
|
||||
max-height: 11.25rem;
|
||||
}
|
||||
|
||||
.custom-select__option-wrap::-webkit-scrollbar {
|
||||
width: 16px;
|
||||
}
|
||||
|
||||
.custom-select__option-wrap::-webkit-scrollbar-thumb {
|
||||
background-color: #e6e6e6;
|
||||
background-clip: padding-box;
|
||||
border-width: 0 4px;
|
||||
border-style: solid;
|
||||
border-color: transparent;
|
||||
}
|
||||
|
||||
.custom-select__input {
|
||||
position: relative;
|
||||
z-index: 1;
|
||||
height: 2.25rem;
|
||||
margin-top: -1px;
|
||||
padding: 0 0.75rem;
|
||||
border-color: #e6e6e6;
|
||||
transform: translateY(1px);
|
||||
font-size: 1rem;
|
||||
color: #212121;
|
||||
}
|
||||
|
||||
.custom-select__input:focus {
|
||||
outline: none;
|
||||
}
|
||||
|
||||
.custom-select--dropup .custom-select__input {
|
||||
border-top-width: 0;
|
||||
margin-top: 0;
|
||||
transform: translateY(0);
|
||||
}
|
||||
|
||||
.custom-select__dropdown {
|
||||
overflow: hidden;
|
||||
z-index: 1;
|
||||
top: calc(100% - 1px);
|
||||
background-color: #fff;
|
||||
border-width: 0 1px 1px;
|
||||
border-style: solid;
|
||||
border-color: #e6e6e6;
|
||||
border-radius: 0 0 0.25rem 0.25rem;
|
||||
}
|
||||
|
||||
.custom-select--dropup .custom-select__dropdown {
|
||||
bottom: calc(100% - 1px);
|
||||
border-width: 1px 1px 0;
|
||||
border-radius: 0.25rem 0.25rem 0 0;
|
||||
}
|
||||
|
||||
/*# sourceMappingURL=jquery.custom-select.css.map */
|
||||
14
assets/js/vendor/customselect/css/jquery.custom-select.css.map
vendored
Normal file
14
assets/js/vendor/customselect/css/jquery.custom-select.css.map
vendored
Normal file
@@ -0,0 +1,14 @@
|
||||
{
|
||||
"version": 3,
|
||||
"file": "jquery.custom-select.css",
|
||||
"sources": [
|
||||
"../../sass/jquery.custom-select.scss",
|
||||
"../../sass/_base.scss"
|
||||
],
|
||||
"sourcesContent": [
|
||||
"@import \"base\";\r\n\r\n/*\r\n * Custom Select jQuery Plugin Theme\r\n */\r\n\r\n$white: #fff !default;\r\n\r\n.#{$custom-select-block} {\r\n $_gutter: 0.75rem;\r\n $_color: #212121;\r\n\r\n &__option {\r\n position: relative;\r\n padding: 0.375rem $_gutter;\r\n font-size: 1rem;\r\n color: $_color;\r\n line-height: 1.5;\r\n\r\n &:focus {\r\n outline: none;\r\n }\r\n\r\n &:hover,\r\n &:focus {\r\n background-color: darken($white, 2.5%);\r\n }\r\n\r\n &--value {\r\n padding-right: $_gutter * 2 + 0.375rem;\r\n background-color: $white;\r\n border: 1px solid darken($white, 10%);\r\n border-radius: 0.25rem;\r\n\r\n &::after {\r\n position: absolute;\r\n box-sizing: border-box;\r\n width: 0;\r\n height: 0;\r\n top: 50%;\r\n right: $_gutter;\r\n border-width: 0.3rem;\r\n border-bottom-width: 0;\r\n border-style: solid;\r\n border-color: currentColor transparent;\r\n transform: translateY(-50%);\r\n content: \"\";\r\n\r\n .#{$custom-select-block}--active & {\r\n transform: translateY(-50%) rotate(-180deg);\r\n }\r\n }\r\n\r\n .#{$custom-select-block}--active & {\r\n border-bottom-color: transparent;\r\n border-radius: 0.25rem 0.25rem 0 0;\r\n\r\n &:hover,\r\n &:focus {\r\n background-color: $white;\r\n }\r\n\r\n @at-root {\r\n .#{$custom-select-block}--dropup#{&} {\r\n border-top-color: transparent;\r\n border-bottom-color: darken($white, 10%);\r\n border-radius: 0 0 0.25rem 0.25rem;\r\n }\r\n }\r\n }\r\n }\r\n\r\n &--selected {\r\n background-color: darken($white, 1.25%);\r\n }\r\n\r\n &[disabled] {\r\n color: lighten($_color, 50%);\r\n cursor: default;\r\n\r\n &:hover,\r\n &:focus {\r\n background-color: transparent;\r\n }\r\n }\r\n }\r\n\r\n &__option-wrap {\r\n overflow-y: auto;\r\n max-height: (0.375rem * 2 + 1rem * 1.5) * 5;\r\n\r\n &::-webkit-scrollbar {\r\n width: 16px;\r\n }\r\n\r\n &::-webkit-scrollbar-thumb {\r\n background-color: darken($white, 10%);\r\n background-clip: padding-box;\r\n border-width: 0 4px;\r\n border-style: solid;\r\n border-color: transparent;\r\n }\r\n }\r\n\r\n &__input {\r\n position: relative;\r\n z-index: 1;\r\n height: 2.25rem;\r\n margin-top: -1px;\r\n padding: 0 $_gutter;\r\n border-color: darken($white, 10%);\r\n transform: translateY(1px);\r\n font-size: 1rem;\r\n color: $_color;\r\n\r\n &:focus {\r\n outline: none;\r\n }\r\n\r\n .#{$custom-select-block}--dropup & {\r\n border-top-width: 0;\r\n margin-top: 0;\r\n transform: translateY(0);\r\n }\r\n }\r\n\r\n &__dropdown {\r\n overflow: hidden;\r\n z-index: 1;\r\n top: calc(100% - 1px);\r\n background-color: $white;\r\n border-width: 0 1px 1px;\r\n border-style: solid;\r\n border-color: darken($white, 10%);\r\n border-radius: 0 0 0.25rem 0.25rem;\r\n\r\n .#{$custom-select-block}--dropup & {\r\n bottom: calc(100% - 1px);\r\n border-width: 1px 1px 0;\r\n border-radius: 0.25rem 0.25rem 0 0;\r\n }\r\n }\r\n}\r\n",
|
||||
"/*\r\n * Custom Select jQuery Plugin Base\r\n */\r\n\r\n$custom-select-block: \"custom-select\" !default;\r\n\r\n.#{$custom-select-block} {\r\n position: relative;\r\n\r\n &__option {\r\n overflow: hidden;\r\n box-sizing: border-box;\r\n display: block;\r\n width: 100%;\r\n padding: 0;\r\n background-color: transparent;\r\n border: 0;\r\n border-radius: 0;\r\n font-family: inherit;\r\n white-space: nowrap;\r\n text-align: left;\r\n text-overflow: ellipsis;\r\n cursor: pointer;\r\n user-select: none;\r\n -webkit-appearance: none;\r\n -moz-appearance: none;\r\n appearance: none;\r\n }\r\n\r\n &__option-wrap {\r\n position: relative;\r\n }\r\n\r\n &__input {\r\n box-sizing: border-box;\r\n display: block;\r\n width: 100%;\r\n padding: 0;\r\n border-width: 1px 0;\r\n border-style: solid;\r\n border-radius: 0;\r\n font-family: inherit;\r\n -webkit-appearance: none;\r\n -moz-appearance: none;\r\n appearance: none;\r\n }\r\n\r\n &__dropdown {\r\n position: absolute;\r\n box-sizing: border-box;\r\n width: 100%;\r\n top: 100%;\r\n left: 0;\r\n\r\n .#{$custom-select-block}--dropup & {\r\n top: auto;\r\n bottom: 100%;\r\n }\r\n }\r\n}\r\n"
|
||||
],
|
||||
"names": [],
|
||||
"mappings": "ACAA;;GAEG;AAIH,AAAA,cAAc,CAAW;EACvB,QAAQ,EAAE,QAAQ;CAoDnB;;AAlDE,AAAD,sBAAS,CAAC;EACR,QAAQ,EAAE,MAAM;EAChB,UAAU,EAAE,UAAU;EACtB,OAAO,EAAE,KAAK;EACd,KAAK,EAAE,IAAI;EACX,OAAO,EAAE,CAAC;EACV,gBAAgB,EAAE,WAAW;EAC7B,MAAM,EAAE,CAAC;EACT,aAAa,EAAE,CAAC;EAChB,WAAW,EAAE,OAAO;EACpB,WAAW,EAAE,MAAM;EACnB,UAAU,EAAE,IAAI;EAChB,aAAa,EAAE,QAAQ;EACvB,MAAM,EAAE,OAAO;EACf,WAAW,EAAE,IAAI;EACjB,kBAAkB,EAAE,IAAI;EACxB,eAAe,EAAE,IAAI;EACrB,UAAU,EAAE,IAAI;CACjB;;AAEA,AAAD,2BAAc,CAAC;EACb,QAAQ,EAAE,QAAQ;CACnB;;AAEA,AAAD,qBAAQ,CAAC;EACP,UAAU,EAAE,UAAU;EACtB,OAAO,EAAE,KAAK;EACd,KAAK,EAAE,IAAI;EACX,OAAO,EAAE,CAAC;EACV,YAAY,EAAE,KAAK;EACnB,YAAY,EAAE,KAAK;EACnB,aAAa,EAAE,CAAC;EAChB,WAAW,EAAE,OAAO;EACpB,kBAAkB,EAAE,IAAI;EACxB,eAAe,EAAE,IAAI;EACrB,UAAU,EAAE,IAAI;CACjB;;AAEA,AAAD,wBAAW,CAAC;EACV,QAAQ,EAAE,QAAQ;EAClB,UAAU,EAAE,UAAU;EACtB,KAAK,EAAE,IAAI;EACX,GAAG,EAAE,IAAI;EACT,IAAI,EAAE,CAAC;CAMR;;AAJC,AAAA,sBAAsB,CAPvB,wBAAU,CAO0B;EACjC,GAAG,EAAE,IAAI;EACT,MAAM,EAAE,IAAI;CACb;;ADvDL;;GAEG;AAQA,AAAD,sBAAS,CAAC;EACR,QAAQ,EAAE,QAAQ;EAClB,OAAO,EAAE,QAAQ,CALT,OAAO;EAMf,SAAS,EAAE,IAAI;EACf,KAAK,EANE,OAAO;EAOd,WAAW,EAAE,GAAG;CAoEjB;;AAzEA,AAOC,sBAPO,AAON,MAAM,CAAC;EACN,OAAO,EAAE,IAAI;CACd;;AATF,AAWC,sBAXO,AAWN,MAAM,EAXR,sBAAQ,AAYN,MAAM,CAAC;EACN,gBAAgB,EAAE,OAAoB;CACvC;;AAEA,AAAD,6BAAQ,CAAC;EACP,aAAa,EAAE,QAAuB;EACtC,gBAAgB,EAxBd,IAAI;EAyBN,MAAM,EAAE,GAAG,CAAC,KAAK,CAAC,OAAmB;EACrC,aAAa,EAAE,OAAO;CAsCvB;;AA1CA,AAMC,6BANM,AAML,OAAO,CAAC;EACP,QAAQ,EAAE,QAAQ;EAClB,UAAU,EAAE,UAAU;EACtB,KAAK,EAAE,CAAC;EACR,MAAM,EAAE,CAAC;EACT,GAAG,EAAE,GAAG;EACR,KAAK,EA/BD,OAAO;EAgCX,YAAY,EAAE,MAAM;EACpB,mBAAmB,EAAE,CAAC;EACtB,YAAY,EAAE,KAAK;EACnB,YAAY,EAAE,wBAAwB;EACtC,SAAS,EAAE,gBAAgB;EAC3B,OAAO,EAAE,EAAE;CAKZ;;AAHC,AAAA,sBAAsB,CApBzB,6BAAO,AAML,OAAO,CAc6B;EACjC,SAAS,EAAE,gBAAgB,CAAC,eAAe;CAC5C;;AAGH,AAAA,sBAAsB,CAzBvB,6BAAO,CAyB6B;EACjC,mBAAmB,EAAE,WAAW;EAChC,aAAa,EAAE,mBAAmB;CAcnC;;AAhBD,AAIE,sBAJoB,CAzBvB,6BAAO,AA6BH,MAAM,EAJT,sBAAsB,CAzBvB,6BAAO,AA8BH,MAAM,CAAC;EACN,gBAAgB,EArDlB,IAAI;CAsDH;;AAGC,AAAA,sBAAsB,AAAA,sBAAsB,CAAC,6BAA6B,CAArC;EACnC,gBAAgB,EAAE,WAAW;EAC7B,mBAAmB,EAAE,OAAmB;EACxC,aAAa,EAAE,mBAAmB;CACnC;;AAKN,AAAD,gCAAW,CAAC;EACV,gBAAgB,EAAE,OAAqB;CACxC;;AA9DF,AAgEC,sBAhEO,CAgEN,AAAA,QAAC,AAAA,EAAU;EACV,KAAK,EAAE,OAAqB;EAC5B,MAAM,EAAE,OAAO;CAMhB;;AAxEF,AAoEG,sBApEK,CAgEN,AAAA,QAAC,AAAA,CAIC,MAAM,EApEV,sBAAQ,CAgEN,AAAA,QAAC,AAAA,CAKC,MAAM,CAAC;EACN,gBAAgB,EAAE,WAAW;CAC9B;;AAIJ,AAAD,2BAAc,CAAC;EACb,UAAU,EAAE,IAAI;EAChB,UAAU,EAAE,QAA+B;CAa5C;;AAfA,AAIC,2BAJY,AAIX,mBAAmB,CAAC;EACnB,KAAK,EAAE,IAAI;CACZ;;AANF,AAQC,2BARY,AAQX,yBAAyB,CAAC;EACzB,gBAAgB,EAAE,OAAmB;EACrC,eAAe,EAAE,WAAW;EAC5B,YAAY,EAAE,KAAK;EACnB,YAAY,EAAE,KAAK;EACnB,YAAY,EAAE,WAAW;CAC1B;;AAGF,AAAD,qBAAQ,CAAC;EACP,QAAQ,EAAE,QAAQ;EAClB,OAAO,EAAE,CAAC;EACV,MAAM,EAAE,OAAO;EACf,UAAU,EAAE,IAAI;EAChB,OAAO,EAAE,CAAC,CApGF,OAAO;EAqGf,YAAY,EAAE,OAAmB;EACjC,SAAS,EAAE,eAAe;EAC1B,SAAS,EAAE,IAAI;EACf,KAAK,EAvGE,OAAO;CAkHf;;AApBA,AAWC,qBAXM,AAWL,MAAM,CAAC;EACN,OAAO,EAAE,IAAI;CACd;;AAED,AAAA,sBAAsB,CAfvB,qBAAO,CAe6B;EACjC,gBAAgB,EAAE,CAAC;EACnB,UAAU,EAAE,CAAC;EACb,SAAS,EAAE,aAAa;CACzB;;AAGF,AAAD,wBAAW,CAAC;EACV,QAAQ,EAAE,MAAM;EAChB,OAAO,EAAE,CAAC;EACV,GAAG,EAAE,gBAAgB;EACrB,gBAAgB,EA5HZ,IAAI;EA6HR,YAAY,EAAE,SAAS;EACvB,YAAY,EAAE,KAAK;EACnB,YAAY,EAAE,OAAmB;EACjC,aAAa,EAAE,mBAAmB;CAOnC;;AALC,AAAA,sBAAsB,CAVvB,wBAAU,CAU0B;EACjC,MAAM,EAAE,gBAAgB;EACxB,YAAY,EAAE,SAAS;EACvB,aAAa,EAAE,mBAAmB;CACnC"
|
||||
}
|
||||
14
assets/js/vendor/customselect/css/jquery.custom-select.min.css.map
vendored
Normal file
14
assets/js/vendor/customselect/css/jquery.custom-select.min.css.map
vendored
Normal file
@@ -0,0 +1,14 @@
|
||||
{
|
||||
"version": 3,
|
||||
"file": "jquery.custom-select.min.css",
|
||||
"sources": [
|
||||
"../../sass/jquery.custom-select.scss",
|
||||
"../../sass/_base.scss"
|
||||
],
|
||||
"sourcesContent": [
|
||||
"@import \"base\";\r\n\r\n/*\r\n * Custom Select jQuery Plugin Theme\r\n */\r\n\r\n$white: #fff !default;\r\n\r\n.#{$custom-select-block} {\r\n $_gutter: 0.75rem;\r\n $_color: #212121;\r\n\r\n &__option {\r\n position: relative;\r\n padding: 0.375rem $_gutter;\r\n font-size: 1rem;\r\n color: $_color;\r\n line-height: 1.5;\r\n\r\n &:focus {\r\n outline: none;\r\n }\r\n\r\n &:hover,\r\n &:focus {\r\n background-color: darken($white, 2.5%);\r\n }\r\n\r\n &--value {\r\n padding-right: $_gutter * 2 + 0.375rem;\r\n background-color: $white;\r\n border: 1px solid darken($white, 10%);\r\n border-radius: 0.25rem;\r\n\r\n &::after {\r\n position: absolute;\r\n box-sizing: border-box;\r\n width: 0;\r\n height: 0;\r\n top: 50%;\r\n right: $_gutter;\r\n border-width: 0.3rem;\r\n border-bottom-width: 0;\r\n border-style: solid;\r\n border-color: currentColor transparent;\r\n transform: translateY(-50%);\r\n content: \"\";\r\n\r\n .#{$custom-select-block}--active & {\r\n transform: translateY(-50%) rotate(-180deg);\r\n }\r\n }\r\n\r\n .#{$custom-select-block}--active & {\r\n border-bottom-color: transparent;\r\n border-radius: 0.25rem 0.25rem 0 0;\r\n\r\n &:hover,\r\n &:focus {\r\n background-color: $white;\r\n }\r\n\r\n @at-root {\r\n .#{$custom-select-block}--dropup#{&} {\r\n border-top-color: transparent;\r\n border-bottom-color: darken($white, 10%);\r\n border-radius: 0 0 0.25rem 0.25rem;\r\n }\r\n }\r\n }\r\n }\r\n\r\n &--selected {\r\n background-color: darken($white, 1.25%);\r\n }\r\n\r\n &[disabled] {\r\n color: lighten($_color, 50%);\r\n cursor: default;\r\n\r\n &:hover,\r\n &:focus {\r\n background-color: transparent;\r\n }\r\n }\r\n }\r\n\r\n &__option-wrap {\r\n overflow-y: auto;\r\n max-height: (0.375rem * 2 + 1rem * 1.5) * 5;\r\n\r\n &::-webkit-scrollbar {\r\n width: 16px;\r\n }\r\n\r\n &::-webkit-scrollbar-thumb {\r\n background-color: darken($white, 10%);\r\n background-clip: padding-box;\r\n border-width: 0 4px;\r\n border-style: solid;\r\n border-color: transparent;\r\n }\r\n }\r\n\r\n &__input {\r\n position: relative;\r\n z-index: 1;\r\n height: 2.25rem;\r\n margin-top: -1px;\r\n padding: 0 $_gutter;\r\n border-color: darken($white, 10%);\r\n transform: translateY(1px);\r\n font-size: 1rem;\r\n color: $_color;\r\n\r\n &:focus {\r\n outline: none;\r\n }\r\n\r\n .#{$custom-select-block}--dropup & {\r\n border-top-width: 0;\r\n margin-top: 0;\r\n transform: translateY(0);\r\n }\r\n }\r\n\r\n &__dropdown {\r\n overflow: hidden;\r\n z-index: 1;\r\n top: calc(100% - 1px);\r\n background-color: $white;\r\n border-width: 0 1px 1px;\r\n border-style: solid;\r\n border-color: darken($white, 10%);\r\n border-radius: 0 0 0.25rem 0.25rem;\r\n\r\n .#{$custom-select-block}--dropup & {\r\n bottom: calc(100% - 1px);\r\n border-width: 1px 1px 0;\r\n border-radius: 0.25rem 0.25rem 0 0;\r\n }\r\n }\r\n}\r\n",
|
||||
"/*\r\n * Custom Select jQuery Plugin Base\r\n */\r\n\r\n$custom-select-block: \"custom-select\" !default;\r\n\r\n.#{$custom-select-block} {\r\n position: relative;\r\n\r\n &__option {\r\n overflow: hidden;\r\n box-sizing: border-box;\r\n display: block;\r\n width: 100%;\r\n padding: 0;\r\n background-color: transparent;\r\n border: 0;\r\n border-radius: 0;\r\n font-family: inherit;\r\n white-space: nowrap;\r\n text-align: left;\r\n text-overflow: ellipsis;\r\n cursor: pointer;\r\n user-select: none;\r\n -webkit-appearance: none;\r\n -moz-appearance: none;\r\n appearance: none;\r\n }\r\n\r\n &__option-wrap {\r\n position: relative;\r\n }\r\n\r\n &__input {\r\n box-sizing: border-box;\r\n display: block;\r\n width: 100%;\r\n padding: 0;\r\n border-width: 1px 0;\r\n border-style: solid;\r\n border-radius: 0;\r\n font-family: inherit;\r\n -webkit-appearance: none;\r\n -moz-appearance: none;\r\n appearance: none;\r\n }\r\n\r\n &__dropdown {\r\n position: absolute;\r\n box-sizing: border-box;\r\n width: 100%;\r\n top: 100%;\r\n left: 0;\r\n\r\n .#{$custom-select-block}--dropup & {\r\n top: auto;\r\n bottom: 100%;\r\n }\r\n }\r\n}\r\n"
|
||||
],
|
||||
"names": [],
|
||||
"mappings": "ACMA,AAAA,cAAc,AAAW,CACvB,QAAQ,CAAE,QAAQ,CAoDnB,AAlDE,AAAD,sBAAS,AAAC,CACR,QAAQ,CAAE,MAAM,CAChB,UAAU,CAAE,UAAU,CACtB,OAAO,CAAE,KAAK,CACd,KAAK,CAAE,IAAI,CACX,OAAO,CAAE,CAAC,CACV,gBAAgB,CAAE,WAAW,CAC7B,MAAM,CAAE,CAAC,CACT,aAAa,CAAE,CAAC,CAChB,WAAW,CAAE,OAAO,CACpB,WAAW,CAAE,MAAM,CACnB,UAAU,CAAE,IAAI,CAChB,aAAa,CAAE,QAAQ,CACvB,MAAM,CAAE,OAAO,CACf,WAAW,CAAE,IAAI,CACjB,kBAAkB,CAAE,IAAI,CACxB,eAAe,CAAE,IAAI,CACrB,UAAU,CAAE,IAAI,CACjB,AAEA,AAAD,2BAAc,AAAC,CACb,QAAQ,CAAE,QAAQ,CACnB,AAEA,AAAD,qBAAQ,AAAC,CACP,UAAU,CAAE,UAAU,CACtB,OAAO,CAAE,KAAK,CACd,KAAK,CAAE,IAAI,CACX,OAAO,CAAE,CAAC,CACV,YAAY,CAAE,KAAK,CACnB,YAAY,CAAE,KAAK,CACnB,aAAa,CAAE,CAAC,CAChB,WAAW,CAAE,OAAO,CACpB,kBAAkB,CAAE,IAAI,CACxB,eAAe,CAAE,IAAI,CACrB,UAAU,CAAE,IAAI,CACjB,AAEA,AAAD,wBAAW,AAAC,CACV,QAAQ,CAAE,QAAQ,CAClB,UAAU,CAAE,UAAU,CACtB,KAAK,CAAE,IAAI,CACX,GAAG,CAAE,IAAI,CACT,IAAI,CAAE,CAAC,CAMR,AAJC,AAAA,sBAAsB,CAPvB,wBAAU,AAO0B,CACjC,GAAG,CAAE,IAAI,CACT,MAAM,CAAE,IAAI,CACb,AD7CF,AAAD,sBAAS,AAAC,CACR,QAAQ,CAAE,QAAQ,CAClB,OAAO,CAAE,QAAQ,CALT,MAAO,CAMf,SAAS,CAAE,IAAI,CACf,KAAK,CANE,OAAO,CAOd,WAAW,CAAE,GAAG,CAoEjB,AAzEA,AAOC,sBAPO,AAON,MAAM,AAAC,CACN,OAAO,CAAE,IAAI,CACd,AATF,AAWC,sBAXO,AAWN,MAAM,CAXR,sBAAQ,AAYN,MAAM,AAAC,CACN,gBAAgB,CAAE,OAAoB,CACvC,AAEA,AAAD,6BAAQ,AAAC,CACP,aAAa,CAAE,QAAuB,CACtC,gBAAgB,CAxBd,IAAI,CAyBN,MAAM,CAAE,GAAG,CAAC,KAAK,CAAC,OAAmB,CACrC,aAAa,CAAE,OAAO,CAsCvB,AA1CA,AAMC,6BANM,AAML,OAAO,AAAC,CACP,QAAQ,CAAE,QAAQ,CAClB,UAAU,CAAE,UAAU,CACtB,KAAK,CAAE,CAAC,CACR,MAAM,CAAE,CAAC,CACT,GAAG,CAAE,GAAG,CACR,KAAK,CA/BD,MAAO,CAgCX,YAAY,CAAE,MAAM,CACpB,mBAAmB,CAAE,CAAC,CACtB,YAAY,CAAE,KAAK,CACnB,YAAY,CAAE,wBAAwB,CACtC,SAAS,CAAE,gBAAgB,CAC3B,OAAO,CAAE,EAAE,CAKZ,AAHC,AAAA,sBAAsB,CApBzB,6BAAO,AAML,OAAO,AAc6B,CACjC,SAAS,CAAE,gBAAgB,CAAC,eAAe,CAC5C,AAGH,AAAA,sBAAsB,CAzBvB,6BAAO,AAyB6B,CACjC,mBAAmB,CAAE,WAAW,CAChC,aAAa,CAAE,mBAAmB,CAcnC,AAhBD,AAIE,sBAJoB,CAzBvB,6BAAO,AA6BH,MAAM,CAJT,sBAAsB,CAzBvB,6BAAO,AA8BH,MAAM,AAAC,CACN,gBAAgB,CArDlB,IAAI,CAsDH,AAGC,AAAA,sBAAsB,AAAA,sBAAsB,CAAC,6BAA6B,AAArC,CACnC,gBAAgB,CAAE,WAAW,CAC7B,mBAAmB,CAAE,OAAmB,CACxC,aAAa,CAAE,mBAAmB,CACnC,AAKN,AAAD,gCAAW,AAAC,CACV,gBAAgB,CAAE,OAAqB,CACxC,AA9DF,AAgEC,sBAhEO,CAgEN,AAAA,QAAC,AAAA,CAAU,CACV,KAAK,CAAE,OAAqB,CAC5B,MAAM,CAAE,OAAO,CAMhB,AAxEF,AAoEG,sBApEK,CAgEN,AAAA,QAAC,AAAA,CAIC,MAAM,CApEV,sBAAQ,CAgEN,AAAA,QAAC,AAAA,CAKC,MAAM,AAAC,CACN,gBAAgB,CAAE,WAAW,CAC9B,AAIJ,AAAD,2BAAc,AAAC,CACb,UAAU,CAAE,IAAI,CAChB,UAAU,CAAE,QAA+B,CAa5C,AAfA,AAIC,2BAJY,AAIX,mBAAmB,AAAC,CACnB,KAAK,CAAE,IAAI,CACZ,AANF,AAQC,2BARY,AAQX,yBAAyB,AAAC,CACzB,gBAAgB,CAAE,OAAmB,CACrC,eAAe,CAAE,WAAW,CAC5B,YAAY,CAAE,KAAK,CACnB,YAAY,CAAE,KAAK,CACnB,YAAY,CAAE,WAAW,CAC1B,AAGF,AAAD,qBAAQ,AAAC,CACP,QAAQ,CAAE,QAAQ,CAClB,OAAO,CAAE,CAAC,CACV,MAAM,CAAE,OAAO,CACf,UAAU,CAAE,IAAI,CAChB,OAAO,CAAE,CAAC,CApGF,MAAO,CAqGf,YAAY,CAAE,OAAmB,CACjC,SAAS,CAAE,eAAe,CAC1B,SAAS,CAAE,IAAI,CACf,KAAK,CAvGE,OAAO,CAkHf,AApBA,AAWC,qBAXM,AAWL,MAAM,AAAC,CACN,OAAO,CAAE,IAAI,CACd,AAED,AAAA,sBAAsB,CAfvB,qBAAO,AAe6B,CACjC,gBAAgB,CAAE,CAAC,CACnB,UAAU,CAAE,CAAC,CACb,SAAS,CAAE,aAAa,CACzB,AAGF,AAAD,wBAAW,AAAC,CACV,QAAQ,CAAE,MAAM,CAChB,OAAO,CAAE,CAAC,CACV,GAAG,CAAE,gBAAgB,CACrB,gBAAgB,CA5HZ,IAAI,CA6HR,YAAY,CAAE,SAAS,CACvB,YAAY,CAAE,KAAK,CACnB,YAAY,CAAE,OAAmB,CACjC,aAAa,CAAE,mBAAmB,CAOnC,AALC,AAAA,sBAAsB,CAVvB,wBAAU,AAU0B,CACjC,MAAM,CAAE,gBAAgB,CACxB,YAAY,CAAE,SAAS,CACvB,aAAa,CAAE,mBAAmB,CACnC"
|
||||
}
|
||||
558
assets/js/vendor/customselect/js/jquery.custom-select.js
vendored
Normal file
558
assets/js/vendor/customselect/js/jquery.custom-select.js
vendored
Normal file
@@ -0,0 +1,558 @@
|
||||
function _extends() { _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
||||
|
||||
/*!
|
||||
* Custom Select jQuery Plugin
|
||||
*/
|
||||
var CustomSelect = function ($) {
|
||||
var defaults = {
|
||||
block: 'custom-select',
|
||||
hideCallback: false,
|
||||
includeValue: false,
|
||||
keyboard: true,
|
||||
modifier: false,
|
||||
placeholder: false,
|
||||
search: false,
|
||||
showCallback: false,
|
||||
transition: 0
|
||||
};
|
||||
|
||||
var CustomSelect =
|
||||
/*#__PURE__*/
|
||||
function () {
|
||||
/**
|
||||
* Custom Select
|
||||
*
|
||||
* @param {Element} select Original `<select>` DOM element to customize.
|
||||
* @param {(Object|string)=} options Settings object or method name.
|
||||
* @param {string=} options.block Custom select BEM block name.
|
||||
* @param {Function=} options.hideCallback Fires after dropdown closes.
|
||||
* @param {boolean=} options.includeValue Adds chosen value option to
|
||||
* dropdown. If enabled also cancels dropdown options rerender.
|
||||
* @param {boolean=} options.keyboard Enables keyboard control.
|
||||
* @param {string=} options.modifier Custom select block BEM modifier.
|
||||
* @param {string=} options.placeholder Placeholder hint, can be an HTML
|
||||
* string (appears only if there is no explicitly selected options).
|
||||
* @param {boolean=} options.search Adds input to filter options.
|
||||
* @param {Function=} options.showCallback Fires after dropdown opens.
|
||||
* @param {(number|string)=} options.transition jQuery slideUp/Down param.
|
||||
*/
|
||||
function CustomSelect(select, options) {
|
||||
this._$select = $(select);
|
||||
this._options = _extends({}, defaults, typeof options === 'object' ? options : {}); // Modifiers
|
||||
|
||||
this._activeModifier = this._options.block + "--active";
|
||||
this._dropupModifier = this._options.block + "--dropup";
|
||||
this._optionSelectedModifier = this._options.block + "__option--selected"; // Event handlers that can be removed
|
||||
|
||||
this._keydown = this._keydown.bind(this);
|
||||
this._dropup = this._dropup.bind(this);
|
||||
this._outside = this._outside.bind(this);
|
||||
|
||||
this._init();
|
||||
}
|
||||
/**
|
||||
* Resets custom select options.
|
||||
*
|
||||
* @public
|
||||
*/
|
||||
|
||||
|
||||
var _proto = CustomSelect.prototype;
|
||||
|
||||
_proto.reset = function reset() {
|
||||
this._$dropdown.hide().empty();
|
||||
|
||||
this._$value.off('click');
|
||||
|
||||
this._fill();
|
||||
}
|
||||
/**
|
||||
* Renders initial state of custom select & sets
|
||||
* options click event listeners.
|
||||
*
|
||||
* @private
|
||||
*/
|
||||
;
|
||||
|
||||
_proto._init = function _init() {
|
||||
this._$element = $("<div class=\"" + this._options.block + "\">\n <button class=\"" + this._options.block + "__option " + this._options.block + "__option--value\" type=\"button\"></button>\n <div class=\"" + this._options.block + "__dropdown\" style=\"display: none;\"></div>\n </div>");
|
||||
|
||||
this._$select.hide().after(this._$element);
|
||||
|
||||
if (this._options.modifier) {
|
||||
this._$element.addClass(this._options.modifier);
|
||||
}
|
||||
|
||||
this._$value = this._$element.find("." + this._options.block + "__option--value");
|
||||
this._$dropdown = this._$element.find("." + this._options.block + "__dropdown");
|
||||
|
||||
this._fill();
|
||||
}
|
||||
/**
|
||||
* Renders custom select options by original
|
||||
* select element options.
|
||||
*
|
||||
* @private
|
||||
*/
|
||||
;
|
||||
|
||||
_proto._fill = function _fill() {
|
||||
var _this = this;
|
||||
|
||||
this._$values = this._$select.find('option');
|
||||
this._values = [];
|
||||
var placeholder = this._options.placeholder;
|
||||
$.each(this._$values, function (i, option) {
|
||||
var el = $(option).text().trim();
|
||||
|
||||
_this._values.push(el);
|
||||
});
|
||||
|
||||
if (placeholder) {
|
||||
// Check explicitly selected option
|
||||
if (this._$select.find('[selected]').length) {
|
||||
placeholder = false;
|
||||
} else {
|
||||
this._$value.html(placeholder); // Set select value to null
|
||||
|
||||
|
||||
this._$select.prop('selectedIndex', -1);
|
||||
}
|
||||
}
|
||||
|
||||
$.each(this._values, function (i, el) {
|
||||
var cssClass = _this._$values.eq(i).attr('class');
|
||||
|
||||
var $option = $("<button class=\"" + _this._options.block + "__option\" type=\"button\">" + el + "</button>");
|
||||
|
||||
var $selected = _this._$select.find(':selected');
|
||||
|
||||
if (_this._$values.eq(i).attr('disabled')) {
|
||||
$option.prop('disabled', true);
|
||||
}
|
||||
|
||||
if (!$selected.length && i === 0 || el === $selected.text().trim()) {
|
||||
if (!placeholder) {
|
||||
_this._$value.text(el).removeClass(_this._$value.data('class')).removeData('class').addClass(cssClass).data('class', cssClass);
|
||||
}
|
||||
|
||||
if (_this._options.includeValue || placeholder) {
|
||||
$option.addClass(cssClass);
|
||||
$option.toggleClass(_this._optionSelectedModifier, _this._$values.eq(i).is('[selected]'));
|
||||
|
||||
_this._$dropdown.append($option);
|
||||
}
|
||||
} else {
|
||||
$option.addClass(cssClass);
|
||||
|
||||
_this._$dropdown.append($option);
|
||||
}
|
||||
});
|
||||
this._$options = this._$dropdown.find("." + this._options.block + "__option");
|
||||
|
||||
if (this._options.search) {
|
||||
this._search();
|
||||
}
|
||||
|
||||
this._$value.one('click', function (event) {
|
||||
_this._show(event);
|
||||
});
|
||||
|
||||
this._$value.prop('disabled', !this._$options.length);
|
||||
|
||||
this._$options.on('click', function (event) {
|
||||
_this._select(event);
|
||||
});
|
||||
}
|
||||
/**
|
||||
* Shows custom select dropdown & sets outside
|
||||
* click listener to hide.
|
||||
*
|
||||
* @param {Object} event Value click jQuery event.
|
||||
* @private
|
||||
*/
|
||||
;
|
||||
|
||||
_proto._show = function _show(event) {
|
||||
var _this2 = this;
|
||||
|
||||
event.preventDefault();
|
||||
|
||||
this._dropup();
|
||||
|
||||
$(window).on('resize scroll', this._dropup);
|
||||
|
||||
this._$element.addClass(this._activeModifier);
|
||||
|
||||
this._$dropdown.slideDown(this._options.transition, function () {
|
||||
if (_this2._options.search) {
|
||||
_this2._$input.focus();
|
||||
|
||||
if (_this2._options.includeValue) {
|
||||
_this2._scroll();
|
||||
}
|
||||
} // Open callback
|
||||
|
||||
|
||||
if (typeof _this2._options.showCallback === 'function') {
|
||||
_this2._options.showCallback.call(_this2._$element[0]);
|
||||
}
|
||||
});
|
||||
|
||||
setTimeout(function () {
|
||||
$(document).on('touchstart click', _this2._outside);
|
||||
}, 0);
|
||||
|
||||
this._$value.one('click', function (event) {
|
||||
event.preventDefault();
|
||||
|
||||
_this2._hide();
|
||||
});
|
||||
|
||||
if (this._options.keyboard) {
|
||||
this._options.index = -1;
|
||||
$(window).on('keydown', this._keydown);
|
||||
}
|
||||
}
|
||||
/**
|
||||
* Hides custom select dropdown & resets events
|
||||
* listeners to initial.
|
||||
*
|
||||
* @private
|
||||
*/
|
||||
;
|
||||
|
||||
_proto._hide = function _hide() {
|
||||
var _this3 = this;
|
||||
|
||||
if (this._options.search) {
|
||||
this._$input.val('').blur();
|
||||
|
||||
this._$options.show();
|
||||
|
||||
this._$wrap.scrollTop(0);
|
||||
}
|
||||
|
||||
this._$dropdown.slideUp(this._options.transition, function () {
|
||||
_this3._$element.removeClass(_this3._activeModifier).removeClass(_this3._dropupModifier); // Close callback
|
||||
|
||||
|
||||
if (typeof _this3._options.hideCallback === 'function') {
|
||||
_this3._options.hideCallback.call(_this3._$element[0]);
|
||||
}
|
||||
|
||||
_this3._$value.off('click').one('click', function (event) {
|
||||
_this3._show(event);
|
||||
});
|
||||
|
||||
$(document).off('touchstart click', _this3._outside);
|
||||
$(window).off('resize scroll', _this3._dropup);
|
||||
});
|
||||
|
||||
if (this._options.keyboard) {
|
||||
this._$options.blur();
|
||||
|
||||
$(window).off('keydown', this._keydown);
|
||||
}
|
||||
}
|
||||
/**
|
||||
* Centers chosen option in scrollable element
|
||||
* of dropdown.
|
||||
*
|
||||
* @private
|
||||
*/
|
||||
;
|
||||
|
||||
_proto._scroll = function _scroll() {
|
||||
var _this4 = this;
|
||||
|
||||
$.each(this._$options, function (i, option) {
|
||||
var $option = $(option);
|
||||
|
||||
if ($option.text() === _this4._$value.text()) {
|
||||
var top = $option.position().top;
|
||||
|
||||
var height = _this4._$wrap.outerHeight();
|
||||
|
||||
var center = height / 2 - $option.outerHeight() / 2;
|
||||
|
||||
if (top > center) {
|
||||
_this4._$wrap.scrollTop(top - center);
|
||||
}
|
||||
|
||||
return false;
|
||||
}
|
||||
});
|
||||
}
|
||||
/**
|
||||
* Changes value of custom select & `<select>`
|
||||
* by chosen option.
|
||||
*
|
||||
* @param {Object} event Option click jQuery event.
|
||||
* @private
|
||||
*/
|
||||
;
|
||||
|
||||
_proto._select = function _select(event) {
|
||||
var _this5 = this;
|
||||
|
||||
event.preventDefault();
|
||||
var choice = $(event.currentTarget).text().trim();
|
||||
var values = [].concat(this._values);
|
||||
|
||||
this._$value.text(choice).removeClass(this._$value.data('class'));
|
||||
|
||||
this._$values.prop('selected', false);
|
||||
|
||||
$.each(values, function (i, el) {
|
||||
if (!_this5._options.includeValue && el === choice) {
|
||||
values.splice(i, 1);
|
||||
}
|
||||
|
||||
$.each(_this5._$values, function (i, option) {
|
||||
var $option = $(option);
|
||||
|
||||
if ($option.text().trim() === choice) {
|
||||
var cssClass = $option.attr('class');
|
||||
$option.prop('selected', true);
|
||||
|
||||
_this5._$value.addClass(cssClass).data('class', cssClass);
|
||||
}
|
||||
});
|
||||
});
|
||||
|
||||
this._hide();
|
||||
|
||||
if (!this._options.includeValue) {
|
||||
// Update dropdown options content
|
||||
if (this._$options.length > values.length) {
|
||||
var last = this._$options.eq(values.length);
|
||||
|
||||
last.remove();
|
||||
this._$options = this._$options.not(last);
|
||||
|
||||
if (!this._$options.length) {
|
||||
this._$value.prop('disabled', true);
|
||||
}
|
||||
}
|
||||
|
||||
$.each(this._$options, function (i, option) {
|
||||
var $option = $(option);
|
||||
$option.text(values[i]); // Reset option class
|
||||
|
||||
$option.attr('class', _this5._options.block + "__option");
|
||||
$.each(_this5._$values, function () {
|
||||
var $this = $(this);
|
||||
|
||||
if ($this.text().trim() === values[i]) {
|
||||
$option.addClass($this.attr('class'));
|
||||
}
|
||||
});
|
||||
});
|
||||
} else {
|
||||
// Select chosen option
|
||||
this._$options.removeClass(this._optionSelectedModifier);
|
||||
|
||||
$.each(this._$options, function (i, option) {
|
||||
var $option = $(option);
|
||||
|
||||
if ($option.text().trim() === choice) {
|
||||
$option.addClass(_this5._optionSelectedModifier);
|
||||
return false;
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
if (typeof event.originalEvent !== 'undefined') {
|
||||
this._$select.trigger('change');
|
||||
}
|
||||
}
|
||||
/**
|
||||
* Wraps options by wrap element, adds search
|
||||
* input to dropdown.
|
||||
*
|
||||
* @private
|
||||
*/
|
||||
;
|
||||
|
||||
_proto._search = function _search() {
|
||||
var _this6 = this;
|
||||
|
||||
this._$input = $("<input class=\"" + this._options.block + "__input\" autocomplete=\"off\">");
|
||||
|
||||
this._$dropdown.prepend(this._$input); // Add scrollable wrap
|
||||
|
||||
|
||||
this._$options.wrapAll("<div class=\"" + this._options.block + "__option-wrap\"></div>");
|
||||
|
||||
this._$wrap = this._$element.find("." + this._options.block + "__option-wrap");
|
||||
|
||||
this._$input.on('focus', function () {
|
||||
_this6._options.index = -1;
|
||||
});
|
||||
|
||||
this._$input.on('keyup', function () {
|
||||
var query = _this6._$input.val().trim();
|
||||
|
||||
if (query.length) {
|
||||
_this6._$wrap.scrollTop(0);
|
||||
|
||||
setTimeout(function () {
|
||||
if (query === _this6._$input.val().trim()) {
|
||||
$.each(_this6._$options, function (i, option) {
|
||||
var $option = $(option);
|
||||
var text = $option.text().trim().toLowerCase();
|
||||
var match = text.indexOf(query.toLowerCase()) !== -1;
|
||||
$option.toggle(match);
|
||||
});
|
||||
}
|
||||
}, 300);
|
||||
} else {
|
||||
_this6._$options.show();
|
||||
}
|
||||
});
|
||||
}
|
||||
/**
|
||||
* Toggles custom select dropup modifier based
|
||||
* on space for dropdown below.
|
||||
*
|
||||
* @private
|
||||
*/
|
||||
;
|
||||
|
||||
_proto._dropup = function _dropup() {
|
||||
var bottom = this._$element[0].getBoundingClientRect().bottom;
|
||||
|
||||
var up = $(window).height() - bottom < this._$dropdown.height();
|
||||
|
||||
this._$element.toggleClass(this._dropupModifier, up);
|
||||
}
|
||||
/**
|
||||
* Hides dropdown if target of event (e.g. click
|
||||
* on `$window`) is not custom select.
|
||||
*
|
||||
* @param {Object} event Outside "click" jQuery event.
|
||||
* @private
|
||||
*/
|
||||
;
|
||||
|
||||
_proto._outside = function _outside(event) {
|
||||
var $target = $(event.target);
|
||||
|
||||
if (!$target.parents().is(this._$element) && !$target.is(this._$element)) {
|
||||
this._hide();
|
||||
}
|
||||
}
|
||||
/**
|
||||
* Controls navigation from keyboard by custom
|
||||
* select options.
|
||||
*
|
||||
* @param {Object} event Keydown jQuery event.
|
||||
* @private
|
||||
*/
|
||||
;
|
||||
|
||||
_proto._keydown = function _keydown(event) {
|
||||
var $visible = this._$options.filter(':visible').not('[disabled]');
|
||||
|
||||
switch (event.which) {
|
||||
// Down
|
||||
case 40:
|
||||
event.preventDefault();
|
||||
var next = $visible.eq(this._options.index + 1).length;
|
||||
|
||||
if (next) {
|
||||
this._options.index += 1;
|
||||
} else {
|
||||
this._options.index = 0;
|
||||
}
|
||||
|
||||
$visible.eq(this._options.index).focus();
|
||||
break;
|
||||
// Up
|
||||
|
||||
case 38:
|
||||
event.preventDefault();
|
||||
var prev = $visible.eq(this._options.index - 1).length;
|
||||
|
||||
if (prev && this._options.index - 1 >= 0) {
|
||||
this._options.index -= 1;
|
||||
} else {
|
||||
this._options.index = $visible.length - 1;
|
||||
}
|
||||
|
||||
$visible.eq(this._options.index).focus();
|
||||
break;
|
||||
// Enter
|
||||
|
||||
case 13: // Space
|
||||
|
||||
case 32:
|
||||
if (!this._$input || !this._$input.is(':focus')) {
|
||||
event.preventDefault();
|
||||
|
||||
var $option = this._$options.add(this._$value).filter(':focus');
|
||||
|
||||
$option.trigger('click');
|
||||
|
||||
if (!$option.is(this._$value)) {
|
||||
this._$select.trigger('change');
|
||||
}
|
||||
|
||||
this._$value.focus();
|
||||
}
|
||||
|
||||
break;
|
||||
// Esc
|
||||
|
||||
case 27:
|
||||
event.preventDefault();
|
||||
|
||||
this._hide();
|
||||
|
||||
this._$value.focus();
|
||||
|
||||
break;
|
||||
|
||||
default:
|
||||
break;
|
||||
}
|
||||
}
|
||||
/**
|
||||
* Creates jQuery plugin function.
|
||||
*
|
||||
* @param {(Object|string)=} config Options or method.
|
||||
* @returns {Function} jQuery plugin.
|
||||
*/
|
||||
;
|
||||
|
||||
CustomSelect._jQueryPlugin = function _jQueryPlugin(config) {
|
||||
return this.each(function () {
|
||||
var $this = $(this);
|
||||
var data = $this.data('custom-select');
|
||||
|
||||
if (!data) {
|
||||
if (typeof config !== 'string') {
|
||||
data = new CustomSelect(this, config);
|
||||
$this.data('custom-select', data);
|
||||
}
|
||||
} else {
|
||||
if (config === 'reset') {
|
||||
data.reset();
|
||||
}
|
||||
}
|
||||
});
|
||||
};
|
||||
|
||||
return CustomSelect;
|
||||
}();
|
||||
|
||||
$.fn['customSelect'] = CustomSelect._jQueryPlugin;
|
||||
|
||||
$.fn['customSelect'].noConflict = function () {
|
||||
return $.fn['customSelect'];
|
||||
};
|
||||
|
||||
return CustomSelect;
|
||||
}($);
|
||||
//# sourceMappingURL=jquery.custom-select.js.map
|
||||
1
assets/js/vendor/customselect/js/jquery.custom-select.js.map
vendored
Normal file
1
assets/js/vendor/customselect/js/jquery.custom-select.js.map
vendored
Normal file
File diff suppressed because one or more lines are too long
1
assets/js/vendor/customselect/js/jquery.custom-select.min.js.map
vendored
Normal file
1
assets/js/vendor/customselect/js/jquery.custom-select.min.js.map
vendored
Normal file
File diff suppressed because one or more lines are too long
460
assets/js/vendor/daterangepicker/daterangepicker.css
vendored
Normal file
460
assets/js/vendor/daterangepicker/daterangepicker.css
vendored
Normal file
@@ -0,0 +1,460 @@
|
||||
.date-picker {
|
||||
width: 170px;
|
||||
height: 25px;
|
||||
padding: 0;
|
||||
border: 0;
|
||||
line-height: 25px;
|
||||
padding-left: 10px;
|
||||
font-size: 12px;
|
||||
font-family: Arial, sans-serif;
|
||||
font-weight: bold;
|
||||
cursor: pointer;
|
||||
color: #303030;
|
||||
position: relative;
|
||||
z-index: 2;
|
||||
}
|
||||
|
||||
.date-picker-wrapper {
|
||||
position: absolute;
|
||||
z-index: 1;
|
||||
border: 1px solid #bfbfbf;
|
||||
background-color: #efefef;
|
||||
padding: 5px 12px;
|
||||
font-size: 12px;
|
||||
line-height: 20px;
|
||||
color: #aaa;
|
||||
font-family: Arial, sans-serif;
|
||||
-webkit-box-shadow: 3px 3px 10px rgba(0, 0, 0, 0.5);
|
||||
box-shadow: 3px 3px 10px rgba(0, 0, 0, 0.5);
|
||||
-webkit-box-sizing: initial;
|
||||
box-sizing: initial;
|
||||
}
|
||||
|
||||
.dp-clearfix {
|
||||
clear: both;
|
||||
height: 0;
|
||||
font-size: 0;
|
||||
}
|
||||
|
||||
.date-picker-wrapper.inline-wrapper {
|
||||
position: relative;
|
||||
-webkit-box-shadow: none;
|
||||
box-shadow: none;
|
||||
display: inline-block;
|
||||
}
|
||||
|
||||
.date-picker-wrapper.single-date {
|
||||
width: auto;
|
||||
}
|
||||
|
||||
.date-picker-wrapper.no-shortcuts {
|
||||
padding-bottom: 12px;
|
||||
}
|
||||
|
||||
.date-picker-wrapper.no-topbar {
|
||||
padding-top: 12px;
|
||||
}
|
||||
|
||||
.date-picker-wrapper .footer {
|
||||
font-size: 11px;
|
||||
padding-top: 3px;
|
||||
}
|
||||
|
||||
.date-picker-wrapper b {
|
||||
color: #666;
|
||||
font-weight: 700;
|
||||
}
|
||||
|
||||
.date-picker-wrapper a {
|
||||
color: #6bb4d6;
|
||||
text-decoration: underline;
|
||||
}
|
||||
|
||||
.date-picker-wrapper .month-name {
|
||||
text-transform: uppercase;
|
||||
}
|
||||
|
||||
.date-picker-wrapper .select-wrapper {
|
||||
position: relative;
|
||||
overflow: hidden;
|
||||
display: inline-block;
|
||||
vertical-align: middle;
|
||||
}
|
||||
|
||||
.date-picker-wrapper .select-wrapper:hover {
|
||||
text-decoration: underline;
|
||||
}
|
||||
|
||||
.date-picker-wrapper .month-element {
|
||||
display: inline-block;
|
||||
vertical-align: middle;
|
||||
}
|
||||
|
||||
.date-picker-wrapper .select-wrapper select {
|
||||
position: absolute;
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
left: 0;
|
||||
top: -1px;
|
||||
font-size: inherit;
|
||||
font-style: inherit;
|
||||
font-weight: inherit;
|
||||
text-transform: inherit;
|
||||
color: inherit;
|
||||
cursor: pointer;
|
||||
-webkit-appearance: none;
|
||||
-moz-appearance: none;
|
||||
appearance: none;
|
||||
background: transparent;
|
||||
border: 0;
|
||||
outline: 0;
|
||||
-ms-filter: "progid:DXImageTransform.Microsoft.Alpha(Opacity=1)";
|
||||
filter: alpha(opacity=1);
|
||||
opacity: 0.01;
|
||||
}
|
||||
|
||||
.date-picker-wrapper .month-wrapper {
|
||||
border: 1px solid #bfbfbf;
|
||||
border-radius: 3px;
|
||||
background-color: #fff;
|
||||
padding: 5px;
|
||||
cursor: default;
|
||||
position: relative;
|
||||
_overflow: hidden;
|
||||
}
|
||||
|
||||
.date-picker-wrapper .month-wrapper table {
|
||||
width: 190px;
|
||||
float: left;
|
||||
}
|
||||
|
||||
.date-picker-wrapper .month-wrapper table.month2 {
|
||||
width: 190px;
|
||||
float: left;
|
||||
}
|
||||
|
||||
.date-picker-wrapper .month-wrapper table th, .date-picker-wrapper .month-wrapper table td {
|
||||
vertical-align: middle;
|
||||
text-align: center;
|
||||
line-height: 14px;
|
||||
margin: 0px;
|
||||
padding: 0px;
|
||||
}
|
||||
|
||||
.date-picker-wrapper .month-wrapper table .day {
|
||||
padding: 5px 0;
|
||||
line-height: 1;
|
||||
font-size: 12px;
|
||||
margin-bottom: 1px;
|
||||
color: #ccc;
|
||||
cursor: default;
|
||||
}
|
||||
|
||||
.date-picker-wrapper .month-wrapper table div.day.lastMonth, .date-picker-wrapper .month-wrapper table div.day.nextMonth {
|
||||
color: #999;
|
||||
cursor: default;
|
||||
}
|
||||
|
||||
.date-picker-wrapper .month-wrapper table .day.checked {
|
||||
background-color: #9cdbf7;
|
||||
}
|
||||
|
||||
.date-picker-wrapper .month-wrapper table .week-name {
|
||||
height: 20px;
|
||||
line-height: 20px;
|
||||
font-weight: 100;
|
||||
text-transform: uppercase;
|
||||
}
|
||||
|
||||
.date-picker-wrapper .month-wrapper table .day.has-tooltip {
|
||||
cursor: help !important;
|
||||
}
|
||||
|
||||
.date-picker-wrapper .month-wrapper table .day.has-tooltip .tooltip {
|
||||
white-space: nowrap;
|
||||
}
|
||||
|
||||
.date-picker-wrapper .time label {
|
||||
white-space: nowrap;
|
||||
}
|
||||
|
||||
.date-picker-wrapper .month-wrapper table .day.toMonth.valid {
|
||||
color: #333;
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
.date-picker-wrapper .month-wrapper table .day.toMonth.hovering {
|
||||
background-color: #cdecfa;
|
||||
}
|
||||
|
||||
.date-picker-wrapper .month-wrapper table .day.nextMonth, .date-picker-wrapper .month-wrapper table .day.lastMonth {
|
||||
display: none;
|
||||
}
|
||||
|
||||
.date-picker-wrapper .month-wrapper table .day.real-today {
|
||||
background-color: #ffe684;
|
||||
}
|
||||
|
||||
.date-picker-wrapper .month-wrapper table .day.real-today.checked, .date-picker-wrapper .month-wrapper table .day.real-today.hovering {
|
||||
background-color: #70ccd5;
|
||||
}
|
||||
|
||||
.date-picker-wrapper table .caption {
|
||||
height: 40px;
|
||||
}
|
||||
|
||||
.date-picker-wrapper table .caption > th:first-of-type, .date-picker-wrapper table .caption > th:last-of-type {
|
||||
width: 27px;
|
||||
}
|
||||
|
||||
.date-picker-wrapper table .caption .next, .date-picker-wrapper table .caption .prev {
|
||||
padding: 0 5px;
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
.date-picker-wrapper table .caption .next:hover, .date-picker-wrapper table .caption .prev:hover {
|
||||
background-color: #ccc;
|
||||
color: white;
|
||||
}
|
||||
|
||||
.date-picker-wrapper .gap {
|
||||
position: relative;
|
||||
z-index: 1;
|
||||
width: 15px;
|
||||
height: 100%;
|
||||
background-color: red;
|
||||
font-size: 0;
|
||||
line-height: 0;
|
||||
float: left;
|
||||
top: -5px;
|
||||
margin: 0 10px -10px;
|
||||
visibility: hidden;
|
||||
height: 0;
|
||||
}
|
||||
|
||||
.date-picker-wrapper .gap .gap-lines {
|
||||
height: 100%;
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
.date-picker-wrapper .gap .gap-line {
|
||||
height: 15px;
|
||||
width: 15px;
|
||||
position: relative;
|
||||
}
|
||||
|
||||
.date-picker-wrapper .gap .gap-line .gap-1 {
|
||||
z-index: 1;
|
||||
height: 0;
|
||||
border-left: 8px solid white;
|
||||
border-top: 8px solid #eee;
|
||||
border-bottom: 8px solid #eee;
|
||||
}
|
||||
|
||||
.date-picker-wrapper .gap .gap-line .gap-2 {
|
||||
position: absolute;
|
||||
right: 0;
|
||||
top: 0px;
|
||||
z-index: 2;
|
||||
height: 0;
|
||||
border-left: 8px solid transparent;
|
||||
border-top: 8px solid white;
|
||||
}
|
||||
|
||||
.date-picker-wrapper .gap .gap-line .gap-3 {
|
||||
position: absolute;
|
||||
right: 0;
|
||||
top: 8px;
|
||||
z-index: 2;
|
||||
height: 0;
|
||||
border-left: 8px solid transparent;
|
||||
border-bottom: 8px solid white;
|
||||
}
|
||||
|
||||
.date-picker-wrapper .gap .gap-top-mask {
|
||||
width: 6px;
|
||||
height: 1px;
|
||||
position: absolute;
|
||||
top: -1px;
|
||||
left: 1px;
|
||||
background-color: #eee;
|
||||
z-index: 3;
|
||||
}
|
||||
|
||||
.date-picker-wrapper .gap .gap-bottom-mask {
|
||||
width: 6px;
|
||||
height: 1px;
|
||||
position: absolute;
|
||||
bottom: -1px;
|
||||
left: 7px;
|
||||
background-color: #eee;
|
||||
z-index: 3;
|
||||
}
|
||||
|
||||
.date-picker-wrapper .selected-days {
|
||||
display: none;
|
||||
}
|
||||
|
||||
.date-picker-wrapper .drp_top-bar {
|
||||
line-height: 1.4;
|
||||
position: relative;
|
||||
padding: 10px 40px 10px 0;
|
||||
}
|
||||
|
||||
.date-picker-wrapper .drp_top-bar .error-top, .date-picker-wrapper .drp_top-bar .normal-top {
|
||||
display: none;
|
||||
}
|
||||
|
||||
.date-picker-wrapper .drp_top-bar .default-top {
|
||||
display: block;
|
||||
}
|
||||
|
||||
.date-picker-wrapper .drp_top-bar.error .default-top {
|
||||
display: none;
|
||||
}
|
||||
|
||||
.date-picker-wrapper .drp_top-bar.error .error-top {
|
||||
display: block;
|
||||
color: red;
|
||||
}
|
||||
|
||||
.date-picker-wrapper .drp_top-bar.normal .default-top {
|
||||
display: none;
|
||||
}
|
||||
|
||||
.date-picker-wrapper .drp_top-bar.normal .normal-top {
|
||||
display: block;
|
||||
}
|
||||
|
||||
.date-picker-wrapper .drp_top-bar.normal .normal-top .selection-top {
|
||||
color: #333;
|
||||
}
|
||||
|
||||
.date-picker-wrapper .drp_top-bar .apply-btn {
|
||||
position: absolute;
|
||||
right: 0px;
|
||||
top: 6px;
|
||||
padding: 3px 5px;
|
||||
margin: 0;
|
||||
font-size: 12px;
|
||||
border-radius: 4px;
|
||||
cursor: pointer;
|
||||
color: #d9eef7;
|
||||
border: solid 1px #0076a3;
|
||||
background: #0095cd;
|
||||
background: -moz-linear-gradient(top, #00adee, #0078a5);
|
||||
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#00adee', endColorstr='#0078a5');
|
||||
color: white;
|
||||
line-height: initial;
|
||||
}
|
||||
|
||||
.date-picker-wrapper .drp_top-bar .apply-btn.disabled {
|
||||
cursor: pointer;
|
||||
color: #606060;
|
||||
border: solid 1px #b7b7b7;
|
||||
background: #fff;
|
||||
background: -moz-linear-gradient(top, #fff, #ededed);
|
||||
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffffff', endColorstr='#ededed');
|
||||
}
|
||||
|
||||
.date-picker-wrapper .time {
|
||||
position: relative;
|
||||
}
|
||||
|
||||
.date-picker-wrapper.single-month .time {
|
||||
display: block;
|
||||
}
|
||||
|
||||
.date-picker-wrapper .time input[type=range] {
|
||||
vertical-align: middle;
|
||||
width: 129px;
|
||||
padding: 0;
|
||||
margin: 0;
|
||||
height: 20px;
|
||||
}
|
||||
|
||||
.date-picker-wrapper .time1 {
|
||||
width: 180px;
|
||||
padding: 0 5px;
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
/*time styling*/
|
||||
.time2 {
|
||||
width: 180px;
|
||||
padding: 0 5px;
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
.date-picker-wrapper .time1 {
|
||||
float: left;
|
||||
}
|
||||
|
||||
.date-picker-wrapper .time2 {
|
||||
float: right;
|
||||
}
|
||||
|
||||
.date-picker-wrapper .hour {
|
||||
text-align: right;
|
||||
}
|
||||
|
||||
.minute {
|
||||
text-align: right;
|
||||
}
|
||||
|
||||
.date-picker-wrapper .hide {
|
||||
display: none;
|
||||
}
|
||||
|
||||
.date-picker-wrapper .first-date-selected, .date-picker-wrapper .last-date-selected {
|
||||
background-color: #49e !important;
|
||||
color: white !important;
|
||||
}
|
||||
|
||||
.date-picker-wrapper .date-range-length-tip {
|
||||
position: absolute;
|
||||
margin-top: -4px;
|
||||
margin-left: -8px;
|
||||
-webkit-box-shadow: 0 0 3px rgba(0, 0, 0, 0.3);
|
||||
box-shadow: 0 0 3px rgba(0, 0, 0, 0.3);
|
||||
display: none;
|
||||
background-color: yellow;
|
||||
padding: 0 6px;
|
||||
border-radius: 2px;
|
||||
font-size: 12px;
|
||||
line-height: 16px;
|
||||
-webkit-filter: drop-shadow(0 0 3px rgba(0, 0, 0, 0.3));
|
||||
-moz-filter: drop-shadow(0 0 3px rgba(0, 0, 0, 0.3));
|
||||
-ms-filter: drop-shadow(0 0 3px rgba(0, 0, 0, 0.3));
|
||||
-o-filter: drop-shadow(0 0 3px rgba(0, 0, 0, 0.3));
|
||||
filter: drop-shadow(0 0 3px rgba(0, 0, 0, 0.3));
|
||||
}
|
||||
|
||||
.date-picker-wrapper .date-range-length-tip:after {
|
||||
content: '';
|
||||
position: absolute;
|
||||
border-left: 4px solid transparent;
|
||||
border-right: 4px solid transparent;
|
||||
border-top: 4px solid yellow;
|
||||
left: 50%;
|
||||
margin-left: -4px;
|
||||
bottom: -4px;
|
||||
}
|
||||
|
||||
.date-picker-wrapper.two-months.no-gap .month1 .next, .date-picker-wrapper.two-months.no-gap .month2 .prev {
|
||||
display: none;
|
||||
}
|
||||
|
||||
.date-picker-wrapper .week-number {
|
||||
padding: 5px 0;
|
||||
line-height: 1;
|
||||
font-size: 12px;
|
||||
margin-bottom: 1px;
|
||||
color: #999;
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
.date-picker-wrapper .week-number.week-number-selected {
|
||||
color: #49e;
|
||||
font-weight: bold;
|
||||
}
|
||||
2911
assets/js/vendor/datetimepicker/jquery.datetimepicker.full.js
vendored
Normal file
2911
assets/js/vendor/datetimepicker/jquery.datetimepicker.full.js
vendored
Normal file
File diff suppressed because one or more lines are too long
1
assets/js/vendor/datetimepicker/jquery.datetimepicker.min.scss
vendored
Normal file
1
assets/js/vendor/datetimepicker/jquery.datetimepicker.min.scss
vendored
Normal file
File diff suppressed because one or more lines are too long
668
assets/js/vendor/ekko-lightbox/ekko-lightbox.js
vendored
Normal file
668
assets/js/vendor/ekko-lightbox/ekko-lightbox.js
vendored
Normal file
@@ -0,0 +1,668 @@
|
||||
/*!
|
||||
* Lightbox for Bootstrap by @ashleydw
|
||||
* https://github.com/ashleydw/lightbox
|
||||
*
|
||||
* License: https://github.com/ashleydw/lightbox/blob/master/LICENSE
|
||||
*/
|
||||
+function ($) {
|
||||
|
||||
'use strict';
|
||||
|
||||
var _createClass = (function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ('value' in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; })();
|
||||
|
||||
function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError('Cannot call a class as a function'); } }
|
||||
|
||||
var Lightbox = (function ($) {
|
||||
|
||||
var NAME = 'ekkoLightbox';
|
||||
var JQUERY_NO_CONFLICT = $.fn[NAME];
|
||||
|
||||
var Default = {
|
||||
title: '',
|
||||
footer: '',
|
||||
maxWidth: 9999,
|
||||
maxHeight: 9999,
|
||||
showArrows: true, //display the left / right arrows or not
|
||||
wrapping: true, //if true, gallery loops infinitely
|
||||
type: null, //force the lightbox into image / youtube mode. if null, or not image|youtube|vimeo; detect it
|
||||
alwaysShowClose: false, //always show the close button, even if there is no title
|
||||
loadingMessage: '<div class="ekko-lightbox-loader"><div><div></div><div></div></div></div>', // http://tobiasahlin.com/spinkit/
|
||||
leftArrow: '<span>❮</span>',
|
||||
rightArrow: '<span>❯</span>',
|
||||
strings: {
|
||||
close: 'Close',
|
||||
fail: 'Failed to load image:',
|
||||
type: 'Could not detect remote target type. Force the type using data-type'
|
||||
},
|
||||
doc: document, // if in an iframe can specify top.document
|
||||
onShow: function onShow() {},
|
||||
onShown: function onShown() {},
|
||||
onHide: function onHide() {},
|
||||
onHidden: function onHidden() {},
|
||||
onNavigate: function onNavigate() {},
|
||||
onContentLoaded: function onContentLoaded() {}
|
||||
};
|
||||
|
||||
var Lightbox = (function () {
|
||||
_createClass(Lightbox, null, [{
|
||||
key: 'Default',
|
||||
|
||||
/**
|
||||
Class properties:
|
||||
_$element: null -> the <a> element currently being displayed
|
||||
_$modal: The bootstrap modal generated
|
||||
_$modalDialog: The .modal-dialog
|
||||
_$modalContent: The .modal-content
|
||||
_$modalBody: The .modal-body
|
||||
_$modalHeader: The .modal-header
|
||||
_$modalFooter: The .modal-footer
|
||||
_$lightboxContainerOne: Container of the first lightbox element
|
||||
_$lightboxContainerTwo: Container of the second lightbox element
|
||||
_$lightboxBody: First element in the container
|
||||
_$modalArrows: The overlayed arrows container
|
||||
_$galleryItems: Other <a>'s available for this gallery
|
||||
_galleryName: Name of the current data('gallery') showing
|
||||
_galleryIndex: The current index of the _$galleryItems being shown
|
||||
_config: {} the options for the modal
|
||||
_modalId: unique id for the current lightbox
|
||||
_padding / _border: CSS properties for the modal container; these are used to calculate the available space for the content
|
||||
*/
|
||||
|
||||
get: function get() {
|
||||
return Default;
|
||||
}
|
||||
}]);
|
||||
|
||||
function Lightbox($element, config) {
|
||||
var _this = this;
|
||||
|
||||
_classCallCheck(this, Lightbox);
|
||||
|
||||
this._config = $.extend({}, Default, config);
|
||||
this._$modalArrows = null;
|
||||
this._galleryIndex = 0;
|
||||
this._galleryName = null;
|
||||
this._padding = null;
|
||||
this._border = null;
|
||||
this._titleIsShown = false;
|
||||
this._footerIsShown = false;
|
||||
this._wantedWidth = 0;
|
||||
this._wantedHeight = 0;
|
||||
this._touchstartX = 0;
|
||||
this._touchendX = 0;
|
||||
|
||||
this._modalId = 'ekkoLightbox-' + Math.floor(Math.random() * 1000 + 1);
|
||||
this._$element = $element instanceof jQuery ? $element : $($element);
|
||||
|
||||
this._isBootstrap3 = $.fn.modal.Constructor.VERSION[0] == 3;
|
||||
|
||||
var h4 = '<h4 class="modal-title">' + (this._config.title || " ") + '</h4>';
|
||||
var btn = '<button type="button" class="close" data-dismiss="modal" aria-label="' + this._config.strings.close + '"><span aria-hidden="true">×</span></button>';
|
||||
|
||||
var header = '<div class="modal-header' + (this._config.title || this._config.alwaysShowClose ? '' : ' hide') + '">' + (this._isBootstrap3 ? btn + h4 : h4 + btn) + '</div>';
|
||||
var footer = '<div class="modal-footer' + (this._config.footer ? '' : ' hide') + '">' + (this._config.footer || " ") + '</div>';
|
||||
var body = '<div class="modal-body"><div class="ekko-lightbox-container"><div class="ekko-lightbox-item fade in show"></div><div class="ekko-lightbox-item fade"></div></div></div>';
|
||||
var dialog = '<div class="modal-dialog" role="document"><div class="modal-content">' + header + body + footer + '</div></div>';
|
||||
$(this._config.doc.body).append('<div id="' + this._modalId + '" class="ekko-lightbox modal fade" tabindex="-1" tabindex="-1" role="dialog" aria-hidden="true">' + dialog + '</div>');
|
||||
|
||||
this._$modal = $('#' + this._modalId, this._config.doc);
|
||||
this._$modalDialog = this._$modal.find('.modal-dialog').first();
|
||||
this._$modalContent = this._$modal.find('.modal-content').first();
|
||||
this._$modalBody = this._$modal.find('.modal-body').first();
|
||||
this._$modalHeader = this._$modal.find('.modal-header').first();
|
||||
this._$modalFooter = this._$modal.find('.modal-footer').first();
|
||||
|
||||
this._$lightboxContainer = this._$modalBody.find('.ekko-lightbox-container').first();
|
||||
this._$lightboxBodyOne = this._$lightboxContainer.find('> div:first-child').first();
|
||||
this._$lightboxBodyTwo = this._$lightboxContainer.find('> div:last-child').first();
|
||||
|
||||
this._border = this._calculateBorders();
|
||||
this._padding = this._calculatePadding();
|
||||
|
||||
this._galleryName = this._$element.data('gallery');
|
||||
if (this._galleryName) {
|
||||
this._$galleryItems = $(document.body).find('*[data-gallery="' + this._galleryName + '"]');
|
||||
this._galleryIndex = this._$galleryItems.index(this._$element);
|
||||
$(document).on('keydown.ekkoLightbox', this._navigationalBinder.bind(this));
|
||||
|
||||
// add the directional arrows to the modal
|
||||
if (this._config.showArrows && this._$galleryItems.length > 1) {
|
||||
this._$lightboxContainer.append('<div class="ekko-lightbox-nav-overlay"><a href="#">' + this._config.leftArrow + '</a><a href="#">' + this._config.rightArrow + '</a></div>');
|
||||
this._$modalArrows = this._$lightboxContainer.find('div.ekko-lightbox-nav-overlay').first();
|
||||
this._$lightboxContainer.on('click', 'a:first-child', function (event) {
|
||||
event.preventDefault();
|
||||
return _this.navigateLeft();
|
||||
});
|
||||
this._$lightboxContainer.on('click', 'a:last-child', function (event) {
|
||||
event.preventDefault();
|
||||
return _this.navigateRight();
|
||||
});
|
||||
this.updateNavigation();
|
||||
}
|
||||
}
|
||||
|
||||
this._$modal.on('show.bs.modal', this._config.onShow.bind(this)).on('shown.bs.modal', function () {
|
||||
_this._toggleLoading(true);
|
||||
_this._handle();
|
||||
return _this._config.onShown.call(_this);
|
||||
}).on('hide.bs.modal', this._config.onHide.bind(this)).on('hidden.bs.modal', function () {
|
||||
if (_this._galleryName) {
|
||||
$(document).off('keydown.ekkoLightbox');
|
||||
$(window).off('resize.ekkoLightbox');
|
||||
}
|
||||
_this._$modal.remove();
|
||||
return _this._config.onHidden.call(_this);
|
||||
}).modal(this._config);
|
||||
|
||||
$(window).on('resize.ekkoLightbox', function () {
|
||||
_this._resize(_this._wantedWidth, _this._wantedHeight);
|
||||
});
|
||||
this._$lightboxContainer.on('touchstart', function () {
|
||||
_this._touchstartX = event.changedTouches[0].screenX;
|
||||
}).on('touchend', function () {
|
||||
_this._touchendX = event.changedTouches[0].screenX;
|
||||
_this._swipeGesure();
|
||||
});
|
||||
}
|
||||
|
||||
_createClass(Lightbox, [{
|
||||
key: 'element',
|
||||
value: function element() {
|
||||
return this._$element;
|
||||
}
|
||||
}, {
|
||||
key: 'modal',
|
||||
value: function modal() {
|
||||
return this._$modal;
|
||||
}
|
||||
}, {
|
||||
key: 'navigateTo',
|
||||
value: function navigateTo(index) {
|
||||
|
||||
if (index < 0 || index > this._$galleryItems.length - 1) return this;
|
||||
|
||||
this._galleryIndex = index;
|
||||
|
||||
this.updateNavigation();
|
||||
|
||||
this._$element = $(this._$galleryItems.get(this._galleryIndex));
|
||||
this._handle();
|
||||
}
|
||||
}, {
|
||||
key: 'navigateLeft',
|
||||
value: function navigateLeft() {
|
||||
|
||||
if (!this._$galleryItems) return;
|
||||
|
||||
if (this._$galleryItems.length === 1) return;
|
||||
|
||||
if (this._galleryIndex === 0) {
|
||||
if (this._config.wrapping) this._galleryIndex = this._$galleryItems.length - 1;else return;
|
||||
} else //circular
|
||||
this._galleryIndex--;
|
||||
|
||||
this._config.onNavigate.call(this, 'left', this._galleryIndex);
|
||||
return this.navigateTo(this._galleryIndex);
|
||||
}
|
||||
}, {
|
||||
key: 'navigateRight',
|
||||
value: function navigateRight() {
|
||||
|
||||
if (!this._$galleryItems) return;
|
||||
|
||||
if (this._$galleryItems.length === 1) return;
|
||||
|
||||
if (this._galleryIndex === this._$galleryItems.length - 1) {
|
||||
if (this._config.wrapping) this._galleryIndex = 0;else return;
|
||||
} else //circular
|
||||
this._galleryIndex++;
|
||||
|
||||
this._config.onNavigate.call(this, 'right', this._galleryIndex);
|
||||
return this.navigateTo(this._galleryIndex);
|
||||
}
|
||||
}, {
|
||||
key: 'updateNavigation',
|
||||
value: function updateNavigation() {
|
||||
if (!this._config.wrapping) {
|
||||
var $nav = this._$lightboxContainer.find('div.ekko-lightbox-nav-overlay');
|
||||
if (this._galleryIndex === 0) $nav.find('a:first-child').addClass('disabled');else $nav.find('a:first-child').removeClass('disabled');
|
||||
|
||||
if (this._galleryIndex === this._$galleryItems.length - 1) $nav.find('a:last-child').addClass('disabled');else $nav.find('a:last-child').removeClass('disabled');
|
||||
}
|
||||
}
|
||||
}, {
|
||||
key: 'close',
|
||||
value: function close() {
|
||||
return this._$modal.modal('hide');
|
||||
}
|
||||
|
||||
// helper private methods
|
||||
}, {
|
||||
key: '_navigationalBinder',
|
||||
value: function _navigationalBinder(event) {
|
||||
event = event || window.event;
|
||||
if (event.keyCode === 39) return this.navigateRight();
|
||||
if (event.keyCode === 37) return this.navigateLeft();
|
||||
}
|
||||
|
||||
// type detection private methods
|
||||
}, {
|
||||
key: '_detectRemoteType',
|
||||
value: function _detectRemoteType(src, type) {
|
||||
|
||||
type = type || false;
|
||||
|
||||
if (!type && this._isImage(src)) type = 'image';
|
||||
if (!type && this._getYoutubeId(src)) type = 'youtube';
|
||||
if (!type && this._getVimeoId(src)) type = 'vimeo';
|
||||
if (!type && this._getInstagramId(src)) type = 'instagram';
|
||||
|
||||
if (!type || ['image', 'youtube', 'vimeo', 'instagram', 'video', 'url'].indexOf(type) < 0) type = 'url';
|
||||
|
||||
return type;
|
||||
}
|
||||
}, {
|
||||
key: '_isImage',
|
||||
value: function _isImage(string) {
|
||||
return string && string.match(/(^data:image\/.*,)|(\.(jp(e|g|eg)|gif|png|bmp|webp|svg)((\?|#).*)?$)/i);
|
||||
}
|
||||
}, {
|
||||
key: '_containerToUse',
|
||||
value: function _containerToUse() {
|
||||
var _this2 = this;
|
||||
|
||||
// if currently showing an image, fade it out and remove
|
||||
var $toUse = this._$lightboxBodyTwo;
|
||||
var $current = this._$lightboxBodyOne;
|
||||
|
||||
if (this._$lightboxBodyTwo.hasClass('in')) {
|
||||
$toUse = this._$lightboxBodyOne;
|
||||
$current = this._$lightboxBodyTwo;
|
||||
}
|
||||
|
||||
$current.removeClass('in show');
|
||||
setTimeout(function () {
|
||||
if (!_this2._$lightboxBodyTwo.hasClass('in')) _this2._$lightboxBodyTwo.empty();
|
||||
if (!_this2._$lightboxBodyOne.hasClass('in')) _this2._$lightboxBodyOne.empty();
|
||||
}, 500);
|
||||
|
||||
$toUse.addClass('in show');
|
||||
return $toUse;
|
||||
}
|
||||
}, {
|
||||
key: '_handle',
|
||||
value: function _handle() {
|
||||
|
||||
var $toUse = this._containerToUse();
|
||||
this._updateTitleAndFooter();
|
||||
|
||||
var currentRemote = this._$element.attr('data-remote') || this._$element.attr('href');
|
||||
var currentType = this._detectRemoteType(currentRemote, this._$element.attr('data-type') || false);
|
||||
|
||||
if (['image', 'youtube', 'vimeo', 'instagram', 'video', 'url'].indexOf(currentType) < 0) return this._error(this._config.strings.type);
|
||||
|
||||
switch (currentType) {
|
||||
case 'image':
|
||||
this._preloadImage(currentRemote, $toUse);
|
||||
this._preloadImageByIndex(this._galleryIndex, 3);
|
||||
break;
|
||||
case 'youtube':
|
||||
this._showYoutubeVideo(currentRemote, $toUse);
|
||||
break;
|
||||
case 'vimeo':
|
||||
this._showVimeoVideo(this._getVimeoId(currentRemote), $toUse);
|
||||
break;
|
||||
case 'instagram':
|
||||
this._showInstagramVideo(this._getInstagramId(currentRemote), $toUse);
|
||||
break;
|
||||
case 'video':
|
||||
this._showHtml5Video(currentRemote, $toUse);
|
||||
break;
|
||||
default:
|
||||
// url
|
||||
this._loadRemoteContent(currentRemote, $toUse);
|
||||
break;
|
||||
}
|
||||
|
||||
return this;
|
||||
}
|
||||
}, {
|
||||
key: '_getYoutubeId',
|
||||
value: function _getYoutubeId(string) {
|
||||
if (!string) return false;
|
||||
var matches = string.match(/^.*(youtu.be\/|v\/|u\/\w\/|embed\/|watch\?v=|\&v=)([^#\&\?]*).*/);
|
||||
return matches && matches[2].length === 11 ? matches[2] : false;
|
||||
}
|
||||
}, {
|
||||
key: '_getVimeoId',
|
||||
value: function _getVimeoId(string) {
|
||||
return string && string.indexOf('vimeo') > 0 ? string : false;
|
||||
}
|
||||
}, {
|
||||
key: '_getInstagramId',
|
||||
value: function _getInstagramId(string) {
|
||||
return string && string.indexOf('instagram') > 0 ? string : false;
|
||||
}
|
||||
|
||||
// layout private methods
|
||||
}, {
|
||||
key: '_toggleLoading',
|
||||
value: function _toggleLoading(show) {
|
||||
show = show || false;
|
||||
if (show) {
|
||||
this._$modalDialog.css('display', 'none');
|
||||
this._$modal.removeClass('in show');
|
||||
$('.modal-backdrop').append(this._config.loadingMessage);
|
||||
} else {
|
||||
this._$modalDialog.css('display', 'block');
|
||||
this._$modal.addClass('in show');
|
||||
$('.modal-backdrop').find('.ekko-lightbox-loader').remove();
|
||||
}
|
||||
return this;
|
||||
}
|
||||
}, {
|
||||
key: '_calculateBorders',
|
||||
value: function _calculateBorders() {
|
||||
return {
|
||||
top: this._totalCssByAttribute('border-top-width'),
|
||||
right: this._totalCssByAttribute('border-right-width'),
|
||||
bottom: this._totalCssByAttribute('border-bottom-width'),
|
||||
left: this._totalCssByAttribute('border-left-width')
|
||||
};
|
||||
}
|
||||
}, {
|
||||
key: '_calculatePadding',
|
||||
value: function _calculatePadding() {
|
||||
return {
|
||||
top: this._totalCssByAttribute('padding-top'),
|
||||
right: this._totalCssByAttribute('padding-right'),
|
||||
bottom: this._totalCssByAttribute('padding-bottom'),
|
||||
left: this._totalCssByAttribute('padding-left')
|
||||
};
|
||||
}
|
||||
}, {
|
||||
key: '_totalCssByAttribute',
|
||||
value: function _totalCssByAttribute(attribute) {
|
||||
return parseInt(this._$modalDialog.css(attribute), 10) + parseInt(this._$modalContent.css(attribute), 10) + parseInt(this._$modalBody.css(attribute), 10);
|
||||
}
|
||||
}, {
|
||||
key: '_updateTitleAndFooter',
|
||||
value: function _updateTitleAndFooter() {
|
||||
var title = this._$element.data('title') || "";
|
||||
var caption = this._$element.data('footer') || "";
|
||||
|
||||
this._titleIsShown = false;
|
||||
if (title || this._config.alwaysShowClose) {
|
||||
this._titleIsShown = true;
|
||||
this._$modalHeader.css('display', '').find('.modal-title').html(title || " ");
|
||||
} else this._$modalHeader.css('display', 'none');
|
||||
|
||||
this._footerIsShown = false;
|
||||
if (caption) {
|
||||
this._footerIsShown = true;
|
||||
this._$modalFooter.css('display', '').html(caption);
|
||||
} else this._$modalFooter.css('display', 'none');
|
||||
|
||||
return this;
|
||||
}
|
||||
}, {
|
||||
key: '_showYoutubeVideo',
|
||||
value: function _showYoutubeVideo(remote, $containerForElement) {
|
||||
var id = this._getYoutubeId(remote);
|
||||
var query = remote.indexOf('&') > 0 ? remote.substr(remote.indexOf('&')) : '';
|
||||
var width = this._$element.data('width') || 560;
|
||||
var height = this._$element.data('height') || width / (560 / 315);
|
||||
return this._showVideoIframe('//www.youtube.com/embed/' + id + '?badge=0&autoplay=1&html5=1' + query, width, height, $containerForElement);
|
||||
}
|
||||
}, {
|
||||
key: '_showVimeoVideo',
|
||||
value: function _showVimeoVideo(id, $containerForElement) {
|
||||
var width = this._$element.data('width') || 500;
|
||||
var height = this._$element.data('height') || width / (560 / 315);
|
||||
return this._showVideoIframe(id + '?autoplay=1', width, height, $containerForElement);
|
||||
}
|
||||
}, {
|
||||
key: '_showInstagramVideo',
|
||||
value: function _showInstagramVideo(id, $containerForElement) {
|
||||
// instagram load their content into iframe's so this can be put straight into the element
|
||||
var width = this._$element.data('width') || 612;
|
||||
var height = width + 80;
|
||||
id = id.substr(-1) !== '/' ? id + '/' : id; // ensure id has trailing slash
|
||||
$containerForElement.html('<iframe width="' + width + '" height="' + height + '" src="' + id + 'embed/" frameborder="0" allowfullscreen></iframe>');
|
||||
this._resize(width, height);
|
||||
this._config.onContentLoaded.call(this);
|
||||
if (this._$modalArrows) //hide the arrows when showing video
|
||||
this._$modalArrows.css('display', 'none');
|
||||
this._toggleLoading(false);
|
||||
return this;
|
||||
}
|
||||
}, {
|
||||
key: '_showVideoIframe',
|
||||
value: function _showVideoIframe(url, width, height, $containerForElement) {
|
||||
// should be used for videos only. for remote content use loadRemoteContent (data-type=url)
|
||||
height = height || width; // default to square
|
||||
$containerForElement.html('<div class="embed-responsive embed-responsive-16by9"><iframe width="' + width + '" height="' + height + '" src="' + url + '" frameborder="0" allowfullscreen class="embed-responsive-item"></iframe></div>');
|
||||
this._resize(width, height);
|
||||
this._config.onContentLoaded.call(this);
|
||||
if (this._$modalArrows) this._$modalArrows.css('display', 'none'); //hide the arrows when showing video
|
||||
this._toggleLoading(false);
|
||||
return this;
|
||||
}
|
||||
}, {
|
||||
key: '_showHtml5Video',
|
||||
value: function _showHtml5Video(url, $containerForElement) {
|
||||
// should be used for videos only. for remote content use loadRemoteContent (data-type=url)
|
||||
var width = this._$element.data('width') || 560;
|
||||
var height = this._$element.data('height') || width / (560 / 315);
|
||||
$containerForElement.html('<div class="embed-responsive embed-responsive-16by9"><video width="' + width + '" height="' + height + '" src="' + url + '" preload="auto" autoplay controls class="embed-responsive-item"></video></div>');
|
||||
this._resize(width, height);
|
||||
this._config.onContentLoaded.call(this);
|
||||
if (this._$modalArrows) this._$modalArrows.css('display', 'none'); //hide the arrows when showing video
|
||||
this._toggleLoading(false);
|
||||
return this;
|
||||
}
|
||||
}, {
|
||||
key: '_loadRemoteContent',
|
||||
value: function _loadRemoteContent(url, $containerForElement) {
|
||||
var _this3 = this;
|
||||
|
||||
var width = this._$element.data('width') || 560;
|
||||
var height = this._$element.data('height') || 560;
|
||||
|
||||
var disableExternalCheck = this._$element.data('disableExternalCheck') || false;
|
||||
this._toggleLoading(false);
|
||||
|
||||
// external urls are loading into an iframe
|
||||
// local ajax can be loaded into the container itself
|
||||
if (!disableExternalCheck && !this._isExternal(url)) {
|
||||
$containerForElement.load(url, $.proxy(function () {
|
||||
return _this3._$element.trigger('loaded.bs.modal');l;
|
||||
}));
|
||||
} else {
|
||||
$containerForElement.html('<iframe src="' + url + '" frameborder="0" allowfullscreen></iframe>');
|
||||
this._config.onContentLoaded.call(this);
|
||||
}
|
||||
|
||||
if (this._$modalArrows) //hide the arrows when remote content
|
||||
this._$modalArrows.css('display', 'none');
|
||||
|
||||
this._resize(width, height);
|
||||
return this;
|
||||
}
|
||||
}, {
|
||||
key: '_isExternal',
|
||||
value: function _isExternal(url) {
|
||||
var match = url.match(/^([^:\/?#]+:)?(?:\/\/([^\/?#]*))?([^?#]+)?(\?[^#]*)?(#.*)?/);
|
||||
if (typeof match[1] === "string" && match[1].length > 0 && match[1].toLowerCase() !== location.protocol) return true;
|
||||
|
||||
if (typeof match[2] === "string" && match[2].length > 0 && match[2].replace(new RegExp(':(' + ({
|
||||
"http:": 80,
|
||||
"https:": 443
|
||||
})[location.protocol] + ')?$'), "") !== location.host) return true;
|
||||
|
||||
return false;
|
||||
}
|
||||
}, {
|
||||
key: '_error',
|
||||
value: function _error(message) {
|
||||
console.error(message);
|
||||
this._containerToUse().html(message);
|
||||
this._resize(300, 300);
|
||||
return this;
|
||||
}
|
||||
}, {
|
||||
key: '_preloadImageByIndex',
|
||||
value: function _preloadImageByIndex(startIndex, numberOfTimes) {
|
||||
|
||||
if (!this._$galleryItems) return;
|
||||
|
||||
var next = $(this._$galleryItems.get(startIndex), false);
|
||||
if (typeof next == 'undefined') return;
|
||||
|
||||
var src = next.attr('data-remote') || next.attr('href');
|
||||
if (next.attr('data-type') === 'image' || this._isImage(src)) this._preloadImage(src, false);
|
||||
|
||||
if (numberOfTimes > 0) return this._preloadImageByIndex(startIndex + 1, numberOfTimes - 1);
|
||||
}
|
||||
}, {
|
||||
key: '_preloadImage',
|
||||
value: function _preloadImage(src, $containerForImage) {
|
||||
var _this4 = this;
|
||||
|
||||
$containerForImage = $containerForImage || false;
|
||||
|
||||
var img = new Image();
|
||||
if ($containerForImage) {
|
||||
(function () {
|
||||
|
||||
// if loading takes > 200ms show a loader
|
||||
var loadingTimeout = setTimeout(function () {
|
||||
$containerForImage.append(_this4._config.loadingMessage);
|
||||
}, 200);
|
||||
|
||||
img.onload = function () {
|
||||
if (loadingTimeout) clearTimeout(loadingTimeout);
|
||||
loadingTimeout = null;
|
||||
var image = $('<img />');
|
||||
image.attr('src', img.src);
|
||||
image.addClass('img-fluid');
|
||||
|
||||
// backward compatibility for bootstrap v3
|
||||
image.css('width', '100%');
|
||||
|
||||
$containerForImage.html(image);
|
||||
if (_this4._$modalArrows) _this4._$modalArrows.css('display', ''); // remove display to default to css property
|
||||
|
||||
_this4._resize(img.width, img.height);
|
||||
_this4._toggleLoading(false);
|
||||
return _this4._config.onContentLoaded.call(_this4);
|
||||
};
|
||||
img.onerror = function () {
|
||||
_this4._toggleLoading(false);
|
||||
return _this4._error(_this4._config.strings.fail + (' ' + src));
|
||||
};
|
||||
})();
|
||||
}
|
||||
|
||||
img.src = src;
|
||||
return img;
|
||||
}
|
||||
}, {
|
||||
key: '_swipeGesure',
|
||||
value: function _swipeGesure() {
|
||||
if (this._touchendX < this._touchstartX) {
|
||||
return this.navigateRight();
|
||||
}
|
||||
if (this._touchendX > this._touchstartX) {
|
||||
return this.navigateLeft();
|
||||
}
|
||||
}
|
||||
}, {
|
||||
key: '_resize',
|
||||
value: function _resize(width, height) {
|
||||
|
||||
height = height || width;
|
||||
this._wantedWidth = width;
|
||||
this._wantedHeight = height;
|
||||
|
||||
var imageAspecRatio = width / height;
|
||||
|
||||
// if width > the available space, scale down the expected width and height
|
||||
var widthBorderAndPadding = this._padding.left + this._padding.right + this._border.left + this._border.right;
|
||||
|
||||
// force 10px margin if window size > 575px
|
||||
var addMargin = this._config.doc.body.clientWidth > 575 ? 20 : 0;
|
||||
var discountMargin = this._config.doc.body.clientWidth > 575 ? 0 : 20;
|
||||
|
||||
var maxWidth = Math.min(width + widthBorderAndPadding, this._config.doc.body.clientWidth - addMargin, this._config.maxWidth);
|
||||
|
||||
if (width + widthBorderAndPadding > maxWidth) {
|
||||
height = (maxWidth - widthBorderAndPadding - discountMargin) / imageAspecRatio;
|
||||
width = maxWidth;
|
||||
} else width = width + widthBorderAndPadding;
|
||||
|
||||
var headerHeight = 0,
|
||||
footerHeight = 0;
|
||||
|
||||
// as the resize is performed the modal is show, the calculate might fail
|
||||
// if so, default to the default sizes
|
||||
if (this._footerIsShown) footerHeight = this._$modalFooter.outerHeight(true) || 55;
|
||||
|
||||
if (this._titleIsShown) headerHeight = this._$modalHeader.outerHeight(true) || 67;
|
||||
|
||||
var borderPadding = this._padding.top + this._padding.bottom + this._border.bottom + this._border.top;
|
||||
|
||||
//calculated each time as resizing the window can cause them to change due to Bootstraps fluid margins
|
||||
var margins = parseFloat(this._$modalDialog.css('margin-top')) + parseFloat(this._$modalDialog.css('margin-bottom'));
|
||||
|
||||
var maxHeight = Math.min(height, $(window).height() - borderPadding - margins - headerHeight - footerHeight, this._config.maxHeight - borderPadding - headerHeight - footerHeight);
|
||||
|
||||
if (height > maxHeight) {
|
||||
// if height > the available height, scale down the width
|
||||
width = Math.ceil(maxHeight * imageAspecRatio) + widthBorderAndPadding;
|
||||
}
|
||||
|
||||
this._$lightboxContainer.css('height', maxHeight);
|
||||
this._$modalDialog.css('flex', 1).css('maxWidth', width);
|
||||
|
||||
var modal = this._$modal.data('bs.modal');
|
||||
if (modal) {
|
||||
// v4 method is mistakenly protected
|
||||
try {
|
||||
modal._handleUpdate();
|
||||
} catch (Exception) {
|
||||
modal.handleUpdate();
|
||||
}
|
||||
}
|
||||
return this;
|
||||
}
|
||||
}], [{
|
||||
key: '_jQueryInterface',
|
||||
value: function _jQueryInterface(config) {
|
||||
var _this5 = this;
|
||||
|
||||
config = config || {};
|
||||
return this.each(function () {
|
||||
var $this = $(_this5);
|
||||
var _config = $.extend({}, Lightbox.Default, $this.data(), typeof config === 'object' && config);
|
||||
|
||||
new Lightbox(_this5, _config);
|
||||
});
|
||||
}
|
||||
}]);
|
||||
|
||||
return Lightbox;
|
||||
})();
|
||||
|
||||
$.fn[NAME] = Lightbox._jQueryInterface;
|
||||
$.fn[NAME].Constructor = Lightbox;
|
||||
$.fn[NAME].noConflict = function () {
|
||||
$.fn[NAME] = JQUERY_NO_CONFLICT;
|
||||
return Lightbox._jQueryInterface;
|
||||
};
|
||||
|
||||
return Lightbox;
|
||||
})(jQuery);
|
||||
//# sourceMappingURL=ekko-lightbox.js.map
|
||||
|
||||
}(jQuery);
|
||||
17514
assets/js/vendor/hy-drawer/index.dev.js
vendored
Normal file
17514
assets/js/vendor/hy-drawer/index.dev.js
vendored
Normal file
File diff suppressed because it is too large
Load Diff
34
assets/js/vendor/hy-drawer/index.js
vendored
Normal file
34
assets/js/vendor/hy-drawer/index.js
vendored
Normal file
File diff suppressed because one or more lines are too long
17427
assets/js/vendor/hy-drawer/vanilla/index.dev.js
vendored
Normal file
17427
assets/js/vendor/hy-drawer/vanilla/index.dev.js
vendored
Normal file
File diff suppressed because it is too large
Load Diff
1
assets/js/vendor/hy-drawer/vanilla/index.dev.js.map
vendored
Normal file
1
assets/js/vendor/hy-drawer/vanilla/index.dev.js.map
vendored
Normal file
File diff suppressed because one or more lines are too long
34
assets/js/vendor/hy-drawer/vanilla/index.js
vendored
Normal file
34
assets/js/vendor/hy-drawer/vanilla/index.js
vendored
Normal file
File diff suppressed because one or more lines are too long
1
assets/js/vendor/hy-drawer/vanilla/index.js.map
vendored
Normal file
1
assets/js/vendor/hy-drawer/vanilla/index.js.map
vendored
Normal file
File diff suppressed because one or more lines are too long
116
assets/js/vendor/images-compare/images-compare.css
vendored
Normal file
116
assets/js/vendor/images-compare/images-compare.css
vendored
Normal file
@@ -0,0 +1,116 @@
|
||||
/* Images compare main container */
|
||||
.images-compare-container {
|
||||
display: inline-block;
|
||||
position: relative;
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
/* Images compare front element */
|
||||
.images-compare-before {
|
||||
will-change: clip;
|
||||
position: absolute;
|
||||
top: 0;
|
||||
left: 0;
|
||||
z-index: 2;
|
||||
pointer-events: none;
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
/* Images compare back element */
|
||||
.images-compare-after {
|
||||
pointer-events: none;
|
||||
}
|
||||
|
||||
/* Responsive image settings */
|
||||
.images-compare-before img, .images-compare-after img {
|
||||
max-width: 100%;
|
||||
height: auto;
|
||||
display: block;
|
||||
}
|
||||
|
||||
/* Separator (thin vertical blank line) */
|
||||
.images-compare-separator {
|
||||
position: absolute;
|
||||
background: white;
|
||||
height: 100%;
|
||||
width: 1px;
|
||||
z-index: 4;
|
||||
left: 0;
|
||||
top: 0;
|
||||
}
|
||||
|
||||
/* Drag handle (circle) */
|
||||
.images-compare-handle {
|
||||
height: 38px;
|
||||
width: 38px;
|
||||
position: absolute;
|
||||
left: 50%;
|
||||
top: 50%;
|
||||
margin-left: -22px;
|
||||
margin-top: -22px;
|
||||
border: 3px solid white;
|
||||
-webkit-border-radius: 1000px;
|
||||
-moz-border-radius: 1000px;
|
||||
border-radius: 1000px;
|
||||
-webkit-box-shadow: 0 0 12px rgba(51, 51, 51, 0.5);
|
||||
-moz-box-shadow: 0 0 12px rgba(51, 51, 51, 0.5);
|
||||
box-shadow: 0 0 12px rgba(51, 51, 51, 0.5);
|
||||
z-index: 3;
|
||||
background: rgb(0, 0, 0);
|
||||
background: rgba(0, 0, 0, 0.7);
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
/* Drag handle arrows */
|
||||
.images-compare-left-arrow, .images-compare-right-arrow {
|
||||
width: 0;
|
||||
height: 0;
|
||||
border: 6px inset transparent;
|
||||
position: absolute;
|
||||
top: 50%;
|
||||
margin-top: -6px;
|
||||
}
|
||||
|
||||
.images-compare-left-arrow {
|
||||
border-right: 6px solid white;
|
||||
left: 50%;
|
||||
margin-left: -17px;
|
||||
}
|
||||
|
||||
.images-compare-right-arrow {
|
||||
border-left: 6px solid white;
|
||||
right: 50%;
|
||||
margin-right: -17px;
|
||||
}
|
||||
|
||||
/* Label */
|
||||
.images-compare-label {
|
||||
font-family: sans-serif;
|
||||
text-transform: uppercase;
|
||||
font-weight: bold;
|
||||
position: absolute;
|
||||
top: 10px;
|
||||
left: 10px;
|
||||
z-index: 1;
|
||||
color: rgb(0, 0, 0);
|
||||
color: rgba(0, 0, 0, 0.4);
|
||||
background: rgb(255, 255, 255);
|
||||
background: rgba(255, 255, 255, 0.7);
|
||||
padding: 10px;
|
||||
border-radius: 5px;
|
||||
pointer-events: none;
|
||||
display: none;
|
||||
}
|
||||
|
||||
.images-compare-container .images-compare-label {
|
||||
display: inherit;
|
||||
}
|
||||
|
||||
.images-compare-before .images-compare-label {
|
||||
left: 10px;
|
||||
}
|
||||
|
||||
.images-compare-after .images-compare-label {
|
||||
left: auto;
|
||||
right: 10px;
|
||||
}
|
||||
471
assets/js/vendor/images-compare/jquery.images-compare.js
vendored
Normal file
471
assets/js/vendor/images-compare/jquery.images-compare.js
vendored
Normal file
@@ -0,0 +1,471 @@
|
||||
/** global: Hammer */
|
||||
;(function ($, window) {
|
||||
"use strict";
|
||||
|
||||
function stringRepeat(s, precision) {
|
||||
// String repeat polyfill
|
||||
if (!String.prototype.repeat) {
|
||||
precision = precision || 1;
|
||||
return new Array(precision + 1).join(s);
|
||||
}
|
||||
return s.repeat(precision);
|
||||
}
|
||||
|
||||
var pluginName = 'imagesCompare',
|
||||
defaults = {
|
||||
initVisibleRatio: 0.5,
|
||||
interactionMode: "drag", // "drag", "mousemove", "click"
|
||||
animationDuration: 400, // default animation duration in ms
|
||||
animationEasing: "swing",
|
||||
addSeparator: true, // add a html element on the separation
|
||||
addDragHandle: true, // add a html drag handle element on the separation
|
||||
precision: 4
|
||||
};
|
||||
|
||||
// Our object, using revealing module pattern
|
||||
function ImagesCompare(element, options) {
|
||||
element = $(element);
|
||||
options = $.extend({}, defaults, options);
|
||||
options.roundFactor = parseInt('1' + stringRepeat('0', options.precision));
|
||||
|
||||
this._name = pluginName;
|
||||
|
||||
var frontElement, backElement, separator, dragHandle, lastRatio = 1, size = {
|
||||
width: 0,
|
||||
height: 0,
|
||||
maxWidth: 0,
|
||||
maxHeight: 0
|
||||
}, events = {
|
||||
initialised: "imagesCompare:initialised",
|
||||
changed: "imagesCompare:changed",
|
||||
resized: "imagesCompare:resized"
|
||||
};
|
||||
|
||||
function onImagesLoaded() {
|
||||
var images = element.find('img'),
|
||||
totalImagesCount= images.length,
|
||||
elementsLoaded = 0;
|
||||
|
||||
function onImageLoaded(){
|
||||
if (elementsLoaded >= totalImagesCount) {
|
||||
init();
|
||||
}
|
||||
}
|
||||
|
||||
images.each(function() {
|
||||
// Image already loaded (cached)
|
||||
if ($(this)[0].complete) {
|
||||
totalImagesCount--;
|
||||
onImageLoaded();
|
||||
} else {
|
||||
// Image loading / error
|
||||
$(this).on('load', function() {
|
||||
elementsLoaded++;
|
||||
onImageLoaded();
|
||||
});
|
||||
$(this).on('error', function() {
|
||||
elementsLoaded++;
|
||||
onImageLoaded();
|
||||
});
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
onImagesLoaded();
|
||||
|
||||
function init() {
|
||||
updateDom();
|
||||
patchSize();
|
||||
initInteractions();
|
||||
|
||||
$(frontElement).attr('ratio', options.initVisibleRatio);
|
||||
setVisibleRatio(options.initVisibleRatio);
|
||||
|
||||
// Let the world know we have done the init
|
||||
element.trigger({
|
||||
type: events.initialised
|
||||
});
|
||||
}
|
||||
|
||||
function addResize() {
|
||||
$(window).on('resize', function (event) {
|
||||
frontElement.css('clip', '');
|
||||
patchSize();
|
||||
setVisibleRatio(lastRatio);
|
||||
|
||||
// Let the world know we have done some resize updates
|
||||
element.trigger({
|
||||
type: events.resized,
|
||||
originalEvent: event
|
||||
});
|
||||
});
|
||||
}
|
||||
|
||||
function initInteractions() {
|
||||
options.interactionMode = options.interactionMode.toLowerCase();
|
||||
|
||||
if (options.interactionMode != "drag" && options.interactionMode != "mousemove" && options.interactionMode != "click") {
|
||||
console.warn('No valid interactionMode found, valid values are "drag", "mousemove", "click"');
|
||||
}
|
||||
|
||||
switch (options.interactionMode) {
|
||||
case "drag":
|
||||
initDrag();
|
||||
break;
|
||||
case "mousemove":
|
||||
initMouseMove();
|
||||
break;
|
||||
case "click":
|
||||
initClick();
|
||||
break;
|
||||
default:
|
||||
initDrag();
|
||||
}
|
||||
}
|
||||
|
||||
function initDrag() {
|
||||
if (typeof Hammer == 'undefined') {
|
||||
console.error('Please include the hammerjs library for drag support');
|
||||
}
|
||||
addDrag();
|
||||
addResize();
|
||||
}
|
||||
|
||||
function initMouseMove() {
|
||||
addMouseMove();
|
||||
addResize();
|
||||
}
|
||||
|
||||
function initClick() {
|
||||
addClick();
|
||||
addResize();
|
||||
}
|
||||
|
||||
function addClick() {
|
||||
element.on('click', function (event) {
|
||||
var ratio = getElementRatio(event.pageX);
|
||||
setVisibleRatio(ratio);
|
||||
});
|
||||
}
|
||||
|
||||
function addMouseMove() {
|
||||
var lastMove = 0;
|
||||
var eventThrottle = 1;
|
||||
element.on('mousemove', function (event) {
|
||||
event.preventDefault();
|
||||
var now = Date.now();
|
||||
if (now > lastMove + eventThrottle) {
|
||||
lastMove = now;
|
||||
var ratio = getElementRatio(event.pageX);
|
||||
setVisibleRatio(ratio);
|
||||
}
|
||||
});
|
||||
|
||||
element.on('mouseout', function (event) {
|
||||
var ratio = getElementRatio(event.pageX);
|
||||
setVisibleRatio(ratio);
|
||||
});
|
||||
}
|
||||
|
||||
function addDrag() {
|
||||
var hammertime = new Hammer(element[0]);
|
||||
hammertime.get('pan').set({direction: Hammer.DIRECTION_HORIZONTAL});
|
||||
hammertime.on('pan', function (event) {
|
||||
var ratio = getElementRatio(event.srcEvent.pageX);
|
||||
setVisibleRatio(ratio);
|
||||
});
|
||||
}
|
||||
|
||||
function updateDom() {
|
||||
element.addClass('images-compare-container');
|
||||
element.css('display', 'inline-block');
|
||||
|
||||
frontElement = element.find('> *:nth-child(1)');
|
||||
backElement = element.find('> *:nth-child(2)');
|
||||
|
||||
frontElement.addClass("images-compare-before");
|
||||
frontElement.css('display', 'block');
|
||||
backElement.addClass("images-compare-after");
|
||||
backElement.css('display', 'block');
|
||||
|
||||
if (options.addDragHandle) {
|
||||
buildDragHandle();
|
||||
}
|
||||
|
||||
if (options.addSeparator) {
|
||||
buildSeparator();
|
||||
}
|
||||
}
|
||||
|
||||
function buildSeparator() {
|
||||
element.prepend("<div class='images-compare-separator'></div>");
|
||||
separator = element.find(".images-compare-separator");
|
||||
|
||||
}
|
||||
|
||||
function buildDragHandle() {
|
||||
element.prepend("<div class='images-compare-handle'></div>");
|
||||
dragHandle = element.find(".images-compare-handle");
|
||||
dragHandle.append("<span class='images-compare-left-arrow'></span>");
|
||||
dragHandle.append("<span class='images-compare-right-arrow'></span>");
|
||||
}
|
||||
|
||||
function patchSize() {
|
||||
var imgRef = backElement.find('img').first();
|
||||
setSize(imgRef.width(), imgRef.height(), imgRef.naturalWidth(), imgRef.naturalHeight());
|
||||
element.css('max-width', size.maxWidth + 'px');
|
||||
element.css('max-height', size.maxHeight + 'px');
|
||||
frontElement.width(size.width);
|
||||
frontElement.height(size.height);
|
||||
}
|
||||
|
||||
/**
|
||||
*
|
||||
* @param x
|
||||
* @return float
|
||||
*/
|
||||
function getElementRatio(x) {
|
||||
return roundRatio((x - element.offset().left) / frontElement.width());
|
||||
}
|
||||
|
||||
/**
|
||||
*
|
||||
* @param ratio
|
||||
* @return float
|
||||
*/
|
||||
function roundRatio(ratio) {
|
||||
ratio = Math.round((ratio * options.roundFactor)) / options.roundFactor;
|
||||
if (ratio > 1) {
|
||||
ratio = 1;
|
||||
}
|
||||
|
||||
if (ratio < 0) {
|
||||
ratio = 0;
|
||||
}
|
||||
|
||||
return ratio;
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
* Animation request
|
||||
*
|
||||
* @param startValue float
|
||||
* @param endValue float
|
||||
* @param duration value in ms
|
||||
* @param easing linear or swing
|
||||
*/
|
||||
function launchAnimation(startValue, endValue, duration, easing) {
|
||||
$(frontElement).attr('ratio', startValue).animate({ratio: startValue}, {
|
||||
duration: 0
|
||||
});
|
||||
|
||||
$(frontElement).stop().attr('ratio', startValue).animate({ratio: endValue}, {
|
||||
duration: duration,
|
||||
easing: easing,
|
||||
step: function (now) {
|
||||
var width = getRatioValue(now);
|
||||
lastRatio = now;
|
||||
frontElement.attr('ratio', now).css('clip', 'rect(0, ' + width + 'px, ' + size.height + 'px, 0)');
|
||||
|
||||
if (options.addSeparator) {
|
||||
separator.css('left', width + 'px');
|
||||
}
|
||||
|
||||
if (options.addDragHandle) {
|
||||
dragHandle.css('left', width + 'px');
|
||||
}
|
||||
},
|
||||
done: function (animation, jumpedToEnd) {
|
||||
var ratio = $(frontElement).attr('ratio');
|
||||
// Let the world know something has changed
|
||||
element.trigger({
|
||||
type: events.changed,
|
||||
ratio: ratio,
|
||||
value: getRatioValue(ratio),
|
||||
animate: true,
|
||||
animation : animation,
|
||||
jumpedToEnd: jumpedToEnd
|
||||
});
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Get value to reach, based on a ratio
|
||||
*
|
||||
* @param ratio float
|
||||
* @return {number}
|
||||
*/
|
||||
function getRatioValue(ratio) {
|
||||
ratio = Math.round((ratio * options.roundFactor)) / options.roundFactor;
|
||||
return Math.round(frontElement.width() * ratio);
|
||||
}
|
||||
|
||||
/**
|
||||
* Change visible ratio
|
||||
*
|
||||
* @param ratio float
|
||||
* @param animate boolean Do we want an animation ?
|
||||
* @param duration in ms
|
||||
* @param easing 'swing', 'linear'
|
||||
*/
|
||||
function setVisibleRatio(ratio, animate, duration, easing) {
|
||||
if (typeof animate == 'undefined') {
|
||||
animate = false;
|
||||
}
|
||||
|
||||
var width = getRatioValue(ratio);
|
||||
|
||||
if (animate) {
|
||||
var finalDuration = duration ? duration : options.animationDuration;
|
||||
var finalEasing = easing ? easing : options.animationEasing;
|
||||
|
||||
launchAnimation(lastRatio, ratio, finalDuration, finalEasing);
|
||||
|
||||
// Let the world know something has changed
|
||||
if (lastRatio != ratio) {
|
||||
element.trigger({
|
||||
type: events.changed,
|
||||
ratio: lastRatio,
|
||||
value: width,
|
||||
animate: animate
|
||||
});
|
||||
}
|
||||
|
||||
return;
|
||||
|
||||
} else {
|
||||
frontElement.stop().css('clip', 'rect(0, ' + width + 'px, ' + size.height + 'px, 0)');
|
||||
|
||||
if (options.addSeparator) {
|
||||
$(separator).stop().css('left', width + 'px');
|
||||
}
|
||||
|
||||
if (options.addDragHandle) {
|
||||
dragHandle.css('left', width + 'px');
|
||||
}
|
||||
}
|
||||
|
||||
// Let the world know something has changed
|
||||
if (lastRatio != ratio) {
|
||||
element.trigger({
|
||||
type: events.changed,
|
||||
ratio: ratio,
|
||||
value: width,
|
||||
animate: animate
|
||||
});
|
||||
}
|
||||
|
||||
lastRatio = ratio;
|
||||
}
|
||||
|
||||
function setSize(width, height, maxWidth, maxHeight) {
|
||||
if (typeof width != 'undefined') {
|
||||
setWidth(width);
|
||||
}
|
||||
if (typeof height != 'undefined') {
|
||||
setHeight(height);
|
||||
}
|
||||
if (typeof maxWidth != 'undefined') {
|
||||
setMaxWidth(maxWidth);
|
||||
}
|
||||
if (typeof maxHeight != 'undefined') {
|
||||
setMaxHeight(maxHeight);
|
||||
}
|
||||
return size;
|
||||
}
|
||||
|
||||
function setWidth(width) {
|
||||
size.width = width;
|
||||
return size;
|
||||
}
|
||||
|
||||
function setMaxWidth(maxWidth) {
|
||||
size.maxWidth = maxWidth;
|
||||
return size;
|
||||
}
|
||||
|
||||
function setHeight(height) {
|
||||
size.height = height;
|
||||
return size;
|
||||
}
|
||||
|
||||
function setMaxHeight(maxHeight) {
|
||||
size.maxHeight = maxHeight;
|
||||
return size;
|
||||
}
|
||||
|
||||
// public function declaration
|
||||
// returning element to preserve chaining
|
||||
return {
|
||||
"setValue": function (ratio, animate, duration, easing) {
|
||||
setVisibleRatio(ratio, animate, duration, easing);
|
||||
return element;
|
||||
},
|
||||
"getValue": function () {
|
||||
return lastRatio;
|
||||
},
|
||||
"on": function (eventName, callback) {
|
||||
element.on(eventName, callback);
|
||||
return element;
|
||||
},
|
||||
"off": function (eventName, callback) {
|
||||
element.off(eventName, callback);
|
||||
return element;
|
||||
},
|
||||
"events": function () {
|
||||
return events;
|
||||
}
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Plugin declaration
|
||||
*
|
||||
* @param userOptions
|
||||
* @return {*}
|
||||
*/
|
||||
$.fn.imagesCompare = function (userOptions) {
|
||||
var options = $.extend(defaults, userOptions);
|
||||
return this.each(function () {
|
||||
if (!$.data(this, pluginName)) {
|
||||
$.data(this, pluginName, new ImagesCompare(this, options));
|
||||
}
|
||||
});
|
||||
};
|
||||
|
||||
})(jQuery, window, document);
|
||||
|
||||
// http://www.jacklmoore.com/notes/naturalwidth-and-naturalheight-in-ie/
|
||||
(function ($) {
|
||||
var props = ['Width', 'Height'], prop, propsLength;
|
||||
|
||||
propsLength = props.length;
|
||||
|
||||
for (var index = 0; index < propsLength; index++) {
|
||||
prop = props[index];
|
||||
/*jslint loopfunc: true */
|
||||
(function (natural, prop) {
|
||||
$.fn[natural] = (natural in document.createElement('img')) ?
|
||||
function () {
|
||||
return this[0][natural];
|
||||
} :
|
||||
function () {
|
||||
var
|
||||
node = this[0],
|
||||
img,
|
||||
value = 0;
|
||||
|
||||
if (node.tagName.toLowerCase() === 'img') {
|
||||
img = document.createElement('img');
|
||||
img.src = node.src;
|
||||
value = img[prop];
|
||||
}
|
||||
return value;
|
||||
};
|
||||
}('natural' + prop, prop.toLowerCase()));
|
||||
/*jslint loopfunc: false */
|
||||
}
|
||||
}(jQuery));
|
||||
1
assets/js/vendor/images-compare/jquery.images-compare.min.js.map
vendored
Normal file
1
assets/js/vendor/images-compare/jquery.images-compare.min.js.map
vendored
Normal file
File diff suppressed because one or more lines are too long
1
assets/js/vendor/images-compare/jquery.images-compare.min.map
vendored
Normal file
1
assets/js/vendor/images-compare/jquery.images-compare.min.map
vendored
Normal file
File diff suppressed because one or more lines are too long
1249
assets/js/vendor/jBox/jBox.all.css
vendored
Normal file
1249
assets/js/vendor/jBox/jBox.all.css
vendored
Normal file
File diff suppressed because it is too large
Load Diff
2767
assets/js/vendor/jBox/jBox.all.js
vendored
Normal file
2767
assets/js/vendor/jBox/jBox.all.js
vendored
Normal file
File diff suppressed because it is too large
Load Diff
572
assets/js/vendor/jBox/jBox.css
vendored
Normal file
572
assets/js/vendor/jBox/jBox.css
vendored
Normal file
@@ -0,0 +1,572 @@
|
||||
.jBox-wrapper {
|
||||
text-align: left;
|
||||
box-sizing: border-box;
|
||||
}
|
||||
|
||||
.jBox-title,
|
||||
.jBox-content,
|
||||
.jBox-container {
|
||||
position: relative;
|
||||
word-break: break-word;
|
||||
box-sizing: border-box;
|
||||
}
|
||||
|
||||
.jBox-container {
|
||||
background: #fff;
|
||||
}
|
||||
|
||||
.jBox-content {
|
||||
padding: 8px 12px;
|
||||
overflow-x: hidden;
|
||||
overflow-y: auto;
|
||||
transition: opacity .2s;
|
||||
}
|
||||
|
||||
.jBox-footer {
|
||||
box-sizing: border-box;
|
||||
}
|
||||
|
||||
.jBox-Tooltip .jBox-container,
|
||||
.jBox-Mouse .jBox-container {
|
||||
border-radius: 4px;
|
||||
box-shadow: 0 0 3px rgba(0, 0, 0, 0.25);
|
||||
}
|
||||
|
||||
.jBox-Tooltip .jBox-title,
|
||||
.jBox-Mouse .jBox-title {
|
||||
padding: 8px 10px 0;
|
||||
font-weight: bold;
|
||||
}
|
||||
|
||||
.jBox-Tooltip.jBox-hasTitle .jBox-content,
|
||||
.jBox-Mouse.jBox-hasTitle .jBox-content {
|
||||
padding-top: 5px;
|
||||
}
|
||||
|
||||
.jBox-Mouse {
|
||||
pointer-events: none;
|
||||
}
|
||||
|
||||
.jBox-pointer {
|
||||
position: absolute;
|
||||
overflow: hidden;
|
||||
box-sizing: border-box;
|
||||
}
|
||||
|
||||
.jBox-pointer:after {
|
||||
content: '';
|
||||
width: 20px;
|
||||
height: 20px;
|
||||
position: absolute;
|
||||
background: #fff;
|
||||
transform: rotate(45deg);
|
||||
box-sizing: border-box;
|
||||
}
|
||||
|
||||
.jBox-pointer-top {
|
||||
top: 0;
|
||||
}
|
||||
|
||||
.jBox-pointer-top:after {
|
||||
left: 5px;
|
||||
top: 6px;
|
||||
box-shadow: -1px -1px 2px rgba(0, 0, 0, 0.15);
|
||||
}
|
||||
|
||||
.jBox-pointer-right {
|
||||
right: 0;
|
||||
}
|
||||
|
||||
.jBox-pointer-right:after {
|
||||
top: 5px;
|
||||
right: 6px;
|
||||
box-shadow: 1px -1px 2px rgba(0, 0, 0, 0.15);
|
||||
}
|
||||
|
||||
.jBox-pointer-left {
|
||||
left: 0;
|
||||
}
|
||||
|
||||
.jBox-pointer-left:after {
|
||||
top: 5px;
|
||||
left: 6px;
|
||||
box-shadow: -1px 1px 2px rgba(0, 0, 0, 0.15);
|
||||
}
|
||||
|
||||
.jBox-pointer-bottom {
|
||||
bottom: 0;
|
||||
}
|
||||
|
||||
.jBox-pointer-bottom:after {
|
||||
left: 5px;
|
||||
bottom: 6px;
|
||||
box-shadow: 1px 1px 2px rgba(0, 0, 0, 0.15);
|
||||
}
|
||||
|
||||
.jBox-pointer-top, .jBox-pointer-bottom {
|
||||
width: 30px;
|
||||
height: 12px;
|
||||
}
|
||||
|
||||
.jBox-pointer-left, .jBox-pointer-right {
|
||||
width: 12px;
|
||||
height: 30px;
|
||||
}
|
||||
|
||||
.jBox-Modal .jBox-container {
|
||||
border-radius: 4px;
|
||||
}
|
||||
|
||||
.jBox-Modal .jBox-container, .jBox-Modal.jBox-closeButton-box:before {
|
||||
box-shadow: 0 3px 15px rgba(0, 0, 0, 0.4), 0 0 5px rgba(0, 0, 0, 0.4);
|
||||
}
|
||||
|
||||
.jBox-Modal .jBox-content {
|
||||
padding: 15px 20px;
|
||||
}
|
||||
|
||||
.jBox-Modal .jBox-title {
|
||||
border-radius: 4px 4px 0 0;
|
||||
padding: 15px 20px;
|
||||
background: #fafafa;
|
||||
border-bottom: 1px solid #eee;
|
||||
}
|
||||
|
||||
.jBox-Modal.jBox-closeButton-title .jBox-title {
|
||||
padding-right: 65px;
|
||||
}
|
||||
|
||||
.jBox-Modal .jBox-footer {
|
||||
border-radius: 0 0 4px 4px;
|
||||
}
|
||||
|
||||
.jBox-closeButton {
|
||||
z-index: 1;
|
||||
cursor: pointer;
|
||||
position: absolute;
|
||||
box-sizing: border-box;
|
||||
}
|
||||
|
||||
.jBox-closeButton svg {
|
||||
position: absolute;
|
||||
top: 50%;
|
||||
right: 50%;
|
||||
}
|
||||
|
||||
.jBox-closeButton path {
|
||||
fill: #aaa;
|
||||
transition: fill .2s;
|
||||
}
|
||||
|
||||
.jBox-closeButton:hover path {
|
||||
fill: #888;
|
||||
}
|
||||
|
||||
.jBox-overlay .jBox-closeButton {
|
||||
top: 0;
|
||||
right: 0;
|
||||
width: 40px;
|
||||
height: 40px;
|
||||
}
|
||||
|
||||
.jBox-overlay .jBox-closeButton svg {
|
||||
width: 20px;
|
||||
height: 20px;
|
||||
margin-top: -10px;
|
||||
margin-right: -10px;
|
||||
}
|
||||
|
||||
.jBox-overlay .jBox-closeButton path {
|
||||
fill: #ddd;
|
||||
}
|
||||
|
||||
.jBox-overlay .jBox-closeButton:hover path {
|
||||
fill: #fff;
|
||||
}
|
||||
|
||||
.jBox-closeButton-title .jBox-closeButton {
|
||||
top: 0;
|
||||
right: 0;
|
||||
bottom: 0;
|
||||
width: 50px;
|
||||
}
|
||||
|
||||
.jBox-closeButton-title svg {
|
||||
width: 12px;
|
||||
height: 12px;
|
||||
margin-top: -6px;
|
||||
margin-right: -6px;
|
||||
}
|
||||
|
||||
.jBox-closeButton-box {
|
||||
box-sizing: border-box;
|
||||
}
|
||||
|
||||
.jBox-closeButton-box .jBox-closeButton {
|
||||
top: -8px;
|
||||
right: -10px;
|
||||
width: 24px;
|
||||
height: 24px;
|
||||
background: #fff;
|
||||
border-radius: 50%;
|
||||
}
|
||||
|
||||
.jBox-closeButton-box .jBox-closeButton svg {
|
||||
width: 10px;
|
||||
height: 10px;
|
||||
margin-top: -5px;
|
||||
margin-right: -5px;
|
||||
}
|
||||
|
||||
.jBox-closeButton-box:before {
|
||||
content: '';
|
||||
position: absolute;
|
||||
top: -8px;
|
||||
right: -10px;
|
||||
width: 24px;
|
||||
height: 24px;
|
||||
border-radius: 50%;
|
||||
box-shadow: 0 0 5px rgba(0, 0, 0, 0.3);
|
||||
}
|
||||
|
||||
.jBox-closeButton-box.jBox-pointerPosition-top:before {
|
||||
top: 5px;
|
||||
}
|
||||
|
||||
.jBox-closeButton-box.jBox-pointerPosition-right:before {
|
||||
right: 2px;
|
||||
}
|
||||
|
||||
.jBox-Modal.jBox-hasTitle.jBox-closeButton-box .jBox-closeButton {
|
||||
background: #fafafa;
|
||||
}
|
||||
|
||||
.jBox-overlay {
|
||||
position: fixed;
|
||||
top: 0;
|
||||
left: 0;
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
background-color: rgba(0, 0, 0, 0.82);
|
||||
}
|
||||
|
||||
.jBox-footer {
|
||||
background: #fafafa;
|
||||
border-top: 1px solid #eee;
|
||||
padding: 8px 10px;
|
||||
border-radius: 0 0 3px 3px;
|
||||
}
|
||||
|
||||
body[class^="jBox-blockScroll-"],
|
||||
body[class*=" jBox-blockScroll-"] {
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
.jBox-draggable {
|
||||
cursor: move;
|
||||
}
|
||||
|
||||
@keyframes jBoxLoading {
|
||||
to {
|
||||
transform: rotate(360deg);
|
||||
}
|
||||
}
|
||||
|
||||
.jBox-loading .jBox-content {
|
||||
opacity: .2;
|
||||
}
|
||||
|
||||
.jBox-loading-spinner .jBox-content {
|
||||
min-height: 38px !important;
|
||||
min-width: 38px !important;
|
||||
opacity: 0;
|
||||
}
|
||||
|
||||
.jBox-spinner {
|
||||
box-sizing: border-box;
|
||||
position: absolute;
|
||||
top: 50%;
|
||||
left: 50%;
|
||||
width: 24px;
|
||||
height: 24px;
|
||||
margin-top: -12px;
|
||||
margin-left: -12px;
|
||||
}
|
||||
|
||||
.jBox-spinner:before {
|
||||
display: block;
|
||||
box-sizing: border-box;
|
||||
content: '';
|
||||
width: 24px;
|
||||
height: 24px;
|
||||
border-radius: 50%;
|
||||
border: 2px solid rgba(0, 0, 0, 0.2);
|
||||
border-top-color: rgba(0, 0, 0, 0.8);
|
||||
animation: jBoxLoading .6s linear infinite;
|
||||
}
|
||||
|
||||
.jBox-countdown {
|
||||
border-radius: 4px 4px 0 0;
|
||||
z-index: 0;
|
||||
background: #000;
|
||||
opacity: .2;
|
||||
position: absolute;
|
||||
top: 0;
|
||||
left: 0;
|
||||
right: 0;
|
||||
height: 3px;
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
.jBox-countdown-inner {
|
||||
top: 0;
|
||||
right: 0;
|
||||
width: 100%;
|
||||
height: 3px;
|
||||
position: absolute;
|
||||
background: #fff;
|
||||
}
|
||||
|
||||
[class^="jBox-animated-"],
|
||||
[class*=" jBox-animated-"] {
|
||||
animation-fill-mode: both;
|
||||
}
|
||||
|
||||
@keyframes jBox-tada {
|
||||
0% {
|
||||
transform: scale(1);
|
||||
}
|
||||
10%,
|
||||
20% {
|
||||
transform: scale(0.8) rotate(-4deg);
|
||||
}
|
||||
30%,
|
||||
50%,
|
||||
70%,
|
||||
90% {
|
||||
transform: scale(1.2) rotate(4deg);
|
||||
}
|
||||
40%,
|
||||
60%,
|
||||
80% {
|
||||
transform: scale(1.2) rotate(-4deg);
|
||||
}
|
||||
100% {
|
||||
transform: scale(1) rotate(0);
|
||||
}
|
||||
}
|
||||
|
||||
.jBox-animated-tada {
|
||||
animation: jBox-tada 1s;
|
||||
}
|
||||
|
||||
@keyframes jBox-tadaSmall {
|
||||
0% {
|
||||
transform: scale(1);
|
||||
}
|
||||
10%,
|
||||
20% {
|
||||
transform: scale(0.9) rotate(-2deg);
|
||||
}
|
||||
30%,
|
||||
50%,
|
||||
70%,
|
||||
90% {
|
||||
transform: scale(1.1) rotate(2deg);
|
||||
}
|
||||
40%,
|
||||
60%,
|
||||
80% {
|
||||
transform: scale(1.1) rotate(-2deg);
|
||||
}
|
||||
100% {
|
||||
transform: scale(1) rotate(0);
|
||||
}
|
||||
}
|
||||
|
||||
.jBox-animated-tadaSmall {
|
||||
animation: jBox-tadaSmall 1s;
|
||||
}
|
||||
|
||||
@keyframes jBox-flash {
|
||||
0%,
|
||||
50%,
|
||||
100% {
|
||||
opacity: 1;
|
||||
}
|
||||
25%,
|
||||
75% {
|
||||
opacity: 0;
|
||||
}
|
||||
}
|
||||
|
||||
.jBox-animated-flash {
|
||||
animation: jBox-flash .5s;
|
||||
}
|
||||
|
||||
@keyframes jBox-shake {
|
||||
0%,
|
||||
100% {
|
||||
transform: translateX(0);
|
||||
}
|
||||
20%,
|
||||
60% {
|
||||
transform: translateX(-6px);
|
||||
}
|
||||
40%,
|
||||
80% {
|
||||
transform: translateX(6px);
|
||||
}
|
||||
}
|
||||
|
||||
.jBox-animated-shake {
|
||||
animation: jBox-shake .4s;
|
||||
}
|
||||
|
||||
@keyframes jBox-pulseUp {
|
||||
0% {
|
||||
transform: scale(1);
|
||||
}
|
||||
50% {
|
||||
transform: scale(1.15);
|
||||
}
|
||||
100% {
|
||||
transform: scale(1);
|
||||
}
|
||||
}
|
||||
|
||||
.jBox-animated-pulseUp {
|
||||
animation: jBox-pulseUp .25s;
|
||||
}
|
||||
|
||||
@keyframes jBox-pulseDown {
|
||||
0% {
|
||||
transform: scale(1);
|
||||
}
|
||||
50% {
|
||||
transform: scale(0.85);
|
||||
}
|
||||
100% {
|
||||
transform: scale(1);
|
||||
}
|
||||
}
|
||||
|
||||
.jBox-animated-pulseDown {
|
||||
animation: jBox-pulseDown .25s;
|
||||
}
|
||||
|
||||
@keyframes jBox-popIn {
|
||||
0% {
|
||||
transform: scale(0);
|
||||
}
|
||||
50% {
|
||||
transform: scale(1.1);
|
||||
}
|
||||
100% {
|
||||
transform: scale(1);
|
||||
}
|
||||
}
|
||||
|
||||
.jBox-animated-popIn {
|
||||
animation: jBox-popIn .25s;
|
||||
}
|
||||
|
||||
@keyframes jBox-popOut {
|
||||
0% {
|
||||
transform: scale(1);
|
||||
}
|
||||
50% {
|
||||
transform: scale(1.1);
|
||||
}
|
||||
100% {
|
||||
transform: scale(0);
|
||||
}
|
||||
}
|
||||
|
||||
.jBox-animated-popOut {
|
||||
animation: jBox-popOut .25s;
|
||||
}
|
||||
|
||||
@keyframes jBox-fadeIn {
|
||||
0% {
|
||||
opacity: 0;
|
||||
}
|
||||
100% {
|
||||
opacity: 1;
|
||||
}
|
||||
}
|
||||
|
||||
.jBox-animated-fadeIn {
|
||||
animation: jBox-fadeIn .2s;
|
||||
}
|
||||
|
||||
@keyframes jBox-fadeOut {
|
||||
0% {
|
||||
opacity: 1;
|
||||
}
|
||||
100% {
|
||||
opacity: 0;
|
||||
}
|
||||
}
|
||||
|
||||
.jBox-animated-fadeOut {
|
||||
animation: jBox-fadeOut .2s;
|
||||
}
|
||||
|
||||
@keyframes jBox-slideUp {
|
||||
0% {
|
||||
transform: translateY(0);
|
||||
}
|
||||
100% {
|
||||
transform: translateY(-300px);
|
||||
opacity: 0;
|
||||
}
|
||||
}
|
||||
|
||||
.jBox-animated-slideUp {
|
||||
animation: jBox-slideUp .4s;
|
||||
}
|
||||
|
||||
@keyframes jBox-slideRight {
|
||||
0% {
|
||||
transform: translateX(0);
|
||||
}
|
||||
100% {
|
||||
transform: translateX(300px);
|
||||
opacity: 0;
|
||||
}
|
||||
}
|
||||
|
||||
.jBox-animated-slideRight {
|
||||
animation: jBox-slideRight .4s;
|
||||
}
|
||||
|
||||
@keyframes jBox-slideDown {
|
||||
0% {
|
||||
transform: translateY(0);
|
||||
}
|
||||
100% {
|
||||
transform: translateY(300px);
|
||||
opacity: 0;
|
||||
}
|
||||
}
|
||||
|
||||
.jBox-animated-slideDown {
|
||||
animation: jBox-slideDown .4s;
|
||||
}
|
||||
|
||||
@keyframes jBox-slideLeft {
|
||||
0% {
|
||||
transform: translateX(0);
|
||||
}
|
||||
100% {
|
||||
transform: translateX(-300px);
|
||||
opacity: 0;
|
||||
}
|
||||
}
|
||||
|
||||
.jBox-animated-slideLeft {
|
||||
animation: jBox-slideLeft .4s;
|
||||
}
|
||||
|
||||
/*# sourceMappingURL=jBox.css.map */
|
||||
2180
assets/js/vendor/jBox/jBox.js
vendored
Normal file
2180
assets/js/vendor/jBox/jBox.js
vendored
Normal file
File diff suppressed because it is too large
Load Diff
58
assets/js/vendor/jBox/plugins/jBox.Confirm.css
vendored
Normal file
58
assets/js/vendor/jBox/plugins/jBox.Confirm.css
vendored
Normal file
@@ -0,0 +1,58 @@
|
||||
.jBox-Confirm .jBox-content {
|
||||
text-align: center;
|
||||
padding: 46px 35px;
|
||||
}
|
||||
|
||||
@media (max-width: 500px) {
|
||||
.jBox-Confirm .jBox-content {
|
||||
padding: 32px 20px;
|
||||
}
|
||||
}
|
||||
|
||||
.jBox-Confirm-footer {
|
||||
height: 46px;
|
||||
}
|
||||
|
||||
.jBox-Confirm-button {
|
||||
display: block;
|
||||
float: left;
|
||||
cursor: pointer;
|
||||
text-align: center;
|
||||
width: 50%;
|
||||
line-height: 46px;
|
||||
height: 46px;
|
||||
overflow: hidden;
|
||||
padding: 0 10px;
|
||||
transition: color .2s, background-color .2s;
|
||||
box-sizing: border-box;
|
||||
}
|
||||
|
||||
.jBox-Confirm-button-cancel {
|
||||
border-bottom-left-radius: 4px;
|
||||
background: #ddd;
|
||||
color: #666;
|
||||
}
|
||||
|
||||
.jBox-Confirm-button-cancel:hover, .jBox-Confirm-button-cancel:active {
|
||||
background: #ccc;
|
||||
}
|
||||
|
||||
.jBox-Confirm-button-cancel:active {
|
||||
box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.2);
|
||||
}
|
||||
|
||||
.jBox-Confirm-button-submit {
|
||||
border-bottom-right-radius: 4px;
|
||||
background: #7d0;
|
||||
color: #fff;
|
||||
}
|
||||
|
||||
.jBox-Confirm-button-submit:hover, .jBox-Confirm-button-submit:active {
|
||||
background: #6c0;
|
||||
}
|
||||
|
||||
.jBox-Confirm-button-submit:active {
|
||||
box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.2);
|
||||
}
|
||||
|
||||
/*# sourceMappingURL=jBox.Confirm.css.map */
|
||||
97
assets/js/vendor/jBox/plugins/jBox.Confirm.js
vendored
Normal file
97
assets/js/vendor/jBox/plugins/jBox.Confirm.js
vendored
Normal file
@@ -0,0 +1,97 @@
|
||||
/**
|
||||
* jBox Confirm plugin: Add a confirm dialog to links, buttons, etc.
|
||||
*
|
||||
* Author: Stephan Wagner <stephanwagner.me@gmail.com> (https://stephanwagner.me)
|
||||
*
|
||||
* License: MIT (https://opensource.org/licenses/MIT)
|
||||
*
|
||||
* Requires: jBox (https://cdn.jsdelivr.net/gh/StephanWagner/jBox@latest/dist/jBox.min.js)
|
||||
*/
|
||||
|
||||
function jBoxConfirmWrapper(jBox, jQuery) {
|
||||
|
||||
new jBox.plugin('Confirm', {
|
||||
|
||||
|
||||
// Options (https://stephanwagner.me/jBox/options#options-confirm)
|
||||
|
||||
confirmButton: 'Submit', // Text for the submit button
|
||||
cancelButton: 'Cancel', // Text for the cancel button
|
||||
confirm: null, // Function to execute when clicking the submit button. By default jBox will use the onclick or href attribute in that order if found
|
||||
cancel: null, // Function to execute when clicking the cancel button
|
||||
closeOnConfirm: true, // Close jBox when the user clicks the confirm button
|
||||
target: window,
|
||||
fixed: true,
|
||||
attach: '[data-confirm]',
|
||||
getContent: 'data-confirm',
|
||||
content: 'Do you really want to do this?',
|
||||
minWidth: 360,
|
||||
maxWidth: 500,
|
||||
blockScroll: true,
|
||||
closeOnEsc: true,
|
||||
closeOnClick: false,
|
||||
closeButton: false,
|
||||
overlay: true,
|
||||
animation: 'zoomIn',
|
||||
preventDefault: true,
|
||||
|
||||
|
||||
// Triggered when jBox is attached to the element
|
||||
|
||||
_onAttach: function (el)
|
||||
{
|
||||
// Extract the href or the onclick event if no submit event is passed
|
||||
if (!this.options.confirm) {
|
||||
var submit = el.attr('onclick') ? el.attr('onclick') : (
|
||||
el.attr('href') ? (
|
||||
el.attr('target') ? 'window.open("' + el.attr('href') + '", "' + el.attr('target') + '");' : 'window.location.href = "' + el.attr('href') + '";'
|
||||
) : '');
|
||||
el.prop('onclick', null).data('jBox-Confirm-submit', submit);
|
||||
}
|
||||
},
|
||||
|
||||
|
||||
// Triggered when jBox was created
|
||||
|
||||
_onCreated: function ()
|
||||
{
|
||||
// Add modal class to mimic jBox modal
|
||||
this.wrapper.addClass('jBox-Modal');
|
||||
|
||||
// Add a footer to the jBox container
|
||||
this.footer = jQuery('<div class="jBox-Confirm-footer"/>');
|
||||
|
||||
jQuery('<div class="jBox-Confirm-button jBox-Confirm-button-cancel"/>')
|
||||
.html(this.options.cancelButton)
|
||||
.click(function () {
|
||||
this.options.cancel && this.options.cancel(this.source);
|
||||
this.close();
|
||||
}.bind(this))
|
||||
.appendTo(this.footer);
|
||||
|
||||
this.submitButton = jQuery('<div class="jBox-Confirm-button jBox-Confirm-button-submit"/>')
|
||||
.html(this.options.confirmButton)
|
||||
.appendTo(this.footer);
|
||||
|
||||
this.footer.appendTo(this.container);
|
||||
},
|
||||
|
||||
|
||||
// Triggered when jBox is opened
|
||||
|
||||
_onOpen: function ()
|
||||
{
|
||||
// Set the new action for the submit button
|
||||
this.submitButton
|
||||
.off('click.jBox-Confirm' + this.id)
|
||||
.on('click.jBox-Confirm' + this.id, function () {
|
||||
this.options.confirm ? this.options.confirm(this.source) : eval(this.source.data('jBox-Confirm-submit'));
|
||||
this.options.closeOnConfirm && this.close();
|
||||
}.bind(this));
|
||||
}
|
||||
|
||||
});
|
||||
|
||||
};
|
||||
|
||||
//# sourceMappingURL=jBox.Confirm.js.map
|
||||
199
assets/js/vendor/jBox/plugins/jBox.Image.css
vendored
Normal file
199
assets/js/vendor/jBox/plugins/jBox.Image.css
vendored
Normal file
@@ -0,0 +1,199 @@
|
||||
.jBox-Image .jBox-container {
|
||||
background-color: transparent;
|
||||
}
|
||||
|
||||
.jBox-Image .jBox-content {
|
||||
padding: 0;
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
}
|
||||
|
||||
.jBox-image-container {
|
||||
background: center center no-repeat;
|
||||
position: absolute;
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
opacity: 0;
|
||||
}
|
||||
|
||||
.jBox-image-label-container {
|
||||
position: absolute;
|
||||
top: 100%;
|
||||
left: 0;
|
||||
right: 0;
|
||||
height: 40px;
|
||||
z-index: 100;
|
||||
}
|
||||
|
||||
.jBox-image-label {
|
||||
box-sizing: border-box;
|
||||
position: absolute;
|
||||
bottom: 0;
|
||||
width: 100%;
|
||||
text-align: center;
|
||||
left: 0;
|
||||
color: #fff;
|
||||
padding: 8px 40px;
|
||||
line-height: 24px;
|
||||
transition: opacity .36s;
|
||||
opacity: 0;
|
||||
z-index: 0;
|
||||
pointer-events: none;
|
||||
}
|
||||
|
||||
.jBox-image-label.expanded {
|
||||
background: #000;
|
||||
}
|
||||
|
||||
.jBox-image-label:not(.expanded) {
|
||||
text-overflow: ellipsis;
|
||||
white-space: nowrap;
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
.jBox-image-label.active {
|
||||
opacity: 1;
|
||||
pointer-events: all;
|
||||
}
|
||||
|
||||
.jBox-image-pointer-next,
|
||||
.jBox-image-pointer-prev {
|
||||
position: absolute;
|
||||
bottom: 0;
|
||||
width: 40px;
|
||||
height: 40px;
|
||||
cursor: pointer;
|
||||
opacity: .8;
|
||||
transition: opacity .2s;
|
||||
background: no-repeat center center url(data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9Ijc0LjcgMjI0IDE4LjcgMzIiPg0KPHBhdGggZmlsbD0iI2ZmZmZmZiIgZD0iTTkzLDIyNy40TDgwLjQsMjQwTDkzLDI1Mi42YzAuNCwwLjQsMC40LDEuMSwwLDEuNWwtMS42LDEuNmMtMC40LDAuNC0xLDAuNS0xLjUsMEw3NSwyNDAuN2MtMC40LTAuNC0wLjUtMSwwLTEuNWwxNC45LTE0LjljMC40LTAuNCwxLTAuNCwxLjUsMGwxLjYsMS42QzkzLjUsMjI2LjQsOTMuNCwyMjcsOTMsMjI3LjR6Ii8+DQo8L3N2Zz4=);
|
||||
background-size: 11px auto;
|
||||
user-select: none;
|
||||
z-index: 1;
|
||||
}
|
||||
|
||||
.jBox-image-pointer-next:hover,
|
||||
.jBox-image-pointer-prev:hover {
|
||||
opacity: 1;
|
||||
}
|
||||
|
||||
.jBox-image-pointer-next {
|
||||
right: 0;
|
||||
transform: scaleX(-1);
|
||||
}
|
||||
|
||||
.jBox-image-pointer-prev {
|
||||
left: 0;
|
||||
}
|
||||
|
||||
.jBox-image-counter-container {
|
||||
position: absolute;
|
||||
right: 40px;
|
||||
height: 40px;
|
||||
line-height: 40px;
|
||||
font-size: 13px;
|
||||
color: #fff;
|
||||
text-align: right;
|
||||
display: none;
|
||||
}
|
||||
|
||||
.jBox-image-has-counter .jBox-image-counter-container {
|
||||
display: block;
|
||||
}
|
||||
|
||||
.jBox-image-has-counter .jBox-image-label:not(.expanded) {
|
||||
padding-right: 80px;
|
||||
text-indent: 40px;
|
||||
}
|
||||
|
||||
.jBox-overlay.jBox-overlay-Image {
|
||||
background: #000;
|
||||
}
|
||||
|
||||
.jBox-image-not-found {
|
||||
background: #000;
|
||||
}
|
||||
|
||||
.jBox-image-not-found:before {
|
||||
content: '';
|
||||
box-sizing: border-box;
|
||||
display: block;
|
||||
width: 80px;
|
||||
height: 80px;
|
||||
margin-top: -40px;
|
||||
margin-left: -40px;
|
||||
position: absolute;
|
||||
top: 50%;
|
||||
left: 50%;
|
||||
border: 5px solid #222;
|
||||
border-radius: 50%;
|
||||
}
|
||||
|
||||
.jBox-image-not-found:after {
|
||||
content: '';
|
||||
display: block;
|
||||
box-sizing: content-box;
|
||||
z-index: auto;
|
||||
width: 6px;
|
||||
height: 74px;
|
||||
margin-top: -37px;
|
||||
margin-left: -3px;
|
||||
position: absolute;
|
||||
top: 50%;
|
||||
left: 50%;
|
||||
background: #222;
|
||||
transform: rotateZ(45deg);
|
||||
transform-origin: 50% 50% 0;
|
||||
}
|
||||
|
||||
.jBox-image-download-button-wrapper {
|
||||
position: absolute;
|
||||
top: -40px;
|
||||
right: 35px;
|
||||
height: 40px;
|
||||
display: flex;
|
||||
cursor: pointer;
|
||||
opacity: .8;
|
||||
transition: opacity .2s;
|
||||
}
|
||||
|
||||
.jBox-image-download-button-wrapper:hover {
|
||||
opacity: 1;
|
||||
}
|
||||
|
||||
.jBox-image-download-button-icon {
|
||||
width: 40px;
|
||||
height: 40px;
|
||||
background: center center no-repeat url(data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCA2NDAgNjQwIj48cGF0aCBmaWxsPSIjRkZGRkZGIiBkPSJNNDE2IDI1NnYtMTkyaC0xOTJ2MTkyaC0xNjBsMjU2IDI1NiAyNTYtMjU2aC0xNjB6TTAgNTc2aDY0MHY2NGgtNjQwdi02NHoiPjwvcGF0aD48L3N2Zz4=);
|
||||
background-size: 60%;
|
||||
}
|
||||
|
||||
.jBox-image-download-button-text {
|
||||
white-space: nowrap;
|
||||
line-height: 40px;
|
||||
padding: 0 10px 0 0;
|
||||
color: #fff;
|
||||
font-size: 14px;
|
||||
}
|
||||
|
||||
@keyframes jBoxImageLoading {
|
||||
to {
|
||||
transform: rotate(360deg);
|
||||
}
|
||||
}
|
||||
|
||||
.jBox-image-loading:before {
|
||||
content: '';
|
||||
position: absolute;
|
||||
top: 50%;
|
||||
left: 50%;
|
||||
width: 32px;
|
||||
height: 32px;
|
||||
margin-top: -16px;
|
||||
margin-left: -16px;
|
||||
border: 4px solid #333;
|
||||
border-bottom-color: #666;
|
||||
animation: jBoxImageLoading 1.2s linear infinite;
|
||||
border-radius: 50%;
|
||||
}
|
||||
|
||||
/*# sourceMappingURL=jBox.Image.css.map */
|
||||
320
assets/js/vendor/jBox/plugins/jBox.Image.js
vendored
Normal file
320
assets/js/vendor/jBox/plugins/jBox.Image.js
vendored
Normal file
@@ -0,0 +1,320 @@
|
||||
/**
|
||||
* jBox Image plugin: Adds a lightbox to your images
|
||||
*
|
||||
* Author: Stephan Wagner <stephanwagner.me@gmail.com> (https://stephanwagner.me)
|
||||
*
|
||||
* License: MIT (https://opensource.org/licenses/MIT)
|
||||
*
|
||||
* Requires: jBox (https://cdn.jsdelivr.net/gh/StephanWagner/jBox@latest/dist/jBox.min.js)
|
||||
*/
|
||||
|
||||
function jBoxImageWrapper(jBox, jQuery) {
|
||||
|
||||
new jBox.plugin('Image', {
|
||||
|
||||
|
||||
// Options (https://stephanwagner.me/jBox/options#options-image)
|
||||
|
||||
src: 'href', // The attribute where jBox gets the image source from, e.g. href="/path_to_image/image.jpg"
|
||||
gallery: 'data-jbox-image', // The attribute to set the galleries, e.g. data-jbox-image="gallery1"
|
||||
imageLabel: 'title', // The attribute where jBox gets the image label from, e.g. title="My label"
|
||||
imageFade: 360, // The fade duration for images in ms
|
||||
imageSize: 'contain', // How to display the images. Use CSS background-position values, e.g. 'cover', 'contain', 'auto', 'initial', '50% 50%'
|
||||
imageCounter: false, // Set to true to add an image counter, e.g. 4/20
|
||||
imageCounterSeparator: '/', // HTML to separate the current image number from all image numbers, e.g. '/' or ' of '
|
||||
downloadButton: false, // Adds a download button
|
||||
downloadButtonText: null, // Text for the download button
|
||||
downloadButtonUrl: null, // The attribute at the source element where to find the image to download, e.g. data-download="/path_to_image/image.jpg". If none provided, the currently active image will be downloaded
|
||||
mobileImageAttr: null, // The attribute to look for an mobile version of the image
|
||||
mobileImageBreakpoint: null, // The upper breakpoint to load the mobile image
|
||||
preloadFirstImage: false, // Preload the first image when page is loaded
|
||||
target: window,
|
||||
attach: '[data-jbox-image]',
|
||||
fixed: true,
|
||||
blockScroll: true,
|
||||
closeOnEsc: true,
|
||||
closeOnClick: 'button',
|
||||
closeButton: true,
|
||||
overlay: true,
|
||||
animation: 'zoomIn',
|
||||
preventDefault: true,
|
||||
width: '100%',
|
||||
height: '100%',
|
||||
adjustDistance: {
|
||||
top: 40,
|
||||
right: 5,
|
||||
bottom: 40,
|
||||
left: 5
|
||||
},
|
||||
|
||||
|
||||
// Triggered when jBox is initialized
|
||||
|
||||
_onInit: function ()
|
||||
{
|
||||
// Initial images and z-index
|
||||
this.images = this.currentImage = {};
|
||||
this.imageZIndex = 1;
|
||||
|
||||
this.initImage = function (item) {
|
||||
item = jQuery(item);
|
||||
|
||||
// Abort if the item was added to a gallery already
|
||||
if (item.data('jBox-image-gallery')) return;
|
||||
|
||||
// Get the image src
|
||||
var src = item.attr(this.options.src);
|
||||
|
||||
// Update responsive image src
|
||||
if (this.options.mobileImageAttr && this.options.mobileImageBreakpoint && item.attr(this.options.mobileImageAttr)) {
|
||||
if (jQuery(window).width() <= this.options.mobileImageBreakpoint) {
|
||||
src = item.attr(this.options.mobileImageAttr);
|
||||
}
|
||||
}
|
||||
|
||||
// Add item to a gallery
|
||||
var gallery = item.attr(this.options.gallery) || 'default';
|
||||
!this.images[gallery] && (this.images[gallery] = []);
|
||||
this.images[gallery].push({
|
||||
src: src,
|
||||
label: (item.attr(this.options.imageLabel) || ''),
|
||||
downloadUrl: this.options.downloadButtonUrl && item.attr(this.options.downloadButtonUrl) ? item.attr(this.options.downloadButtonUrl) : null
|
||||
});
|
||||
|
||||
// Remove the title attribute so it won't show the browsers tooltip
|
||||
this.options.imageLabel == 'title' && item.removeAttr('title');
|
||||
|
||||
// Store data in source element for easy access
|
||||
item.data('jBox-image-gallery', gallery);
|
||||
item.data('jBox-image-id', (this.images[gallery].length - 1));
|
||||
}.bind(this);
|
||||
|
||||
// Loop through images, sort and save in global variable
|
||||
this.attachedElements && this.attachedElements.length && jQuery.each(this.attachedElements, function (index, item) {
|
||||
this.initImage(item);
|
||||
}.bind(this));
|
||||
|
||||
// Helper to inject the image into content area
|
||||
var appendImage = function (gallery, id, show, instant) {
|
||||
// Abort if image was appended already
|
||||
if (jQuery('#jBox-image-' + gallery + '-' + id).length) {
|
||||
return;
|
||||
}
|
||||
|
||||
// Create image container
|
||||
var image = jQuery('<div/>', {
|
||||
id: 'jBox-image-' + gallery + '-' + id,
|
||||
'class': 'jBox-image-container' + (show ? ' jBox-image-' + gallery + '-current' : '')
|
||||
}).css({
|
||||
backgroundSize: this.options.imageSize,
|
||||
opacity: (instant ? 1 : 0),
|
||||
zIndex: (show ? this.imageZIndex++ : 0)
|
||||
}).appendTo(this.content);
|
||||
|
||||
// Create labels
|
||||
jQuery('<div/>', {
|
||||
id: 'jBox-image-label-' + gallery + '-' + id,
|
||||
'class': 'jBox-image-label' + (show ? ' active' : '')
|
||||
}).html(this.images[gallery][id].label).click(function () { jQuery(this).toggleClass('expanded'); }).appendTo(this.imageLabel);
|
||||
|
||||
// Show image
|
||||
show && image.animate({opacity: 1}, instant ? 0 : this.options.imageFade);
|
||||
|
||||
return image;
|
||||
}.bind(this);
|
||||
|
||||
// Function to download an image
|
||||
this.downloadImage = function (imageUrl) {
|
||||
var link = document.createElement('a');
|
||||
link.href = imageUrl;
|
||||
link.setAttribute('download', imageUrl.substring(imageUrl.lastIndexOf('/')+1));
|
||||
document.body.appendChild(link);
|
||||
link.click();
|
||||
};
|
||||
|
||||
// Helper to show new image label
|
||||
var showLabel = function (gallery, id) {
|
||||
jQuery('.jBox-image-label.active').removeClass('active expanded');
|
||||
jQuery('#jBox-image-label-' + gallery + '-' + id).addClass('active');
|
||||
};
|
||||
|
||||
// Helper to load image
|
||||
var loadImage = function (gallery, id, show, instant) {
|
||||
var imageContainer = appendImage(gallery, id, show, instant);
|
||||
imageContainer.addClass('jBox-image-loading');
|
||||
|
||||
jQuery('<img src="' + this.images[gallery][id].src + '" />').each(function () {
|
||||
var tmpImg = new Image();
|
||||
tmpImg.onload = function () {
|
||||
imageContainer.removeClass('jBox-image-loading');
|
||||
imageContainer.css({backgroundImage: 'url("' + this.images[gallery][id].src + '")'});
|
||||
}.bind(this);
|
||||
|
||||
tmpImg.onerror = function () {
|
||||
imageContainer.removeClass('jBox-image-loading');
|
||||
imageContainer.addClass('jBox-image-not-found');
|
||||
}.bind(this);
|
||||
|
||||
tmpImg.src = this.images[gallery][id].src;
|
||||
}.bind(this));
|
||||
}.bind(this);
|
||||
|
||||
// Show images when they are loaded or load them if not
|
||||
this.showImage = function (img) {
|
||||
// Get the gallery and the image id from the next or the previous image
|
||||
if (img != 'open') {
|
||||
var gallery = this.currentImage.gallery;
|
||||
var id = this.currentImage.id + (1 * (img == 'prev') ? -1 : 1);
|
||||
id = id > (this.images[gallery].length - 1) ? 0 : (id < 0 ? (this.images[gallery].length - 1) : id);
|
||||
|
||||
// Or get image data from source element
|
||||
} else {
|
||||
// Get gallery and image id from source element
|
||||
if (this.source) {
|
||||
var gallery = this.source.data('jBox-image-gallery');
|
||||
var id = this.source.data('jBox-image-id');
|
||||
|
||||
// Get gallery and image id attached elements
|
||||
} else if (this.attachedElements && this.attachedElements.length) {
|
||||
var gallery = jQuery(this.attachedElements[0]).data('jBox-image-gallery');
|
||||
var id = jQuery(this.attachedElements[0]).data('jBox-image-id');
|
||||
} else {
|
||||
return;
|
||||
}
|
||||
|
||||
// Remove or show the next and prev buttons
|
||||
jQuery('.jBox-image-pointer-prev, .jBox-image-pointer-next').css({display: (this.images[gallery].length > 1 ? 'block' : 'none')});
|
||||
}
|
||||
|
||||
// If there is a current image already shown, hide it
|
||||
if (jQuery('.jBox-image-' + gallery + '-current').length) {
|
||||
jQuery('.jBox-image-' + gallery + '-current').removeClass('jBox-image-' + gallery + '-current').animate({opacity: 0}, (img == 'open') ? 0 : this.options.imageFade);
|
||||
}
|
||||
|
||||
// Set new current image
|
||||
this.currentImage = {gallery: gallery, id: id};
|
||||
|
||||
// Show image if it already exists
|
||||
if (jQuery('#jBox-image-' + gallery + '-' + id).length) {
|
||||
jQuery('#jBox-image-' + gallery + '-' + id).addClass('jBox-image-' + gallery + '-current').css({zIndex: this.imageZIndex++, opacity: 0}).animate({opacity: 1}, (img == 'open') ? 0 : this.options.imageFade);
|
||||
|
||||
// Load image
|
||||
} else {
|
||||
loadImage(gallery, id, true, (img === 'open'));
|
||||
}
|
||||
|
||||
// Show label
|
||||
showLabel(gallery, id);
|
||||
|
||||
// Update the image counter numbers
|
||||
if (this.imageCounter) {
|
||||
if (this.images[gallery].length > 1) {
|
||||
this.wrapper.addClass('jBox-image-has-counter');
|
||||
this.imageCounter.find('.jBox-image-counter-all').html(this.images[gallery].length);
|
||||
this.imageCounter.find('.jBox-image-counter-current').html(id + 1);
|
||||
} else {
|
||||
this.wrapper.removeClass('jBox-image-has-counter');
|
||||
}
|
||||
}
|
||||
|
||||
// Preload next image
|
||||
if (this.images[gallery].length - 1) {
|
||||
var next_id = id + 1;
|
||||
next_id = next_id > (this.images[gallery].length - 1) ? 0 : (next_id < 0 ? (this.images[gallery].length - 1) : next_id);
|
||||
|
||||
if (!jQuery('#jBox-image-' + gallery + '-' + next_id).length) {
|
||||
loadImage(gallery, next_id, false, false);
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
// Preload image
|
||||
if (this.options.preloadFirstImage) {
|
||||
jQuery(window).on('load', function() {
|
||||
this.showImage('open');
|
||||
}.bind(this));
|
||||
}
|
||||
},
|
||||
|
||||
|
||||
// Triggered when jBox attaches a new element
|
||||
|
||||
_onAttach: function (item) {
|
||||
this.initImage && this.initImage(item);
|
||||
},
|
||||
|
||||
|
||||
// Triggered when jBox was created
|
||||
|
||||
_onCreated: function ()
|
||||
{
|
||||
// Append image label containers
|
||||
this.imageLabel = jQuery('<div/>', {'class': 'jBox-image-label-container'}).appendTo(this.wrapper);
|
||||
this.imageLabel.append(jQuery('<div/>', {'class': 'jBox-image-pointer-prev', click: function () { this.showImage('prev'); }.bind(this)})).append(jQuery('<div/>', {'class': 'jBox-image-pointer-next', click: function () { this.showImage('next'); }.bind(this)}));
|
||||
|
||||
// Append the download button
|
||||
if (this.options.downloadButton) {
|
||||
this.downloadButton = jQuery('<div/>', {'class': 'jBox-image-download-button-wrapper'})
|
||||
.appendTo(this.wrapper)
|
||||
.append(
|
||||
this.options.downloadButtonText ? jQuery('<div/>', {'class': 'jBox-image-download-button-text'}).html(this.options.downloadButtonText) : null
|
||||
)
|
||||
.append(
|
||||
jQuery('<div/>', {'class': 'jBox-image-download-button-icon'})
|
||||
).on('click touchdown', function () {
|
||||
if (this.images[this.currentImage.gallery][this.currentImage.id].downloadUrl) {
|
||||
var currentImageUrl = this.images[this.currentImage.gallery][this.currentImage.id].downloadUrl;
|
||||
} else {
|
||||
var currentImage = this.wrapper.find('.jBox-image-' + this.currentImage.gallery + '-current');
|
||||
var currentImageStyle = currentImage[0].style.backgroundImage;
|
||||
var currentImageUrl = currentImageStyle.slice(4, -1).replace(/["']/g, '');
|
||||
}
|
||||
this.downloadImage(currentImageUrl);
|
||||
}.bind(this));
|
||||
}
|
||||
|
||||
// Creating the image counter containers
|
||||
if (this.options.imageCounter) {
|
||||
this.imageCounter = jQuery('<div/>', {'class': 'jBox-image-counter-container'}).appendTo(this.wrapper);
|
||||
this.imageCounter.append(jQuery('<span/>', {'class': 'jBox-image-counter-current'})).append(jQuery('<span/>').html(this.options.imageCounterSeparator)).append(jQuery('<span/>', {'class': 'jBox-image-counter-all'}));
|
||||
}
|
||||
},
|
||||
|
||||
|
||||
// Triggered when jBox opens
|
||||
|
||||
_onOpen: function ()
|
||||
{
|
||||
// Add key events
|
||||
jQuery(document).on('keyup.jBox-Image-' + this.id, function (ev) {
|
||||
(ev.keyCode == 37) && this.showImage('prev');
|
||||
(ev.keyCode == 39) && this.showImage('next');
|
||||
}.bind(this));
|
||||
|
||||
// Load the image from the attached element
|
||||
this.showImage('open');
|
||||
},
|
||||
|
||||
|
||||
// Triggered when jBox closes
|
||||
|
||||
_onClose: function ()
|
||||
{
|
||||
// Remove key events
|
||||
jQuery(document).off('keyup.jBox-Image-' + this.id);
|
||||
},
|
||||
|
||||
|
||||
// Triggered when jBox finished closing
|
||||
|
||||
_onCloseComplete: function ()
|
||||
{
|
||||
// Hide all image containers
|
||||
this.wrapper.find('.jBox-image-container').css('opacity', 0);
|
||||
}
|
||||
|
||||
});
|
||||
|
||||
};
|
||||
|
||||
//# sourceMappingURL=jBox.Image.js.map
|
||||
122
assets/js/vendor/jBox/plugins/jBox.Notice.css
vendored
Normal file
122
assets/js/vendor/jBox/plugins/jBox.Notice.css
vendored
Normal file
@@ -0,0 +1,122 @@
|
||||
.jBox-Notice {
|
||||
transition: margin .2s;
|
||||
}
|
||||
|
||||
.jBox-Notice .jBox-container {
|
||||
border-radius: 4px;
|
||||
box-shadow: inset 1px 1px 0 0 rgba(255, 255, 255, 0.25), inset -1px -1px 0 0 rgba(0, 0, 0, 0.1);
|
||||
}
|
||||
|
||||
.jBox-Notice .jBox-content {
|
||||
border-radius: 4px;
|
||||
padding: 12px 20px;
|
||||
}
|
||||
|
||||
@media (max-width: 768px) {
|
||||
.jBox-Notice .jBox-content {
|
||||
padding: 10px 15px;
|
||||
}
|
||||
}
|
||||
|
||||
@media (max-width: 500px) {
|
||||
.jBox-Notice .jBox-content {
|
||||
padding: 8px 10px;
|
||||
}
|
||||
}
|
||||
|
||||
.jBox-Notice.jBox-hasTitle .jBox-content {
|
||||
padding-top: 5px;
|
||||
}
|
||||
|
||||
@media (max-width: 500px) {
|
||||
.jBox-Notice.jBox-hasTitle .jBox-content {
|
||||
padding-top: 0;
|
||||
}
|
||||
}
|
||||
|
||||
.jBox-Notice.jBox-hasTitle .jBox-title {
|
||||
padding: 12px 20px 0;
|
||||
font-weight: bold;
|
||||
}
|
||||
|
||||
@media (max-width: 768px) {
|
||||
.jBox-Notice.jBox-hasTitle .jBox-title {
|
||||
padding: 10px 15px 0;
|
||||
}
|
||||
}
|
||||
|
||||
@media (max-width: 500px) {
|
||||
.jBox-Notice.jBox-hasTitle .jBox-title {
|
||||
padding: 8px 10px 0;
|
||||
}
|
||||
}
|
||||
|
||||
.jBox-Notice.jBox-closeButton-title .jBox-title {
|
||||
padding-right: 55px;
|
||||
}
|
||||
|
||||
.jBox-Notice.jBox-closeButton-title.jBox-hasTitle .jBox-closeButton {
|
||||
width: 40px;
|
||||
}
|
||||
|
||||
.jBox-Notice.jBox-Notice-black .jBox-container {
|
||||
color: #fff;
|
||||
background: #000;
|
||||
}
|
||||
|
||||
.jBox-Notice.jBox-Notice-black.jBox-closeButton-title.jBox-hasTitle .jBox-closeButton path,
|
||||
.jBox-Notice.jBox-Notice-black.jBox-closeButton-title.jBox-hasTitle .jBox-closeButton:hover path {
|
||||
fill: #fff;
|
||||
}
|
||||
|
||||
.jBox-Notice.jBox-Notice-gray .jBox-container {
|
||||
color: #222;
|
||||
background: #f6f6f6;
|
||||
}
|
||||
|
||||
.jBox-Notice.jBox-Notice-gray.jBox-closeButton-title.jBox-hasTitle .jBox-closeButton path,
|
||||
.jBox-Notice.jBox-Notice-gray.jBox-closeButton-title.jBox-hasTitle .jBox-closeButton:hover path {
|
||||
fill: #222;
|
||||
}
|
||||
|
||||
.jBox-Notice.jBox-Notice-red .jBox-container {
|
||||
color: #fff;
|
||||
background: #d00;
|
||||
}
|
||||
|
||||
.jBox-Notice.jBox-Notice-red.jBox-closeButton-title.jBox-hasTitle .jBox-closeButton path,
|
||||
.jBox-Notice.jBox-Notice-red.jBox-closeButton-title.jBox-hasTitle .jBox-closeButton:hover path {
|
||||
fill: #fff;
|
||||
}
|
||||
|
||||
.jBox-Notice.jBox-Notice-green .jBox-container {
|
||||
color: #fff;
|
||||
background: #5d0;
|
||||
}
|
||||
|
||||
.jBox-Notice.jBox-Notice-green.jBox-closeButton-title.jBox-hasTitle .jBox-closeButton path,
|
||||
.jBox-Notice.jBox-Notice-green.jBox-closeButton-title.jBox-hasTitle .jBox-closeButton:hover path {
|
||||
fill: #fff;
|
||||
}
|
||||
|
||||
.jBox-Notice.jBox-Notice-blue .jBox-container {
|
||||
color: #fff;
|
||||
background: #49d;
|
||||
}
|
||||
|
||||
.jBox-Notice.jBox-Notice-blue.jBox-closeButton-title.jBox-hasTitle .jBox-closeButton path,
|
||||
.jBox-Notice.jBox-Notice-blue.jBox-closeButton-title.jBox-hasTitle .jBox-closeButton:hover path {
|
||||
fill: #fff;
|
||||
}
|
||||
|
||||
.jBox-Notice.jBox-Notice-yellow .jBox-container {
|
||||
color: #000;
|
||||
background: #fd0;
|
||||
}
|
||||
|
||||
.jBox-Notice.jBox-Notice-yellow.jBox-closeButton-title.jBox-hasTitle .jBox-closeButton path,
|
||||
.jBox-Notice.jBox-Notice-yellow.jBox-closeButton-title.jBox-hasTitle .jBox-closeButton:hover path {
|
||||
fill: #fff;
|
||||
}
|
||||
|
||||
/*# sourceMappingURL=jBox.Notice.css.map */
|
||||
173
assets/js/vendor/jBox/plugins/jBox.Notice.js
vendored
Normal file
173
assets/js/vendor/jBox/plugins/jBox.Notice.js
vendored
Normal file
@@ -0,0 +1,173 @@
|
||||
/**
|
||||
* jBox Notice plugin: Opens a popup notice
|
||||
*
|
||||
* Author: Stephan Wagner <stephanwagner.me@gmail.com> (https://stephanwagner.me)
|
||||
*
|
||||
* License: MIT (https://opensource.org/licenses/MIT)
|
||||
*
|
||||
* Requires: jBox (https://cdn.jsdelivr.net/gh/StephanWagner/jBox@latest/dist/jBox.min.js)
|
||||
*/
|
||||
|
||||
function jBoxNoticeWrapper(jBox, jQuery) {
|
||||
|
||||
new jBox.plugin('Notice', {
|
||||
|
||||
|
||||
// Options (https://stephanwagner.me/jBox/options#options-notice)
|
||||
|
||||
color: null, // Add a color to your notices, use 'gray' (default), 'black', 'red', 'green', 'blue' or 'yellow'
|
||||
stack: true, // Set to false to disable notice-stacking
|
||||
stackSpacing: 10, // Spacing between notices when they stack
|
||||
autoClose: 6000, // Time in ms after which the notice will disappear
|
||||
attributes: { // Defines where the notice will pop up
|
||||
x: 'right', // 'left' or 'right'
|
||||
y: 'top' // 'top' or 'bottom'
|
||||
},
|
||||
position: { // Defines the distance to the viewport boundary
|
||||
x: 15,
|
||||
y: 15
|
||||
},
|
||||
responsivePositions: { // Responsive positions
|
||||
500: { // The key defines the maximum width of the viewport, the values will replace the default position options
|
||||
x: 5, // Start with the lowest viewport
|
||||
y: 5
|
||||
},
|
||||
768: {
|
||||
x: 10,
|
||||
y: 10
|
||||
}
|
||||
},
|
||||
target: window,
|
||||
fixed: true,
|
||||
animation: 'zoomIn',
|
||||
closeOnClick: 'box',
|
||||
zIndex: 12000,
|
||||
|
||||
|
||||
// Triggered when notice is initialized
|
||||
|
||||
_onInit: function ()
|
||||
{
|
||||
// Cache position values
|
||||
this.defaultNoticePosition = jQuery.extend({}, this.options.position);
|
||||
|
||||
// Type Notice has its own adjust position function
|
||||
this._adjustNoticePositon = function () {
|
||||
var win = jQuery(window);
|
||||
var windowDimensions = {
|
||||
x: win.width(),
|
||||
y: win.height()
|
||||
};
|
||||
|
||||
// Reset default position
|
||||
this.options.position = jQuery.extend({}, this.defaultNoticePosition);
|
||||
|
||||
// Adjust depending on viewport
|
||||
jQuery.each(this.options.responsivePositions, function (viewport, position) {
|
||||
if (windowDimensions.x <= viewport) {
|
||||
this.options.position = position;
|
||||
return false;
|
||||
}
|
||||
}.bind(this));
|
||||
|
||||
// Set new padding options
|
||||
this.options.adjustDistance = {
|
||||
top: this.options.position.y,
|
||||
right: this.options.position.x,
|
||||
bottom: this.options.position.y,
|
||||
left: this.options.position.x
|
||||
};
|
||||
};
|
||||
|
||||
// If jBox grabs an element as content, crab a clone instead
|
||||
this.options.content instanceof jQuery && (this.options.content = this.options.content.clone().attr('id', ''));
|
||||
|
||||
// Adjust paddings when window resizes
|
||||
jQuery(window).on('resize.responsivejBoxNotice-' + this.id, function (ev) { if (this.isOpen) { this._adjustNoticePositon(); } }.bind(this));
|
||||
|
||||
this.open();
|
||||
},
|
||||
|
||||
|
||||
// Triggered when notice was created
|
||||
|
||||
_onCreated: function ()
|
||||
{
|
||||
// Add color class
|
||||
this.wrapper.addClass('jBox-Notice-color jBox-Notice-' + (this.options.color || 'gray'));
|
||||
|
||||
// Store position in jBox wrapper
|
||||
this.wrapper.data('jBox-Notice-position', this.options.attributes.x + '-' + this.options.attributes.y);
|
||||
},
|
||||
|
||||
|
||||
// Triggered when notice opens
|
||||
|
||||
_onOpen: function ()
|
||||
{
|
||||
// Bail if we're stacking
|
||||
if (this.options.stack) {
|
||||
return;
|
||||
}
|
||||
|
||||
// Adjust position when opening
|
||||
this._adjustNoticePositon();
|
||||
|
||||
// Loop through notices at same window corner destroy them
|
||||
jQuery.each(jQuery('.jBox-Notice'), function (index, el)
|
||||
{
|
||||
el = jQuery(el);
|
||||
|
||||
// Abort if the element is this notice or when it's not at the same position
|
||||
if (el.attr('id') == this.id || el.data('jBox-Notice-position') != this.options.attributes.x + '-' + this.options.attributes.y) {
|
||||
return;
|
||||
}
|
||||
|
||||
// Remove notice when we don't wont to stack them
|
||||
if (!this.options.stack) {
|
||||
el.data('jBox').close({ignoreDelay: true});
|
||||
return;
|
||||
}
|
||||
}.bind(this));
|
||||
},
|
||||
|
||||
// Triggered when resizing window etc.
|
||||
|
||||
_onPosition: function ()
|
||||
{
|
||||
var stacks = {};
|
||||
jQuery.each(jQuery('.jBox-Notice'), function (index, el)
|
||||
{
|
||||
el = jQuery(el);
|
||||
var pos = el.data('jBox-Notice-position');
|
||||
if (!stacks[pos]) {
|
||||
stacks[pos] = [];
|
||||
}
|
||||
stacks[pos].push(el);
|
||||
});
|
||||
for (var pos in stacks) {
|
||||
var position = pos.split('-');
|
||||
var direction = position[1];
|
||||
stacks[pos].reverse();
|
||||
var margin = 0;
|
||||
for (var i in stacks[pos]) {
|
||||
el = stacks[pos][i];
|
||||
el.css('margin-' + direction, margin);
|
||||
margin += el.outerHeight() + this.options.stackSpacing;
|
||||
}
|
||||
}
|
||||
},
|
||||
|
||||
// Remove notice from DOM and reposition other notices when closing finishes
|
||||
|
||||
_onCloseComplete: function ()
|
||||
{
|
||||
this.destroy();
|
||||
this.options._onPosition.bind(this).call();
|
||||
}
|
||||
|
||||
});
|
||||
|
||||
};
|
||||
|
||||
//# sourceMappingURL=jBox.Notice.js.map
|
||||
49
assets/js/vendor/jBox/themes/jBox.NoticeFancy.css
vendored
Normal file
49
assets/js/vendor/jBox/themes/jBox.NoticeFancy.css
vendored
Normal file
@@ -0,0 +1,49 @@
|
||||
.jBox-NoticeFancy .jBox-content,
|
||||
.jBox-NoticeFancy .jBox-title {
|
||||
padding-left: 25px;
|
||||
}
|
||||
|
||||
.jBox-NoticeFancy.jBox-Notice-color .jBox-container {
|
||||
color: #fff;
|
||||
background: #000;
|
||||
}
|
||||
|
||||
.jBox-NoticeFancy.jBox-Notice-color .jBox-container:after {
|
||||
content: '';
|
||||
position: absolute;
|
||||
top: 0;
|
||||
left: 0;
|
||||
bottom: 0;
|
||||
width: 8px;
|
||||
border-radius: 4px 0 0 4px;
|
||||
background-image: linear-gradient(45deg, rgba(255, 255, 255, 0.4) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.4) 50%, rgba(255, 255, 255, 0.4) 75%, transparent 75%, transparent);
|
||||
background-size: 14px 14px;
|
||||
}
|
||||
|
||||
.jBox-NoticeFancy.jBox-Notice-black .jBox-container:after,
|
||||
.jBox-NoticeFancy.jBox-Notice-gray .jBox-container:after {
|
||||
background-color: #888;
|
||||
}
|
||||
|
||||
.jBox-NoticeFancy.jBox-Notice-red .jBox-container:after {
|
||||
background-color: #e00;
|
||||
}
|
||||
|
||||
.jBox-NoticeFancy.jBox-Notice-green .jBox-container:after {
|
||||
background-color: #6c0;
|
||||
}
|
||||
|
||||
.jBox-NoticeFancy.jBox-Notice-blue .jBox-container:after {
|
||||
background-color: #49d;
|
||||
}
|
||||
|
||||
.jBox-NoticeFancy.jBox-Notice-yellow .jBox-container:after {
|
||||
background-color: #fb0;
|
||||
}
|
||||
|
||||
.jBox-NoticeFancy .jBox-countdown {
|
||||
left: 8px;
|
||||
border-radius: 0 4px 0 0;
|
||||
}
|
||||
|
||||
/*# sourceMappingURL=jBox.NoticeFancy.css.map */
|
||||
39
assets/js/vendor/jBox/themes/jBox.TooltipBorder.css
vendored
Normal file
39
assets/js/vendor/jBox/themes/jBox.TooltipBorder.css
vendored
Normal file
@@ -0,0 +1,39 @@
|
||||
.jBox-TooltipBorder .jBox-container,
|
||||
.jBox-TooltipBorder .jBox-pointer:after {
|
||||
border: 2px solid #49d;
|
||||
}
|
||||
|
||||
.jBox-TooltipBorder .jBox-pointer:after {
|
||||
width: 22px;
|
||||
height: 22px;
|
||||
}
|
||||
|
||||
.jBox-TooltipBorder .jBox-pointer-top,
|
||||
.jBox-TooltipBorder .jBox-pointer-bottom {
|
||||
width: 34px;
|
||||
height: 13px;
|
||||
}
|
||||
|
||||
.jBox-TooltipBorder .jBox-pointer-top:after,
|
||||
.jBox-TooltipBorder .jBox-pointer-bottom:after {
|
||||
left: 6px;
|
||||
}
|
||||
|
||||
.jBox-TooltipBorder .jBox-pointer-left,
|
||||
.jBox-TooltipBorder .jBox-pointer-right {
|
||||
width: 13px;
|
||||
height: 34px;
|
||||
}
|
||||
|
||||
.jBox-TooltipBorder .jBox-pointer-left:after,
|
||||
.jBox-TooltipBorder .jBox-pointer-right:after {
|
||||
top: 6px;
|
||||
}
|
||||
|
||||
.jBox-TooltipBorder.jBox-closeButton-box:before {
|
||||
width: 28px;
|
||||
height: 28px;
|
||||
background: #49d;
|
||||
}
|
||||
|
||||
/*# sourceMappingURL=jBox.TooltipBorder.css.map */
|
||||
32
assets/js/vendor/jBox/themes/jBox.TooltipBorderThick.css
vendored
Normal file
32
assets/js/vendor/jBox/themes/jBox.TooltipBorderThick.css
vendored
Normal file
@@ -0,0 +1,32 @@
|
||||
.jBox-TooltipBorderThick .jBox-container {
|
||||
box-shadow: none;
|
||||
border-radius: 8px;
|
||||
border: 4px solid #ccc;
|
||||
}
|
||||
|
||||
.jBox-TooltipBorderThick .jBox-pointer:after {
|
||||
box-shadow: none;
|
||||
border: 4px solid #ccc;
|
||||
width: 24px;
|
||||
height: 24px;
|
||||
}
|
||||
|
||||
.jBox-TooltipBorderThick .jBox-pointer-top,
|
||||
.jBox-TooltipBorderThick .jBox-pointer-bottom {
|
||||
width: 38px;
|
||||
height: 13px;
|
||||
}
|
||||
|
||||
.jBox-TooltipBorderThick .jBox-pointer-left,
|
||||
.jBox-TooltipBorderThick .jBox-pointer-right {
|
||||
width: 13px;
|
||||
height: 38px;
|
||||
}
|
||||
|
||||
.jBox-TooltipBorderThick.jBox-closeButton-box:before {
|
||||
width: 32px;
|
||||
height: 32px;
|
||||
background: #ccc;
|
||||
}
|
||||
|
||||
/*# sourceMappingURL=jBox.TooltipBorderThick.css.map */
|
||||
32
assets/js/vendor/jBox/themes/jBox.TooltipDark.css
vendored
Normal file
32
assets/js/vendor/jBox/themes/jBox.TooltipDark.css
vendored
Normal file
@@ -0,0 +1,32 @@
|
||||
.jBox-TooltipDark .jBox-container {
|
||||
border-radius: 4px;
|
||||
background: #000;
|
||||
color: #fff;
|
||||
box-shadow: 0 0 6px rgba(0, 0, 0, 0.4);
|
||||
}
|
||||
|
||||
.jBox-TooltipDark .jBox-pointer:after {
|
||||
background: #000;
|
||||
}
|
||||
|
||||
.jBox-TooltipDark .jBox-closeButton {
|
||||
background: #000;
|
||||
}
|
||||
|
||||
.jBox-TooltipDark.jBox-closeButton-box:before {
|
||||
box-shadow: 0 0 6px rgba(0, 0, 0, 0.4);
|
||||
}
|
||||
|
||||
.jBox-TooltipDark.jBox-closeButton-box .jBox-closeButton path {
|
||||
fill: #ddd;
|
||||
}
|
||||
|
||||
.jBox-TooltipDark.jBox-closeButton-box .jBox-closeButton:hover path {
|
||||
fill: #fff;
|
||||
}
|
||||
|
||||
.jBox-TooltipDark.jBox-closeButton-box .jBox-closeButton:active path {
|
||||
fill: #bbb;
|
||||
}
|
||||
|
||||
/*# sourceMappingURL=jBox.TooltipDark.css.map */
|
||||
54
assets/js/vendor/jBox/themes/jBox.TooltipError.css
vendored
Normal file
54
assets/js/vendor/jBox/themes/jBox.TooltipError.css
vendored
Normal file
@@ -0,0 +1,54 @@
|
||||
.jBox-TooltipError {
|
||||
pointer-events: none;
|
||||
}
|
||||
|
||||
.jBox-TooltipError .jBox-container {
|
||||
border-radius: 2px;
|
||||
background: #d00;
|
||||
color: #fff;
|
||||
font-weight: bold;
|
||||
font-size: 13px;
|
||||
}
|
||||
|
||||
.jBox-TooltipError .jBox-content {
|
||||
padding: 0 10px;
|
||||
line-height: 28px;
|
||||
}
|
||||
|
||||
.jBox-TooltipError .jBox-pointer:after {
|
||||
background: #d00;
|
||||
width: 20px;
|
||||
height: 20px;
|
||||
}
|
||||
|
||||
.jBox-TooltipError .jBox-pointer-top, .jBox-TooltipError .jBox-pointer-bottom {
|
||||
width: 22px;
|
||||
height: 8px;
|
||||
}
|
||||
|
||||
.jBox-TooltipError .jBox-pointer-right, .jBox-TooltipError .jBox-pointer-left {
|
||||
width: 8px;
|
||||
height: 22px;
|
||||
}
|
||||
|
||||
.jBox-TooltipError .jBox-pointer-top:after {
|
||||
left: 1px;
|
||||
top: 6px;
|
||||
}
|
||||
|
||||
.jBox-TooltipError .jBox-pointer-right:after {
|
||||
top: 1px;
|
||||
right: 6px;
|
||||
}
|
||||
|
||||
.jBox-TooltipError .jBox-pointer-bottom:after {
|
||||
left: 1px;
|
||||
bottom: 6px;
|
||||
}
|
||||
|
||||
.jBox-TooltipError .jBox-pointer-left:after {
|
||||
top: 1px;
|
||||
left: 6px;
|
||||
}
|
||||
|
||||
/*# sourceMappingURL=jBox.TooltipError.css.map */
|
||||
49
assets/js/vendor/jBox/themes/jBox.TooltipSmall.css
vendored
Normal file
49
assets/js/vendor/jBox/themes/jBox.TooltipSmall.css
vendored
Normal file
@@ -0,0 +1,49 @@
|
||||
.jBox-TooltipSmall {
|
||||
pointer-events: none;
|
||||
}
|
||||
|
||||
.jBox-TooltipSmall .jBox-container {
|
||||
border-radius: 2px;
|
||||
}
|
||||
|
||||
.jBox-TooltipSmall .jBox-content {
|
||||
padding: 0 10px;
|
||||
line-height: 28px;
|
||||
}
|
||||
|
||||
.jBox-TooltipSmall .jBox-pointer:after {
|
||||
width: 20px;
|
||||
height: 20px;
|
||||
}
|
||||
|
||||
.jBox-TooltipSmall .jBox-pointer-top, .jBox-TooltipSmall .jBox-pointer-bottom {
|
||||
width: 22px;
|
||||
height: 8px;
|
||||
}
|
||||
|
||||
.jBox-TooltipSmall .jBox-pointer-right, .jBox-TooltipSmall .jBox-pointer-left {
|
||||
width: 8px;
|
||||
height: 22px;
|
||||
}
|
||||
|
||||
.jBox-TooltipSmall .jBox-pointer-top:after {
|
||||
left: 1px;
|
||||
top: 6px;
|
||||
}
|
||||
|
||||
.jBox-TooltipSmall .jBox-pointer-right:after {
|
||||
top: 1px;
|
||||
right: 6px;
|
||||
}
|
||||
|
||||
.jBox-TooltipSmall .jBox-pointer-bottom:after {
|
||||
left: 1px;
|
||||
bottom: 6px;
|
||||
}
|
||||
|
||||
.jBox-TooltipSmall .jBox-pointer-left:after {
|
||||
top: 1px;
|
||||
left: 6px;
|
||||
}
|
||||
|
||||
/*# sourceMappingURL=jBox.TooltipSmall.css.map */
|
||||
53
assets/js/vendor/jBox/themes/jBox.TooltipSmallGray.css
vendored
Normal file
53
assets/js/vendor/jBox/themes/jBox.TooltipSmallGray.css
vendored
Normal file
@@ -0,0 +1,53 @@
|
||||
.jBox-TooltipSmallGray {
|
||||
pointer-events: none;
|
||||
}
|
||||
|
||||
.jBox-TooltipSmallGray .jBox-container {
|
||||
font-size: 13px;
|
||||
line-height: 24px;
|
||||
border-radius: 12px;
|
||||
background-image: linear-gradient(to bottom, #fafafa, #f2f2f2);
|
||||
}
|
||||
|
||||
.jBox-TooltipSmallGray .jBox-content {
|
||||
padding: 0 10px;
|
||||
}
|
||||
|
||||
.jBox-TooltipSmallGray .jBox-pointer:after {
|
||||
width: 20px;
|
||||
height: 20px;
|
||||
}
|
||||
|
||||
.jBox-TooltipSmallGray .jBox-pointer-top, .jBox-TooltipSmallGray .jBox-pointer-bottom {
|
||||
width: 22px;
|
||||
height: 8px;
|
||||
}
|
||||
|
||||
.jBox-TooltipSmallGray .jBox-pointer-left, .jBox-TooltipSmallGray .jBox-pointer-right {
|
||||
width: 8px;
|
||||
height: 22px;
|
||||
}
|
||||
|
||||
.jBox-TooltipSmallGray .jBox-pointer-top:after {
|
||||
background: #fafafa;
|
||||
left: 1px;
|
||||
top: 6px;
|
||||
}
|
||||
|
||||
.jBox-TooltipSmallGray .jBox-pointer-right:after {
|
||||
top: 1px;
|
||||
right: 6px;
|
||||
}
|
||||
|
||||
.jBox-TooltipSmallGray .jBox-pointer-bottom:after {
|
||||
background: #f2f2f2;
|
||||
left: 1px;
|
||||
bottom: 6px;
|
||||
}
|
||||
|
||||
.jBox-TooltipSmallGray .jBox-pointer-left:after {
|
||||
top: 1px;
|
||||
left: 6px;
|
||||
}
|
||||
|
||||
/*# sourceMappingURL=jBox.TooltipSmallGray.css.map */
|
||||
812
assets/js/vendor/jquery.scrollbar/demo/advanced.html
vendored
Normal file
812
assets/js/vendor/jquery.scrollbar/demo/advanced.html
vendored
Normal file
@@ -0,0 +1,812 @@
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<title>jQuery Advanced Scrollbar Demo</title>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
|
||||
<link rel="stylesheet" href="../includes/style.css" />
|
||||
<link rel="stylesheet" href="../includes/prettify/prettify.css" />
|
||||
<link rel="stylesheet" href="../jquery.scrollbar.css" />
|
||||
|
||||
<script src="../includes/prettify/prettify.js"></script>
|
||||
<script src="../includes/jquery.js"></script>
|
||||
<script src="../jquery.scrollbar.js"></script>
|
||||
<script>
|
||||
jQuery(function($){
|
||||
|
||||
function getAlignedText(text){
|
||||
text = text.split('\n');
|
||||
while(text.length > 0 && $.trim(text[0]) == ''){
|
||||
text.shift();
|
||||
}
|
||||
var tabs = (text[0] || '').replace(/^(\s+).+$/, '$1');
|
||||
for(var i=0; i<text.length; i++){
|
||||
text[i] = text[i].replace(tabs, '');
|
||||
}
|
||||
if(text.length > 0 && text[text.length - 1].match(/^\s*$/)){
|
||||
text.pop();
|
||||
}
|
||||
return text.join('\n');
|
||||
}
|
||||
|
||||
$('.container').each(function(){
|
||||
|
||||
var content = $(this).find('.content');
|
||||
var controls = $(this).find('.controls');
|
||||
|
||||
$('<pre></pre>').addClass('prettyprint linenums lang-html').text(getAlignedText(content.find('.demo').html())).appendTo(content.find('.html'));
|
||||
$('<pre></pre>').addClass('prettyprint linenums lang-css').text(getAlignedText($('#css-common').html()) + "\n" + getAlignedText(content.find('style').html())).appendTo(content.find('.css'));
|
||||
$('<pre></pre>').addClass('prettyprint linenums lang-js').text(getAlignedText(content.find('script').html())).appendTo(content.find('.js'));
|
||||
|
||||
controls.on('click', 'span', function(){
|
||||
content.find('.' + $(this).removeClass('active').attr('class')).show().siblings('div').hide();
|
||||
$(this).addClass('active').siblings('span').removeClass('active');
|
||||
});
|
||||
controls.find('.demo').click();
|
||||
});
|
||||
|
||||
$('.container').on('click', '.add-content', function(){
|
||||
$('#lorem-ipsum').clone().removeAttr('id').appendTo($(this).closest('.container').find('.scroll-content'));
|
||||
return false;
|
||||
});
|
||||
$('.container').on('click', '.remove-content', function(){
|
||||
$(this).closest('.container').find('.scroll-content').find('p').not('.permanent').last().remove();
|
||||
return false;
|
||||
});
|
||||
|
||||
window.prettyPrint && prettyPrint();
|
||||
$('.wrapper').scrollbar();
|
||||
});
|
||||
</script>
|
||||
|
||||
<script type="text/javascript">
|
||||
if(window.location.href.match(/gromo.github.io/i)){
|
||||
(function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
|
||||
(i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
|
||||
m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
|
||||
})(window,document,'script','//www.google-analytics.com/analytics.js','ga');
|
||||
|
||||
ga('create', 'UA-52878040-1', 'auto');
|
||||
ga('send', 'pageview');
|
||||
}
|
||||
</script>
|
||||
|
||||
<style type="text/css">
|
||||
.content .demo {
|
||||
border: none;
|
||||
}
|
||||
.content .demo > div {
|
||||
height: 400px;
|
||||
max-height: none;
|
||||
overflow: auto;
|
||||
width: 600px;
|
||||
}
|
||||
.scroll-content img {
|
||||
display: block;
|
||||
}
|
||||
|
||||
label.theme {
|
||||
cursor: pointer;
|
||||
margin-right: 14px;
|
||||
}
|
||||
label.theme input {
|
||||
margin-right: 2px;
|
||||
}
|
||||
</style>
|
||||
|
||||
<style type="text/css" id="css-common">
|
||||
/*************** SCROLLBAR BASE CSS ***************/
|
||||
|
||||
.scroll-wrapper {
|
||||
overflow: hidden !important;
|
||||
padding: 0 !important;
|
||||
position: relative;
|
||||
}
|
||||
|
||||
.scroll-wrapper > .scroll-content {
|
||||
border: none !important;
|
||||
box-sizing: content-box !important;
|
||||
height: auto;
|
||||
left: 0;
|
||||
margin: 0;
|
||||
max-height: none;
|
||||
max-width: none !important;
|
||||
overflow: scroll !important;
|
||||
padding: 0;
|
||||
position: relative !important;
|
||||
top: 0;
|
||||
width: auto !important;
|
||||
}
|
||||
|
||||
.scroll-wrapper > .scroll-content::-webkit-scrollbar {
|
||||
height: 0;
|
||||
width: 0;
|
||||
}
|
||||
|
||||
.scroll-element {
|
||||
display: none;
|
||||
}
|
||||
.scroll-element, .scroll-element div {
|
||||
box-sizing: content-box;
|
||||
}
|
||||
|
||||
.scroll-element.scroll-x.scroll-scrollx_visible,
|
||||
.scroll-element.scroll-y.scroll-scrolly_visible {
|
||||
display: block;
|
||||
}
|
||||
|
||||
.scroll-element .scroll-bar,
|
||||
.scroll-element .scroll-arrow {
|
||||
cursor: default;
|
||||
}
|
||||
|
||||
.scroll-textarea {
|
||||
border: 1px solid #cccccc;
|
||||
border-top-color: #999999;
|
||||
}
|
||||
.scroll-textarea > .scroll-content {
|
||||
overflow: hidden !important;
|
||||
}
|
||||
.scroll-textarea > .scroll-content > textarea {
|
||||
border: none !important;
|
||||
box-sizing: border-box;
|
||||
height: 100% !important;
|
||||
margin: 0;
|
||||
max-height: none !important;
|
||||
max-width: none !important;
|
||||
overflow: scroll !important;
|
||||
outline: none;
|
||||
padding: 2px;
|
||||
position: relative !important;
|
||||
top: 0;
|
||||
width: 100% !important;
|
||||
}
|
||||
.scroll-textarea > .scroll-content > textarea::-webkit-scrollbar {
|
||||
height: 0;
|
||||
width: 0;
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
</style>
|
||||
</head>
|
||||
<body>
|
||||
<div class="wrapper scrollbar-dynamic">
|
||||
<div class="page-content">
|
||||
|
||||
<h1>Advanced Scrollbars</h1>
|
||||
|
||||
<a href="basic.html">Basic Scrollbars Demo</a><br/>
|
||||
<a href="angular.html">jQuery Scrollbars as Angular.JS directive</a><br/>
|
||||
<a href="../">« Back to home</a>
|
||||
|
||||
<div class="container">
|
||||
<h2>Microsoft Windows Vista</h2>
|
||||
<div class="controls">
|
||||
<span class="demo">DEMO</span>
|
||||
<span class="html">HTML</span>
|
||||
<span class="css">CSS</span>
|
||||
<span class="js">JS</span>
|
||||
<button onclick="jQuery('.scrollbar-vista').scrollbar('destroy');">Destroy</button>
|
||||
</div>
|
||||
<div class="content">
|
||||
<style type="text/css">
|
||||
|
||||
/******************* WINDOWS VISTA SCROLLBAR *******************/
|
||||
|
||||
.scrollbar-vista > .scroll-content.scroll-scrolly_visible { left: -17px; margin-left: 17px; }
|
||||
.scrollbar-vista > .scroll-content.scroll-scrollx_visible { top: -17px; margin-top: 17px; }
|
||||
|
||||
|
||||
.scrollbar-vista > .scroll-element {
|
||||
background-color: #fcfdff;
|
||||
}
|
||||
|
||||
.scrollbar-vista > .scroll-element,
|
||||
.scrollbar-vista > .scroll-element div
|
||||
{
|
||||
border: none;
|
||||
margin: 0;
|
||||
overflow: hidden;
|
||||
padding: 0;
|
||||
position: absolute;
|
||||
z-index: 10;
|
||||
}
|
||||
|
||||
.scrollbar-vista > .scroll-element .scroll-element_outer,
|
||||
.scrollbar-vista > .scroll-element .scroll-element_size,
|
||||
.scrollbar-vista > .scroll-element .scroll-element_inner-wrapper,
|
||||
.scrollbar-vista > .scroll-element .scroll-element_inner,
|
||||
.scrollbar-vista > .scroll-element .scroll-bar,
|
||||
.scrollbar-vista > .scroll-element .scroll-bar div
|
||||
{
|
||||
height: 100%;
|
||||
left: 0;
|
||||
top: 0;
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.scrollbar-vista > .scroll-element .scroll-element_outer,
|
||||
.scrollbar-vista > .scroll-element .scroll-element_size,
|
||||
.scrollbar-vista > .scroll-element .scroll-element_inner-wrapper,
|
||||
.scrollbar-vista > .scroll-element .scroll-bar_body
|
||||
{
|
||||
background: none !important;
|
||||
}
|
||||
|
||||
|
||||
.scrollbar-vista > .scroll-element.scroll-x {
|
||||
border-top: solid 1px #fcfdff;
|
||||
bottom: 0;
|
||||
height: 16px;
|
||||
left: 0;
|
||||
min-width: 100%;
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.scrollbar-vista > .scroll-element.scroll-y {
|
||||
border-left: solid 1px #fcfdff;
|
||||
height: 100%;
|
||||
min-height: 100%;
|
||||
right: 0;
|
||||
top: 0;
|
||||
width: 16px;
|
||||
}
|
||||
|
||||
.scrollbar-vista > .scroll-element.scroll-x div {
|
||||
background-image: url('skins/vista-x.png');
|
||||
background-repeat: repeat-x;
|
||||
}
|
||||
|
||||
.scrollbar-vista > .scroll-element.scroll-y div {
|
||||
background-image: url('skins/vista-y.png');
|
||||
background-repeat: repeat-y;
|
||||
}
|
||||
|
||||
.scrollbar-vista > .scroll-element.scroll-x .scroll-arrow {}
|
||||
|
||||
.scrollbar-vista > .scroll-element.scroll-x .scroll-bar { min-width: 16px; background-position: 0px -34px; background-repeat: no-repeat; }
|
||||
.scrollbar-vista > .scroll-element.scroll-x .scroll-bar_body { left: 2px; }
|
||||
.scrollbar-vista > .scroll-element.scroll-x .scroll-bar_body-inner { left: -4px; background-position: 0px -17px; }
|
||||
.scrollbar-vista > .scroll-element.scroll-x .scroll-bar_center { left: 50%; margin-left: -6px; width: 12px; background-position: 24px -34px; }
|
||||
.scrollbar-vista > .scroll-element.scroll-x .scroll-bar_bottom { left: auto; right: 0; width: 2px; background-position: 37px -34px; }
|
||||
|
||||
|
||||
.scrollbar-vista > .scroll-element.scroll-y .scroll-bar { min-height: 16px; background-position: -34px 0px; background-repeat: no-repeat; }
|
||||
.scrollbar-vista > .scroll-element.scroll-y .scroll-bar_body { top: 2px; }
|
||||
.scrollbar-vista > .scroll-element.scroll-y .scroll-bar_body-inner { top: -4px; background-position: -17px 0px; }
|
||||
.scrollbar-vista > .scroll-element.scroll-y .scroll-bar_center { top: 50%; margin-top: -6px; height: 12px; background-position: -34px 24px; }
|
||||
.scrollbar-vista > .scroll-element.scroll-y .scroll-bar_bottom { top: auto; bottom: 0; height: 2px; background-position: -34px 37px; }
|
||||
|
||||
|
||||
|
||||
/* SCROLL ARROWS */
|
||||
|
||||
.scrollbar-vista > .scroll-element .scroll-arrow { display: none; }
|
||||
.scrollbar-vista > .scroll-element.scroll-element_arrows_visible .scroll-arrow { display: block; z-index: 12; }
|
||||
|
||||
|
||||
.scrollbar-vista > .scroll-element.scroll-x.scroll-element_arrows_visible .scroll-arrow_less { height: 100%; width: 17px; background-position: 0px -51px;}
|
||||
.scrollbar-vista > .scroll-element.scroll-x.scroll-element_arrows_visible .scroll-arrow_more { height: 100%; left: auto; right: 0; width: 17px; background-position: 17px -51px;}
|
||||
|
||||
.scrollbar-vista > .scroll-element.scroll-x.scroll-element_arrows_visible .scroll-element_outer { left: 17px; }
|
||||
.scrollbar-vista > .scroll-element.scroll-x.scroll-element_arrows_visible .scroll-element_inner { left: -34px; }
|
||||
.scrollbar-vista > .scroll-element.scroll-x.scroll-element_arrows_visible .scroll-element_size { left: -34px; }
|
||||
|
||||
|
||||
.scrollbar-vista > .scroll-element.scroll-y.scroll-element_arrows_visible .scroll-arrow_less { width: 100%; height: 17px; background-position: -51px 0px;}
|
||||
.scrollbar-vista > .scroll-element.scroll-y.scroll-element_arrows_visible .scroll-arrow_more { width: 100%; top: auto; bottom: 0; height: 17px; background-position: -51px 17px;}
|
||||
|
||||
.scrollbar-vista > .scroll-element.scroll-y.scroll-element_arrows_visible .scroll-element_outer { top: 17px; }
|
||||
.scrollbar-vista > .scroll-element.scroll-y.scroll-element_arrows_visible .scroll-element_inner { top: -34px; }
|
||||
.scrollbar-vista > .scroll-element.scroll-y.scroll-element_arrows_visible .scroll-element_size { top: -34px; }
|
||||
|
||||
|
||||
/* PROCEED OFFSET IF ANOTHER SCROLL VISIBLE */
|
||||
|
||||
.scrollbar-vista > .scroll-element.scroll-x.scroll-scrolly_visible .scroll-element_size { left: -17px; }
|
||||
.scrollbar-vista > .scroll-element.scroll-y.scroll-scrollx_visible .scroll-element_size { top: -17px; }
|
||||
|
||||
.scrollbar-vista > .scroll-element.scroll-x.scroll-scrolly_visible .scroll-element_inner { left: -17px; }
|
||||
.scrollbar-vista > .scroll-element.scroll-y.scroll-scrollx_visible .scroll-element_inner { top: -17px; }
|
||||
|
||||
|
||||
/* PROCEED OFFSET IF ARROWS & ANOTHER SCROLL */
|
||||
|
||||
.scrollbar-vista > .scroll-element.scroll-x.scroll-element_arrows_visible.scroll-scrolly_visible .scroll-arrow_more { right: 17px;}
|
||||
.scrollbar-vista > .scroll-element.scroll-x.scroll-element_arrows_visible.scroll-scrolly_visible .scroll-element_inner { left: -51px;}
|
||||
.scrollbar-vista > .scroll-element.scroll-x.scroll-element_arrows_visible.scroll-scrolly_visible .scroll-element_size { left: -51px;}
|
||||
|
||||
|
||||
.scrollbar-vista > .scroll-element.scroll-y.scroll-element_arrows_visible.scroll-scrollx_visible .scroll-arrow_more { bottom: 17px;}
|
||||
.scrollbar-vista > .scroll-element.scroll-y.scroll-element_arrows_visible.scroll-scrollx_visible .scroll-element_inner { top: -51px;}
|
||||
.scrollbar-vista > .scroll-element.scroll-y.scroll-element_arrows_visible.scroll-scrollx_visible .scroll-element_size { top: -51px;}
|
||||
</style>
|
||||
<script type="text/javascript">
|
||||
jQuery(document).ready(function(){
|
||||
jQuery('.scrollbar-vista').scrollbar({
|
||||
"showArrows": true,
|
||||
"scrollx": "advanced",
|
||||
"scrolly": "advanced"
|
||||
});
|
||||
});
|
||||
</script>
|
||||
<div class="demo">
|
||||
<div class="scrollbar-vista">
|
||||
<img src="../includes/tarzan.jpg" height="2100" width="2800">
|
||||
</div>
|
||||
</div>
|
||||
<div class="html"></div>
|
||||
<div class="css"></div>
|
||||
<div class="js"></div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="container">
|
||||
<h2>External</h2>
|
||||
<p>External scrollbars can be located in any place inside or outside of scrollable container</p>
|
||||
<div class="controls">
|
||||
<span class="demo">DEMO</span>
|
||||
<span class="html">HTML</span>
|
||||
<span class="css">CSS</span>
|
||||
<span class="js">JS</span>
|
||||
</div>
|
||||
<div class="content">
|
||||
<style type="text/css">
|
||||
|
||||
.scrollbar-external_wrapper {
|
||||
height: 450px !important;
|
||||
position: relative;
|
||||
width: auto !important;
|
||||
}
|
||||
.scrollbar-external {
|
||||
height: 400px;
|
||||
overflow: auto;
|
||||
width: 600px;
|
||||
}
|
||||
|
||||
/******************* EXTERNAL SCROLLBAR *******************/
|
||||
|
||||
.external-scroll_x,
|
||||
.external-scroll_y {
|
||||
border: solid 1px #9999fc;
|
||||
cursor: pointer;
|
||||
display: none;
|
||||
position: absolute;
|
||||
}
|
||||
|
||||
.external-scroll_x.scroll-scrollx_visible {
|
||||
display: block;
|
||||
height: 10px;
|
||||
left: 0;
|
||||
top: 410px;
|
||||
width: 200px;
|
||||
}
|
||||
|
||||
.external-scroll_y.scroll-scrolly_visible {
|
||||
display: block;
|
||||
height: 200px;
|
||||
left: 610px;
|
||||
top: 0;
|
||||
width: 10px;
|
||||
}
|
||||
|
||||
.external-scroll_x div,
|
||||
.external-scroll_y div
|
||||
{
|
||||
height: 100%;
|
||||
left: 0;
|
||||
top: 0;
|
||||
position: absolute;
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.external-scroll_x .scroll-bar,
|
||||
.external-scroll_y .scroll-bar {
|
||||
background: #9999fc;
|
||||
z-index: 12;
|
||||
}
|
||||
|
||||
.external-scroll_x .scroll-bar {
|
||||
width: 100px;
|
||||
}
|
||||
.external-scroll_y .scroll-bar {
|
||||
height: 100px;
|
||||
}
|
||||
</style>
|
||||
<script type="text/javascript">
|
||||
jQuery(document).ready(function(){
|
||||
jQuery('.scrollbar-external').scrollbar({
|
||||
"autoScrollSize": false,
|
||||
"scrollx": $('.external-scroll_x'),
|
||||
"scrolly": $('.external-scroll_y')
|
||||
});
|
||||
});
|
||||
</script>
|
||||
<div class="demo">
|
||||
<div class="scrollbar-external_wrapper">
|
||||
<div class="scrollbar-external">
|
||||
<img src="../includes/tarzan.jpg">
|
||||
</div>
|
||||
|
||||
<div class="external-scroll_x">
|
||||
<div class="scroll-element_outer">
|
||||
<div class="scroll-element_size"></div>
|
||||
<div class="scroll-element_track"></div>
|
||||
<div class="scroll-bar"></div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="external-scroll_y">
|
||||
<div class="scroll-element_outer">
|
||||
<div class="scroll-element_size"></div>
|
||||
<div class="scroll-element_track"></div>
|
||||
<div class="scroll-bar"></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="html"></div>
|
||||
<div class="css"></div>
|
||||
<div class="js"></div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="container">
|
||||
<h2>Page Map</h2>
|
||||
<p>Page Map is resizable scrollbar that combinates both horizontal and vertical scrollbars in one element</p>
|
||||
<div class="controls">
|
||||
<span class="demo">DEMO</span>
|
||||
<span class="html">HTML</span>
|
||||
<span class="css">CSS</span>
|
||||
<span class="js">JS</span>
|
||||
<button onclick="$('.scrollbar-map img').css({'height':'2100px','width':'2800px'});">Resize</button>
|
||||
<button onclick="$('.scrollbar-map img').css({'height':'600px','width':'800px'});">Original</button>
|
||||
</div>
|
||||
<div class="content">
|
||||
<style type="text/css">
|
||||
|
||||
/******************* PAGE THUMBNAIL SCROLLBAR *******************/
|
||||
|
||||
.scrollbar-map > .scroll-element_outer {
|
||||
display: none;
|
||||
height: 100px;
|
||||
position: absolute;
|
||||
right: 10px;
|
||||
top: 10px;
|
||||
width: 100px;
|
||||
}
|
||||
.scrollbar-map > .scroll-element_outer .scroll-element_size,
|
||||
.scrollbar-map > .scroll-element_outer .scroll-element_track {
|
||||
background-color: #999;
|
||||
background-color: rgba(153, 153, 153, 0.4);
|
||||
height: 100%;
|
||||
position: absolute;
|
||||
right: 0;
|
||||
top: 0;
|
||||
width: 100%;
|
||||
}
|
||||
.scrollbar-map > .scroll-element_outer .scroll-bar {
|
||||
background-color: #CCC;
|
||||
background-color: rgba(204, 204, 204, 0.5);
|
||||
height: 100%;
|
||||
position: absolute;
|
||||
left: 0;
|
||||
top: 0;
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.scrollbar-map > .scroll-element_outer.scroll-scrollx_visible,
|
||||
.scrollbar-map > .scroll-element_outer.scroll-scrolly_visible {
|
||||
display: block;
|
||||
}
|
||||
|
||||
|
||||
</style>
|
||||
<script type="text/javascript">
|
||||
/**
|
||||
* Get inscribed area size
|
||||
*
|
||||
* @param int oW outer width
|
||||
* @param int oH outer height
|
||||
* @param int iW inner width
|
||||
* @param int iH inner height
|
||||
* @param bool R resize if smaller
|
||||
*/
|
||||
function getInscribedArea(oW, oH, iW, iH, R){
|
||||
if(!R && iW < oW && iH < oH){
|
||||
return {
|
||||
"h": iH,
|
||||
"w": iW
|
||||
};
|
||||
}
|
||||
if((oW / oH) > (iW / iH)){
|
||||
return {
|
||||
"h": oH,
|
||||
"w": Math.round(oH * iW / iH)
|
||||
}
|
||||
} else {
|
||||
return {
|
||||
"h": Math.round(oW * iH / iW),
|
||||
"w": oW
|
||||
};
|
||||
}
|
||||
}
|
||||
|
||||
jQuery(document).ready(function(){
|
||||
jQuery('.scrollbar-map').scrollbar({
|
||||
"onInit": function(){
|
||||
this.container.find('.scroll-element_outer').appendTo(this.wrapper);
|
||||
},
|
||||
"onUpdate": function(container){
|
||||
var s = getInscribedArea(140, 140, this.scrollx.size, this.scrolly.size);
|
||||
this.scrolly.scroll.height(s.h);
|
||||
this.scrollx.scroll.width(s.w);
|
||||
},
|
||||
"scrollx": $('.scrollbar-map .scroll-element_outer'),
|
||||
"scrolly": $('.scrollbar-map .scroll-element_outer'),
|
||||
"stepScrolling": false
|
||||
});
|
||||
});
|
||||
</script>
|
||||
<div class="demo">
|
||||
<div class="scrollbar-map">
|
||||
<div class="scroll-element_outer">
|
||||
<div class="scroll-element_size">
|
||||
<div class="scroll-element_track"></div>
|
||||
<div class="scroll-bar"></div>
|
||||
</div>
|
||||
</div>
|
||||
<img src="../includes/tarzan.jpg" height="900" width="1200">
|
||||
</div>
|
||||
</div>
|
||||
<div class="html"></div>
|
||||
<div class="css"></div>
|
||||
<div class="js"></div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="container">
|
||||
<h2>Janos Scrollbar</h2>
|
||||
<p>Janos Scrollbar uses design from
|
||||
<a href="http://users.atw.hu/nokiss/formstyle.html" target="_blank">Janos custom form elements</a></p>
|
||||
<div class="controls">
|
||||
<span class="demo">DEMO</span>
|
||||
<span class="html">HTML</span>
|
||||
<span class="css">CSS</span>
|
||||
<span class="js">JS</span>
|
||||
</div>
|
||||
<div>
|
||||
<label class="theme"><input type="radio" name="janos-theme" value="theme-blue" checked="checked">Blue</label>
|
||||
<label class="theme"><input type="radio" name="janos-theme" value="theme-woods">Woods</label>
|
||||
<label class="theme"><input type="radio" name="janos-theme" value="theme-paint4">Paint 4</label>
|
||||
<label class="theme"><input type="radio" name="janos-theme" value="theme-palace3">Palace 3</label>
|
||||
<label class="theme"><input type="radio" name="janos-theme" value="theme-dark">Dark</label>
|
||||
<label class="theme"><input type="radio" name="janos-theme" value="theme-sprites">Sprites</label>
|
||||
<script type="text/javascript">
|
||||
jQuery(function($){
|
||||
var currentTheme = 'theme-blue';
|
||||
$('input:radio[name="janos-theme"]').on('change', function(){
|
||||
$('.scrollbar-janos').removeClass(currentTheme);
|
||||
currentTheme = $(this).val();
|
||||
$('.scrollbar-janos').addClass(currentTheme);
|
||||
}).eq(0).prop('checked', true).change();
|
||||
});
|
||||
</script>
|
||||
</div>
|
||||
<div class="content">
|
||||
<style type="text/css">
|
||||
|
||||
.scrollbar-janos.theme-blue > .scroll-element,
|
||||
.scrollbar-janos.theme-blue > .scroll-element .scroll-bar,
|
||||
.scrollbar-janos.theme-blue > .scroll-element .scroll-element_corner,
|
||||
.scrollbar-janos.theme-blue > .scroll-element .scroll-element_track
|
||||
{ background-color: #66CCEE; }
|
||||
|
||||
.scrollbar-janos.theme-woods > .scroll-element,
|
||||
.scrollbar-janos.theme-woods > .scroll-element .scroll-bar,
|
||||
.scrollbar-janos.theme-woods > .scroll-element .scroll-element_corner,
|
||||
.scrollbar-janos.theme-woods > .scroll-element .scroll-element_track
|
||||
{ background-color: #5F7C7F; }
|
||||
|
||||
.scrollbar-janos.theme-paint4 > .scroll-element,
|
||||
.scrollbar-janos.theme-paint4 > .scroll-element .scroll-bar,
|
||||
.scrollbar-janos.theme-paint4 > .scroll-element .scroll-element_corner,
|
||||
.scrollbar-janos.theme-paint4 > .scroll-element .scroll-element_track
|
||||
{ background-color: #5566AA; }
|
||||
|
||||
.scrollbar-janos.theme-palace3 > .scroll-element,
|
||||
.scrollbar-janos.theme-palace3 > .scroll-element .scroll-bar,
|
||||
.scrollbar-janos.theme-palace3 > .scroll-element .scroll-element_corner,
|
||||
.scrollbar-janos.theme-palace3 > .scroll-element .scroll-element_track
|
||||
{ background-color: #028B54; }
|
||||
|
||||
.scrollbar-janos.theme-dark > .scroll-element,
|
||||
.scrollbar-janos.theme-dark > .scroll-element .scroll-bar,
|
||||
.scrollbar-janos.theme-dark > .scroll-element .scroll-element_corner,
|
||||
.scrollbar-janos.theme-dark > .scroll-element .scroll-element_track
|
||||
{ background-color: #999999; }
|
||||
|
||||
.scrollbar-janos.theme-sprites > .scroll-element,
|
||||
.scrollbar-janos.theme-sprites > .scroll-element .scroll-bar,
|
||||
.scrollbar-janos.theme-sprites > .scroll-element .scroll-element_corner,
|
||||
.scrollbar-janos.theme-sprites > .scroll-element .scroll-element_track
|
||||
{ background-color: #BBBBBB; }
|
||||
|
||||
|
||||
/******************* JANOS SCROLLBAR *******************/
|
||||
|
||||
.scrollbar-janos > .scroll-element,
|
||||
.scrollbar-janos > .scroll-element div
|
||||
{
|
||||
border: none;
|
||||
margin: 0;
|
||||
overflow: hidden;
|
||||
padding: 0;
|
||||
position: absolute;
|
||||
z-index: 10;
|
||||
}
|
||||
|
||||
.scrollbar-janos > .scroll-element div {
|
||||
background-color: transparent;
|
||||
display: block;
|
||||
height: 100%;
|
||||
left: 0;
|
||||
top: 0;
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.scrollbar-janos > .scroll-element.scroll-x {
|
||||
border-top: 1px solid #AAAAAA;
|
||||
bottom: 0;
|
||||
height: 16px;
|
||||
left: 0;
|
||||
min-width: 100%;
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.scrollbar-janos > .scroll-element.scroll-y {
|
||||
border-left: 1px solid #AAAAAA;
|
||||
height: 100%;
|
||||
min-height: 100%;
|
||||
right: 0;
|
||||
top: 0;
|
||||
width: 16px;
|
||||
}
|
||||
|
||||
.scrollbar-janos > .scroll-element .scroll-element_corner {
|
||||
display: none;
|
||||
}
|
||||
|
||||
.scrollbar-janos > .scroll-element.scroll-x,
|
||||
.scrollbar-janos > .scroll-element.scroll-x .scroll-bar {
|
||||
background-image: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAoAAAAPCAYAAADd/14OAAAAS0lEQVR42qzQywkAIAxEQQPpvwn7E/EDESXREt7BHPY0sEvE3XMCpyJiwIW+mBR2Civa+BVGhOuLQt/TaHWncFBoFC4KN4WHwCvAAHI/GzHvcCTCAAAAAElFTkSuQmCC);
|
||||
background-repeat: repeat-x;
|
||||
}
|
||||
.scrollbar-janos > .scroll-element.scroll-x .scroll-bar {
|
||||
box-shadow: 0 1px 2px, 0 -1px 1px rgba(255, 255, 255, 0.8);
|
||||
}
|
||||
.scrollbar-janos > .scroll-element.scroll-y,
|
||||
.scrollbar-janos > .scroll-element.scroll-y .scroll-bar {
|
||||
background-image: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAA8AAAAKCAYAAABrGwT5AAAAAXNSR0IArs4c6QAAAEtJREFUKM/ty00Kg0AAQ+Ev3v8W3k/8qWipzLiYFrqR7osPsknyUkrpk2xYsWDCWGsdMCaZ3/0DO5544eg08pVWJJ/tkp+HW/4L+QSzjxQbWJrRJQAAAABJRU5ErkJggg==);
|
||||
background-repeat: repeat-y;
|
||||
}
|
||||
.scrollbar-janos > .scroll-element.scroll-y .scroll-bar {
|
||||
box-shadow: 0 1px 2px, 0 -1px 1px rgba(255, 255, 255, 0.8);
|
||||
}
|
||||
|
||||
.scrollbar-janos > .scroll-element.scroll-x .scroll-element_track {
|
||||
background-image: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAoAAAAQCAYAAAAvf+5AAAAAXklEQVR42mJkYGBIZcAO/iPR/1iAxG8CisAYpPAnsQp/EGE1XoUoiklS+J0BPwArJmQiA7FWoyj8hUXiH7oArnBE9ghc4S9irf5NrMI/xFr9hwgTwQr/4TMJBgACDABrOConte5OAgAAAABJRU5ErkJggg==);
|
||||
background-repeat: repeat-x;
|
||||
}
|
||||
.scrollbar-janos > .scroll-element.scroll-y .scroll-element_track {
|
||||
background-image: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAKCAYAAAC9vt6cAAAAAXNSR0IArs4c6QAAAFNJREFUKM/FzksKgDAMBNDX3NT7X8BaC25clBKw4sKBgYTMJwUbGurAfWLFcbPhREcPBEpC05ztqXkUPyKS5LJqHj9YaU11sdgarw+LKF8D/B9wAWL/DzbaLOVxAAAAAElFTkSuQmCC);
|
||||
background-repeat: repeat-y;
|
||||
}
|
||||
.scrollbar-janos > .scroll-element.scroll-x .scroll-bar .scroll-bar_body {
|
||||
background-image: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAUAAAAHCAYAAADAp4fuAAAAMklEQVR42mL4DwRnz579zwAEMDYTiLN7924GGACxmRiwAEoFV6xYwSAvLw/mwNgAAQYAEz0X3c1VmrwAAAAASUVORK5CYII=);
|
||||
}
|
||||
.scrollbar-janos > .scroll-element.scroll-y .scroll-bar .scroll-bar_body {
|
||||
background-image: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAcAAAAFCAYAAACJmvbYAAAAAXNSR0IArs4c6QAAAChJREFUCNdj/P///38GLGDFihUMLOfOnWPYvXs3hqS8vDwDXsBItrEA28oV4/a4edAAAAAASUVORK5CYII=);
|
||||
}
|
||||
.scrollbar-janos > .scroll-element.scroll-x .scroll-arrow_less {
|
||||
background-image: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAoAAAAKCAYAAACNMs+9AAAAj0lEQVR42mJgwA4EgVgbRP///58BhJmwKFIwNTW1AEpGANlSMEEWNFOkNm/ebObj42MHZLMDsSi6QpApmqdOnbICspWxuQWkUPTYsWOOlpaWMFOwAiYGIgFI4WsrK6v9ZmZmq4Dsu4RMfHD69OkTjIyMK7Zs2bIbyP9JjC0gj3kCg6cZFJawcGQgNsABAgwAc40zrttfic8AAAAASUVORK5CYII=);
|
||||
box-shadow: 0 1px 2px, 0 -1px 1px rgba(255, 255, 255, 0.8);
|
||||
}
|
||||
.scrollbar-janos > .scroll-element.scroll-x .scroll-arrow_more {
|
||||
background-image: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAoAAAAKCAYAAACNMs+9AAAAh0lEQVR42mL4//8/AwgDgSAQa0NpDMCExJYCaogwNTW1ALIVMFQimegApJcB8fzNmzcnopvOhMUWdh8fH1d007EphAHlU6dOhR07dswRyBbFpxAFsOCRu2tmZnbs9OnT14Hs19gU/tyyZcshX1/fU0D2MyB+j+5rbSDdDPSAJ6HgwRvgAAEGAC2sRKFV1v+TAAAAAElFTkSuQmCC);
|
||||
}
|
||||
.scrollbar-janos > .scroll-element.scroll-y .scroll-arrow_less {
|
||||
background-image: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAoAAAAKCAYAAACNMs+9AAAAjklEQVR42mJgwASiUIwCGNH4CseOHXMEMaysrPYDqQdYDGIQNDU19fz///98EAaxQWLYTNQGKogA0spQ/l1GRsYVQPoqiMMEs3Lz5s1mSIpAQBkqpgAzEWSlxalTp8KAbHY05/w0MzNbdfr06ROMWKxEB2AnMEIdLIUtSKDgNRA/YwSaxkAMYGIgEgAEGADQpyzNaQf+BAAAAABJRU5ErkJggg==);
|
||||
box-shadow: 0 1px 2px rgba(0, 0, 0, 0.7);
|
||||
}
|
||||
.scrollbar-janos > .scroll-element.scroll-y .scroll-arrow_more {
|
||||
background-image: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAoAAAAKCAYAAACNMs+9AAAAg0lEQVR42mL8//8/AzGAiYFIwAjEgkAsBcSiONS8BuJnLCBFQOsjgLQyDoV3GRkZV4CsfmZmZnYMSP/EougnVO4ZSOH706dPX9+yZcshdFUgMZAcSA0jkrg2mhPAVgLpq+i+RnYC3EpkXyMDhWPHjjmCGFZWVvuB1AN8QSaKLagAAgwAkYkwicybOCoAAAAASUVORK5CYII=);
|
||||
}
|
||||
|
||||
.scrollbar-janos > .scroll-element .scroll-arrow,
|
||||
.scrollbar-janos > .scroll-element .scroll-bar_body {
|
||||
background-position: center;
|
||||
background-repeat: no-repeat;
|
||||
}
|
||||
|
||||
.scrollbar-janos > .scroll-content.scroll-scrolly_visible { left: -17px; margin-left: 17px; }
|
||||
.scrollbar-janos > .scroll-content.scroll-scrollx_visible { top: -17px; margin-top: 17px; }
|
||||
|
||||
/* scrollbar arrows */
|
||||
|
||||
.scrollbar-janos > .scroll-element .scroll-arrow { display: none; }
|
||||
.scrollbar-janos > .scroll-element.scroll-element_arrows_visible .scroll-arrow { display: block; z-index: 12; }
|
||||
|
||||
.scrollbar-janos > .scroll-element.scroll-x.scroll-element_arrows_visible .scroll-arrow_less { height: 100%; width: 16px;}
|
||||
.scrollbar-janos > .scroll-element.scroll-x.scroll-element_arrows_visible .scroll-arrow_more { height: 100%; left: auto; right: 0; width: 16px;}
|
||||
|
||||
.scrollbar-janos > .scroll-element.scroll-x.scroll-element_arrows_visible .scroll-element_outer { left: 16px; }
|
||||
.scrollbar-janos > .scroll-element.scroll-x.scroll-element_arrows_visible .scroll-element_track { left: -32px; }
|
||||
.scrollbar-janos > .scroll-element.scroll-x.scroll-element_arrows_visible .scroll-element_size { left: -33px; }
|
||||
|
||||
.scrollbar-janos > .scroll-element.scroll-y.scroll-element_arrows_visible .scroll-arrow_less { width: 100%; height: 16px;}
|
||||
.scrollbar-janos > .scroll-element.scroll-y.scroll-element_arrows_visible .scroll-arrow_more { width: 100%; top: auto; bottom: 0; height: 16px;}
|
||||
|
||||
.scrollbar-janos > .scroll-element.scroll-y.scroll-element_arrows_visible .scroll-element_outer { top: 16px; }
|
||||
.scrollbar-janos > .scroll-element.scroll-y.scroll-element_arrows_visible .scroll-element_track { top: -32px; }
|
||||
.scrollbar-janos > .scroll-element.scroll-y.scroll-element_arrows_visible .scroll-element_size { top: -33px; }
|
||||
|
||||
/* if another scrollbar is visible */
|
||||
|
||||
.scrollbar-janos > .scroll-element.scroll-x.scroll-scrolly_visible .scroll-element_size { left: -17px; }
|
||||
.scrollbar-janos > .scroll-element.scroll-y.scroll-scrollx_visible .scroll-element_size { top: -17px; }
|
||||
|
||||
.scrollbar-janos > .scroll-element.scroll-x.scroll-scrolly_visible .scroll-element_inner { left: -17px; }
|
||||
.scrollbar-janos > .scroll-element.scroll-y.scroll-scrollx_visible .scroll-element_inner { top: -17px; }
|
||||
|
||||
/* if arrows & another scrollbar are visible */
|
||||
|
||||
.scrollbar-janos > .scroll-element.scroll-y.scroll-scrollx_visible .scroll-element_corner,
|
||||
.scrollbar-janos > .scroll-element.scroll-y.scroll-element_arrows_visible.scroll-scrollx_visible .scroll-element_corner {
|
||||
border-top: 1px solid #AAAAAA;
|
||||
bottom: 0;
|
||||
display: block;
|
||||
height: 16px;
|
||||
left: auto;
|
||||
right: 0;
|
||||
top: auto;
|
||||
width: 16px;
|
||||
z-index: 13;
|
||||
}
|
||||
|
||||
.scrollbar-janos > .scroll-element.scroll-x.scroll-element_arrows_visible.scroll-scrolly_visible .scroll-arrow_more { right: 17px;}
|
||||
.scrollbar-janos > .scroll-element.scroll-x.scroll-element_arrows_visible.scroll-scrolly_visible .scroll-element_track { left: -50px;}
|
||||
.scrollbar-janos > .scroll-element.scroll-x.scroll-element_arrows_visible.scroll-scrolly_visible .scroll-element_size { left: -51px;}
|
||||
|
||||
|
||||
.scrollbar-janos > .scroll-element.scroll-y.scroll-element_arrows_visible.scroll-scrollx_visible .scroll-arrow_more { bottom: 17px;}
|
||||
.scrollbar-janos > .scroll-element.scroll-y.scroll-element_arrows_visible.scroll-scrollx_visible .scroll-element_track { top: -50px;}
|
||||
.scrollbar-janos > .scroll-element.scroll-y.scroll-element_arrows_visible.scroll-scrollx_visible .scroll-element_size { top: -51px;}
|
||||
|
||||
|
||||
</style>
|
||||
<script type="text/javascript">
|
||||
jQuery(document).ready(function(){
|
||||
jQuery('.scrollbar-janos').scrollbar({
|
||||
"showArrows": true,
|
||||
"scrollx": "advanced",
|
||||
"scrolly": "advanced"
|
||||
});
|
||||
});
|
||||
</script>
|
||||
<div class="demo">
|
||||
<div class="scrollbar-janos theme-blue">
|
||||
<img src="../includes/tarzan.jpg" height="2100" width="2800">
|
||||
</div>
|
||||
</div>
|
||||
<div class="html"></div>
|
||||
<div class="css"></div>
|
||||
<div class="js"></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
175
assets/js/vendor/jquery.scrollbar/demo/angular.html
vendored
Normal file
175
assets/js/vendor/jquery.scrollbar/demo/angular.html
vendored
Normal file
@@ -0,0 +1,175 @@
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<title>jQuery Scrollbar as AngularJS directive</title>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
|
||||
<link rel="stylesheet" href="../includes/style.css" />
|
||||
<link rel="stylesheet" href="../includes/prettify/prettify.css" />
|
||||
<link rel="stylesheet" href="../jquery.scrollbar.css" />
|
||||
<style type="text/css">
|
||||
* {
|
||||
box-sizing: border-box;
|
||||
}
|
||||
.content .demo > div {
|
||||
max-height: none;
|
||||
}
|
||||
</style>
|
||||
|
||||
<script src="../includes/prettify/prettify.js"></script>
|
||||
<script src="../includes/jquery.js"></script>
|
||||
<script src="../includes/angular.js"></script>
|
||||
<script src="../jquery.scrollbar.js"></script>
|
||||
|
||||
<script type="text/javascript">
|
||||
if(window.location.href.match(/gromo.github.io/i)){
|
||||
(function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
|
||||
(i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
|
||||
m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
|
||||
})(window,document,'script','//www.google-analytics.com/analytics.js','ga');
|
||||
|
||||
ga('create', 'UA-52878040-1', 'auto');
|
||||
ga('send', 'pageview');
|
||||
}
|
||||
</script>
|
||||
</head>
|
||||
<body>
|
||||
<div class="wrapper scrollbar-dynamic">
|
||||
<div class="page-content">
|
||||
|
||||
<h1>jQuery Scrollbar as AngularJS directive</h1>
|
||||
|
||||
<a href="basic.html">Basic Scrollbars Demo</a><br/>
|
||||
<a href="advanced.html">Advanced Scrollbars Demo</a><br/>
|
||||
<a href="../">« Back to home</a>
|
||||
|
||||
<p id="lorem-ipsum">
|
||||
Lorem ipsum dolor sit amet, consectetur adipisicing elit. Proin nibh augue, suscipit a,
|
||||
scelerisque sed, lacinia in, mi. Cras vel lorem. Etiam pellentesque aliquet tellus.
|
||||
Phasellus pharetra nulla ac diam. Quisque semper justo at risus. Donec venenatis, turpis vel
|
||||
hendrerit interdum, dui ligula ultricies purus, sed posuere libero dui id orci. Nam congue,
|
||||
pede vitae dapibus aliquet, elit magna vulputate arcu, vel tempus metus leo non est. Etiam
|
||||
sit amet lectus quis est congue mollis. Phasellus congue lacus eget neque. Phasellus ornare,
|
||||
ante vitae consectetuer consequat, purus sapien ultricies dolor, et mollis pede metus eget
|
||||
nisi. Praesent sodales velit quis augue. Cras suscipit, urna at aliquam rhoncus, urna quam
|
||||
viverra nisi, in interdum massa nibh nec erat.
|
||||
</p>
|
||||
|
||||
<div class="container">
|
||||
<h2></h2>
|
||||
<div class="controls">
|
||||
<span class="demo">DEMO</span>
|
||||
<span class="html">HTML</span>
|
||||
<span class="css">CSS</span>
|
||||
<span class="js">JS</span>
|
||||
<button class="add-content">Add Content</button>
|
||||
<button class="remove-content">Remove Content</button>
|
||||
</div>
|
||||
<div class="content">
|
||||
<style type="text/css">
|
||||
.scrollbar-dynamic {
|
||||
max-height: 300px;
|
||||
overflow: auto;
|
||||
}
|
||||
</style>
|
||||
<script type="text/javascript">
|
||||
var demoApp = angular.module('demoApp', ['jQueryScrollbar']);
|
||||
demoApp.controller('SimpleController', function($scope){
|
||||
$scope.jqueryScrollbarOptions = {
|
||||
"onScroll":function(y, x){
|
||||
if(y.scroll == y.maxScroll){
|
||||
alert('Scrolled to bottom');
|
||||
}
|
||||
}
|
||||
};
|
||||
});
|
||||
</script>
|
||||
<div class="demo">
|
||||
<div data-ng-app="demoApp">
|
||||
<div data-ng-controller="SimpleController">
|
||||
<div class="scrollbar-dynamic" data-jquery-scrollbar="jqueryScrollbarOptions">
|
||||
<p class="permanent">
|
||||
Using jQuery scrollbar as Angular.JS directive is simple. Just include jquery.scrollbar.js
|
||||
file after jQuery and Angular. jQuery Scrollbar automatically creates Angular.JS module
|
||||
<em>jQueryScrollbar</em> with directive <em>jqueryScrollbar</em>.<br/>
|
||||
<i>* Please note that Angular.JS does not work with IE 7.</i>
|
||||
</p>
|
||||
<p>
|
||||
Lorem ipsum dolor sit amet, consectetur adipisicing elit. Proin nibh augue, suscipit a,
|
||||
scelerisque sed, lacinia in, mi. Cras vel lorem. Etiam pellentesque aliquet tellus.
|
||||
Phasellus pharetra nulla ac diam. Quisque semper justo at risus. Donec venenatis, turpis vel
|
||||
hendrerit interdum, dui ligula ultricies purus, sed posuere libero dui id orci. Nam congue,
|
||||
pede vitae dapibus aliquet, elit magna vulputate arcu, vel tempus metus leo non est. Etiam
|
||||
sit amet lectus quis est congue mollis. Phasellus congue lacus eget neque. Phasellus ornare,
|
||||
ante vitae consectetuer consequat, purus sapien ultricies dolor, et mollis pede metus eget
|
||||
nisi. Praesent sodales velit quis augue. Cras suscipit, urna at aliquam rhoncus, urna quam
|
||||
viverra nisi, in interdum massa nibh nec erat.
|
||||
</p>
|
||||
<p>
|
||||
Lorem ipsum dolor sit amet, consectetur adipisicing elit. Proin nibh augue, suscipit a,
|
||||
scelerisque sed, lacinia in, mi. Cras vel lorem. Etiam pellentesque aliquet tellus.
|
||||
Phasellus pharetra nulla ac diam. Quisque semper justo at risus. Donec venenatis, turpis vel
|
||||
hendrerit interdum, dui ligula ultricies purus, sed posuere libero dui id orci. Nam congue,
|
||||
pede vitae dapibus aliquet, elit magna vulputate arcu, vel tempus metus leo non est. Etiam
|
||||
sit amet lectus quis est congue mollis. Phasellus congue lacus eget neque. Phasellus ornare,
|
||||
ante vitae consectetuer consequat, purus sapien ultricies dolor, et mollis pede metus eget
|
||||
nisi. Praesent sodales velit quis augue. Cras suscipit, urna at aliquam rhoncus, urna quam
|
||||
viverra nisi, in interdum massa nibh nec erat.
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="html"></div>
|
||||
<div class="css"></div>
|
||||
<div class="js"></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<script>
|
||||
function getAlignedText(text){
|
||||
text = (text || '').split('\n');
|
||||
while(text.length > 0 && $.trim(text[0]) == ''){
|
||||
text.shift();
|
||||
}
|
||||
var tabs = (text[0] || '').replace(/^(\s+).+$/, '$1');
|
||||
for(var i=0; i<text.length; i++){
|
||||
text[i] = text[i].replace(tabs, '');
|
||||
}
|
||||
if(text.length > 0 && text[text.length - 1].match(/^\s*$/)){
|
||||
text.pop();
|
||||
}
|
||||
return text.join('\n');
|
||||
}
|
||||
|
||||
$('.container').each(function(){
|
||||
|
||||
var content = $(this).find('.content');
|
||||
var controls = $(this).find('.controls');
|
||||
|
||||
$('<pre></pre>').addClass('prettyprint linenums lang-html').text(getAlignedText(content.find('.demo').html())).appendTo(content.find('.html'));
|
||||
$('<pre></pre>').addClass('prettyprint linenums lang-css').text(getAlignedText($('#css-common').html()) + "\n" + getAlignedText(content.find('style').html())).appendTo(content.find('.css'));
|
||||
$('<pre></pre>').addClass('prettyprint linenums lang-js').text(getAlignedText(content.find('script').html())).appendTo(content.find('.js'));
|
||||
|
||||
controls.on('click', 'span', function(){
|
||||
content.find('.' + $(this).removeClass('active').attr('class')).show().siblings('div').hide();
|
||||
$(this).addClass('active').siblings('span').removeClass('active');
|
||||
});
|
||||
controls.find('.demo').click();
|
||||
});
|
||||
|
||||
$('.container').on('click', '.add-content', function(){
|
||||
$('#lorem-ipsum').clone().removeAttr('id').appendTo($(this).closest('.container').find('.scroll-content'));
|
||||
return false;
|
||||
});
|
||||
$('.container').on('click', '.remove-content', function(){
|
||||
$(this).closest('.container').find('.scroll-content').find('p').not('.permanent').last().remove();
|
||||
return false;
|
||||
});
|
||||
|
||||
window.prettyPrint && prettyPrint();
|
||||
$('.wrapper').scrollbar();
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
||||
1385
assets/js/vendor/jquery.scrollbar/demo/basic.html
vendored
Normal file
1385
assets/js/vendor/jquery.scrollbar/demo/basic.html
vendored
Normal file
File diff suppressed because it is too large
Load Diff
21464
assets/js/vendor/jquery.scrollbar/includes/angular.js
vendored
Normal file
21464
assets/js/vendor/jquery.scrollbar/includes/angular.js
vendored
Normal file
File diff suppressed because it is too large
Load Diff
4
assets/js/vendor/jquery.scrollbar/includes/jquery.js
vendored
Normal file
4
assets/js/vendor/jquery.scrollbar/includes/jquery.js
vendored
Normal file
File diff suppressed because one or more lines are too long
1
assets/js/vendor/jquery.scrollbar/includes/prettify/prettify.css
vendored
Normal file
1
assets/js/vendor/jquery.scrollbar/includes/prettify/prettify.css
vendored
Normal file
@@ -0,0 +1 @@
|
||||
.pln{color:#000}@media screen{.str{color:#080}.kwd{color:#008}.com{color:#800}.typ{color:#606}.lit{color:#066}.pun,.opn,.clo{color:#660}.tag{color:#008}.atn{color:#606}.atv{color:#080}.dec,.var{color:#606}.fun{color:red}}@media print,projection{.str{color:#060}.kwd{color:#006;font-weight:bold}.com{color:#600;font-style:italic}.typ{color:#404;font-weight:bold}.lit{color:#044}.pun,.opn,.clo{color:#440}.tag{color:#006;font-weight:bold}.atn{color:#404}.atv{color:#060}}pre.prettyprint{padding:2px;border:1px solid #888}ol.linenums{margin-top:0;margin-bottom:0}li.L0,li.L1,li.L2,li.L3,li.L5,li.L6,li.L7,li.L8{list-style-type:none}li.L1,li.L3,li.L5,li.L7,li.L9{background:#eee}
|
||||
30
assets/js/vendor/jquery.scrollbar/includes/prettify/prettify.js
vendored
Normal file
30
assets/js/vendor/jquery.scrollbar/includes/prettify/prettify.js
vendored
Normal file
@@ -0,0 +1,30 @@
|
||||
!function(){var q=null;window.PR_SHOULD_USE_CONTINUATION=!0;
|
||||
(function(){function S(a){function d(e){var b=e.charCodeAt(0);if(b!==92)return b;var a=e.charAt(1);return(b=r[a])?b:"0"<=a&&a<="7"?parseInt(e.substring(1),8):a==="u"||a==="x"?parseInt(e.substring(2),16):e.charCodeAt(1)}function g(e){if(e<32)return(e<16?"\\x0":"\\x")+e.toString(16);e=String.fromCharCode(e);return e==="\\"||e==="-"||e==="]"||e==="^"?"\\"+e:e}function b(e){var b=e.substring(1,e.length-1).match(/\\u[\dA-Fa-f]{4}|\\x[\dA-Fa-f]{2}|\\[0-3][0-7]{0,2}|\\[0-7]{1,2}|\\[\S\s]|[^\\]/g),e=[],a=
|
||||
b[0]==="^",c=["["];a&&c.push("^");for(var a=a?1:0,f=b.length;a<f;++a){var h=b[a];if(/\\[bdsw]/i.test(h))c.push(h);else{var h=d(h),l;a+2<f&&"-"===b[a+1]?(l=d(b[a+2]),a+=2):l=h;e.push([h,l]);l<65||h>122||(l<65||h>90||e.push([Math.max(65,h)|32,Math.min(l,90)|32]),l<97||h>122||e.push([Math.max(97,h)&-33,Math.min(l,122)&-33]))}}e.sort(function(e,a){return e[0]-a[0]||a[1]-e[1]});b=[];f=[];for(a=0;a<e.length;++a)h=e[a],h[0]<=f[1]+1?f[1]=Math.max(f[1],h[1]):b.push(f=h);for(a=0;a<b.length;++a)h=b[a],c.push(g(h[0])),
|
||||
h[1]>h[0]&&(h[1]+1>h[0]&&c.push("-"),c.push(g(h[1])));c.push("]");return c.join("")}function s(e){for(var a=e.source.match(/\[(?:[^\\\]]|\\[\S\s])*]|\\u[\dA-Fa-f]{4}|\\x[\dA-Fa-f]{2}|\\\d+|\\[^\dux]|\(\?[!:=]|[()^]|[^()[\\^]+/g),c=a.length,d=[],f=0,h=0;f<c;++f){var l=a[f];l==="("?++h:"\\"===l.charAt(0)&&(l=+l.substring(1))&&(l<=h?d[l]=-1:a[f]=g(l))}for(f=1;f<d.length;++f)-1===d[f]&&(d[f]=++x);for(h=f=0;f<c;++f)l=a[f],l==="("?(++h,d[h]||(a[f]="(?:")):"\\"===l.charAt(0)&&(l=+l.substring(1))&&l<=h&&
|
||||
(a[f]="\\"+d[l]);for(f=0;f<c;++f)"^"===a[f]&&"^"!==a[f+1]&&(a[f]="");if(e.ignoreCase&&m)for(f=0;f<c;++f)l=a[f],e=l.charAt(0),l.length>=2&&e==="["?a[f]=b(l):e!=="\\"&&(a[f]=l.replace(/[A-Za-z]/g,function(a){a=a.charCodeAt(0);return"["+String.fromCharCode(a&-33,a|32)+"]"}));return a.join("")}for(var x=0,m=!1,j=!1,k=0,c=a.length;k<c;++k){var i=a[k];if(i.ignoreCase)j=!0;else if(/[a-z]/i.test(i.source.replace(/\\u[\da-f]{4}|\\x[\da-f]{2}|\\[^UXux]/gi,""))){m=!0;j=!1;break}}for(var r={b:8,t:9,n:10,v:11,
|
||||
f:12,r:13},n=[],k=0,c=a.length;k<c;++k){i=a[k];if(i.global||i.multiline)throw Error(""+i);n.push("(?:"+s(i)+")")}return RegExp(n.join("|"),j?"gi":"g")}function T(a,d){function g(a){var c=a.nodeType;if(c==1){if(!b.test(a.className)){for(c=a.firstChild;c;c=c.nextSibling)g(c);c=a.nodeName.toLowerCase();if("br"===c||"li"===c)s[j]="\n",m[j<<1]=x++,m[j++<<1|1]=a}}else if(c==3||c==4)c=a.nodeValue,c.length&&(c=d?c.replace(/\r\n?/g,"\n"):c.replace(/[\t\n\r ]+/g," "),s[j]=c,m[j<<1]=x,x+=c.length,m[j++<<1|1]=
|
||||
a)}var b=/(?:^|\s)nocode(?:\s|$)/,s=[],x=0,m=[],j=0;g(a);return{a:s.join("").replace(/\n$/,""),d:m}}function H(a,d,g,b){d&&(a={a:d,e:a},g(a),b.push.apply(b,a.g))}function U(a){for(var d=void 0,g=a.firstChild;g;g=g.nextSibling)var b=g.nodeType,d=b===1?d?a:g:b===3?V.test(g.nodeValue)?a:d:d;return d===a?void 0:d}function C(a,d){function g(a){for(var j=a.e,k=[j,"pln"],c=0,i=a.a.match(s)||[],r={},n=0,e=i.length;n<e;++n){var z=i[n],w=r[z],t=void 0,f;if(typeof w==="string")f=!1;else{var h=b[z.charAt(0)];
|
||||
if(h)t=z.match(h[1]),w=h[0];else{for(f=0;f<x;++f)if(h=d[f],t=z.match(h[1])){w=h[0];break}t||(w="pln")}if((f=w.length>=5&&"lang-"===w.substring(0,5))&&!(t&&typeof t[1]==="string"))f=!1,w="src";f||(r[z]=w)}h=c;c+=z.length;if(f){f=t[1];var l=z.indexOf(f),B=l+f.length;t[2]&&(B=z.length-t[2].length,l=B-f.length);w=w.substring(5);H(j+h,z.substring(0,l),g,k);H(j+h+l,f,I(w,f),k);H(j+h+B,z.substring(B),g,k)}else k.push(j+h,w)}a.g=k}var b={},s;(function(){for(var g=a.concat(d),j=[],k={},c=0,i=g.length;c<i;++c){var r=
|
||||
g[c],n=r[3];if(n)for(var e=n.length;--e>=0;)b[n.charAt(e)]=r;r=r[1];n=""+r;k.hasOwnProperty(n)||(j.push(r),k[n]=q)}j.push(/[\S\s]/);s=S(j)})();var x=d.length;return g}function v(a){var d=[],g=[];a.tripleQuotedStrings?d.push(["str",/^(?:'''(?:[^'\\]|\\[\S\s]|''?(?=[^']))*(?:'''|$)|"""(?:[^"\\]|\\[\S\s]|""?(?=[^"]))*(?:"""|$)|'(?:[^'\\]|\\[\S\s])*(?:'|$)|"(?:[^"\\]|\\[\S\s])*(?:"|$))/,q,"'\""]):a.multiLineStrings?d.push(["str",/^(?:'(?:[^'\\]|\\[\S\s])*(?:'|$)|"(?:[^"\\]|\\[\S\s])*(?:"|$)|`(?:[^\\`]|\\[\S\s])*(?:`|$))/,
|
||||
q,"'\"`"]):d.push(["str",/^(?:'(?:[^\n\r'\\]|\\.)*(?:'|$)|"(?:[^\n\r"\\]|\\.)*(?:"|$))/,q,"\"'"]);a.verbatimStrings&&g.push(["str",/^@"(?:[^"]|"")*(?:"|$)/,q]);var b=a.hashComments;b&&(a.cStyleComments?(b>1?d.push(["com",/^#(?:##(?:[^#]|#(?!##))*(?:###|$)|.*)/,q,"#"]):d.push(["com",/^#(?:(?:define|e(?:l|nd)if|else|error|ifn?def|include|line|pragma|undef|warning)\b|[^\n\r]*)/,q,"#"]),g.push(["str",/^<(?:(?:(?:\.\.\/)*|\/?)(?:[\w-]+(?:\/[\w-]+)+)?[\w-]+\.h(?:h|pp|\+\+)?|[a-z]\w*)>/,q])):d.push(["com",
|
||||
/^#[^\n\r]*/,q,"#"]));a.cStyleComments&&(g.push(["com",/^\/\/[^\n\r]*/,q]),g.push(["com",/^\/\*[\S\s]*?(?:\*\/|$)/,q]));if(b=a.regexLiterals){var s=(b=b>1?"":"\n\r")?".":"[\\S\\s]";g.push(["lang-regex",RegExp("^(?:^^\\.?|[+-]|[!=]=?=?|\\#|%=?|&&?=?|\\(|\\*=?|[+\\-]=|->|\\/=?|::?|<<?=?|>>?>?=?|,|;|\\?|@|\\[|~|{|\\^\\^?=?|\\|\\|?=?|break|case|continue|delete|do|else|finally|instanceof|return|throw|try|typeof)\\s*("+("/(?=[^/*"+b+"])(?:[^/\\x5B\\x5C"+b+"]|\\x5C"+s+"|\\x5B(?:[^\\x5C\\x5D"+b+"]|\\x5C"+
|
||||
s+")*(?:\\x5D|$))+/")+")")])}(b=a.types)&&g.push(["typ",b]);b=(""+a.keywords).replace(/^ | $/g,"");b.length&&g.push(["kwd",RegExp("^(?:"+b.replace(/[\s,]+/g,"|")+")\\b"),q]);d.push(["pln",/^\s+/,q," \r\n\t\u00a0"]);b="^.[^\\s\\w.$@'\"`/\\\\]*";a.regexLiterals&&(b+="(?!s*/)");g.push(["lit",/^@[$_a-z][\w$@]*/i,q],["typ",/^(?:[@_]?[A-Z]+[a-z][\w$@]*|\w+_t\b)/,q],["pln",/^[$_a-z][\w$@]*/i,q],["lit",/^(?:0x[\da-f]+|(?:\d(?:_\d+)*\d*(?:\.\d*)?|\.\d\+)(?:e[+-]?\d+)?)[a-z]*/i,q,"0123456789"],["pln",/^\\[\S\s]?/,
|
||||
q],["pun",RegExp(b),q]);return C(d,g)}function J(a,d,g){function b(a){var c=a.nodeType;if(c==1&&!x.test(a.className))if("br"===a.nodeName)s(a),a.parentNode&&a.parentNode.removeChild(a);else for(a=a.firstChild;a;a=a.nextSibling)b(a);else if((c==3||c==4)&&g){var d=a.nodeValue,i=d.match(m);if(i)c=d.substring(0,i.index),a.nodeValue=c,(d=d.substring(i.index+i[0].length))&&a.parentNode.insertBefore(j.createTextNode(d),a.nextSibling),s(a),c||a.parentNode.removeChild(a)}}function s(a){function b(a,c){var d=
|
||||
c?a.cloneNode(!1):a,e=a.parentNode;if(e){var e=b(e,1),g=a.nextSibling;e.appendChild(d);for(var i=g;i;i=g)g=i.nextSibling,e.appendChild(i)}return d}for(;!a.nextSibling;)if(a=a.parentNode,!a)return;for(var a=b(a.nextSibling,0),d;(d=a.parentNode)&&d.nodeType===1;)a=d;c.push(a)}for(var x=/(?:^|\s)nocode(?:\s|$)/,m=/\r\n?|\n/,j=a.ownerDocument,k=j.createElement("li");a.firstChild;)k.appendChild(a.firstChild);for(var c=[k],i=0;i<c.length;++i)b(c[i]);d===(d|0)&&c[0].setAttribute("value",d);var r=j.createElement("ol");
|
||||
r.className="linenums";for(var d=Math.max(0,d-1|0)||0,i=0,n=c.length;i<n;++i)k=c[i],k.className="L"+(i+d)%10,k.firstChild||k.appendChild(j.createTextNode("\u00a0")),r.appendChild(k);a.appendChild(r)}function p(a,d){for(var g=d.length;--g>=0;){var b=d[g];F.hasOwnProperty(b)?D.console&&console.warn("cannot override language handler %s",b):F[b]=a}}function I(a,d){if(!a||!F.hasOwnProperty(a))a=/^\s*</.test(d)?"default-markup":"default-code";return F[a]}function K(a){var d=a.h;try{var g=T(a.c,a.i),b=g.a;
|
||||
a.a=b;a.d=g.d;a.e=0;I(d,b)(a);var s=/\bMSIE\s(\d+)/.exec(navigator.userAgent),s=s&&+s[1]<=8,d=/\n/g,x=a.a,m=x.length,g=0,j=a.d,k=j.length,b=0,c=a.g,i=c.length,r=0;c[i]=m;var n,e;for(e=n=0;e<i;)c[e]!==c[e+2]?(c[n++]=c[e++],c[n++]=c[e++]):e+=2;i=n;for(e=n=0;e<i;){for(var p=c[e],w=c[e+1],t=e+2;t+2<=i&&c[t+1]===w;)t+=2;c[n++]=p;c[n++]=w;e=t}c.length=n;var f=a.c,h;if(f)h=f.style.display,f.style.display="none";try{for(;b<k;){var l=j[b+2]||m,B=c[r+2]||m,t=Math.min(l,B),A=j[b+1],G;if(A.nodeType!==1&&(G=x.substring(g,
|
||||
t))){s&&(G=G.replace(d,"\r"));A.nodeValue=G;var L=A.ownerDocument,o=L.createElement("span");o.className=c[r+1];var v=A.parentNode;v.replaceChild(o,A);o.appendChild(A);g<l&&(j[b+1]=A=L.createTextNode(x.substring(t,l)),v.insertBefore(A,o.nextSibling))}g=t;g>=l&&(b+=2);g>=B&&(r+=2)}}finally{if(f)f.style.display=h}}catch(u){D.console&&console.log(u&&u.stack||u)}}var D=window,y=["break,continue,do,else,for,if,return,while"],E=[[y,"auto,case,char,const,default,double,enum,extern,float,goto,inline,int,long,register,short,signed,sizeof,static,struct,switch,typedef,union,unsigned,void,volatile"],
|
||||
"catch,class,delete,false,import,new,operator,private,protected,public,this,throw,true,try,typeof"],M=[E,"alignof,align_union,asm,axiom,bool,concept,concept_map,const_cast,constexpr,decltype,delegate,dynamic_cast,explicit,export,friend,generic,late_check,mutable,namespace,nullptr,property,reinterpret_cast,static_assert,static_cast,template,typeid,typename,using,virtual,where"],N=[E,"abstract,assert,boolean,byte,extends,final,finally,implements,import,instanceof,interface,null,native,package,strictfp,super,synchronized,throws,transient"],
|
||||
O=[N,"as,base,by,checked,decimal,delegate,descending,dynamic,event,fixed,foreach,from,group,implicit,in,internal,into,is,let,lock,object,out,override,orderby,params,partial,readonly,ref,sbyte,sealed,stackalloc,string,select,uint,ulong,unchecked,unsafe,ushort,var,virtual,where"],E=[E,"debugger,eval,export,function,get,null,set,undefined,var,with,Infinity,NaN"],P=[y,"and,as,assert,class,def,del,elif,except,exec,finally,from,global,import,in,is,lambda,nonlocal,not,or,pass,print,raise,try,with,yield,False,True,None"],
|
||||
Q=[y,"alias,and,begin,case,class,def,defined,elsif,end,ensure,false,in,module,next,nil,not,or,redo,rescue,retry,self,super,then,true,undef,unless,until,when,yield,BEGIN,END"],W=[y,"as,assert,const,copy,drop,enum,extern,fail,false,fn,impl,let,log,loop,match,mod,move,mut,priv,pub,pure,ref,self,static,struct,true,trait,type,unsafe,use"],y=[y,"case,done,elif,esac,eval,fi,function,in,local,set,then,until"],R=/^(DIR|FILE|vector|(de|priority_)?queue|list|stack|(const_)?iterator|(multi)?(set|map)|bitset|u?(int|float)\d*)\b/,
|
||||
V=/\S/,X=v({keywords:[M,O,E,"caller,delete,die,do,dump,elsif,eval,exit,foreach,for,goto,if,import,last,local,my,next,no,our,print,package,redo,require,sub,undef,unless,until,use,wantarray,while,BEGIN,END",P,Q,y],hashComments:!0,cStyleComments:!0,multiLineStrings:!0,regexLiterals:!0}),F={};p(X,["default-code"]);p(C([],[["pln",/^[^<?]+/],["dec",/^<!\w[^>]*(?:>|$)/],["com",/^<\!--[\S\s]*?(?:--\>|$)/],["lang-",/^<\?([\S\s]+?)(?:\?>|$)/],["lang-",/^<%([\S\s]+?)(?:%>|$)/],["pun",/^(?:<[%?]|[%?]>)/],["lang-",
|
||||
/^<xmp\b[^>]*>([\S\s]+?)<\/xmp\b[^>]*>/i],["lang-js",/^<script\b[^>]*>([\S\s]*?)(<\/script\b[^>]*>)/i],["lang-css",/^<style\b[^>]*>([\S\s]*?)(<\/style\b[^>]*>)/i],["lang-in.tag",/^(<\/?[a-z][^<>]*>)/i]]),["default-markup","htm","html","mxml","xhtml","xml","xsl"]);p(C([["pln",/^\s+/,q," \t\r\n"],["atv",/^(?:"[^"]*"?|'[^']*'?)/,q,"\"'"]],[["tag",/^^<\/?[a-z](?:[\w-.:]*\w)?|\/?>$/i],["atn",/^(?!style[\s=]|on)[a-z](?:[\w:-]*\w)?/i],["lang-uq.val",/^=\s*([^\s"'>]*(?:[^\s"'/>]|\/(?=\s)))/],["pun",/^[/<->]+/],
|
||||
["lang-js",/^on\w+\s*=\s*"([^"]+)"/i],["lang-js",/^on\w+\s*=\s*'([^']+)'/i],["lang-js",/^on\w+\s*=\s*([^\s"'>]+)/i],["lang-css",/^style\s*=\s*"([^"]+)"/i],["lang-css",/^style\s*=\s*'([^']+)'/i],["lang-css",/^style\s*=\s*([^\s"'>]+)/i]]),["in.tag"]);p(C([],[["atv",/^[\S\s]+/]]),["uq.val"]);p(v({keywords:M,hashComments:!0,cStyleComments:!0,types:R}),["c","cc","cpp","cxx","cyc","m"]);p(v({keywords:"null,true,false"}),["json"]);p(v({keywords:O,hashComments:!0,cStyleComments:!0,verbatimStrings:!0,types:R}),
|
||||
["cs"]);p(v({keywords:N,cStyleComments:!0}),["java"]);p(v({keywords:y,hashComments:!0,multiLineStrings:!0}),["bash","bsh","csh","sh"]);p(v({keywords:P,hashComments:!0,multiLineStrings:!0,tripleQuotedStrings:!0}),["cv","py","python"]);p(v({keywords:"caller,delete,die,do,dump,elsif,eval,exit,foreach,for,goto,if,import,last,local,my,next,no,our,print,package,redo,require,sub,undef,unless,until,use,wantarray,while,BEGIN,END",hashComments:!0,multiLineStrings:!0,regexLiterals:2}),["perl","pl","pm"]);p(v({keywords:Q,
|
||||
hashComments:!0,multiLineStrings:!0,regexLiterals:!0}),["rb","ruby"]);p(v({keywords:E,cStyleComments:!0,regexLiterals:!0}),["javascript","js"]);p(v({keywords:"all,and,by,catch,class,else,extends,false,finally,for,if,in,is,isnt,loop,new,no,not,null,of,off,on,or,return,super,then,throw,true,try,unless,until,when,while,yes",hashComments:3,cStyleComments:!0,multilineStrings:!0,tripleQuotedStrings:!0,regexLiterals:!0}),["coffee"]);p(v({keywords:W,cStyleComments:!0,multilineStrings:!0}),["rc","rs","rust"]);
|
||||
p(C([],[["str",/^[\S\s]+/]]),["regex"]);var Y=D.PR={createSimpleLexer:C,registerLangHandler:p,sourceDecorator:v,PR_ATTRIB_NAME:"atn",PR_ATTRIB_VALUE:"atv",PR_COMMENT:"com",PR_DECLARATION:"dec",PR_KEYWORD:"kwd",PR_LITERAL:"lit",PR_NOCODE:"nocode",PR_PLAIN:"pln",PR_PUNCTUATION:"pun",PR_SOURCE:"src",PR_STRING:"str",PR_TAG:"tag",PR_TYPE:"typ",prettyPrintOne:D.prettyPrintOne=function(a,d,g){var b=document.createElement("div");b.innerHTML="<pre>"+a+"</pre>";b=b.firstChild;g&&J(b,g,!0);K({h:d,j:g,c:b,i:1});
|
||||
return b.innerHTML},prettyPrint:D.prettyPrint=function(a,d){function g(){for(var b=D.PR_SHOULD_USE_CONTINUATION?c.now()+250:Infinity;i<p.length&&c.now()<b;i++){for(var d=p[i],j=h,k=d;k=k.previousSibling;){var m=k.nodeType,o=(m===7||m===8)&&k.nodeValue;if(o?!/^\??prettify\b/.test(o):m!==3||/\S/.test(k.nodeValue))break;if(o){j={};o.replace(/\b(\w+)=([\w%+\-.:]+)/g,function(a,b,c){j[b]=c});break}}k=d.className;if((j!==h||e.test(k))&&!v.test(k)){m=!1;for(o=d.parentNode;o;o=o.parentNode)if(f.test(o.tagName)&&
|
||||
o.className&&e.test(o.className)){m=!0;break}if(!m){d.className+=" prettyprinted";m=j.lang;if(!m){var m=k.match(n),y;if(!m&&(y=U(d))&&t.test(y.tagName))m=y.className.match(n);m&&(m=m[1])}if(w.test(d.tagName))o=1;else var o=d.currentStyle,u=s.defaultView,o=(o=o?o.whiteSpace:u&&u.getComputedStyle?u.getComputedStyle(d,q).getPropertyValue("white-space"):0)&&"pre"===o.substring(0,3);u=j.linenums;if(!(u=u==="true"||+u))u=(u=k.match(/\blinenums\b(?::(\d+))?/))?u[1]&&u[1].length?+u[1]:!0:!1;u&&J(d,u,o);r=
|
||||
{h:m,c:d,j:u,i:o};K(r)}}}i<p.length?setTimeout(g,250):"function"===typeof a&&a()}for(var b=d||document.body,s=b.ownerDocument||document,b=[b.getElementsByTagName("pre"),b.getElementsByTagName("code"),b.getElementsByTagName("xmp")],p=[],m=0;m<b.length;++m)for(var j=0,k=b[m].length;j<k;++j)p.push(b[m][j]);var b=q,c=Date;c.now||(c={now:function(){return+new Date}});var i=0,r,n=/\blang(?:uage)?-([\w.]+)(?!\S)/,e=/\bprettyprint\b/,v=/\bprettyprinted\b/,w=/pre|xmp/i,t=/^code$/i,f=/^(?:pre|code|xmp)$/i,
|
||||
h={};g()}};typeof define==="function"&&define.amd&&define("google-code-prettify",[],function(){return Y})})();}()
|
||||
515
assets/js/vendor/jquery.scrollbar/includes/style.css
vendored
Normal file
515
assets/js/vendor/jquery.scrollbar/includes/style.css
vendored
Normal file
@@ -0,0 +1,515 @@
|
||||
/*! normalize.css v3.0.0 | MIT License | git.io/normalize */
|
||||
|
||||
/**
|
||||
* 1. Set default font family to sans-serif.
|
||||
* 2. Prevent iOS text size adjust after orientation change, without disabling
|
||||
* user zoom.
|
||||
*/
|
||||
html {
|
||||
font-family: sans-serif; /* 1 */
|
||||
-ms-text-size-adjust: 100%; /* 2 */
|
||||
-webkit-text-size-adjust: 100%; /* 2 */
|
||||
}
|
||||
|
||||
/**
|
||||
* Remove default margin.
|
||||
*/
|
||||
|
||||
body {
|
||||
margin: 0;
|
||||
}
|
||||
|
||||
/* HTML5 display definitions
|
||||
========================================================================== */
|
||||
|
||||
/**
|
||||
* Correct `block` display not defined in IE 8/9.
|
||||
*/
|
||||
|
||||
article,
|
||||
aside,
|
||||
details,
|
||||
figcaption,
|
||||
figure,
|
||||
footer,
|
||||
header,
|
||||
hgroup,
|
||||
main,
|
||||
nav,
|
||||
section,
|
||||
summary {
|
||||
display: block;
|
||||
}
|
||||
|
||||
/**
|
||||
* 1. Correct `inline-block` display not defined in IE 8/9.
|
||||
* 2. Normalize vertical alignment of `progress` in Chrome, Firefox, and Opera.
|
||||
*/
|
||||
|
||||
audio,
|
||||
canvas,
|
||||
progress,
|
||||
video {
|
||||
display: inline-block; /* 1 */
|
||||
vertical-align: baseline; /* 2 */
|
||||
}
|
||||
|
||||
/**
|
||||
* Prevent modern browsers from displaying `audio` without controls.
|
||||
* Remove excess height in iOS 5 devices.
|
||||
*/
|
||||
|
||||
audio:not([controls]) {
|
||||
display: none;
|
||||
height: 0;
|
||||
}
|
||||
|
||||
/**
|
||||
* Address `[hidden]` styling not present in IE 8/9.
|
||||
* Hide the `template` element in IE, Safari, and Firefox < 22.
|
||||
*/
|
||||
|
||||
[hidden],
|
||||
template {
|
||||
display: none;
|
||||
}
|
||||
|
||||
/* Links
|
||||
========================================================================== */
|
||||
|
||||
/**
|
||||
* Remove the gray background color from active links in IE 10.
|
||||
*/
|
||||
|
||||
a {
|
||||
background: transparent;
|
||||
}
|
||||
|
||||
/**
|
||||
* Improve readability when focused and also mouse hovered in all browsers.
|
||||
*/
|
||||
|
||||
a:active,
|
||||
a:hover {
|
||||
outline: 0;
|
||||
}
|
||||
|
||||
/* Text-level semantics
|
||||
========================================================================== */
|
||||
|
||||
/**
|
||||
* Address styling not present in IE 8/9, Safari 5, and Chrome.
|
||||
*/
|
||||
|
||||
abbr[title] {
|
||||
border-bottom: 1px dotted;
|
||||
}
|
||||
|
||||
/**
|
||||
* Address style set to `bolder` in Firefox 4+, Safari 5, and Chrome.
|
||||
*/
|
||||
|
||||
b,
|
||||
strong {
|
||||
font-weight: bold;
|
||||
}
|
||||
|
||||
/**
|
||||
* Address styling not present in Safari 5 and Chrome.
|
||||
*/
|
||||
|
||||
dfn {
|
||||
font-style: italic;
|
||||
}
|
||||
|
||||
/**
|
||||
* Address variable `h1` font-size and margin within `section` and `article`
|
||||
* contexts in Firefox 4+, Safari 5, and Chrome.
|
||||
*/
|
||||
|
||||
h1 {
|
||||
font-size: 2em;
|
||||
margin: 0.67em 0;
|
||||
}
|
||||
|
||||
/**
|
||||
* Address styling not present in IE 8/9.
|
||||
*/
|
||||
|
||||
mark {
|
||||
background: #ff0;
|
||||
color: #000;
|
||||
}
|
||||
|
||||
/**
|
||||
* Address inconsistent and variable font size in all browsers.
|
||||
*/
|
||||
|
||||
small {
|
||||
font-size: 80%;
|
||||
}
|
||||
|
||||
/**
|
||||
* Prevent `sub` and `sup` affecting `line-height` in all browsers.
|
||||
*/
|
||||
|
||||
sub,
|
||||
sup {
|
||||
font-size: 75%;
|
||||
line-height: 0;
|
||||
position: relative;
|
||||
vertical-align: baseline;
|
||||
}
|
||||
|
||||
sup {
|
||||
top: -0.5em;
|
||||
}
|
||||
|
||||
sub {
|
||||
bottom: -0.25em;
|
||||
}
|
||||
|
||||
/* Embedded content
|
||||
========================================================================== */
|
||||
|
||||
/**
|
||||
* Remove border when inside `a` element in IE 8/9.
|
||||
*/
|
||||
|
||||
img {
|
||||
border: 0;
|
||||
}
|
||||
|
||||
/**
|
||||
* Correct overflow displayed oddly in IE 9.
|
||||
*/
|
||||
|
||||
svg:not(:root) {
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
/* Grouping content
|
||||
========================================================================== */
|
||||
|
||||
/**
|
||||
* Address margin not present in IE 8/9 and Safari 5.
|
||||
*/
|
||||
|
||||
figure {
|
||||
margin: 1em 40px;
|
||||
}
|
||||
|
||||
/**
|
||||
* Address differences between Firefox and other browsers.
|
||||
*/
|
||||
|
||||
hr {
|
||||
-moz-box-sizing: content-box;
|
||||
box-sizing: content-box;
|
||||
height: 0;
|
||||
}
|
||||
|
||||
/**
|
||||
* Contain overflow in all browsers.
|
||||
*/
|
||||
|
||||
pre {
|
||||
overflow: auto;
|
||||
}
|
||||
|
||||
/**
|
||||
* Address odd `em`-unit font size rendering in all browsers.
|
||||
*/
|
||||
|
||||
code,
|
||||
kbd,
|
||||
pre,
|
||||
samp {
|
||||
font-family: monospace, monospace;
|
||||
font-size: 1em;
|
||||
}
|
||||
|
||||
/* Forms
|
||||
========================================================================== */
|
||||
|
||||
/**
|
||||
* Known limitation: by default, Chrome and Safari on OS X allow very limited
|
||||
* styling of `select`, unless a `border` property is set.
|
||||
*/
|
||||
|
||||
/**
|
||||
* 1. Correct color not being inherited.
|
||||
* Known issue: affects color of disabled elements.
|
||||
* 2. Correct font properties not being inherited.
|
||||
* 3. Address margins set differently in Firefox 4+, Safari 5, and Chrome.
|
||||
*/
|
||||
|
||||
button,
|
||||
input,
|
||||
optgroup,
|
||||
select,
|
||||
textarea {
|
||||
color: inherit; /* 1 */
|
||||
font: inherit; /* 2 */
|
||||
margin: 0; /* 3 */
|
||||
}
|
||||
|
||||
/**
|
||||
* Address `overflow` set to `hidden` in IE 8/9/10.
|
||||
*/
|
||||
|
||||
button {
|
||||
overflow: visible;
|
||||
}
|
||||
|
||||
/**
|
||||
* Address inconsistent `text-transform` inheritance for `button` and `select`.
|
||||
* All other form control elements do not inherit `text-transform` values.
|
||||
* Correct `button` style inheritance in Firefox, IE 8+, and Opera
|
||||
* Correct `select` style inheritance in Firefox.
|
||||
*/
|
||||
|
||||
button,
|
||||
select {
|
||||
text-transform: none;
|
||||
}
|
||||
|
||||
/**
|
||||
* 1. Avoid the WebKit bug in Android 4.0.* where (2) destroys native `audio`
|
||||
* and `video` controls.
|
||||
* 2. Correct inability to style clickable `input` types in iOS.
|
||||
* 3. Improve usability and consistency of cursor style between image-type
|
||||
* `input` and others.
|
||||
*/
|
||||
|
||||
button,
|
||||
html input[type="button"], /* 1 */
|
||||
input[type="reset"],
|
||||
input[type="submit"] {
|
||||
-webkit-appearance: button; /* 2 */
|
||||
cursor: pointer; /* 3 */
|
||||
}
|
||||
|
||||
/**
|
||||
* Re-set default cursor for disabled elements.
|
||||
*/
|
||||
|
||||
button[disabled],
|
||||
html input[disabled] {
|
||||
cursor: default;
|
||||
}
|
||||
|
||||
/**
|
||||
* Remove inner padding and border in Firefox 4+.
|
||||
*/
|
||||
|
||||
button::-moz-focus-inner,
|
||||
input::-moz-focus-inner {
|
||||
border: 0;
|
||||
padding: 0;
|
||||
}
|
||||
|
||||
/**
|
||||
* Address Firefox 4+ setting `line-height` on `input` using `!important` in
|
||||
* the UA stylesheet.
|
||||
*/
|
||||
|
||||
input {
|
||||
line-height: normal;
|
||||
}
|
||||
|
||||
/**
|
||||
* It's recommended that you don't attempt to style these elements.
|
||||
* Firefox's implementation doesn't respect box-sizing, padding, or width.
|
||||
*
|
||||
* 1. Address box sizing set to `content-box` in IE 8/9/10.
|
||||
* 2. Remove excess padding in IE 8/9/10.
|
||||
*/
|
||||
|
||||
input[type="checkbox"],
|
||||
input[type="radio"] {
|
||||
box-sizing: border-box; /* 1 */
|
||||
padding: 0; /* 2 */
|
||||
}
|
||||
|
||||
/**
|
||||
* Fix the cursor style for Chrome's increment/decrement buttons. For certain
|
||||
* `font-size` values of the `input`, it causes the cursor style of the
|
||||
* decrement button to change from `default` to `text`.
|
||||
*/
|
||||
|
||||
input[type="number"]::-webkit-inner-spin-button,
|
||||
input[type="number"]::-webkit-outer-spin-button {
|
||||
height: auto;
|
||||
}
|
||||
|
||||
/**
|
||||
* 1. Address `appearance` set to `searchfield` in Safari 5 and Chrome.
|
||||
* 2. Address `box-sizing` set to `border-box` in Safari 5 and Chrome
|
||||
* (include `-moz` to future-proof).
|
||||
*/
|
||||
|
||||
input[type="search"] {
|
||||
-webkit-appearance: textfield; /* 1 */
|
||||
-moz-box-sizing: content-box;
|
||||
-webkit-box-sizing: content-box; /* 2 */
|
||||
box-sizing: content-box;
|
||||
}
|
||||
|
||||
/**
|
||||
* Remove inner padding and search cancel button in Safari and Chrome on OS X.
|
||||
* Safari (but not Chrome) clips the cancel button when the search input has
|
||||
* padding (and `textfield` appearance).
|
||||
*/
|
||||
|
||||
input[type="search"]::-webkit-search-cancel-button,
|
||||
input[type="search"]::-webkit-search-decoration {
|
||||
-webkit-appearance: none;
|
||||
}
|
||||
|
||||
/**
|
||||
* Define consistent border, margin, and padding.
|
||||
*/
|
||||
|
||||
fieldset {
|
||||
border: 1px solid #c0c0c0;
|
||||
margin: 0 2px;
|
||||
padding: 0.35em 0.625em 0.75em;
|
||||
}
|
||||
|
||||
/**
|
||||
* 1. Correct `color` not being inherited in IE 8/9.
|
||||
* 2. Remove padding so people aren't caught out if they zero out fieldsets.
|
||||
*/
|
||||
|
||||
legend {
|
||||
border: 0; /* 1 */
|
||||
padding: 0; /* 2 */
|
||||
}
|
||||
|
||||
/**
|
||||
* Remove default vertical scrollbar in IE 8/9.
|
||||
*/
|
||||
|
||||
textarea {
|
||||
overflow: auto;
|
||||
}
|
||||
|
||||
/**
|
||||
* Don't inherit the `font-weight` (applied by a rule above).
|
||||
* NOTE: the default cannot safely be changed in Chrome and Safari on OS X.
|
||||
*/
|
||||
|
||||
optgroup {
|
||||
font-weight: bold;
|
||||
}
|
||||
|
||||
/* Tables
|
||||
========================================================================== */
|
||||
|
||||
/**
|
||||
* Remove most spacing between table cells.
|
||||
*/
|
||||
|
||||
table {
|
||||
border-collapse: collapse;
|
||||
border-spacing: 0;
|
||||
}
|
||||
|
||||
td,
|
||||
th {
|
||||
padding: 0;
|
||||
}
|
||||
|
||||
/* General
|
||||
========================================================================== */
|
||||
html, body {
|
||||
height: 100%;
|
||||
width: 100%;
|
||||
}
|
||||
body {
|
||||
background: #fff;
|
||||
font: 14px/1.55 Helvetica, sans-serif;
|
||||
color: #393938;
|
||||
}
|
||||
.wrapper {
|
||||
height: 100%;
|
||||
overflow: auto;
|
||||
width: 100%;
|
||||
}
|
||||
.wrapper.scrollbar-dynamic {
|
||||
max-height: none;
|
||||
}
|
||||
.page-content {
|
||||
margin: 0 auto;
|
||||
max-width: 1600px;
|
||||
padding: 25px;
|
||||
}
|
||||
.content .demo {
|
||||
padding: 25px;
|
||||
}
|
||||
h1 {
|
||||
font: bold 32px/1.2 Helvetica, sans-serif;
|
||||
margin: 24px 0 16px;
|
||||
}
|
||||
h2 {
|
||||
font: bold 26px/1.2 Helvetica, sans-serif;
|
||||
margin: 24px 0 16px;
|
||||
}
|
||||
h3 {
|
||||
font: bold 22px/1.2 Helvetica, sans-serif;
|
||||
margin: 24px 0 16px;
|
||||
}
|
||||
h4 {
|
||||
font: bold 18px/1.2 Helvetica, sans-serif;
|
||||
margin: 24px 0 16px;
|
||||
}
|
||||
h5 {
|
||||
font: bold 16px/1.2 Helvetica, sans-serif;
|
||||
margin: 24px 0 16px;
|
||||
}
|
||||
h6 {
|
||||
font: bold 14px/1.2 Helvetica, sans-serif;
|
||||
margin: 24px 0 16px;
|
||||
}
|
||||
|
||||
/** Custom page styles **/
|
||||
|
||||
.content {
|
||||
max-width: 1200px;
|
||||
}
|
||||
|
||||
.content .demo {
|
||||
border: 1px solid #CCC;
|
||||
}
|
||||
|
||||
.content .demo .inner-content {
|
||||
border: 1px solid #CCC;
|
||||
max-height: 170px;
|
||||
width: 600px;
|
||||
}
|
||||
|
||||
.content .demo > div {
|
||||
max-height: 250px;
|
||||
overflow: auto;
|
||||
}
|
||||
.content .demo .permanent {
|
||||
min-width: 800px;
|
||||
}
|
||||
.controls {
|
||||
padding: 0 0 10px;
|
||||
}
|
||||
.controls span {
|
||||
cursor: pointer; padding: 2px 8px;
|
||||
}
|
||||
.controls span.active {
|
||||
background: #4698CE;
|
||||
color: #fff;
|
||||
cursor: default;
|
||||
}
|
||||
.prettyprint ol.linenums > li {
|
||||
list-style-type: decimal;
|
||||
}
|
||||
#lorem-ipsum {
|
||||
display: none;
|
||||
}
|
||||
371
assets/js/vendor/jquery.scrollbar/index.html
vendored
Normal file
371
assets/js/vendor/jquery.scrollbar/index.html
vendored
Normal file
@@ -0,0 +1,371 @@
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<title>jQuery Scrollbar</title>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
|
||||
<link rel="stylesheet" href="includes/style.css">
|
||||
<link rel="stylesheet" href="includes/prettify/prettify.css">
|
||||
<link rel="stylesheet" href="jquery.scrollbar.css">
|
||||
|
||||
<script type="text/javascript" src="includes/prettify/prettify.js"></script>
|
||||
<script type="text/javascript" src="includes/jquery.js"></script>
|
||||
<script type="text/javascript" src="jquery.scrollbar.js"></script>
|
||||
<script type="text/javascript">
|
||||
jQuery(document).ready(function($){
|
||||
window.prettyPrint && prettyPrint();
|
||||
$('.wrapper').scrollbar();
|
||||
});
|
||||
</script>
|
||||
|
||||
<script type="text/javascript">
|
||||
if(window.location.href.match(/gromo.github.io/i)){
|
||||
(function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
|
||||
(i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
|
||||
m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
|
||||
})(window,document,'script','//www.google-analytics.com/analytics.js','ga');
|
||||
|
||||
ga('create', 'UA-52878040-1', 'auto');
|
||||
ga('send', 'pageview');
|
||||
}
|
||||
</script>
|
||||
</head>
|
||||
<body>
|
||||
<div class="wrapper scrollbar-dynamic">
|
||||
<div class="page-content">
|
||||
|
||||
<h1>jQuery Scrollbar</h1>
|
||||
|
||||
Cross-browser CSS customizable scrollbar with advanced features:
|
||||
<ul>
|
||||
<li>Easy to implement</li>
|
||||
<li>No fixed height or width needed</li>
|
||||
<li>Supports responsive design</li>
|
||||
<li>Customizable CSS</li>
|
||||
<li>Standard browser scroll behaviour</li>
|
||||
<li>Supports vertical and horizontal scrollbars or both</li>
|
||||
<li>Automatically re-initializes scrollbars</li>
|
||||
<li>Supports external scrollbars</li>
|
||||
<li>Provides a AngularJS directive</li>
|
||||
<li>Supports the use as textarea scrollbar</li>
|
||||
<li>Browser support: IE7+, Edge, Firefox, Opera, Chrome, Safari</li>
|
||||
</ul>
|
||||
|
||||
<h4><a href="demo/basic.html">Basic Scrollbars Demo</a></h4>
|
||||
<h4><a href="demo/advanced.html">Advanced Scrollbars Demo</a></h4>
|
||||
<h4><a href="demo/angular.html">jQuery Scrollbars as AngularJS directive</a></h4>
|
||||
<h4><a href="https://github.com/gromo/jquery.scrollbar/archive/gh-pages.zip">Download example</a></h4>
|
||||
|
||||
<h3>Easy to implement</h3>
|
||||
<p>
|
||||
Go to the demo pages, find a scrollbar that fits your needs, copy the HTML/CSS/JavaScript and paste it to your page.
|
||||
Modify CSS styles to change scrollbar colors/sizes. If you can't find a scrollbar that fits your needs, contact the
|
||||
author and your scrollbar will be added to the demo page.
|
||||
</p>
|
||||
|
||||
<h3>No fixed height or width needed</h3>
|
||||
<p>
|
||||
Most of the scrollbar plugins require container height or width to be set in order to calculate scrollbar sizes.
|
||||
jQuery Scrollbar does not require height, nor width. You can use max-height/max-width to restrict
|
||||
container sizes, or use standard height/width in pixels/percents in the parent container.
|
||||
</p>
|
||||
|
||||
<h3>Supports responsive design</h3>
|
||||
<p>
|
||||
jQuery Scrollbar can be used in responsive designs as there is no need to set fixed height/width to the container.
|
||||
Scrollbars will be automatically updated/hidden/displayed when content or container size changes.
|
||||
</p>
|
||||
|
||||
<h3>Customizable CSS</h3>
|
||||
<p>
|
||||
Use CSS to customize scrollbar colors, sizes or positions. Use simple or advanced HTML structure to
|
||||
customize how scrollbars should look. If simple or advanced HTML structure is not what you are looking for,
|
||||
you can use your own HTML structure with custom elements.
|
||||
</p>
|
||||
|
||||
<h3>Standard browser scroll behaviour</h3>
|
||||
<p>
|
||||
If your browser can scroll content, jQuery Scrollbar will scroll it too! Why? Because it does not emulate
|
||||
browser scroll behaviour as many plugins do, instead hides standard scrollbars and displays custom ones. You want
|
||||
to scroll with mouse middle button? – Just use it! You want to scroll with touch? – Do it! Your browser
|
||||
supports custom scroll behavior? – Use it too! Use the standard or jQuery scrollTop/scrollLeft functions to get
|
||||
current scroll offset or scroll to any position. Use the standard "scroll" event to handle content scrolling.
|
||||
You don't need to know custom functions/events – everything is done based on standard scroll behaviour.
|
||||
</p>
|
||||
|
||||
<h3>Supports vertical and horizontal scrollbars or both</h3>
|
||||
<p>
|
||||
Most of the scrollbar plugins allow using either vertical or horizontal scrollbars.
|
||||
Only a few can use both vertical and horizontal scrollbars and they are using scroll emulation
|
||||
which has limitations. jQuery Scrollbar does not emulate scroll behaviour. Also it can work
|
||||
with both vertical and horizontal scrollbars together.
|
||||
</p>
|
||||
|
||||
<h3>Automatically re-initializes scrollbars</h3>
|
||||
<p>
|
||||
Usually scrollbar size and positions are calculated when plugin is initialized. What if content or container
|
||||
size is changed with javascript/ajax? - You have to update plugin to recalculate scrollbar sizes. And it's
|
||||
OK because you know when content is changed. But what to do if you don't know when it is changed? For
|
||||
example, if content contains images without height/width. These images change content size after loading.
|
||||
There are 3 obvious ways: always set image height/width (and force users to set image size for content added
|
||||
with WYSIWYG editor), wait for whole page to load and then initialize scrollbars or handle content images
|
||||
loading and then re-initialize scrollbar plugin. Annoying, isn't it?
|
||||
</p>
|
||||
<p>
|
||||
jQuery Scrollbar handles content/container size changes and recalculate scrollbar sizes automatically. Just
|
||||
initialize it once and forget about it.
|
||||
</p>
|
||||
|
||||
<h3>Supports external scrollbars</h3>
|
||||
<p>
|
||||
jQuery Scrollbar supports 3 types of scrollbars: <strong>inner</strong> — scrollbar is displayed over
|
||||
content (Apple Mac OS); <strong>outer</strong> — scrollbar shifts content to display itself (Microsoft
|
||||
Windows scrollbars); <strong>external</strong> — scrollbar is located in any place of your page. So,
|
||||
you can choose between Apple Mac and Windows style scrollbar or even place it outside of the container and
|
||||
style it as you wish. Cool, isn't it?
|
||||
</p>
|
||||
|
||||
<h3>Provides a AngularJS directive</h3>
|
||||
<p>
|
||||
Now you can easily use jQuery Scrollbar with AngularJS as directive. Just include module <em>jQueryScrollbar</em>
|
||||
as dependency in your module, and you can use jQuery Scrollbar on your container with attribute
|
||||
<em>data-jquery-scrollbar</em>. <a href="demo/angular.html">jQuery Scrollbar as AngularJS directive</a>.
|
||||
</p>
|
||||
|
||||
<h3>Textarea scrollbars</h3>
|
||||
<p>
|
||||
Apply jQuery Scrollbar to your textarea and enjoy CSS styled scrollbars. Supports IE8+. Fixed height/width are required.
|
||||
</p>
|
||||
|
||||
<h3>Browser support: IE7+, Edge, Firefox, Opera, Chrome, Safari</h3>
|
||||
<p>
|
||||
Of course all modern browsers are supported starting from IE7. The most problematic browser is IE, as you
|
||||
already suspect. But it's not IE7, it's IE8! Surprised? I was! IE7 works better with height/width
|
||||
calculations than IE8. IE8 renderer is crashed when using <em>max-height</em> with <em>overflow:auto</em>.
|
||||
It is officially logged as a <a href="https://www.google.com/#q=IE8+max+height+crash" target="_blank">bug</a>
|
||||
in the final version of IE8 with no fix. There are also other bugs with max-height/max-width and positioning.
|
||||
So, be careful if you are going to support IE8.
|
||||
</p>
|
||||
|
||||
<h4>Advanced features that standard scroll has, but scroll emulation plugins have to emulate or don't have at all</h4>
|
||||
<ul>
|
||||
<li>mouse middle button / touch / arrow buttons scrolling</li>
|
||||
<li>auto content scrolling when selecting text</li>
|
||||
<li>auto scrolling to focused element</li>
|
||||
</ul>
|
||||
|
||||
<h2>jQuery Scrollbar Options</h2>
|
||||
<ul>
|
||||
<li>
|
||||
<strong>autoScrollSize</strong> [true|false] (default: true)<br/>
|
||||
automatically calculate scrollbar size depending on container/content size
|
||||
</li>
|
||||
<li>
|
||||
<strong>autoUpdate</strong> [true|false] (default: true)<br/>
|
||||
automatically update scrollbar if container/content size is changed
|
||||
</li>
|
||||
<li>
|
||||
<strong>disableBodyScroll</strong> [true|false] (default: false)<br/>
|
||||
if this option is enabled and the mouse is over the scrollable container, the main page won't be scrolled
|
||||
</li>
|
||||
<li>
|
||||
<strong>duration</strong> [ms] (default: 200)<br/>
|
||||
scroll speed duration when the mouse is over scrollbar (scroll emulating mode)
|
||||
</li>
|
||||
<li>
|
||||
<strong>ignoreMobile</strong> [true|false] (default: false)<br/>
|
||||
do not initialize custom scrollbars on mobile devices
|
||||
</li>
|
||||
<li>
|
||||
<strong>ignoreOverlay</strong> [true|false] (default: false)<br/>
|
||||
do not initialize custom scrollbars in browsers when native scrollbars
|
||||
overlay content (Mac OS, mobile devices, etc...)
|
||||
</li>
|
||||
<li>
|
||||
<strong>scrollStep</strong> [px] (default: 30)<br/>
|
||||
scroll step when the mouse is over the scrollbar (scroll emulating mode)
|
||||
</li>
|
||||
<li>
|
||||
<strong>showArrows</strong> [true|false] (default: false)<br/>
|
||||
add a class to show scrollbar arrows in the advanced scrollbar
|
||||
</li>
|
||||
<li>
|
||||
<strong>stepScrolling</strong> [true|false] (default: true)<br/>
|
||||
emulate step scrolling on mousedown over scrollbar
|
||||
</li>
|
||||
<li>
|
||||
<strong>scrollx</strong> [string|element] (default: simple)<br/>
|
||||
<i>simple</i>, <i>advanced</i>, HTML or jQuery element for horizontal scrollbar
|
||||
</li>
|
||||
<li>
|
||||
<strong>scrolly</strong> [string|element] (default: simple)<br/>
|
||||
<i>simple</i>, <i>advanced</i>, HTML or jQuery element for vertical scrollbar
|
||||
</li>
|
||||
<li>
|
||||
<strong>onDestroy</strong> [function] (default: null)<br/>
|
||||
callback function when scrollbar is destroyed
|
||||
</li>
|
||||
<li>
|
||||
<strong>onInit</strong> [function] (default: null)<br/>
|
||||
callback function when scrollbar is initialized at the first time
|
||||
</li>
|
||||
<li>
|
||||
<strong>onScroll</strong> [function] (default: null)<br/>
|
||||
callback function when container is scrolled
|
||||
</li>
|
||||
<li>
|
||||
<strong>onUpdate</strong> [function] (default: null)<br/>
|
||||
callback function before scrollbars size is calculated
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
<h2>Limitations</h2>
|
||||
<ul>
|
||||
<li>scrollable elements should not have paddings, margins, left/top values</li>
|
||||
<li>do not use max-height in IE8 – it crashes browser renderer</li>
|
||||
<li>custom scroll is not initialized in Firefox under MacOS because of a bug while hiding native overlay scrollbar</li>
|
||||
<li>custom scroll works incorrectly if containers children's height is set in percent of parent (issue <a href="https://github.com/gromo/jquery.scrollbar/issues/57">#57</a>)</li>
|
||||
</ul>
|
||||
|
||||
<h2>FAQ</h2>
|
||||
<ol>
|
||||
<li>
|
||||
<p>
|
||||
<strong>Question:</strong> I need padding between border/scrollbar and text, but scrollbar does not
|
||||
allow it. What should I do?
|
||||
</p>
|
||||
<p>
|
||||
<strong>Answer:</strong> Wrap the inner content in the div with padding
|
||||
</p>
|
||||
</li>
|
||||
<li>
|
||||
<p>
|
||||
<strong>Question:</strong> I need space between content with scrollbar and the rest of the page.
|
||||
What should I do?
|
||||
</p>
|
||||
<p>
|
||||
<strong>Answer:</strong> Wrap the scrollable content into container with padding.
|
||||
</p>
|
||||
</li>
|
||||
<li>
|
||||
<p>
|
||||
<strong>Question:</strong> If content contains images, content size can be changed after images will
|
||||
be loaded. Should I re-initialize scrollbar?
|
||||
</p>
|
||||
<p>
|
||||
<strong>Answer:</strong> No, scrollbar detects content/container size changes automatically and
|
||||
recalculates its size or hides/shows scrollbars.
|
||||
</p>
|
||||
</li>
|
||||
<li>
|
||||
<p>
|
||||
<strong>Question:</strong> How can I scroll content to a custom position?
|
||||
</p>
|
||||
<p>
|
||||
<strong>Answer:</strong> Use standard jQuery scrollTop/scrollLeft functions on the container.
|
||||
For example if you have a container with a class "scrollbar-macosx" use the following code to scroll 50px from top:
|
||||
<pre class="prettyprint linenums lang-js">
|
||||
jQuery('.scrollbar-macosx').scrollTop(50);</pre>
|
||||
</p>
|
||||
</li>
|
||||
<li>
|
||||
<p>
|
||||
<strong>Question:</strong> I want to know when the content is scrolled. Is there any callback for this?
|
||||
</p>
|
||||
<p>
|
||||
<strong>Answer:</strong> Yes, you can use "onScroll" callback (look at AngularJS example),
|
||||
or use the standard "scroll" event on the container. For example you have a container with a class
|
||||
"scrollbar-macosx", then use the following code to handle the scroll event:
|
||||
<pre class="prettyprint linenums lang-js">
|
||||
jQuery('.scrollbar-macosx').not('.scroll-wrapper').on("scroll", function(){
|
||||
console.log('content is scrolling');
|
||||
});</pre>
|
||||
</p>
|
||||
</li>
|
||||
<li>
|
||||
<p>
|
||||
<strong>Question:</strong> The scrollbar does not replace the standard scrollbar. What should I do?
|
||||
</p>
|
||||
<p>
|
||||
<strong>Answer:</strong> It's not a good idea to replace the standard scrollbar for a whole page. But if you
|
||||
really need it, wrap all page into container with height/width 100%, overflow: auto and apply
|
||||
the scrollbar to this container.
|
||||
</p>
|
||||
</li>
|
||||
<li>
|
||||
<p>
|
||||
<strong>Question:</strong> I don't want to see horizontal scrollbar ever. What should I do?
|
||||
</p>
|
||||
<p>
|
||||
<strong>Answer:</strong> Hide it with CSS like this:
|
||||
<pre class="prettyprint linenums lang-css">
|
||||
.scroll-element.scroll-x {
|
||||
display: none !important;
|
||||
}</pre>
|
||||
But don't forget that even if the scrollbar is hidden, the content still may be scrollable horizontally.
|
||||
</p>
|
||||
</li>
|
||||
<li>
|
||||
<p>
|
||||
<strong>Question:</strong> Using jQuery's .width() or .height() on a container
|
||||
will return incorrect values. What is going on?
|
||||
</p>
|
||||
<p>
|
||||
<strong>Answer:</strong> Inner scrollable content uses additional height/width & offset of the scrollbar
|
||||
to hide it. To get correct height/width values use the visible container:
|
||||
<pre class="prettyprint linenums lang-js">
|
||||
jQuery('.scrollbar-macosx').not('.scroll-content').height();
|
||||
jQuery('.scrollbar-macosx').not('.scroll-content').width();</pre>
|
||||
</p>
|
||||
</li>
|
||||
<li>
|
||||
<p>
|
||||
<strong>Question:</strong> How to detect when a DIV is scrolled to the bottom edge?
|
||||
</p>
|
||||
<p>
|
||||
<strong>Answer:</strong> You can make calculations using jQuery's "scroll" event or you can use
|
||||
the "onScroll" callback function that provides information about container's sizes & offset:
|
||||
<pre class="prettyprint linenums lang-js">
|
||||
jQuery('.scrollbar-dynamic').scrollbar({
|
||||
"onScroll": function(y, x){
|
||||
if(y.scroll == y.maxScroll){
|
||||
console.log('Scrolled to bottom');
|
||||
}
|
||||
}
|
||||
});</pre>
|
||||
</p>
|
||||
</li>
|
||||
<li>
|
||||
<p>
|
||||
<strong>Question:</strong> Can I use jQuery Scrollbar to customize textarea scrollbar?
|
||||
</p>
|
||||
<p>
|
||||
<strong>Answer:</strong> Yes, you can. Textarea scrollbars are supported now.
|
||||
Look at <a href="demo/basic.html">Basic Scrollbars Demo</a> page.
|
||||
</p>
|
||||
</li>
|
||||
<li>
|
||||
<p>
|
||||
<strong>Question:</strong> Is it possible to set scrollbars max/min size?
|
||||
</p>
|
||||
<p>
|
||||
<strong>Answer:</strong> Use CSS max-height/min-height (max-width/min-width) to set scrollbar size limits.
|
||||
</p>
|
||||
</li>
|
||||
<li>
|
||||
<p>
|
||||
<strong>Question:</strong> I have a question / want to report an issue. How can I contact the author?
|
||||
</p>
|
||||
<p>
|
||||
<strong>Answer:</strong> Please send an email to <a href="mailto:13real008@gmail.com">13real008@gmail.com</a>
|
||||
</p>
|
||||
</li>
|
||||
</ol>
|
||||
|
||||
<h5 style="display:none;">
|
||||
<a href="https://docs.google.com/spreadsheet/ccc?key=0Ao4HbHsCLP0YdEhnZVh1WGZSbXloekZiNWlaNElnTnc&usp=sharing"
|
||||
target="_blank">Compare with other popular scrollbars</a>
|
||||
</h5>
|
||||
</div>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
791
assets/js/vendor/jquery.scrollbar/jquery.scrollbar.css
vendored
Normal file
791
assets/js/vendor/jquery.scrollbar/jquery.scrollbar.css
vendored
Normal file
@@ -0,0 +1,791 @@
|
||||
/*************** SCROLLBAR BASE CSS ***************/
|
||||
|
||||
.scroll-wrapper {
|
||||
overflow: hidden !important;
|
||||
padding: 0 !important;
|
||||
position: relative;
|
||||
}
|
||||
|
||||
.scroll-wrapper > .scroll-content {
|
||||
border: none !important;
|
||||
box-sizing: content-box !important;
|
||||
height: auto;
|
||||
left: 0;
|
||||
margin: 0;
|
||||
max-height: none;
|
||||
max-width: none !important;
|
||||
overflow: scroll !important;
|
||||
padding: 0;
|
||||
position: relative !important;
|
||||
top: 0;
|
||||
width: auto !important;
|
||||
}
|
||||
|
||||
.scroll-wrapper > .scroll-content::-webkit-scrollbar {
|
||||
height: 0;
|
||||
width: 0;
|
||||
}
|
||||
|
||||
.scroll-element {
|
||||
display: none;
|
||||
}
|
||||
.scroll-element, .scroll-element div {
|
||||
box-sizing: content-box;
|
||||
}
|
||||
|
||||
.scroll-element.scroll-x.scroll-scrollx_visible,
|
||||
.scroll-element.scroll-y.scroll-scrolly_visible {
|
||||
display: block;
|
||||
}
|
||||
|
||||
.scroll-element .scroll-bar,
|
||||
.scroll-element .scroll-arrow {
|
||||
cursor: default;
|
||||
}
|
||||
|
||||
.scroll-textarea {
|
||||
border: 1px solid #cccccc;
|
||||
border-top-color: #999999;
|
||||
}
|
||||
.scroll-textarea > .scroll-content {
|
||||
overflow: hidden !important;
|
||||
}
|
||||
.scroll-textarea > .scroll-content > textarea {
|
||||
border: none !important;
|
||||
box-sizing: border-box;
|
||||
height: 100% !important;
|
||||
margin: 0;
|
||||
max-height: none !important;
|
||||
max-width: none !important;
|
||||
overflow: scroll !important;
|
||||
outline: none;
|
||||
padding: 2px;
|
||||
position: relative !important;
|
||||
top: 0;
|
||||
width: 100% !important;
|
||||
}
|
||||
.scroll-textarea > .scroll-content > textarea::-webkit-scrollbar {
|
||||
height: 0;
|
||||
width: 0;
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
/*************** SIMPLE INNER SCROLLBAR ***************/
|
||||
|
||||
.scrollbar-inner > .scroll-element,
|
||||
.scrollbar-inner > .scroll-element div
|
||||
{
|
||||
border: none;
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
position: absolute;
|
||||
z-index: 10;
|
||||
}
|
||||
|
||||
.scrollbar-inner > .scroll-element div {
|
||||
display: block;
|
||||
height: 100%;
|
||||
left: 0;
|
||||
top: 0;
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.scrollbar-inner > .scroll-element.scroll-x {
|
||||
bottom: 2px;
|
||||
height: 8px;
|
||||
left: 0;
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.scrollbar-inner > .scroll-element.scroll-y {
|
||||
height: 100%;
|
||||
right: 2px;
|
||||
top: 0;
|
||||
width: 8px;
|
||||
}
|
||||
|
||||
.scrollbar-inner > .scroll-element .scroll-element_outer {
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
.scrollbar-inner > .scroll-element .scroll-element_outer,
|
||||
.scrollbar-inner > .scroll-element .scroll-element_track,
|
||||
.scrollbar-inner > .scroll-element .scroll-bar {
|
||||
-webkit-border-radius: 8px;
|
||||
-moz-border-radius: 8px;
|
||||
border-radius: 8px;
|
||||
}
|
||||
|
||||
.scrollbar-inner > .scroll-element .scroll-element_track,
|
||||
.scrollbar-inner > .scroll-element .scroll-bar {
|
||||
-ms-filter:"progid:DXImageTransform.Microsoft.Alpha(Opacity=40)";
|
||||
filter: alpha(opacity=40);
|
||||
opacity: 0.4;
|
||||
}
|
||||
|
||||
.scrollbar-inner > .scroll-element .scroll-element_track { background-color: #e0e0e0; }
|
||||
.scrollbar-inner > .scroll-element .scroll-bar { background-color: #c2c2c2; }
|
||||
.scrollbar-inner > .scroll-element:hover .scroll-bar { background-color: #919191; }
|
||||
.scrollbar-inner > .scroll-element.scroll-draggable .scroll-bar { background-color: #919191; }
|
||||
|
||||
|
||||
/* update scrollbar offset if both scrolls are visible */
|
||||
|
||||
.scrollbar-inner > .scroll-element.scroll-x.scroll-scrolly_visible .scroll-element_track { left: -12px; }
|
||||
.scrollbar-inner > .scroll-element.scroll-y.scroll-scrollx_visible .scroll-element_track { top: -12px; }
|
||||
|
||||
|
||||
.scrollbar-inner > .scroll-element.scroll-x.scroll-scrolly_visible .scroll-element_size { left: -12px; }
|
||||
.scrollbar-inner > .scroll-element.scroll-y.scroll-scrollx_visible .scroll-element_size { top: -12px; }
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
/*************** SIMPLE OUTER SCROLLBAR ***************/
|
||||
|
||||
.scrollbar-outer > .scroll-element,
|
||||
.scrollbar-outer > .scroll-element div
|
||||
{
|
||||
border: none;
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
position: absolute;
|
||||
z-index: 10;
|
||||
}
|
||||
|
||||
.scrollbar-outer > .scroll-element {
|
||||
background-color: #ffffff;
|
||||
}
|
||||
|
||||
.scrollbar-outer > .scroll-element div {
|
||||
display: block;
|
||||
height: 100%;
|
||||
left: 0;
|
||||
top: 0;
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.scrollbar-outer > .scroll-element.scroll-x {
|
||||
bottom: 0;
|
||||
height: 12px;
|
||||
left: 0;
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.scrollbar-outer > .scroll-element.scroll-y {
|
||||
height: 100%;
|
||||
right: 0;
|
||||
top: 0;
|
||||
width: 12px;
|
||||
}
|
||||
|
||||
.scrollbar-outer > .scroll-element.scroll-x .scroll-element_outer { height: 8px; top: 2px; }
|
||||
.scrollbar-outer > .scroll-element.scroll-y .scroll-element_outer { left: 2px; width: 8px; }
|
||||
|
||||
.scrollbar-outer > .scroll-element .scroll-element_outer { overflow: hidden; }
|
||||
.scrollbar-outer > .scroll-element .scroll-element_track { background-color: #eeeeee; }
|
||||
|
||||
.scrollbar-outer > .scroll-element .scroll-element_outer,
|
||||
.scrollbar-outer > .scroll-element .scroll-element_track,
|
||||
.scrollbar-outer > .scroll-element .scroll-bar {
|
||||
-webkit-border-radius: 8px;
|
||||
-moz-border-radius: 8px;
|
||||
border-radius: 8px;
|
||||
}
|
||||
|
||||
.scrollbar-outer > .scroll-element .scroll-bar { background-color: #d9d9d9; }
|
||||
.scrollbar-outer > .scroll-element .scroll-bar:hover { background-color: #c2c2c2; }
|
||||
.scrollbar-outer > .scroll-element.scroll-draggable .scroll-bar { background-color: #919191; }
|
||||
|
||||
|
||||
/* scrollbar height/width & offset from container borders */
|
||||
|
||||
.scrollbar-outer > .scroll-content.scroll-scrolly_visible { left: -12px; margin-left: 12px; }
|
||||
.scrollbar-outer > .scroll-content.scroll-scrollx_visible { top: -12px; margin-top: 12px; }
|
||||
|
||||
.scrollbar-outer > .scroll-element.scroll-x .scroll-bar { min-width: 10px; }
|
||||
.scrollbar-outer > .scroll-element.scroll-y .scroll-bar { min-height: 10px; }
|
||||
|
||||
|
||||
/* update scrollbar offset if both scrolls are visible */
|
||||
|
||||
.scrollbar-outer > .scroll-element.scroll-x.scroll-scrolly_visible .scroll-element_track { left: -14px; }
|
||||
.scrollbar-outer > .scroll-element.scroll-y.scroll-scrollx_visible .scroll-element_track { top: -14px; }
|
||||
|
||||
.scrollbar-outer > .scroll-element.scroll-x.scroll-scrolly_visible .scroll-element_size { left: -14px; }
|
||||
.scrollbar-outer > .scroll-element.scroll-y.scroll-scrollx_visible .scroll-element_size { top: -14px; }
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
/*************** SCROLLBAR MAC OS X ***************/
|
||||
|
||||
.scrollbar-macosx > .scroll-element,
|
||||
.scrollbar-macosx > .scroll-element div
|
||||
{
|
||||
background: none;
|
||||
border: none;
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
position: absolute;
|
||||
z-index: 10;
|
||||
}
|
||||
|
||||
.scrollbar-macosx > .scroll-element div {
|
||||
display: block;
|
||||
height: 100%;
|
||||
left: 0;
|
||||
top: 0;
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.scrollbar-macosx > .scroll-element .scroll-element_track { display: none; }
|
||||
.scrollbar-macosx > .scroll-element .scroll-bar {
|
||||
background-color: #6C6E71;
|
||||
display: block;
|
||||
|
||||
-ms-filter:"progid:DXImageTransform.Microsoft.Alpha(Opacity=0)";
|
||||
filter: alpha(opacity=0);
|
||||
opacity: 0;
|
||||
|
||||
-webkit-border-radius: 7px;
|
||||
-moz-border-radius: 7px;
|
||||
border-radius: 7px;
|
||||
|
||||
-webkit-transition: opacity 0.2s linear;
|
||||
-moz-transition: opacity 0.2s linear;
|
||||
-o-transition: opacity 0.2s linear;
|
||||
-ms-transition: opacity 0.2s linear;
|
||||
transition: opacity 0.2s linear;
|
||||
}
|
||||
.scrollbar-macosx:hover > .scroll-element .scroll-bar,
|
||||
.scrollbar-macosx > .scroll-element.scroll-draggable .scroll-bar {
|
||||
-ms-filter:"progid:DXImageTransform.Microsoft.Alpha(Opacity=70)";
|
||||
filter: alpha(opacity=70);
|
||||
opacity: 0.7;
|
||||
}
|
||||
|
||||
|
||||
.scrollbar-macosx > .scroll-element.scroll-x {
|
||||
bottom: 0px;
|
||||
height: 0px;
|
||||
left: 0;
|
||||
min-width: 100%;
|
||||
overflow: visible;
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.scrollbar-macosx > .scroll-element.scroll-y {
|
||||
height: 100%;
|
||||
min-height: 100%;
|
||||
right: 0px;
|
||||
top: 0;
|
||||
width: 0px;
|
||||
}
|
||||
|
||||
/* scrollbar height/width & offset from container borders */
|
||||
.scrollbar-macosx > .scroll-element.scroll-x .scroll-bar { height: 7px; min-width: 10px; top: -9px; }
|
||||
.scrollbar-macosx > .scroll-element.scroll-y .scroll-bar { left: -9px; min-height: 10px; width: 7px; }
|
||||
|
||||
.scrollbar-macosx > .scroll-element.scroll-x .scroll-element_outer { left: 2px; }
|
||||
.scrollbar-macosx > .scroll-element.scroll-x .scroll-element_size { left: -4px; }
|
||||
|
||||
.scrollbar-macosx > .scroll-element.scroll-y .scroll-element_outer { top: 2px; }
|
||||
.scrollbar-macosx > .scroll-element.scroll-y .scroll-element_size { top: -4px; }
|
||||
|
||||
/* update scrollbar offset if both scrolls are visible */
|
||||
.scrollbar-macosx > .scroll-element.scroll-x.scroll-scrolly_visible .scroll-element_size { left: -11px; }
|
||||
.scrollbar-macosx > .scroll-element.scroll-y.scroll-scrollx_visible .scroll-element_size { top: -11px; }
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
/*************** SCROLLBAR LIGHT ***************/
|
||||
|
||||
.scrollbar-light > .scroll-element,
|
||||
.scrollbar-light > .scroll-element div {
|
||||
border: none;
|
||||
margin: 0;
|
||||
overflow: hidden;
|
||||
padding: 0;
|
||||
position: absolute;
|
||||
z-index: 10;
|
||||
}
|
||||
|
||||
.scrollbar-light > .scroll-element {
|
||||
background-color: #ffffff;
|
||||
}
|
||||
|
||||
.scrollbar-light > .scroll-element div {
|
||||
display: block;
|
||||
height: 100%;
|
||||
left: 0;
|
||||
top: 0;
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.scrollbar-light > .scroll-element .scroll-element_outer {
|
||||
-webkit-border-radius: 10px;
|
||||
-moz-border-radius: 10px;
|
||||
border-radius: 10px;
|
||||
}
|
||||
|
||||
.scrollbar-light > .scroll-element .scroll-element_size {
|
||||
background: #dbdbdb;
|
||||
background: url('data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiA/Pgo8c3ZnIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgd2lkdGg9IjEwMCUiIGhlaWdodD0iMTAwJSIgdmlld0JveD0iMCAwIDEgMSIgcHJlc2VydmVBc3BlY3RSYXRpbz0ibm9uZSI+CiAgPGxpbmVhckdyYWRpZW50IGlkPSJncmFkLXVjZ2ctZ2VuZXJhdGVkIiBncmFkaWVudFVuaXRzPSJ1c2VyU3BhY2VPblVzZSIgeDE9IjAlIiB5MT0iMCUiIHgyPSIxMDAlIiB5Mj0iMCUiPgogICAgPHN0b3Agb2Zmc2V0PSIwJSIgc3RvcC1jb2xvcj0iI2RiZGJkYiIgc3RvcC1vcGFjaXR5PSIxIi8+CiAgICA8c3RvcCBvZmZzZXQ9IjEwMCUiIHN0b3AtY29sb3I9IiNlOGU4ZTgiIHN0b3Atb3BhY2l0eT0iMSIvPgogIDwvbGluZWFyR3JhZGllbnQ+CiAgPHJlY3QgeD0iMCIgeT0iMCIgd2lkdGg9IjEiIGhlaWdodD0iMSIgZmlsbD0idXJsKCNncmFkLXVjZ2ctZ2VuZXJhdGVkKSIgLz4KPC9zdmc+');
|
||||
background: -moz-linear-gradient(left, #dbdbdb 0%, #e8e8e8 100%);
|
||||
background: -webkit-gradient(linear, left top, right top, color-stop(0%,#dbdbdb), color-stop(100%,#e8e8e8));
|
||||
background: -webkit-linear-gradient(left, #dbdbdb 0%,#e8e8e8 100%);
|
||||
background: -o-linear-gradient(left, #dbdbdb 0%,#e8e8e8 100%);
|
||||
background: -ms-linear-gradient(left, #dbdbdb 0%,#e8e8e8 100%);
|
||||
background: linear-gradient(to right, #dbdbdb 0%,#e8e8e8 100%);
|
||||
|
||||
-webkit-border-radius: 10px;
|
||||
-moz-border-radius: 10px;
|
||||
border-radius: 10px;
|
||||
}
|
||||
|
||||
.scrollbar-light > .scroll-element.scroll-x {
|
||||
bottom: 0;
|
||||
height: 17px;
|
||||
left: 0;
|
||||
min-width: 100%;
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.scrollbar-light > .scroll-element.scroll-y {
|
||||
height: 100%;
|
||||
min-height: 100%;
|
||||
right: 0;
|
||||
top: 0;
|
||||
width: 17px;
|
||||
}
|
||||
|
||||
.scrollbar-light > .scroll-element .scroll-bar {
|
||||
background: #fefefe;
|
||||
background: url('data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiA/Pgo8c3ZnIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgd2lkdGg9IjEwMCUiIGhlaWdodD0iMTAwJSIgdmlld0JveD0iMCAwIDEgMSIgcHJlc2VydmVBc3BlY3RSYXRpbz0ibm9uZSI+CiAgPGxpbmVhckdyYWRpZW50IGlkPSJncmFkLXVjZ2ctZ2VuZXJhdGVkIiBncmFkaWVudFVuaXRzPSJ1c2VyU3BhY2VPblVzZSIgeDE9IjAlIiB5MT0iMCUiIHgyPSIxMDAlIiB5Mj0iMCUiPgogICAgPHN0b3Agb2Zmc2V0PSIwJSIgc3RvcC1jb2xvcj0iI2ZlZmVmZSIgc3RvcC1vcGFjaXR5PSIxIi8+CiAgICA8c3RvcCBvZmZzZXQ9IjEwMCUiIHN0b3AtY29sb3I9IiNmNWY1ZjUiIHN0b3Atb3BhY2l0eT0iMSIvPgogIDwvbGluZWFyR3JhZGllbnQ+CiAgPHJlY3QgeD0iMCIgeT0iMCIgd2lkdGg9IjEiIGhlaWdodD0iMSIgZmlsbD0idXJsKCNncmFkLXVjZ2ctZ2VuZXJhdGVkKSIgLz4KPC9zdmc+');
|
||||
background: -moz-linear-gradient(left, #fefefe 0%, #f5f5f5 100%);
|
||||
background: -webkit-gradient(linear, left top, right top, color-stop(0%,#fefefe), color-stop(100%,#f5f5f5));
|
||||
background: -webkit-linear-gradient(left, #fefefe 0%,#f5f5f5 100%);
|
||||
background: -o-linear-gradient(left, #fefefe 0%,#f5f5f5 100%);
|
||||
background: -ms-linear-gradient(left, #fefefe 0%,#f5f5f5 100%);
|
||||
background: linear-gradient(to right, #fefefe 0%,#f5f5f5 100%);
|
||||
|
||||
border: 1px solid #dbdbdb;
|
||||
-webkit-border-radius: 10px;
|
||||
-moz-border-radius: 10px;
|
||||
border-radius: 10px;
|
||||
}
|
||||
|
||||
/* scrollbar height/width & offset from container borders */
|
||||
|
||||
.scrollbar-light > .scroll-content.scroll-scrolly_visible { left: -17px; margin-left: 17px; }
|
||||
.scrollbar-light > .scroll-content.scroll-scrollx_visible { top: -17px; margin-top: 17px; }
|
||||
|
||||
.scrollbar-light > .scroll-element.scroll-x .scroll-bar { height: 10px; min-width: 10px; top: 0px; }
|
||||
.scrollbar-light > .scroll-element.scroll-y .scroll-bar { left: 0px; min-height: 10px; width: 10px; }
|
||||
|
||||
.scrollbar-light > .scroll-element.scroll-x .scroll-element_outer { height: 12px; left: 2px; top: 2px; }
|
||||
.scrollbar-light > .scroll-element.scroll-x .scroll-element_size { left: -4px; }
|
||||
|
||||
.scrollbar-light > .scroll-element.scroll-y .scroll-element_outer { left: 2px; top: 2px; width: 12px; }
|
||||
.scrollbar-light > .scroll-element.scroll-y .scroll-element_size { top: -4px; }
|
||||
|
||||
/* update scrollbar offset if both scrolls are visible */
|
||||
|
||||
.scrollbar-light > .scroll-element.scroll-x.scroll-scrolly_visible .scroll-element_size { left: -19px; }
|
||||
.scrollbar-light > .scroll-element.scroll-y.scroll-scrollx_visible .scroll-element_size { top: -19px; }
|
||||
|
||||
.scrollbar-light > .scroll-element.scroll-x.scroll-scrolly_visible .scroll-element_track { left: -19px; }
|
||||
.scrollbar-light > .scroll-element.scroll-y.scroll-scrollx_visible .scroll-element_track { top: -19px; }
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
/*************** SCROLLBAR RAIL ***************/
|
||||
|
||||
.scrollbar-rail > .scroll-element,
|
||||
.scrollbar-rail > .scroll-element div
|
||||
{
|
||||
border: none;
|
||||
margin: 0;
|
||||
overflow: hidden;
|
||||
padding: 0;
|
||||
position: absolute;
|
||||
z-index: 10;
|
||||
}
|
||||
|
||||
.scrollbar-rail > .scroll-element {
|
||||
background-color: #ffffff;
|
||||
}
|
||||
|
||||
.scrollbar-rail > .scroll-element div {
|
||||
display: block;
|
||||
height: 100%;
|
||||
left: 0;
|
||||
top: 0;
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.scrollbar-rail > .scroll-element .scroll-element_size {
|
||||
background-color: #999;
|
||||
background-color: rgba(0, 0, 0, 0.3);
|
||||
}
|
||||
|
||||
.scrollbar-rail > .scroll-element .scroll-element_outer:hover .scroll-element_size {
|
||||
background-color: #666;
|
||||
background-color: rgba(0, 0, 0, 0.5);
|
||||
}
|
||||
|
||||
.scrollbar-rail > .scroll-element.scroll-x {
|
||||
bottom: 0;
|
||||
height: 12px;
|
||||
left: 0;
|
||||
min-width: 100%;
|
||||
padding: 3px 0 2px;
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.scrollbar-rail > .scroll-element.scroll-y {
|
||||
height: 100%;
|
||||
min-height: 100%;
|
||||
padding: 0 2px 0 3px;
|
||||
right: 0;
|
||||
top: 0;
|
||||
width: 12px;
|
||||
}
|
||||
|
||||
.scrollbar-rail > .scroll-element .scroll-bar {
|
||||
background-color: #d0b9a0;
|
||||
|
||||
-webkit-border-radius: 2px;
|
||||
-moz-border-radius: 2px;
|
||||
border-radius: 2px;
|
||||
|
||||
box-shadow: 1px 1px 3px rgba(0, 0, 0, 0.5);
|
||||
}
|
||||
|
||||
.scrollbar-rail > .scroll-element .scroll-element_outer:hover .scroll-bar {
|
||||
box-shadow: 1px 1px 3px rgba(0, 0, 0, 0.6);
|
||||
}
|
||||
|
||||
/* scrollbar height/width & offset from container borders */
|
||||
|
||||
.scrollbar-rail > .scroll-content.scroll-scrolly_visible { left: -17px; margin-left: 17px; }
|
||||
.scrollbar-rail > .scroll-content.scroll-scrollx_visible { margin-top: 17px; top: -17px; }
|
||||
|
||||
.scrollbar-rail > .scroll-element.scroll-x .scroll-bar { height: 10px; min-width: 10px; top: 1px; }
|
||||
.scrollbar-rail > .scroll-element.scroll-y .scroll-bar { left: 1px; min-height: 10px; width: 10px; }
|
||||
|
||||
.scrollbar-rail > .scroll-element.scroll-x .scroll-element_outer { height: 15px; left: 5px; }
|
||||
.scrollbar-rail > .scroll-element.scroll-x .scroll-element_size { height: 2px; left: -10px; top: 5px; }
|
||||
|
||||
.scrollbar-rail > .scroll-element.scroll-y .scroll-element_outer { top: 5px; width: 15px; }
|
||||
.scrollbar-rail > .scroll-element.scroll-y .scroll-element_size { left: 5px; top: -10px; width: 2px; }
|
||||
|
||||
/* update scrollbar offset if both scrolls are visible */
|
||||
|
||||
.scrollbar-rail > .scroll-element.scroll-x.scroll-scrolly_visible .scroll-element_size { left: -25px; }
|
||||
.scrollbar-rail > .scroll-element.scroll-y.scroll-scrollx_visible .scroll-element_size { top: -25px; }
|
||||
|
||||
.scrollbar-rail > .scroll-element.scroll-x.scroll-scrolly_visible .scroll-element_track { left: -25px; }
|
||||
.scrollbar-rail > .scroll-element.scroll-y.scroll-scrollx_visible .scroll-element_track { top: -25px; }
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
/*************** SCROLLBAR DYNAMIC ***************/
|
||||
|
||||
.scrollbar-dynamic > .scroll-element,
|
||||
.scrollbar-dynamic > .scroll-element div
|
||||
{
|
||||
background: none;
|
||||
border: none;
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
position: absolute;
|
||||
z-index: 10;
|
||||
}
|
||||
|
||||
.scrollbar-dynamic > .scroll-element div {
|
||||
display: block;
|
||||
height: 100%;
|
||||
left: 0;
|
||||
top: 0;
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.scrollbar-dynamic > .scroll-element.scroll-x {
|
||||
bottom: 2px;
|
||||
height: 7px;
|
||||
left: 0;
|
||||
min-width: 100%;
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.scrollbar-dynamic > .scroll-element.scroll-y {
|
||||
height: 100%;
|
||||
min-height: 100%;
|
||||
right: 2px;
|
||||
top: 0;
|
||||
width: 7px;
|
||||
}
|
||||
|
||||
.scrollbar-dynamic > .scroll-element .scroll-element_outer {
|
||||
opacity: 0.3;
|
||||
|
||||
-webkit-border-radius: 12px;
|
||||
-moz-border-radius: 12px;
|
||||
border-radius: 12px;
|
||||
}
|
||||
.scrollbar-dynamic > .scroll-element .scroll-element_size {
|
||||
background-color: #cccccc;
|
||||
opacity: 0;
|
||||
|
||||
-webkit-border-radius: 12px;
|
||||
-moz-border-radius: 12px;
|
||||
border-radius: 12px;
|
||||
|
||||
-webkit-transition: opacity 0.2s;
|
||||
-moz-transition: opacity 0.2s;
|
||||
-o-transition: opacity 0.2s;
|
||||
-ms-transition: opacity 0.2s;
|
||||
transition: opacity 0.2s;
|
||||
}
|
||||
|
||||
.scrollbar-dynamic > .scroll-element .scroll-bar {
|
||||
background-color: #6c6e71;
|
||||
|
||||
-webkit-border-radius: 7px;
|
||||
-moz-border-radius: 7px;
|
||||
border-radius: 7px;
|
||||
}
|
||||
|
||||
/* scrollbar height/width & offset from container borders */
|
||||
|
||||
.scrollbar-dynamic > .scroll-element.scroll-x .scroll-bar {
|
||||
bottom: 0;
|
||||
height: 7px;
|
||||
min-width: 24px;
|
||||
top: auto;
|
||||
}
|
||||
.scrollbar-dynamic > .scroll-element.scroll-y .scroll-bar {
|
||||
left: auto;
|
||||
min-height: 24px;
|
||||
right: 0;
|
||||
width: 7px;
|
||||
}
|
||||
|
||||
.scrollbar-dynamic > .scroll-element.scroll-x .scroll-element_outer {
|
||||
bottom: 0;
|
||||
top: auto;
|
||||
left: 2px;
|
||||
|
||||
-webkit-transition: height 0.2s;
|
||||
-moz-transition: height 0.2s;
|
||||
-o-transition: height 0.2s;
|
||||
-ms-transition: height 0.2s;
|
||||
transition: height 0.2s;
|
||||
}
|
||||
|
||||
.scrollbar-dynamic > .scroll-element.scroll-y .scroll-element_outer {
|
||||
left: auto;
|
||||
right: 0;
|
||||
top: 2px;
|
||||
|
||||
-webkit-transition: width 0.2s;
|
||||
-moz-transition: width 0.2s;
|
||||
-o-transition: width 0.2s;
|
||||
-ms-transition: width 0.2s;
|
||||
transition: width 0.2s;
|
||||
}
|
||||
|
||||
.scrollbar-dynamic > .scroll-element.scroll-x .scroll-element_size { left: -4px; }
|
||||
.scrollbar-dynamic > .scroll-element.scroll-y .scroll-element_size { top: -4px; }
|
||||
|
||||
|
||||
/* update scrollbar offset if both scrolls are visible */
|
||||
|
||||
.scrollbar-dynamic > .scroll-element.scroll-x.scroll-scrolly_visible .scroll-element_size { left: -11px; }
|
||||
.scrollbar-dynamic > .scroll-element.scroll-y.scroll-scrollx_visible .scroll-element_size { top: -11px; }
|
||||
|
||||
|
||||
/* hover & drag */
|
||||
|
||||
.scrollbar-dynamic > .scroll-element:hover .scroll-element_outer,
|
||||
.scrollbar-dynamic > .scroll-element.scroll-draggable .scroll-element_outer {
|
||||
overflow: hidden;
|
||||
|
||||
-ms-filter:"progid:DXImageTransform.Microsoft.Alpha(Opacity=70)";
|
||||
filter: alpha(opacity=70);
|
||||
opacity: 0.7;
|
||||
}
|
||||
.scrollbar-dynamic > .scroll-element:hover .scroll-element_outer .scroll-element_size,
|
||||
.scrollbar-dynamic > .scroll-element.scroll-draggable .scroll-element_outer .scroll-element_size {
|
||||
opacity: 1;
|
||||
}
|
||||
.scrollbar-dynamic > .scroll-element:hover .scroll-element_outer .scroll-bar,
|
||||
.scrollbar-dynamic > .scroll-element.scroll-draggable .scroll-element_outer .scroll-bar {
|
||||
height: 100%;
|
||||
width: 100%;
|
||||
|
||||
-webkit-border-radius: 12px;
|
||||
-moz-border-radius: 12px;
|
||||
border-radius: 12px;
|
||||
}
|
||||
|
||||
.scrollbar-dynamic > .scroll-element.scroll-x:hover .scroll-element_outer,
|
||||
.scrollbar-dynamic > .scroll-element.scroll-x.scroll-draggable .scroll-element_outer {
|
||||
height: 20px;
|
||||
min-height: 7px;
|
||||
}
|
||||
.scrollbar-dynamic > .scroll-element.scroll-y:hover .scroll-element_outer,
|
||||
.scrollbar-dynamic > .scroll-element.scroll-y.scroll-draggable .scroll-element_outer {
|
||||
min-width: 7px;
|
||||
width: 20px;
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
/*************** SCROLLBAR GOOGLE CHROME ***************/
|
||||
|
||||
.scrollbar-chrome > .scroll-element,
|
||||
.scrollbar-chrome > .scroll-element div
|
||||
{
|
||||
border: none;
|
||||
margin: 0;
|
||||
overflow: hidden;
|
||||
padding: 0;
|
||||
position: absolute;
|
||||
z-index: 10;
|
||||
}
|
||||
|
||||
.scrollbar-chrome > .scroll-element {
|
||||
background-color: #ffffff;
|
||||
}
|
||||
|
||||
.scrollbar-chrome > .scroll-element div {
|
||||
display: block;
|
||||
height: 100%;
|
||||
left: 0;
|
||||
top: 0;
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.scrollbar-chrome > .scroll-element .scroll-element_outer {}
|
||||
|
||||
.scrollbar-chrome > .scroll-element .scroll-element_track {
|
||||
background: #f1f1f1;
|
||||
border: 1px solid #dbdbdb;
|
||||
}
|
||||
|
||||
.scrollbar-chrome > .scroll-element.scroll-x {
|
||||
bottom: 0;
|
||||
height: 16px;
|
||||
left: 0;
|
||||
min-width: 100%;
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.scrollbar-chrome > .scroll-element.scroll-y {
|
||||
height: 100%;
|
||||
min-height: 100%;
|
||||
right: 0;
|
||||
top: 0;
|
||||
width: 16px;
|
||||
}
|
||||
|
||||
.scrollbar-chrome > .scroll-element .scroll-bar {
|
||||
background-color: #d9d9d9;
|
||||
border: 1px solid #bdbdbd;
|
||||
cursor: default;
|
||||
|
||||
-webkit-border-radius: 2px;
|
||||
-moz-border-radius: 2px;
|
||||
border-radius: 2px;
|
||||
}
|
||||
|
||||
.scrollbar-chrome > .scroll-element .scroll-bar:hover {
|
||||
background-color: #c2c2c2;
|
||||
border-color: #a9a9a9;
|
||||
}
|
||||
|
||||
.scrollbar-chrome > .scroll-element.scroll-draggable .scroll-bar {
|
||||
background-color: #919191;
|
||||
border-color: #7e7e7e;
|
||||
}
|
||||
|
||||
/* scrollbar height/width & offset from container borders */
|
||||
|
||||
.scrollbar-chrome > .scroll-content.scroll-scrolly_visible { left: -16px; margin-left: 16px; }
|
||||
.scrollbar-chrome > .scroll-content.scroll-scrollx_visible { top: -16px; margin-top: 16px; }
|
||||
|
||||
.scrollbar-chrome > .scroll-element.scroll-x .scroll-bar { height: 8px; min-width: 10px; top: 3px; }
|
||||
.scrollbar-chrome > .scroll-element.scroll-y .scroll-bar { left: 3px; min-height: 10px; width: 8px; }
|
||||
|
||||
.scrollbar-chrome > .scroll-element.scroll-x .scroll-element_outer { border-left: 1px solid #dbdbdb; }
|
||||
.scrollbar-chrome > .scroll-element.scroll-x .scroll-element_track { height: 14px; left: -3px; }
|
||||
.scrollbar-chrome > .scroll-element.scroll-x .scroll-element_size { height: 14px; left: -4px; }
|
||||
|
||||
.scrollbar-chrome > .scroll-element.scroll-y .scroll-element_outer { border-top: 1px solid #dbdbdb; }
|
||||
.scrollbar-chrome > .scroll-element.scroll-y .scroll-element_track { top: -3px; width: 14px; }
|
||||
.scrollbar-chrome > .scroll-element.scroll-y .scroll-element_size { top: -4px; width: 14px; }
|
||||
|
||||
/* update scrollbar offset if both scrolls are visible */
|
||||
|
||||
.scrollbar-chrome > .scroll-element.scroll-x.scroll-scrolly_visible .scroll-element_size { left: -19px; }
|
||||
.scrollbar-chrome > .scroll-element.scroll-y.scroll-scrollx_visible .scroll-element_size { top: -19px; }
|
||||
|
||||
.scrollbar-chrome > .scroll-element.scroll-x.scroll-scrolly_visible .scroll-element_track { left: -19px; }
|
||||
.scrollbar-chrome > .scroll-element.scroll-y.scroll-scrollx_visible .scroll-element_track { top: -19px; }
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
781
assets/js/vendor/jquery.scrollbar/jquery.scrollbar.js
vendored
Normal file
781
assets/js/vendor/jquery.scrollbar/jquery.scrollbar.js
vendored
Normal file
@@ -0,0 +1,781 @@
|
||||
/**
|
||||
* jQuery CSS Customizable Scrollbar
|
||||
*
|
||||
* Copyright 2015, Yuriy Khabarov
|
||||
* Dual licensed under the MIT or GPL Version 2 licenses.
|
||||
*
|
||||
* If you found bug, please contact me via email <13real008@gmail.com>
|
||||
*
|
||||
* @author Yuriy Khabarov aka Gromo
|
||||
* @version 0.2.10
|
||||
* @url https://github.com/gromo/jquery.scrollbar/
|
||||
*
|
||||
*/
|
||||
;
|
||||
(function (root, factory) {
|
||||
if (typeof define === 'function' && define.amd) {
|
||||
define(['jquery'], factory);
|
||||
} else {
|
||||
factory(root.jQuery);
|
||||
}
|
||||
}(this, function ($) {
|
||||
'use strict';
|
||||
|
||||
// init flags & variables
|
||||
var debug = false;
|
||||
|
||||
var browser = {
|
||||
data: {
|
||||
index: 0,
|
||||
name: 'scrollbar'
|
||||
},
|
||||
macosx: /mac/i.test(navigator.platform),
|
||||
mobile: /android|webos|iphone|ipad|ipod|blackberry/i.test(navigator.userAgent),
|
||||
overlay: null,
|
||||
scroll: null,
|
||||
scrolls: [],
|
||||
webkit: /webkit/i.test(navigator.userAgent) && !/edge\/\d+/i.test(navigator.userAgent)
|
||||
};
|
||||
|
||||
browser.scrolls.add = function (instance) {
|
||||
this.remove(instance).push(instance);
|
||||
};
|
||||
browser.scrolls.remove = function (instance) {
|
||||
while ($.inArray(instance, this) >= 0) {
|
||||
this.splice($.inArray(instance, this), 1);
|
||||
}
|
||||
return this;
|
||||
};
|
||||
|
||||
var defaults = {
|
||||
"autoScrollSize": true, // automatically calculate scrollsize
|
||||
"autoUpdate": true, // update scrollbar if content/container size changed
|
||||
"debug": false, // debug mode
|
||||
"disableBodyScroll": false, // disable body scroll if mouse over container
|
||||
"duration": 200, // scroll animate duration in ms
|
||||
"ignoreMobile": false, // ignore mobile devices
|
||||
"ignoreOverlay": false, // ignore browsers with overlay scrollbars (mobile, MacOS)
|
||||
"scrollStep": 30, // scroll step for scrollbar arrows
|
||||
"showArrows": false, // add class to show arrows
|
||||
"stepScrolling": true, // when scrolling to scrollbar mousedown position
|
||||
|
||||
"scrollx": null, // horizontal scroll element
|
||||
"scrolly": null, // vertical scroll element
|
||||
|
||||
"onDestroy": null, // callback function on destroy,
|
||||
"onInit": null, // callback function on first initialization
|
||||
"onScroll": null, // callback function on content scrolling
|
||||
"onUpdate": null // callback function on init/resize (before scrollbar size calculation)
|
||||
};
|
||||
|
||||
|
||||
var BaseScrollbar = function (container) {
|
||||
|
||||
if (!browser.scroll) {
|
||||
browser.overlay = isScrollOverlaysContent();
|
||||
browser.scroll = getBrowserScrollSize();
|
||||
updateScrollbars();
|
||||
|
||||
$(window).resize(function () {
|
||||
var forceUpdate = false;
|
||||
if (browser.scroll && (browser.scroll.height || browser.scroll.width)) {
|
||||
var scroll = getBrowserScrollSize();
|
||||
if (scroll.height !== browser.scroll.height || scroll.width !== browser.scroll.width) {
|
||||
browser.scroll = scroll;
|
||||
forceUpdate = true; // handle page zoom
|
||||
}
|
||||
}
|
||||
updateScrollbars(forceUpdate);
|
||||
});
|
||||
}
|
||||
|
||||
this.container = container;
|
||||
this.namespace = '.scrollbar_' + browser.data.index++;
|
||||
this.options = $.extend({}, defaults, window.jQueryScrollbarOptions || {});
|
||||
this.scrollTo = null;
|
||||
this.scrollx = {};
|
||||
this.scrolly = {};
|
||||
|
||||
container.data(browser.data.name, this);
|
||||
browser.scrolls.add(this);
|
||||
};
|
||||
|
||||
BaseScrollbar.prototype = {
|
||||
|
||||
destroy: function () {
|
||||
|
||||
if (!this.wrapper) {
|
||||
return;
|
||||
}
|
||||
|
||||
this.container.removeData(browser.data.name);
|
||||
browser.scrolls.remove(this);
|
||||
|
||||
// init variables
|
||||
var scrollLeft = this.container.scrollLeft();
|
||||
var scrollTop = this.container.scrollTop();
|
||||
|
||||
this.container.insertBefore(this.wrapper).css({
|
||||
"height": "",
|
||||
"margin": "",
|
||||
"max-height": ""
|
||||
})
|
||||
.removeClass('scroll-content scroll-scrollx_visible scroll-scrolly_visible')
|
||||
.off(this.namespace)
|
||||
.scrollLeft(scrollLeft)
|
||||
.scrollTop(scrollTop);
|
||||
|
||||
this.scrollx.scroll.removeClass('scroll-scrollx_visible').find('div').andSelf().off(this.namespace);
|
||||
this.scrolly.scroll.removeClass('scroll-scrolly_visible').find('div').andSelf().off(this.namespace);
|
||||
|
||||
this.wrapper.remove();
|
||||
|
||||
$(document).add('body').off(this.namespace);
|
||||
|
||||
if ($.isFunction(this.options.onDestroy)){
|
||||
this.options.onDestroy.apply(this, [this.container]);
|
||||
}
|
||||
},
|
||||
init: function (options) {
|
||||
|
||||
// init variables
|
||||
var S = this,
|
||||
c = this.container,
|
||||
cw = this.containerWrapper || c,
|
||||
namespace = this.namespace,
|
||||
o = $.extend(this.options, options || {}),
|
||||
s = {x: this.scrollx, y: this.scrolly},
|
||||
w = this.wrapper;
|
||||
|
||||
var initScroll = {
|
||||
"scrollLeft": c.scrollLeft(),
|
||||
"scrollTop": c.scrollTop()
|
||||
};
|
||||
|
||||
// do not init if in ignorable browser
|
||||
if ((browser.mobile && o.ignoreMobile)
|
||||
|| (browser.overlay && o.ignoreOverlay)
|
||||
|| (browser.macosx && !browser.webkit) // still required to ignore nonWebKit browsers on Mac
|
||||
) {
|
||||
return false;
|
||||
}
|
||||
|
||||
// init scroll container
|
||||
if (!w) {
|
||||
this.wrapper = w = $('<div>').addClass('scroll-wrapper').addClass(c.attr('class'))
|
||||
.css('position', c.css('position') == 'absolute' ? 'absolute' : 'relative')
|
||||
.insertBefore(c).append(c);
|
||||
|
||||
if (c.is('textarea')) {
|
||||
this.containerWrapper = cw = $('<div>').insertBefore(c).append(c);
|
||||
w.addClass('scroll-textarea');
|
||||
}
|
||||
|
||||
cw.addClass('scroll-content').css({
|
||||
"height": "auto",
|
||||
"margin-bottom": browser.scroll.height * -1 + 'px',
|
||||
"margin-right": browser.scroll.width * -1 + 'px',
|
||||
"max-height": ""
|
||||
});
|
||||
|
||||
c.on('scroll' + namespace, function (event) {
|
||||
if ($.isFunction(o.onScroll)) {
|
||||
o.onScroll.call(S, {
|
||||
"maxScroll": s.y.maxScrollOffset,
|
||||
"scroll": c.scrollTop(),
|
||||
"size": s.y.size,
|
||||
"visible": s.y.visible
|
||||
}, {
|
||||
"maxScroll": s.x.maxScrollOffset,
|
||||
"scroll": c.scrollLeft(),
|
||||
"size": s.x.size,
|
||||
"visible": s.x.visible
|
||||
});
|
||||
}
|
||||
s.x.isVisible && s.x.scroll.bar.css('left', c.scrollLeft() * s.x.kx + 'px');
|
||||
s.y.isVisible && s.y.scroll.bar.css('top', c.scrollTop() * s.y.kx + 'px');
|
||||
});
|
||||
|
||||
/* prevent native scrollbars to be visible on #anchor click */
|
||||
w.on('scroll' + namespace, function () {
|
||||
w.scrollTop(0).scrollLeft(0);
|
||||
});
|
||||
|
||||
if (o.disableBodyScroll) {
|
||||
var handleMouseScroll = function (event) {
|
||||
isVerticalScroll(event) ?
|
||||
s.y.isVisible && s.y.mousewheel(event) :
|
||||
s.x.isVisible && s.x.mousewheel(event);
|
||||
};
|
||||
w.on('MozMousePixelScroll' + namespace, handleMouseScroll);
|
||||
w.on('mousewheel' + namespace, handleMouseScroll);
|
||||
|
||||
if (browser.mobile) {
|
||||
w.on('touchstart' + namespace, function (event) {
|
||||
var touch = event.originalEvent.touches && event.originalEvent.touches[0] || event;
|
||||
var originalTouch = {
|
||||
"pageX": touch.pageX,
|
||||
"pageY": touch.pageY
|
||||
};
|
||||
var originalScroll = {
|
||||
"left": c.scrollLeft(),
|
||||
"top": c.scrollTop()
|
||||
};
|
||||
$(document).on('touchmove' + namespace, function (event) {
|
||||
var touch = event.originalEvent.targetTouches && event.originalEvent.targetTouches[0] || event;
|
||||
c.scrollLeft(originalScroll.left + originalTouch.pageX - touch.pageX);
|
||||
c.scrollTop(originalScroll.top + originalTouch.pageY - touch.pageY);
|
||||
event.preventDefault();
|
||||
});
|
||||
$(document).on('touchend' + namespace, function () {
|
||||
$(document).off(namespace);
|
||||
});
|
||||
});
|
||||
}
|
||||
}
|
||||
if ($.isFunction(o.onInit)){
|
||||
o.onInit.apply(this, [c]);
|
||||
}
|
||||
} else {
|
||||
cw.css({
|
||||
"height": "auto",
|
||||
"margin-bottom": browser.scroll.height * -1 + 'px',
|
||||
"margin-right": browser.scroll.width * -1 + 'px',
|
||||
"max-height": ""
|
||||
});
|
||||
}
|
||||
|
||||
// init scrollbars & recalculate sizes
|
||||
$.each(s, function (d, scrollx) {
|
||||
|
||||
var scrollCallback = null;
|
||||
var scrollForward = 1;
|
||||
var scrollOffset = (d === 'x') ? 'scrollLeft' : 'scrollTop';
|
||||
var scrollStep = o.scrollStep;
|
||||
var scrollTo = function () {
|
||||
var currentOffset = c[scrollOffset]();
|
||||
c[scrollOffset](currentOffset + scrollStep);
|
||||
if (scrollForward == 1 && (currentOffset + scrollStep) >= scrollToValue)
|
||||
currentOffset = c[scrollOffset]();
|
||||
if (scrollForward == -1 && (currentOffset + scrollStep) <= scrollToValue)
|
||||
currentOffset = c[scrollOffset]();
|
||||
if (c[scrollOffset]() == currentOffset && scrollCallback) {
|
||||
scrollCallback();
|
||||
}
|
||||
}
|
||||
var scrollToValue = 0;
|
||||
|
||||
if (!scrollx.scroll) {
|
||||
|
||||
scrollx.scroll = S._getScroll(o['scroll' + d]).addClass('scroll-' + d);
|
||||
|
||||
if(o.showArrows){
|
||||
scrollx.scroll.addClass('scroll-element_arrows_visible');
|
||||
}
|
||||
|
||||
scrollx.mousewheel = function (event) {
|
||||
|
||||
if (!scrollx.isVisible || (d === 'x' && isVerticalScroll(event))) {
|
||||
return true;
|
||||
}
|
||||
if (d === 'y' && !isVerticalScroll(event)) {
|
||||
s.x.mousewheel(event);
|
||||
return true;
|
||||
}
|
||||
|
||||
var delta = event.originalEvent.wheelDelta * -1 || event.originalEvent.detail;
|
||||
var maxScrollValue = scrollx.size - scrollx.visible - scrollx.offset;
|
||||
|
||||
if ((delta > 0 && scrollToValue < maxScrollValue) || (delta < 0 && scrollToValue > 0)) {
|
||||
scrollToValue = scrollToValue + delta;
|
||||
if (scrollToValue < 0)
|
||||
scrollToValue = 0;
|
||||
if (scrollToValue > maxScrollValue)
|
||||
scrollToValue = maxScrollValue;
|
||||
|
||||
S.scrollTo = S.scrollTo || {};
|
||||
S.scrollTo[scrollOffset] = scrollToValue;
|
||||
setTimeout(function () {
|
||||
if (S.scrollTo) {
|
||||
c.stop().animate(S.scrollTo, 240, 'linear', function () {
|
||||
scrollToValue = c[scrollOffset]();
|
||||
});
|
||||
S.scrollTo = null;
|
||||
}
|
||||
}, 1);
|
||||
}
|
||||
|
||||
event.preventDefault();
|
||||
return false;
|
||||
};
|
||||
|
||||
scrollx.scroll
|
||||
.on('MozMousePixelScroll' + namespace, scrollx.mousewheel)
|
||||
.on('mousewheel' + namespace, scrollx.mousewheel)
|
||||
.on('mouseenter' + namespace, function () {
|
||||
scrollToValue = c[scrollOffset]();
|
||||
});
|
||||
|
||||
// handle arrows & scroll inner mousedown event
|
||||
scrollx.scroll.find('.scroll-arrow, .scroll-element_track')
|
||||
.on('mousedown' + namespace, function (event) {
|
||||
|
||||
if (event.which != 1) // lmb
|
||||
return true;
|
||||
|
||||
scrollForward = 1;
|
||||
|
||||
var data = {
|
||||
"eventOffset": event[(d === 'x') ? 'pageX' : 'pageY'],
|
||||
"maxScrollValue": scrollx.size - scrollx.visible - scrollx.offset,
|
||||
"scrollbarOffset": scrollx.scroll.bar.offset()[(d === 'x') ? 'left' : 'top'],
|
||||
"scrollbarSize": scrollx.scroll.bar[(d === 'x') ? 'outerWidth' : 'outerHeight']()
|
||||
};
|
||||
var timeout = 0, timer = 0;
|
||||
|
||||
if ($(this).hasClass('scroll-arrow')) {
|
||||
scrollForward = $(this).hasClass("scroll-arrow_more") ? 1 : -1;
|
||||
scrollStep = o.scrollStep * scrollForward;
|
||||
scrollToValue = scrollForward > 0 ? data.maxScrollValue : 0;
|
||||
} else {
|
||||
scrollForward = (data.eventOffset > (data.scrollbarOffset + data.scrollbarSize) ? 1
|
||||
: (data.eventOffset < data.scrollbarOffset ? -1 : 0));
|
||||
scrollStep = Math.round(scrollx.visible * 0.75) * scrollForward;
|
||||
scrollToValue = (data.eventOffset - data.scrollbarOffset -
|
||||
(o.stepScrolling ? (scrollForward == 1 ? data.scrollbarSize : 0)
|
||||
: Math.round(data.scrollbarSize / 2)));
|
||||
scrollToValue = c[scrollOffset]() + (scrollToValue / scrollx.kx);
|
||||
}
|
||||
|
||||
S.scrollTo = S.scrollTo || {};
|
||||
S.scrollTo[scrollOffset] = o.stepScrolling ? c[scrollOffset]() + scrollStep : scrollToValue;
|
||||
|
||||
if (o.stepScrolling) {
|
||||
scrollCallback = function () {
|
||||
scrollToValue = c[scrollOffset]();
|
||||
clearInterval(timer);
|
||||
clearTimeout(timeout);
|
||||
timeout = 0;
|
||||
timer = 0;
|
||||
};
|
||||
timeout = setTimeout(function () {
|
||||
timer = setInterval(scrollTo, 40);
|
||||
}, o.duration + 100);
|
||||
}
|
||||
|
||||
setTimeout(function () {
|
||||
if (S.scrollTo) {
|
||||
c.animate(S.scrollTo, o.duration);
|
||||
S.scrollTo = null;
|
||||
}
|
||||
}, 1);
|
||||
|
||||
return S._handleMouseDown(scrollCallback, event);
|
||||
});
|
||||
|
||||
// handle scrollbar drag'n'drop
|
||||
scrollx.scroll.bar.on('mousedown' + namespace, function (event) {
|
||||
|
||||
if (event.which != 1) // lmb
|
||||
return true;
|
||||
|
||||
var eventPosition = event[(d === 'x') ? 'pageX' : 'pageY'];
|
||||
var initOffset = c[scrollOffset]();
|
||||
|
||||
scrollx.scroll.addClass('scroll-draggable');
|
||||
|
||||
$(document).on('mousemove' + namespace, function (event) {
|
||||
var diff = parseInt((event[(d === 'x') ? 'pageX' : 'pageY'] - eventPosition) / scrollx.kx, 10);
|
||||
c[scrollOffset](initOffset + diff);
|
||||
});
|
||||
|
||||
return S._handleMouseDown(function () {
|
||||
scrollx.scroll.removeClass('scroll-draggable');
|
||||
scrollToValue = c[scrollOffset]();
|
||||
}, event);
|
||||
});
|
||||
}
|
||||
});
|
||||
|
||||
// remove classes & reset applied styles
|
||||
$.each(s, function (d, scrollx) {
|
||||
var scrollClass = 'scroll-scroll' + d + '_visible';
|
||||
var scrolly = (d == "x") ? s.y : s.x;
|
||||
|
||||
scrollx.scroll.removeClass(scrollClass);
|
||||
scrolly.scroll.removeClass(scrollClass);
|
||||
cw.removeClass(scrollClass);
|
||||
});
|
||||
|
||||
// calculate init sizes
|
||||
$.each(s, function (d, scrollx) {
|
||||
$.extend(scrollx, (d == "x") ? {
|
||||
"offset": parseInt(c.css('left'), 10) || 0,
|
||||
"size": c.prop('scrollWidth'),
|
||||
"visible": w.width()
|
||||
} : {
|
||||
"offset": parseInt(c.css('top'), 10) || 0,
|
||||
"size": c.prop('scrollHeight'),
|
||||
"visible": w.height()
|
||||
});
|
||||
});
|
||||
|
||||
// update scrollbar visibility/dimensions
|
||||
this._updateScroll('x', this.scrollx);
|
||||
this._updateScroll('y', this.scrolly);
|
||||
|
||||
if ($.isFunction(o.onUpdate)){
|
||||
o.onUpdate.apply(this, [c]);
|
||||
}
|
||||
|
||||
// calculate scroll size
|
||||
$.each(s, function (d, scrollx) {
|
||||
|
||||
var cssOffset = (d === 'x') ? 'left' : 'top';
|
||||
var cssFullSize = (d === 'x') ? 'outerWidth' : 'outerHeight';
|
||||
var cssSize = (d === 'x') ? 'width' : 'height';
|
||||
var offset = parseInt(c.css(cssOffset), 10) || 0;
|
||||
|
||||
var AreaSize = scrollx.size;
|
||||
var AreaVisible = scrollx.visible + offset;
|
||||
|
||||
var scrollSize = scrollx.scroll.size[cssFullSize]() + (parseInt(scrollx.scroll.size.css(cssOffset), 10) || 0);
|
||||
|
||||
if (o.autoScrollSize) {
|
||||
scrollx.scrollbarSize = parseInt(scrollSize * AreaVisible / AreaSize, 10);
|
||||
scrollx.scroll.bar.css(cssSize, scrollx.scrollbarSize + 'px');
|
||||
}
|
||||
|
||||
scrollx.scrollbarSize = scrollx.scroll.bar[cssFullSize]();
|
||||
scrollx.kx = ((scrollSize - scrollx.scrollbarSize) / (AreaSize - AreaVisible)) || 1;
|
||||
scrollx.maxScrollOffset = AreaSize - AreaVisible;
|
||||
});
|
||||
|
||||
c.scrollLeft(initScroll.scrollLeft).scrollTop(initScroll.scrollTop).trigger('scroll');
|
||||
},
|
||||
|
||||
/**
|
||||
* Get scrollx/scrolly object
|
||||
*
|
||||
* @param {Mixed} scroll
|
||||
* @returns {jQuery} scroll object
|
||||
*/
|
||||
_getScroll: function (scroll) {
|
||||
var types = {
|
||||
advanced: [
|
||||
'<div class="scroll-element">',
|
||||
'<div class="scroll-element_corner"></div>',
|
||||
'<div class="scroll-arrow scroll-arrow_less"></div>',
|
||||
'<div class="scroll-arrow scroll-arrow_more"></div>',
|
||||
'<div class="scroll-element_outer">',
|
||||
'<div class="scroll-element_size"></div>', // required! used for scrollbar size calculation !
|
||||
'<div class="scroll-element_inner-wrapper">',
|
||||
'<div class="scroll-element_inner scroll-element_track">', // used for handling scrollbar click
|
||||
'<div class="scroll-element_inner-bottom"></div>',
|
||||
'</div>',
|
||||
'</div>',
|
||||
'<div class="scroll-bar">', // required
|
||||
'<div class="scroll-bar_body">',
|
||||
'<div class="scroll-bar_body-inner"></div>',
|
||||
'</div>',
|
||||
'<div class="scroll-bar_bottom"></div>',
|
||||
'<div class="scroll-bar_center"></div>',
|
||||
'</div>',
|
||||
'</div>',
|
||||
'</div>'
|
||||
].join(''),
|
||||
simple: [
|
||||
'<div class="scroll-element">',
|
||||
'<div class="scroll-element_outer">',
|
||||
'<div class="scroll-element_size"></div>', // required! used for scrollbar size calculation !
|
||||
'<div class="scroll-element_track"></div>', // used for handling scrollbar click
|
||||
'<div class="scroll-bar"></div>', // required
|
||||
'</div>',
|
||||
'</div>'
|
||||
].join('')
|
||||
};
|
||||
if (types[scroll]) {
|
||||
scroll = types[scroll];
|
||||
}
|
||||
if (!scroll) {
|
||||
scroll = types['simple'];
|
||||
}
|
||||
if (typeof (scroll) == 'string') {
|
||||
scroll = $(scroll).appendTo(this.wrapper);
|
||||
} else {
|
||||
scroll = $(scroll);
|
||||
}
|
||||
$.extend(scroll, {
|
||||
bar: scroll.find('.scroll-bar'),
|
||||
size: scroll.find('.scroll-element_size'),
|
||||
track: scroll.find('.scroll-element_track')
|
||||
});
|
||||
return scroll;
|
||||
},
|
||||
|
||||
_handleMouseDown: function(callback, event) {
|
||||
|
||||
var namespace = this.namespace;
|
||||
|
||||
$(document).on('blur' + namespace, function () {
|
||||
$(document).add('body').off(namespace);
|
||||
callback && callback();
|
||||
});
|
||||
$(document).on('dragstart' + namespace, function (event) {
|
||||
event.preventDefault();
|
||||
return false;
|
||||
});
|
||||
$(document).on('mouseup' + namespace, function () {
|
||||
$(document).add('body').off(namespace);
|
||||
callback && callback();
|
||||
});
|
||||
$('body').on('selectstart' + namespace, function (event) {
|
||||
event.preventDefault();
|
||||
return false;
|
||||
});
|
||||
|
||||
event && event.preventDefault();
|
||||
return false;
|
||||
},
|
||||
|
||||
_updateScroll: function (d, scrollx) {
|
||||
|
||||
var container = this.container,
|
||||
containerWrapper = this.containerWrapper || container,
|
||||
scrollClass = 'scroll-scroll' + d + '_visible',
|
||||
scrolly = (d === 'x') ? this.scrolly : this.scrollx,
|
||||
offset = parseInt(this.container.css((d === 'x') ? 'left' : 'top'), 10) || 0,
|
||||
wrapper = this.wrapper;
|
||||
|
||||
var AreaSize = scrollx.size;
|
||||
var AreaVisible = scrollx.visible + offset;
|
||||
|
||||
scrollx.isVisible = (AreaSize - AreaVisible) > 1; // bug in IE9/11 with 1px diff
|
||||
if (scrollx.isVisible) {
|
||||
scrollx.scroll.addClass(scrollClass);
|
||||
scrolly.scroll.addClass(scrollClass);
|
||||
containerWrapper.addClass(scrollClass);
|
||||
} else {
|
||||
scrollx.scroll.removeClass(scrollClass);
|
||||
scrolly.scroll.removeClass(scrollClass);
|
||||
containerWrapper.removeClass(scrollClass);
|
||||
}
|
||||
|
||||
if (d === 'y') {
|
||||
if(container.is('textarea') || AreaSize < AreaVisible){
|
||||
containerWrapper.css({
|
||||
"height": (AreaVisible + browser.scroll.height) + 'px',
|
||||
"max-height": "none"
|
||||
});
|
||||
} else {
|
||||
containerWrapper.css({
|
||||
//"height": "auto", // do not reset height value: issue with height:100%!
|
||||
"max-height": (AreaVisible + browser.scroll.height) + 'px'
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
if (scrollx.size != container.prop('scrollWidth')
|
||||
|| scrolly.size != container.prop('scrollHeight')
|
||||
|| scrollx.visible != wrapper.width()
|
||||
|| scrolly.visible != wrapper.height()
|
||||
|| scrollx.offset != (parseInt(container.css('left'), 10) || 0)
|
||||
|| scrolly.offset != (parseInt(container.css('top'), 10) || 0)
|
||||
) {
|
||||
$.extend(this.scrollx, {
|
||||
"offset": parseInt(container.css('left'), 10) || 0,
|
||||
"size": container.prop('scrollWidth'),
|
||||
"visible": wrapper.width()
|
||||
});
|
||||
$.extend(this.scrolly, {
|
||||
"offset": parseInt(container.css('top'), 10) || 0,
|
||||
"size": this.container.prop('scrollHeight'),
|
||||
"visible": wrapper.height()
|
||||
});
|
||||
this._updateScroll(d === 'x' ? 'y' : 'x', scrolly);
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
var CustomScrollbar = BaseScrollbar;
|
||||
|
||||
/*
|
||||
* Extend jQuery as plugin
|
||||
*
|
||||
* @param {Mixed} command to execute
|
||||
* @param {Mixed} arguments as Array
|
||||
* @return {jQuery}
|
||||
*/
|
||||
$.fn.scrollbar = function (command, args) {
|
||||
if (typeof command !== 'string') {
|
||||
args = command;
|
||||
command = 'init';
|
||||
}
|
||||
if (typeof args === 'undefined') {
|
||||
args = [];
|
||||
}
|
||||
if (!$.isArray(args)) {
|
||||
args = [args];
|
||||
}
|
||||
this.not('body, .scroll-wrapper').each(function () {
|
||||
var element = $(this),
|
||||
instance = element.data(browser.data.name);
|
||||
if (instance || command === 'init') {
|
||||
if (!instance) {
|
||||
instance = new CustomScrollbar(element);
|
||||
}
|
||||
if (instance[command]) {
|
||||
instance[command].apply(instance, args);
|
||||
}
|
||||
}
|
||||
});
|
||||
return this;
|
||||
};
|
||||
|
||||
/**
|
||||
* Connect default options to global object
|
||||
*/
|
||||
$.fn.scrollbar.options = defaults;
|
||||
|
||||
|
||||
/**
|
||||
* Check if scroll content/container size is changed
|
||||
*/
|
||||
|
||||
var updateScrollbars = (function () {
|
||||
var timer = 0,
|
||||
timerCounter = 0;
|
||||
|
||||
return function (force) {
|
||||
var i, container, options, scroll, wrapper, scrollx, scrolly;
|
||||
for (i = 0; i < browser.scrolls.length; i++) {
|
||||
scroll = browser.scrolls[i];
|
||||
container = scroll.container;
|
||||
options = scroll.options;
|
||||
wrapper = scroll.wrapper;
|
||||
scrollx = scroll.scrollx;
|
||||
scrolly = scroll.scrolly;
|
||||
if (force || (options.autoUpdate && wrapper && wrapper.is(':visible') &&
|
||||
(container.prop('scrollWidth') != scrollx.size || container.prop('scrollHeight') != scrolly.size || wrapper.width() != scrollx.visible || wrapper.height() != scrolly.visible))) {
|
||||
scroll.init();
|
||||
|
||||
if (options.debug) {
|
||||
window.console && console.log({
|
||||
scrollHeight: container.prop('scrollHeight') + ':' + scroll.scrolly.size,
|
||||
scrollWidth: container.prop('scrollWidth') + ':' + scroll.scrollx.size,
|
||||
visibleHeight: wrapper.height() + ':' + scroll.scrolly.visible,
|
||||
visibleWidth: wrapper.width() + ':' + scroll.scrollx.visible
|
||||
}, true);
|
||||
timerCounter++;
|
||||
}
|
||||
}
|
||||
}
|
||||
if (debug && timerCounter > 10) {
|
||||
window.console && console.log('Scroll updates exceed 10');
|
||||
updateScrollbars = function () {};
|
||||
} else {
|
||||
clearTimeout(timer);
|
||||
timer = setTimeout(updateScrollbars, 300);
|
||||
}
|
||||
};
|
||||
})();
|
||||
|
||||
/* ADDITIONAL FUNCTIONS */
|
||||
/**
|
||||
* Get native browser scrollbar size (height/width)
|
||||
*
|
||||
* @param {Boolean} actual size or CSS size, default - CSS size
|
||||
* @returns {Object} with height, width
|
||||
*/
|
||||
function getBrowserScrollSize(actualSize) {
|
||||
|
||||
if (browser.webkit && !actualSize) {
|
||||
return {
|
||||
"height": 0,
|
||||
"width": 0
|
||||
};
|
||||
}
|
||||
|
||||
if (!browser.data.outer) {
|
||||
var css = {
|
||||
"border": "none",
|
||||
"box-sizing": "content-box",
|
||||
"height": "200px",
|
||||
"margin": "0",
|
||||
"padding": "0",
|
||||
"width": "200px"
|
||||
};
|
||||
browser.data.inner = $("<div>").css($.extend({}, css));
|
||||
browser.data.outer = $("<div>").css($.extend({
|
||||
"left": "-1000px",
|
||||
"overflow": "scroll",
|
||||
"position": "absolute",
|
||||
"top": "-1000px"
|
||||
}, css)).append(browser.data.inner).appendTo("body");
|
||||
}
|
||||
|
||||
browser.data.outer.scrollLeft(1000).scrollTop(1000);
|
||||
|
||||
return {
|
||||
"height": Math.ceil((browser.data.outer.offset().top - browser.data.inner.offset().top) || 0),
|
||||
"width": Math.ceil((browser.data.outer.offset().left - browser.data.inner.offset().left) || 0)
|
||||
};
|
||||
}
|
||||
|
||||
/**
|
||||
* Check if native browser scrollbars overlay content
|
||||
*
|
||||
* @returns {Boolean}
|
||||
*/
|
||||
function isScrollOverlaysContent() {
|
||||
var scrollSize = getBrowserScrollSize(true);
|
||||
return !(scrollSize.height || scrollSize.width);
|
||||
}
|
||||
|
||||
function isVerticalScroll(event) {
|
||||
var e = event.originalEvent;
|
||||
if (e.axis && e.axis === e.HORIZONTAL_AXIS)
|
||||
return false;
|
||||
if (e.wheelDeltaX)
|
||||
return false;
|
||||
return true;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Extend AngularJS as UI directive
|
||||
* and expose a provider for override default config
|
||||
*
|
||||
*/
|
||||
if (window.angular) {
|
||||
(function (angular) {
|
||||
angular.module('jQueryScrollbar', [])
|
||||
.provider('jQueryScrollbar', function () {
|
||||
var defaultOptions = defaults;
|
||||
return {
|
||||
setOptions: function (options) {
|
||||
angular.extend(defaultOptions, options);
|
||||
},
|
||||
$get: function () {
|
||||
return {
|
||||
options: angular.copy(defaultOptions)
|
||||
};
|
||||
}
|
||||
};
|
||||
})
|
||||
.directive('jqueryScrollbar', ['jQueryScrollbar', '$parse', function (jQueryScrollbar, $parse) {
|
||||
return {
|
||||
"restrict": "AC",
|
||||
"link": function (scope, element, attrs) {
|
||||
var model = $parse(attrs.jqueryScrollbar),
|
||||
options = model(scope);
|
||||
element.scrollbar(options || jQueryScrollbar.options)
|
||||
.on('$destroy', function () {
|
||||
element.scrollbar('destroy');
|
||||
});
|
||||
}
|
||||
};
|
||||
}]);
|
||||
})(window.angular);
|
||||
}
|
||||
}));
|
||||
1588
assets/js/vendor/lightgallery.js/dist/js/lightgallery.js
vendored
Normal file
1588
assets/js/vendor/lightgallery.js/dist/js/lightgallery.js
vendored
Normal file
File diff suppressed because it is too large
Load Diff
190
assets/js/vendor/nice-select/jquery.nice-select.js
vendored
Normal file
190
assets/js/vendor/nice-select/jquery.nice-select.js
vendored
Normal file
@@ -0,0 +1,190 @@
|
||||
/* jQuery Nice Select - v1.1.0
|
||||
https://github.com/hernansartorio/jquery-nice-select
|
||||
Made by Hernán Sartorio */
|
||||
|
||||
(function($) {
|
||||
|
||||
$.fn.niceSelect = function(method) {
|
||||
|
||||
// Methods
|
||||
if (typeof method == 'string') {
|
||||
if (method == 'update') {
|
||||
this.each(function() {
|
||||
var $select = $(this);
|
||||
var $dropdown = $(this).next('.nice-select');
|
||||
var open = $dropdown.hasClass('open');
|
||||
|
||||
if ($dropdown.length) {
|
||||
$dropdown.remove();
|
||||
create_nice_select($select);
|
||||
|
||||
if (open) {
|
||||
$select.next().trigger('click');
|
||||
}
|
||||
}
|
||||
});
|
||||
} else if (method == 'destroy') {
|
||||
this.each(function() {
|
||||
var $select = $(this);
|
||||
var $dropdown = $(this).next('.nice-select');
|
||||
|
||||
if ($dropdown.length) {
|
||||
$dropdown.remove();
|
||||
$select.css('display', '');
|
||||
}
|
||||
});
|
||||
if ($('.nice-select').length == 0) {
|
||||
$(document).off('.nice_select');
|
||||
}
|
||||
} else {
|
||||
console.log('Method "' + method + '" does not exist.')
|
||||
}
|
||||
return this;
|
||||
}
|
||||
|
||||
// Hide native select
|
||||
this.hide();
|
||||
|
||||
// Create custom markup
|
||||
this.each(function() {
|
||||
var $select = $(this);
|
||||
|
||||
if (!$select.next().hasClass('nice-select')) {
|
||||
create_nice_select($select);
|
||||
}
|
||||
});
|
||||
|
||||
function create_nice_select($select) {
|
||||
$select.after($('<div></div>')
|
||||
.addClass('nice-select')
|
||||
.addClass($select.attr('class') || '')
|
||||
.addClass($select.attr('disabled') ? 'disabled' : '')
|
||||
.attr('tabindex', $select.attr('disabled') ? null : '0')
|
||||
.html('<span class="current"></span><ul class="list"></ul>')
|
||||
);
|
||||
|
||||
var $dropdown = $select.next();
|
||||
var $options = $select.find('option');
|
||||
var $selected = $select.find('option:selected');
|
||||
|
||||
$dropdown.find('.current').html($selected.data('display') || $selected.text());
|
||||
|
||||
$options.each(function(i) {
|
||||
var $option = $(this);
|
||||
var display = $option.data('display');
|
||||
|
||||
$dropdown.find('ul').append($('<li></li>')
|
||||
.attr('data-value', $option.val())
|
||||
.attr('data-display', (display || null))
|
||||
.addClass('option' +
|
||||
($option.is(':selected') ? ' selected' : '') +
|
||||
($option.is(':disabled') ? ' disabled' : ''))
|
||||
.html($option.text())
|
||||
);
|
||||
});
|
||||
}
|
||||
|
||||
/* Event listeners */
|
||||
|
||||
// Unbind existing events in case that the plugin has been initialized before
|
||||
$(document).off('.nice_select');
|
||||
|
||||
// Open/close
|
||||
$(document).on('click.nice_select', '.nice-select', function(event) {
|
||||
var $dropdown = $(this);
|
||||
|
||||
$('.nice-select').not($dropdown).removeClass('open');
|
||||
$dropdown.toggleClass('open');
|
||||
|
||||
if ($dropdown.hasClass('open')) {
|
||||
$dropdown.find('.option');
|
||||
$dropdown.find('.focus').removeClass('focus');
|
||||
$dropdown.find('.selected').addClass('focus');
|
||||
} else {
|
||||
$dropdown.focus();
|
||||
}
|
||||
});
|
||||
|
||||
// Close when clicking outside
|
||||
$(document).on('click.nice_select', function(event) {
|
||||
if ($(event.target).closest('.nice-select').length === 0) {
|
||||
$('.nice-select').removeClass('open').find('.option');
|
||||
}
|
||||
});
|
||||
|
||||
// Option click
|
||||
$(document).on('click.nice_select', '.nice-select .option:not(.disabled)', function(event) {
|
||||
var $option = $(this);
|
||||
var $dropdown = $option.closest('.nice-select');
|
||||
|
||||
$dropdown.find('.selected').removeClass('selected');
|
||||
$option.addClass('selected');
|
||||
|
||||
var text = $option.data('display') || $option.text();
|
||||
$dropdown.find('.current').text(text);
|
||||
|
||||
$dropdown.prev('select').val($option.data('value')).trigger('change');
|
||||
});
|
||||
|
||||
// Keyboard events
|
||||
$(document).on('keydown.nice_select', '.nice-select', function(event) {
|
||||
var $dropdown = $(this);
|
||||
var $focused_option = $($dropdown.find('.focus') || $dropdown.find('.list .option.selected'));
|
||||
|
||||
// Space or Enter
|
||||
if (event.keyCode == 32 || event.keyCode == 13) {
|
||||
if ($dropdown.hasClass('open')) {
|
||||
$focused_option.trigger('click');
|
||||
} else {
|
||||
$dropdown.trigger('click');
|
||||
}
|
||||
return false;
|
||||
// Down
|
||||
} else if (event.keyCode == 40) {
|
||||
if (!$dropdown.hasClass('open')) {
|
||||
$dropdown.trigger('click');
|
||||
} else {
|
||||
var $next = $focused_option.nextAll('.option:not(.disabled)').first();
|
||||
if ($next.length > 0) {
|
||||
$dropdown.find('.focus').removeClass('focus');
|
||||
$next.addClass('focus');
|
||||
}
|
||||
}
|
||||
return false;
|
||||
// Up
|
||||
} else if (event.keyCode == 38) {
|
||||
if (!$dropdown.hasClass('open')) {
|
||||
$dropdown.trigger('click');
|
||||
} else {
|
||||
var $prev = $focused_option.prevAll('.option:not(.disabled)').first();
|
||||
if ($prev.length > 0) {
|
||||
$dropdown.find('.focus').removeClass('focus');
|
||||
$prev.addClass('focus');
|
||||
}
|
||||
}
|
||||
return false;
|
||||
// Esc
|
||||
} else if (event.keyCode == 27) {
|
||||
if ($dropdown.hasClass('open')) {
|
||||
$dropdown.trigger('click');
|
||||
}
|
||||
// Tab
|
||||
} else if (event.keyCode == 9) {
|
||||
if ($dropdown.hasClass('open')) {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
// Detect CSS pointer-events support, for IE <= 10. From Modernizr.
|
||||
var style = document.createElement('a').style;
|
||||
style.cssText = 'pointer-events:auto';
|
||||
if (style.pointerEvents !== 'auto') {
|
||||
$('html').addClass('no-csspointerevents');
|
||||
}
|
||||
|
||||
return this;
|
||||
|
||||
};
|
||||
|
||||
}(jQuery));
|
||||
171
assets/js/vendor/nice-select/nice-select.scss
vendored
Normal file
171
assets/js/vendor/nice-select/nice-select.scss
vendored
Normal file
@@ -0,0 +1,171 @@
|
||||
// Default variables
|
||||
$font_size: 14px !default;
|
||||
$font_size_small: 12px !default;
|
||||
|
||||
$input_border_radius: 5px !default;
|
||||
$input_height: 42px !default;
|
||||
$input_height_small: 36px !default;
|
||||
$dropdown_padding: 18px !default;
|
||||
|
||||
$gray_dark: #444 !default;
|
||||
$gray: #999 !default;
|
||||
$gray_light: #e8e8e8 !default;
|
||||
$gray_lighter: #f6f6f6 !default;
|
||||
$primary_light: $gray !default;
|
||||
$arrow_color: $gray !default;
|
||||
|
||||
// Style the dropdown
|
||||
.nice-select {
|
||||
-webkit-tap-highlight-color: rgba(0, 0, 0, 0);
|
||||
background-color: #fff;
|
||||
border-radius: $input_border_radius;
|
||||
border: solid 1px $gray_light;
|
||||
box-sizing: border-box;
|
||||
clear: both;
|
||||
cursor: pointer;
|
||||
display: block;
|
||||
float: left;
|
||||
font-family: inherit;
|
||||
font-size: $font_size;
|
||||
font-weight: normal;
|
||||
height: $input_height;
|
||||
line-height: $input_height - 2;
|
||||
outline: none;
|
||||
padding-left: $dropdown_padding;
|
||||
padding-right: $dropdown_padding + 12;
|
||||
position: relative;
|
||||
text-align: left !important;
|
||||
transition: all 0.2s ease-in-out;
|
||||
user-select: none;
|
||||
white-space: nowrap;
|
||||
width: auto;
|
||||
&:hover {
|
||||
border-color: darken($gray_light, 5%);
|
||||
}
|
||||
&:active, &:focus {
|
||||
border-color: $primary_light;
|
||||
}
|
||||
// Arrow
|
||||
&:after {
|
||||
border-bottom: 2px solid $arrow_color;
|
||||
border-right: 2px solid $arrow_color;
|
||||
content: '';
|
||||
display: block;
|
||||
height: 5px;
|
||||
margin-top: -4px;
|
||||
pointer-events: none;
|
||||
position: absolute;
|
||||
right: 12px;
|
||||
top: 50%;
|
||||
transform-origin: 66% 66%;
|
||||
transform: rotate(45deg);
|
||||
transition: all 0.15s ease-in-out;
|
||||
width: 5px;
|
||||
}
|
||||
|
||||
&.open {
|
||||
@extend :active;
|
||||
&:after {
|
||||
transform: rotate(-135deg);
|
||||
}
|
||||
.list {
|
||||
opacity: 1;
|
||||
pointer-events: auto;
|
||||
transform: scale(1) translateY(0);
|
||||
}
|
||||
}
|
||||
&.disabled {
|
||||
border-color: lighten($gray_light, 2%);
|
||||
color: $gray;
|
||||
pointer-events: none;
|
||||
&:after {
|
||||
border-color: lighten($arrow_color, 20%);
|
||||
}
|
||||
}
|
||||
|
||||
// Modifiers
|
||||
&.wide {
|
||||
width: 100%;
|
||||
.list {
|
||||
left: 0 !important;
|
||||
right: 0 !important;
|
||||
}
|
||||
}
|
||||
&.right {
|
||||
float: right;
|
||||
.list {
|
||||
left: auto;
|
||||
right: 0;
|
||||
}
|
||||
}
|
||||
&.small {
|
||||
font-size: $font_size_small;
|
||||
height: $input_height_small;
|
||||
line-height: $input_height_small - 2;
|
||||
&:after {
|
||||
height: 4px;
|
||||
width: 4px;
|
||||
}
|
||||
.option {
|
||||
line-height: $input_height_small - 2;
|
||||
min-height: $input_height_small - 2;
|
||||
}
|
||||
}
|
||||
|
||||
// List and options
|
||||
.list {
|
||||
background-color: #fff;
|
||||
border-radius: $input_border_radius;
|
||||
box-shadow: 0 0 0 1px rgba($gray_dark, .11);
|
||||
box-sizing: border-box;
|
||||
margin-top: 4px;
|
||||
opacity: 0;
|
||||
overflow: hidden;
|
||||
padding: 0;
|
||||
pointer-events: none;
|
||||
position: absolute;
|
||||
top: 100%; left: 0;
|
||||
transform-origin: 50% 0;
|
||||
transform: scale(.75) translateY(- $input_height / 2);
|
||||
transition: all .2s cubic-bezier(0.5, 0, 0, 1.25), opacity .15s ease-out;
|
||||
z-index: 9;
|
||||
&:hover .option:not(:hover) {
|
||||
background-color: transparent !important;
|
||||
}
|
||||
}
|
||||
.option {
|
||||
cursor: pointer;
|
||||
font-weight: 400;
|
||||
line-height: $input_height - 2;
|
||||
list-style: none;
|
||||
min-height: $input_height - 2;
|
||||
outline: none;
|
||||
padding-left: $dropdown_padding;
|
||||
padding-right: $dropdown_padding + 11;
|
||||
text-align: left;
|
||||
transition: all 0.2s;
|
||||
&:hover, &.focus, &.selected.focus {
|
||||
background-color: $gray_lighter;
|
||||
}
|
||||
&.selected {
|
||||
font-weight: bold;
|
||||
}
|
||||
&.disabled {
|
||||
background-color: transparent;
|
||||
color: $gray;
|
||||
cursor: default;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// Use display instead of opacity for IE <= 10
|
||||
.no-csspointerevents .nice-select {
|
||||
.list {
|
||||
display: none;
|
||||
}
|
||||
&.open {
|
||||
.list {
|
||||
display: block;
|
||||
}
|
||||
}
|
||||
}
|
||||
20
assets/js/vendor/scrollify/LICENSE
vendored
Normal file
20
assets/js/vendor/scrollify/LICENSE
vendored
Normal file
@@ -0,0 +1,20 @@
|
||||
The MIT License (MIT)
|
||||
|
||||
Copyright (c) 2017 Luke Haas
|
||||
|
||||
Permission is hereby granted, free of charge, to any person obtaining a copy of
|
||||
this software and associated documentation files (the "Software"), to deal in
|
||||
the Software without restriction, including without limitation the rights to
|
||||
use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
|
||||
the Software, and to permit persons to whom the Software is furnished to do so,
|
||||
subject to the following conditions:
|
||||
|
||||
The above copyright notice and this permission notice shall be included in all
|
||||
copies or substantial portions of the Software.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
|
||||
FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
|
||||
COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
|
||||
IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
|
||||
CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
||||
28
assets/js/vendor/scrollify/bower.json
vendored
Normal file
28
assets/js/vendor/scrollify/bower.json
vendored
Normal file
@@ -0,0 +1,28 @@
|
||||
{
|
||||
"name": "Scrollify",
|
||||
"version": "1.0.19",
|
||||
"homepage": "https://github.com/lukehaas/Scrollify",
|
||||
"authors": [
|
||||
"Luke Haas <lukehaas7@gmail.com>"
|
||||
],
|
||||
"description": "A jQuery plugin that assists scrolling and smoothly snaps to sections.",
|
||||
"main": "jquery.scrollify.js",
|
||||
"moduleType": [
|
||||
"globals"
|
||||
],
|
||||
"keywords": [
|
||||
"scroll",
|
||||
"snap"
|
||||
],
|
||||
"license": "MIT",
|
||||
"ignore": [
|
||||
"**/.*",
|
||||
"node_modules",
|
||||
"bower_components",
|
||||
"test",
|
||||
"tests"
|
||||
],
|
||||
"dependencies": {
|
||||
"jquery": "*"
|
||||
}
|
||||
}
|
||||
847
assets/js/vendor/scrollify/jquery.scrollify.js
vendored
Normal file
847
assets/js/vendor/scrollify/jquery.scrollify.js
vendored
Normal file
@@ -0,0 +1,847 @@
|
||||
/*!
|
||||
* jQuery Scrollify
|
||||
* Version 1.0.19
|
||||
*
|
||||
* Requires:
|
||||
* - jQuery 1.7 or higher
|
||||
*
|
||||
* https://github.com/lukehaas/Scrollify
|
||||
*
|
||||
* Copyright 2016, Luke Haas
|
||||
* Permission is hereby granted, free of charge, to any person obtaining a copy of
|
||||
* this software and associated documentation files (the "Software"), to deal in
|
||||
* the Software without restriction, including without limitation the rights to
|
||||
* use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
|
||||
* the Software, and to permit persons to whom the Software is furnished to do so,
|
||||
* subject to the following conditions:
|
||||
*
|
||||
* The above copyright notice and this permission notice shall be included in all
|
||||
* copies or substantial portions of the Software.
|
||||
*
|
||||
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
|
||||
* FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
|
||||
* COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
|
||||
* IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
|
||||
* CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
||||
|
||||
|
||||
|
||||
if touchScroll is false - update index
|
||||
|
||||
*/
|
||||
(function (global,factory) {
|
||||
"use strict";
|
||||
if (typeof define === 'function' && define.amd) {
|
||||
// AMD. Register as an anonymous module.
|
||||
define(['jquery'], function($) {
|
||||
return factory($, global, global.document);
|
||||
});
|
||||
} else if (typeof module === 'object' && module.exports) {
|
||||
// Node/CommonJS
|
||||
module.exports = factory(require('jquery'), global, global.document);
|
||||
} else {
|
||||
// Browser globals
|
||||
factory(jQuery, global, global.document);
|
||||
}
|
||||
}(typeof window !== 'undefined' ? window : this, function ($, window, document, undefined) {
|
||||
"use strict";
|
||||
var heights = [],
|
||||
names = [],
|
||||
elements = [],
|
||||
overflow = [],
|
||||
index = 0,
|
||||
currentIndex = 0,
|
||||
interstitialIndex = 1,
|
||||
hasLocation = false,
|
||||
timeoutId,
|
||||
timeoutId2,
|
||||
$window = $(window),
|
||||
portHeight,
|
||||
top = $window.scrollTop(),
|
||||
scrollable = false,
|
||||
locked = false,
|
||||
scrolled = false,
|
||||
manualScroll,
|
||||
swipeScroll,
|
||||
util,
|
||||
disabled = false,
|
||||
scrollSamples = [],
|
||||
scrollTime = new Date().getTime(),
|
||||
firstLoad = true,
|
||||
initialised = false,
|
||||
destination = 0,
|
||||
wheelEvent = 'onwheel' in document ? 'wheel' : document.onmousewheel !== undefined ? 'mousewheel' : 'DOMMouseScroll',
|
||||
settings = {
|
||||
//section should be an identifier that is the same for each section
|
||||
section: ".section",
|
||||
sectionName: "section-name",
|
||||
interstitialSection: "",
|
||||
easing: "easeOutExpo",
|
||||
scrollSpeed: 1100,
|
||||
offset: 0,
|
||||
scrollbars: true,
|
||||
target:"html,body",
|
||||
standardScrollElements: false,
|
||||
setHeights: true,
|
||||
overflowScroll:true,
|
||||
updateHash: true,
|
||||
touchScroll:true,
|
||||
before:function() {},
|
||||
after:function() {},
|
||||
afterResize:function() {},
|
||||
afterRender:function() {}
|
||||
};
|
||||
function getportHeight() {
|
||||
return ($window.height() + settings.offset);
|
||||
}
|
||||
function animateScroll(index,instant,callbacks,toTop) {
|
||||
if(currentIndex===index) {
|
||||
callbacks = false;
|
||||
}
|
||||
if(disabled===true) {
|
||||
return true;
|
||||
}
|
||||
if(names[index]) {
|
||||
scrollable = false;
|
||||
if(firstLoad===true) {
|
||||
settings.afterRender();
|
||||
firstLoad = false;
|
||||
}
|
||||
if(callbacks) {
|
||||
if( typeof settings.before == 'function' && settings.before(index,elements) === false ){
|
||||
return true;
|
||||
}
|
||||
}
|
||||
interstitialIndex = 1;
|
||||
destination = heights[index];
|
||||
if(firstLoad===false && currentIndex>index && toTop===false) {
|
||||
//We're going backwards
|
||||
if(overflow[index]) {
|
||||
portHeight = getportHeight();
|
||||
|
||||
interstitialIndex = parseInt(elements[index].outerHeight()/portHeight);
|
||||
|
||||
destination = parseInt(heights[index])+(elements[index].outerHeight()-portHeight);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
if(settings.updateHash && settings.sectionName && !(firstLoad===true && index===0)) {
|
||||
if(history.pushState) {
|
||||
try {
|
||||
history.replaceState(null, null, names[index]);
|
||||
} catch (e) {
|
||||
if(window.console) {
|
||||
console.warn("Scrollify warning: Page must be hosted to manipulate the hash value.");
|
||||
}
|
||||
}
|
||||
|
||||
} else {
|
||||
window.location.hash = names[index];
|
||||
}
|
||||
}
|
||||
|
||||
currentIndex = index;
|
||||
if(instant) {
|
||||
$(settings.target).stop().scrollTop(destination);
|
||||
if(callbacks) {
|
||||
settings.after(index,elements);
|
||||
}
|
||||
} else {
|
||||
locked = true;
|
||||
if( $().velocity ) {
|
||||
$(settings.target).stop().velocity('scroll', {
|
||||
duration: settings.scrollSpeed,
|
||||
easing: settings.easing,
|
||||
offset: destination,
|
||||
mobileHA: false
|
||||
});
|
||||
} else {
|
||||
$(settings.target).stop().animate({
|
||||
scrollTop: destination
|
||||
}, settings.scrollSpeed,settings.easing);
|
||||
}
|
||||
|
||||
if(window.location.hash.length && settings.sectionName && window.console) {
|
||||
try {
|
||||
if($(window.location.hash).length) {
|
||||
console.warn("Scrollify warning: ID matches hash value - this will cause the page to anchor.");
|
||||
}
|
||||
} catch (e) {}
|
||||
}
|
||||
$(settings.target).promise().done(function(){
|
||||
locked = false;
|
||||
firstLoad = false;
|
||||
if(callbacks) {
|
||||
settings.after(index,elements);
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
function isAccelerating(samples) {
|
||||
function average(num) {
|
||||
var sum = 0;
|
||||
|
||||
var lastElements = samples.slice(Math.max(samples.length - num, 1));
|
||||
|
||||
for(var i = 0; i < lastElements.length; i++){
|
||||
sum += lastElements[i];
|
||||
}
|
||||
|
||||
return Math.ceil(sum/num);
|
||||
}
|
||||
|
||||
var avEnd = average(10);
|
||||
var avMiddle = average(70);
|
||||
|
||||
if(avEnd >= avMiddle) {
|
||||
return true;
|
||||
} else {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
var scrollify = function(options) {
|
||||
initialised = true;
|
||||
$.easing['easeOutExpo'] = function(x, t, b, c, d) {
|
||||
return (t==d) ? b+c : c * (-Math.pow(2, -10 * t/d) + 1) + b;
|
||||
};
|
||||
|
||||
manualScroll = {
|
||||
handleMousedown:function() {
|
||||
if(disabled===true) {
|
||||
return true;
|
||||
}
|
||||
scrollable = false;
|
||||
scrolled = false;
|
||||
},
|
||||
handleMouseup:function() {
|
||||
if(disabled===true) {
|
||||
return true;
|
||||
}
|
||||
scrollable = true;
|
||||
if(scrolled) {
|
||||
//instant,callbacks
|
||||
manualScroll.calculateNearest(false,true);
|
||||
}
|
||||
},
|
||||
handleScroll:function() {
|
||||
if(disabled===true) {
|
||||
return true;
|
||||
}
|
||||
if(timeoutId){
|
||||
clearTimeout(timeoutId);
|
||||
}
|
||||
|
||||
timeoutId = setTimeout(function(){
|
||||
scrolled = true;
|
||||
if(scrollable===false) {
|
||||
return false;
|
||||
}
|
||||
scrollable = false;
|
||||
//instant,callbacks
|
||||
manualScroll.calculateNearest(false,true);
|
||||
}, 200);
|
||||
},
|
||||
calculateNearest:function(instant,callbacks) {
|
||||
top = $window.scrollTop();
|
||||
var i =1,
|
||||
max = heights.length,
|
||||
closest = 0,
|
||||
prev = Math.abs(heights[0] - top),
|
||||
diff;
|
||||
for(;i<max;i++) {
|
||||
diff = Math.abs(heights[i] - top);
|
||||
|
||||
if(diff < prev) {
|
||||
prev = diff;
|
||||
closest = i;
|
||||
}
|
||||
}
|
||||
if((atBottom() && closest>index) || atTop()) {
|
||||
index = closest;
|
||||
//index, instant, callbacks, toTop
|
||||
animateScroll(closest,instant,callbacks,false);
|
||||
}
|
||||
},
|
||||
wheelHandler:function(e) {
|
||||
if(disabled===true) {
|
||||
return true;
|
||||
} else if(settings.standardScrollElements) {
|
||||
if($(e.target).is(settings.standardScrollElements) || $(e.target).closest(settings.standardScrollElements).length) {
|
||||
return true;
|
||||
}
|
||||
}
|
||||
if(!overflow[index]) {
|
||||
e.preventDefault();
|
||||
}
|
||||
var currentScrollTime = new Date().getTime();
|
||||
|
||||
|
||||
e = e || window.event;
|
||||
var value = e.originalEvent.wheelDelta || -e.originalEvent.deltaY || -e.originalEvent.detail;
|
||||
var delta = Math.max(-1, Math.min(1, value));
|
||||
|
||||
//delta = delta || -e.originalEvent.detail / 3 || e.originalEvent.wheelDelta / 120;
|
||||
|
||||
if(scrollSamples.length > 149){
|
||||
scrollSamples.shift();
|
||||
}
|
||||
//scrollSamples.push(Math.abs(delta*10));
|
||||
scrollSamples.push(Math.abs(value));
|
||||
|
||||
if((currentScrollTime-scrollTime) > 200){
|
||||
scrollSamples = [];
|
||||
}
|
||||
scrollTime = currentScrollTime;
|
||||
|
||||
|
||||
if(locked) {
|
||||
return false;
|
||||
}
|
||||
if(delta<0) {
|
||||
if(index<heights.length-1) {
|
||||
if(atBottom()) {
|
||||
if(isAccelerating(scrollSamples)) {
|
||||
e.preventDefault();
|
||||
index++;
|
||||
locked = true;
|
||||
//index, instant, callbacks, toTop
|
||||
animateScroll(index,false,true, false);
|
||||
} else {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
}
|
||||
} else if(delta>0) {
|
||||
if(index>0) {
|
||||
if(atTop()) {
|
||||
if(isAccelerating(scrollSamples)) {
|
||||
e.preventDefault();
|
||||
index--;
|
||||
locked = true;
|
||||
//index, instant, callbacks, toTop
|
||||
animateScroll(index,false,true, false);
|
||||
} else {
|
||||
return false
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
},
|
||||
keyHandler:function(e) {
|
||||
if(disabled===true || document.activeElement.readOnly===false) {
|
||||
return true;
|
||||
} else if(settings.standardScrollElements) {
|
||||
if($(e.target).is(settings.standardScrollElements) || $(e.target).closest(settings.standardScrollElements).length) {
|
||||
return true;
|
||||
}
|
||||
}
|
||||
if(locked===true) {
|
||||
return false;
|
||||
}
|
||||
if(e.keyCode==38 || e.keyCode==33) {
|
||||
if(index>0) {
|
||||
if(atTop()) {
|
||||
e.preventDefault();
|
||||
index--;
|
||||
//index, instant, callbacks, toTop
|
||||
animateScroll(index,false,true,false);
|
||||
}
|
||||
}
|
||||
} else if(e.keyCode==40 || e.keyCode==34) {
|
||||
if(index<heights.length-1) {
|
||||
if(atBottom()) {
|
||||
e.preventDefault();
|
||||
index++;
|
||||
//index, instant, callbacks, toTop
|
||||
animateScroll(index,false,true,false);
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
init:function() {
|
||||
if(settings.scrollbars) {
|
||||
$window.on('mousedown', manualScroll.handleMousedown);
|
||||
$window.on('mouseup', manualScroll.handleMouseup);
|
||||
$window.on('scroll', manualScroll.handleScroll);
|
||||
} else {
|
||||
$("body").css({"overflow":"hidden"});
|
||||
}
|
||||
$window.on(wheelEvent,manualScroll.wheelHandler);
|
||||
//$(document).bind(wheelEvent,manualScroll.wheelHandler);
|
||||
$window.on('keydown', manualScroll.keyHandler);
|
||||
}
|
||||
};
|
||||
|
||||
swipeScroll = {
|
||||
touches : {
|
||||
"touchstart": {"y":-1,"x":-1},
|
||||
"touchmove" : {"y":-1,"x":-1},
|
||||
"touchend" : false,
|
||||
"direction" : "undetermined"
|
||||
},
|
||||
options:{
|
||||
"distance" : 30,
|
||||
"timeGap" : 800,
|
||||
"timeStamp" : new Date().getTime()
|
||||
},
|
||||
touchHandler: function(event) {
|
||||
if(disabled===true) {
|
||||
return true;
|
||||
} else if(settings.standardScrollElements) {
|
||||
if($(event.target).is(settings.standardScrollElements) || $(event.target).closest(settings.standardScrollElements).length) {
|
||||
return true;
|
||||
}
|
||||
}
|
||||
var touch;
|
||||
if (typeof event !== 'undefined'){
|
||||
if (typeof event.touches !== 'undefined') {
|
||||
touch = event.touches[0];
|
||||
switch (event.type) {
|
||||
case 'touchstart':
|
||||
swipeScroll.touches.touchstart.y = touch.pageY;
|
||||
swipeScroll.touches.touchmove.y = -1;
|
||||
|
||||
swipeScroll.touches.touchstart.x = touch.pageX;
|
||||
swipeScroll.touches.touchmove.x = -1;
|
||||
|
||||
swipeScroll.options.timeStamp = new Date().getTime();
|
||||
swipeScroll.touches.touchend = false;
|
||||
case 'touchmove':
|
||||
swipeScroll.touches.touchmove.y = touch.pageY;
|
||||
swipeScroll.touches.touchmove.x = touch.pageX;
|
||||
if(swipeScroll.touches.touchstart.y!==swipeScroll.touches.touchmove.y && (Math.abs(swipeScroll.touches.touchstart.y-swipeScroll.touches.touchmove.y)>Math.abs(swipeScroll.touches.touchstart.x-swipeScroll.touches.touchmove.x))) {
|
||||
//if(!overflow[index]) {
|
||||
event.preventDefault();
|
||||
//}
|
||||
swipeScroll.touches.direction = "y";
|
||||
if((swipeScroll.options.timeStamp+swipeScroll.options.timeGap)<(new Date().getTime()) && swipeScroll.touches.touchend == false) {
|
||||
|
||||
swipeScroll.touches.touchend = true;
|
||||
if (swipeScroll.touches.touchstart.y > -1) {
|
||||
|
||||
if(Math.abs(swipeScroll.touches.touchmove.y-swipeScroll.touches.touchstart.y)>swipeScroll.options.distance) {
|
||||
if(swipeScroll.touches.touchstart.y < swipeScroll.touches.touchmove.y) {
|
||||
|
||||
swipeScroll.up();
|
||||
|
||||
} else {
|
||||
swipeScroll.down();
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
break;
|
||||
case 'touchend':
|
||||
if(swipeScroll.touches[event.type]===false) {
|
||||
swipeScroll.touches[event.type] = true;
|
||||
if (swipeScroll.touches.touchstart.y > -1 && swipeScroll.touches.touchmove.y > -1 && swipeScroll.touches.direction==="y") {
|
||||
|
||||
if(Math.abs(swipeScroll.touches.touchmove.y-swipeScroll.touches.touchstart.y)>swipeScroll.options.distance) {
|
||||
if(swipeScroll.touches.touchstart.y < swipeScroll.touches.touchmove.y) {
|
||||
swipeScroll.up();
|
||||
|
||||
} else {
|
||||
swipeScroll.down();
|
||||
|
||||
}
|
||||
}
|
||||
swipeScroll.touches.touchstart.y = -1;
|
||||
swipeScroll.touches.touchstart.x = -1;
|
||||
swipeScroll.touches.direction = "undetermined";
|
||||
}
|
||||
}
|
||||
default:
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
down: function() {
|
||||
|
||||
if(index<heights.length) {
|
||||
|
||||
if(atBottom() && index<heights.length-1) {
|
||||
|
||||
index++;
|
||||
//index, instant, callbacks, toTop
|
||||
animateScroll(index,false,true,false);
|
||||
} else {
|
||||
portHeight = getportHeight();
|
||||
if(Math.floor(elements[index].height()/portHeight)>interstitialIndex) {
|
||||
|
||||
interstitialScroll(parseInt(heights[index])+(portHeight*interstitialIndex));
|
||||
interstitialIndex += 1;
|
||||
|
||||
} else {
|
||||
interstitialScroll(parseInt(heights[index])+(elements[index].outerHeight()-portHeight));
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
},
|
||||
up: function() {
|
||||
if(index>=0) {
|
||||
if(atTop() && index>0) {
|
||||
|
||||
index--;
|
||||
//index, instant, callbacks, toTop
|
||||
animateScroll(index,false,true,false);
|
||||
} else {
|
||||
|
||||
if(interstitialIndex>2) {
|
||||
portHeight = getportHeight();
|
||||
|
||||
interstitialIndex -= 1;
|
||||
interstitialScroll(parseInt(heights[index])+(portHeight*interstitialIndex));
|
||||
|
||||
} else {
|
||||
|
||||
interstitialIndex = 1;
|
||||
interstitialScroll(parseInt(heights[index]));
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
},
|
||||
init: function() {
|
||||
if (document.addEventListener && settings.touchScroll) {
|
||||
var eventListenerOptions = {
|
||||
passive: false
|
||||
};
|
||||
document.addEventListener('touchstart', swipeScroll.touchHandler, eventListenerOptions);
|
||||
document.addEventListener('touchmove', swipeScroll.touchHandler, eventListenerOptions);
|
||||
document.addEventListener('touchend', swipeScroll.touchHandler, eventListenerOptions);
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
util = {
|
||||
refresh:function(withCallback,scroll) {
|
||||
clearTimeout(timeoutId2);
|
||||
timeoutId2 = setTimeout(function() {
|
||||
//retain position
|
||||
sizePanels(true);
|
||||
//scroll, firstLoad
|
||||
calculatePositions(scroll,false);
|
||||
if(withCallback) {
|
||||
settings.afterResize();
|
||||
}
|
||||
},400);
|
||||
},
|
||||
handleUpdate:function() {
|
||||
//callbacks, scroll
|
||||
//changed from false,true to false,false
|
||||
util.refresh(false,false);
|
||||
},
|
||||
handleResize:function() {
|
||||
//callbacks, scroll
|
||||
util.refresh(true,false);
|
||||
},
|
||||
handleOrientation:function() {
|
||||
//callbacks, scroll
|
||||
util.refresh(true,true);
|
||||
}
|
||||
};
|
||||
settings = $.extend(settings, options);
|
||||
|
||||
//retain position
|
||||
sizePanels(false);
|
||||
|
||||
calculatePositions(false,true);
|
||||
|
||||
if(true===hasLocation) {
|
||||
//index, instant, callbacks, toTop
|
||||
animateScroll(index,false,true,true);
|
||||
} else {
|
||||
setTimeout(function() {
|
||||
//instant,callbacks
|
||||
manualScroll.calculateNearest(true,false);
|
||||
},200);
|
||||
}
|
||||
if(heights.length) {
|
||||
manualScroll.init();
|
||||
swipeScroll.init();
|
||||
|
||||
$window.on("resize",util.handleResize);
|
||||
if (document.addEventListener) {
|
||||
window.addEventListener("orientationchange", util.handleOrientation, false);
|
||||
}
|
||||
}
|
||||
function interstitialScroll(pos) {
|
||||
if( $().velocity ) {
|
||||
$(settings.target).stop().velocity('scroll', {
|
||||
duration: settings.scrollSpeed,
|
||||
easing: settings.easing,
|
||||
offset: pos,
|
||||
mobileHA: false
|
||||
});
|
||||
} else {
|
||||
$(settings.target).stop().animate({
|
||||
scrollTop: pos
|
||||
}, settings.scrollSpeed,settings.easing);
|
||||
}
|
||||
}
|
||||
|
||||
function sizePanels(keepPosition) {
|
||||
if(keepPosition) {
|
||||
top = $window.scrollTop();
|
||||
}
|
||||
|
||||
var selector = settings.section;
|
||||
overflow = [];
|
||||
if(settings.interstitialSection.length) {
|
||||
selector += "," + settings.interstitialSection;
|
||||
}
|
||||
if(settings.scrollbars===false) {
|
||||
settings.overflowScroll = false;
|
||||
}
|
||||
portHeight = getportHeight();
|
||||
$(selector).each(function(i) {
|
||||
var $this = $(this);
|
||||
|
||||
if(settings.setHeights) {
|
||||
if($this.is(settings.interstitialSection)) {
|
||||
overflow[i] = false;
|
||||
} else {
|
||||
if(($this.css("height","auto").outerHeight()<portHeight) || $this.css("overflow")==="hidden") {
|
||||
$this.css({"height":portHeight});
|
||||
|
||||
overflow[i] = false;
|
||||
} else {
|
||||
|
||||
$this.css({"height":$this.outerHeight()});
|
||||
|
||||
if(settings.overflowScroll) {
|
||||
overflow[i] = true;
|
||||
} else {
|
||||
overflow[i] = false;
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
} else {
|
||||
|
||||
if(($this.outerHeight()<portHeight) || (settings.overflowScroll===false)) {
|
||||
overflow[i] = false;
|
||||
} else {
|
||||
overflow[i] = true;
|
||||
}
|
||||
}
|
||||
});
|
||||
if(keepPosition) {
|
||||
$window.scrollTop(top);
|
||||
}
|
||||
}
|
||||
function calculatePositions(scroll,firstLoad) {
|
||||
var selector = settings.section;
|
||||
if(settings.interstitialSection.length) {
|
||||
selector += "," + settings.interstitialSection;
|
||||
}
|
||||
heights = [];
|
||||
names = [];
|
||||
elements = [];
|
||||
$(selector).each(function(i){
|
||||
var $this = $(this);
|
||||
if(i>0) {
|
||||
heights[i] = parseInt($this.offset().top) + settings.offset;
|
||||
} else {
|
||||
heights[i] = parseInt($this.offset().top);
|
||||
}
|
||||
if(settings.sectionName && $this.data(settings.sectionName)) {
|
||||
names[i] = "#" + $this.data(settings.sectionName).toString().replace(/ /g,"-");
|
||||
} else {
|
||||
if($this.is(settings.interstitialSection)===false) {
|
||||
names[i] = "#" + (i + 1);
|
||||
} else {
|
||||
names[i] = "#";
|
||||
if(i===$(selector).length-1 && i>1) {
|
||||
heights[i] = heights[i-1] + (parseInt($($(selector)[i-1]).outerHeight()) - parseInt($(window).height())) + parseInt($this.outerHeight());
|
||||
}
|
||||
}
|
||||
}
|
||||
elements[i] = $this;
|
||||
try {
|
||||
if($(names[i]).length && window.console) {
|
||||
console.warn("Scrollify warning: Section names can't match IDs - this will cause the browser to anchor.");
|
||||
}
|
||||
} catch (e) {}
|
||||
|
||||
if(window.location.hash===names[i]) {
|
||||
index = i;
|
||||
hasLocation = true;
|
||||
}
|
||||
|
||||
});
|
||||
|
||||
if(true===scroll) {
|
||||
//index, instant, callbacks, toTop
|
||||
animateScroll(index,false,false,false);
|
||||
}
|
||||
}
|
||||
|
||||
function atTop() {
|
||||
if(!overflow[index]) {
|
||||
return true;
|
||||
}
|
||||
top = $window.scrollTop();
|
||||
if(top>parseInt(heights[index])) {
|
||||
return false;
|
||||
} else {
|
||||
return true;
|
||||
}
|
||||
}
|
||||
function atBottom() {
|
||||
if(!overflow[index]) {
|
||||
return true;
|
||||
}
|
||||
top = $window.scrollTop();
|
||||
portHeight = getportHeight();
|
||||
|
||||
if(top<parseInt(heights[index])+(elements[index].outerHeight()-portHeight)-28) {
|
||||
|
||||
return false;
|
||||
|
||||
} else {
|
||||
return true;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
function move(panel,instant) {
|
||||
var z = names.length;
|
||||
for(;z>=0;z--) {
|
||||
if(typeof panel === 'string') {
|
||||
if (names[z]===panel) {
|
||||
index = z;
|
||||
//index, instant, callbacks, toTop
|
||||
animateScroll(z,instant,true,true);
|
||||
}
|
||||
} else {
|
||||
if(z===panel) {
|
||||
index = z;
|
||||
//index, instant, callbacks, toTop
|
||||
animateScroll(z,instant,true,true);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
scrollify.move = function(panel) {
|
||||
if(panel===undefined) {
|
||||
return false;
|
||||
}
|
||||
if(panel.originalEvent) {
|
||||
panel = $(this).attr("href");
|
||||
}
|
||||
move(panel,false);
|
||||
};
|
||||
scrollify.instantMove = function(panel) {
|
||||
if(panel===undefined) {
|
||||
return false;
|
||||
}
|
||||
move(panel,true);
|
||||
};
|
||||
scrollify.next = function() {
|
||||
if(index<names.length) {
|
||||
index += 1;
|
||||
//index, instant, callbacks, toTop
|
||||
animateScroll(index,false,true,true);
|
||||
}
|
||||
};
|
||||
scrollify.previous = function() {
|
||||
if(index>0) {
|
||||
index -= 1;
|
||||
//index, instant, callbacks, toTop
|
||||
animateScroll(index,false,true,true);
|
||||
}
|
||||
};
|
||||
scrollify.instantNext = function() {
|
||||
if(index<names.length) {
|
||||
index += 1;
|
||||
//index, instant, callbacks, toTop
|
||||
animateScroll(index,true,true,true);
|
||||
}
|
||||
};
|
||||
scrollify.instantPrevious = function() {
|
||||
if(index>0) {
|
||||
index -= 1;
|
||||
//index, instant, callbacks, toTop
|
||||
animateScroll(index,true,true,true);
|
||||
}
|
||||
};
|
||||
scrollify.destroy = function() {
|
||||
if(!initialised) {
|
||||
return false;
|
||||
}
|
||||
if(settings.setHeights) {
|
||||
$(settings.section).each(function() {
|
||||
$(this).css("height","auto");
|
||||
});
|
||||
}
|
||||
$window.off("resize",util.handleResize);
|
||||
if(settings.scrollbars) {
|
||||
$window.off('mousedown', manualScroll.handleMousedown);
|
||||
$window.off('mouseup', manualScroll.handleMouseup);
|
||||
$window.off('scroll', manualScroll.handleScroll);
|
||||
}
|
||||
$window.off(wheelEvent,manualScroll.wheelHandler);
|
||||
$window.off('keydown', manualScroll.keyHandler);
|
||||
|
||||
if (document.addEventListener && settings.touchScroll) {
|
||||
document.removeEventListener('touchstart', swipeScroll.touchHandler, false);
|
||||
document.removeEventListener('touchmove', swipeScroll.touchHandler, false);
|
||||
document.removeEventListener('touchend', swipeScroll.touchHandler, false);
|
||||
}
|
||||
heights = [];
|
||||
names = [];
|
||||
elements = [];
|
||||
overflow = [];
|
||||
};
|
||||
scrollify.update = function() {
|
||||
if(!initialised) {
|
||||
return false;
|
||||
}
|
||||
util.handleUpdate();
|
||||
};
|
||||
scrollify.current = function() {
|
||||
return elements[index];
|
||||
};
|
||||
scrollify.currentIndex = function() {
|
||||
return index;
|
||||
};
|
||||
scrollify.disable = function() {
|
||||
disabled = true;
|
||||
};
|
||||
scrollify.enable = function() {
|
||||
disabled = false;
|
||||
if (initialised) {
|
||||
//instant,callbacks
|
||||
manualScroll.calculateNearest(false,false);
|
||||
}
|
||||
};
|
||||
scrollify.isDisabled = function() {
|
||||
return disabled;
|
||||
};
|
||||
scrollify.setOptions = function(updatedOptions) {
|
||||
if(!initialised) {
|
||||
return false;
|
||||
}
|
||||
if(typeof updatedOptions === "object") {
|
||||
settings = $.extend(settings, updatedOptions);
|
||||
util.handleUpdate();
|
||||
} else if(window.console) {
|
||||
console.warn("Scrollify warning: setOptions expects an object.");
|
||||
}
|
||||
};
|
||||
$.scrollify = scrollify;
|
||||
return scrollify;
|
||||
}));
|
||||
37
assets/js/vendor/scrollify/package.json
vendored
Normal file
37
assets/js/vendor/scrollify/package.json
vendored
Normal file
@@ -0,0 +1,37 @@
|
||||
{
|
||||
"name": "jquery-scrollify",
|
||||
"version": "1.0.19",
|
||||
"description": "A jQuery plugin that assists scrolling and smoothly snaps to sections.",
|
||||
"main": "jquery.scrollify.js",
|
||||
"scripts": {
|
||||
"test": "mocha ./test/scrollify_test.js --recursive ./test"
|
||||
},
|
||||
"repository": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/lukehaas/Scrollify.git"
|
||||
},
|
||||
"keywords": [
|
||||
"scroll",
|
||||
"jquery-plugin",
|
||||
"ecosystem:jquery",
|
||||
"snap",
|
||||
"page"
|
||||
],
|
||||
"dependencies": {
|
||||
"jquery": ">=1.7"
|
||||
},
|
||||
"author": "Luke Haas",
|
||||
"license": "MIT",
|
||||
"bugs": {
|
||||
"url": "https://github.com/lukehaas/Scrollify/issues"
|
||||
},
|
||||
"demo": "http://projects.lukehaas.me/scrollify",
|
||||
"homepage": "https://github.com/lukehaas/Scrollify",
|
||||
"devDependencies": {
|
||||
"chai": "^3.5.0",
|
||||
"chai-jquery": "^2.0.0",
|
||||
"jquery": "^3.1.1",
|
||||
"jsdom": "^9.8.3",
|
||||
"mocha": "^3.1.2"
|
||||
}
|
||||
}
|
||||
34
assets/js/vendor/scrollify/scrollify.jquery.json
vendored
Normal file
34
assets/js/vendor/scrollify/scrollify.jquery.json
vendored
Normal file
@@ -0,0 +1,34 @@
|
||||
{
|
||||
"name": "scrollify",
|
||||
"title": "jQuery Scrollify",
|
||||
"description": "A jQuery plugin that assists scrolling and smoothly snaps to sections.",
|
||||
"keywords": [
|
||||
"scroll",
|
||||
"snap"
|
||||
],
|
||||
"version": "1.0.19",
|
||||
"author": {
|
||||
"name": "Luke Haas",
|
||||
"url": "http://lukehaas.me"
|
||||
},
|
||||
"maintainers": [
|
||||
{
|
||||
"name": "Luke Haas",
|
||||
"email": "",
|
||||
"url": "http://lukehaas.me"
|
||||
}
|
||||
],
|
||||
"licenses": [
|
||||
{
|
||||
"type": "MIT",
|
||||
"url": "https://github.com/lukehaas/Scrollify/blob/master/LICENSE"
|
||||
}
|
||||
],
|
||||
"bugs": "https://github.com/lukehaas/Scrollify/issues",
|
||||
"homepage": "http://projects.lukehaas.me/scrollify",
|
||||
"docs": "https://github.com/lukehaas/Scrollify",
|
||||
"download": "https://github.com/lukehaas/Scrollify",
|
||||
"dependencies": {
|
||||
"jquery": ">=1.7"
|
||||
}
|
||||
}
|
||||
3
assets/js/vendor/select2/i18n/af.js
vendored
Normal file
3
assets/js/vendor/select2/i18n/af.js
vendored
Normal file
@@ -0,0 +1,3 @@
|
||||
/*! Select2 4.1.0-beta.0 | https://github.com/select2/select2/blob/master/LICENSE.md */
|
||||
|
||||
!function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;e.define("select2/i18n/af",[],function(){return{errorLoading:function(){return"Die resultate kon nie gelaai word nie."},inputTooLong:function(e){var n=e.input.length-e.maximum,r="Verwyders asseblief "+n+" character";return 1!=n&&(r+="s"),r},inputTooShort:function(e){return"Voer asseblief "+(e.minimum-e.input.length)+" of meer karakters"},loadingMore:function(){return"Meer resultate word gelaai…"},maximumSelected:function(e){var n="Kies asseblief net "+e.maximum+" item";return 1!=e.maximum&&(n+="s"),n},noResults:function(){return"Geen resultate gevind"},searching:function(){return"Besig…"},removeAllItems:function(){return"Verwyder alle items"}}}),e.define,e.require}();
|
||||
3
assets/js/vendor/select2/i18n/ar.js
vendored
Normal file
3
assets/js/vendor/select2/i18n/ar.js
vendored
Normal file
@@ -0,0 +1,3 @@
|
||||
/*! Select2 4.1.0-beta.0 | https://github.com/select2/select2/blob/master/LICENSE.md */
|
||||
|
||||
!function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var n=jQuery.fn.select2.amd;n.define("select2/i18n/ar",[],function(){return{errorLoading:function(){return"لا يمكن تحميل النتائج"},inputTooLong:function(n){return"الرجاء حذف "+(n.input.length-n.maximum)+" عناصر"},inputTooShort:function(n){return"الرجاء إضافة "+(n.minimum-n.input.length)+" عناصر"},loadingMore:function(){return"جاري تحميل نتائج إضافية..."},maximumSelected:function(n){return"تستطيع إختيار "+n.maximum+" بنود فقط"},noResults:function(){return"لم يتم العثور على أي نتائج"},searching:function(){return"جاري البحث…"},removeAllItems:function(){return"قم بإزالة كل العناصر"}}}),n.define,n.require}();
|
||||
3
assets/js/vendor/select2/i18n/az.js
vendored
Normal file
3
assets/js/vendor/select2/i18n/az.js
vendored
Normal file
@@ -0,0 +1,3 @@
|
||||
/*! Select2 4.1.0-beta.0 | https://github.com/select2/select2/blob/master/LICENSE.md */
|
||||
|
||||
!function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var n=jQuery.fn.select2.amd;n.define("select2/i18n/az",[],function(){return{inputTooLong:function(n){return n.input.length-n.maximum+" simvol silin"},inputTooShort:function(n){return n.minimum-n.input.length+" simvol daxil edin"},loadingMore:function(){return"Daha çox nəticə yüklənir…"},maximumSelected:function(n){return"Sadəcə "+n.maximum+" element seçə bilərsiniz"},noResults:function(){return"Nəticə tapılmadı"},searching:function(){return"Axtarılır…"},removeAllItems:function(){return"Bütün elementləri sil"}}}),n.define,n.require}();
|
||||
3
assets/js/vendor/select2/i18n/bg.js
vendored
Normal file
3
assets/js/vendor/select2/i18n/bg.js
vendored
Normal file
@@ -0,0 +1,3 @@
|
||||
/*! Select2 4.1.0-beta.0 | https://github.com/select2/select2/blob/master/LICENSE.md */
|
||||
|
||||
!function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var n=jQuery.fn.select2.amd;n.define("select2/i18n/bg",[],function(){return{inputTooLong:function(n){var e=n.input.length-n.maximum,u="Моля въведете с "+e+" по-малко символ";return e>1&&(u+="a"),u},inputTooShort:function(n){var e=n.minimum-n.input.length,u="Моля въведете още "+e+" символ";return e>1&&(u+="a"),u},loadingMore:function(){return"Зареждат се още…"},maximumSelected:function(n){var e="Можете да направите до "+n.maximum+" ";return n.maximum>1?e+="избора":e+="избор",e},noResults:function(){return"Няма намерени съвпадения"},searching:function(){return"Търсене…"},removeAllItems:function(){return"Премахнете всички елементи"}}}),n.define,n.require}();
|
||||
3
assets/js/vendor/select2/i18n/bn.js
vendored
Normal file
3
assets/js/vendor/select2/i18n/bn.js
vendored
Normal file
@@ -0,0 +1,3 @@
|
||||
/*! Select2 4.1.0-beta.0 | https://github.com/select2/select2/blob/master/LICENSE.md */
|
||||
|
||||
!function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var n=jQuery.fn.select2.amd;n.define("select2/i18n/bn",[],function(){return{errorLoading:function(){return"ফলাফলগুলি লোড করা যায়নি।"},inputTooLong:function(n){var e=n.input.length-n.maximum,u="অনুগ্রহ করে "+e+" টি অক্ষর মুছে দিন।";return 1!=e&&(u="অনুগ্রহ করে "+e+" টি অক্ষর মুছে দিন।"),u},inputTooShort:function(n){return n.minimum-n.input.length+" টি অক্ষর অথবা অধিক অক্ষর লিখুন।"},loadingMore:function(){return"আরো ফলাফল লোড হচ্ছে ..."},maximumSelected:function(n){var e=n.maximum+" টি আইটেম নির্বাচন করতে পারবেন।";return 1!=n.maximum&&(e=n.maximum+" টি আইটেম নির্বাচন করতে পারবেন।"),e},noResults:function(){return"কোন ফলাফল পাওয়া যায়নি।"},searching:function(){return"অনুসন্ধান করা হচ্ছে ..."}}}),n.define,n.require}();
|
||||
3
assets/js/vendor/select2/i18n/bs.js
vendored
Normal file
3
assets/js/vendor/select2/i18n/bs.js
vendored
Normal file
@@ -0,0 +1,3 @@
|
||||
/*! Select2 4.1.0-beta.0 | https://github.com/select2/select2/blob/master/LICENSE.md */
|
||||
|
||||
!function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;e.define("select2/i18n/bs",[],function(){function e(e,n,r,t){return e%10==1&&e%100!=11?n:e%10>=2&&e%10<=4&&(e%100<12||e%100>14)?r:t}return{errorLoading:function(){return"Preuzimanje nije uspijelo."},inputTooLong:function(n){var r=n.input.length-n.maximum,t="Obrišite "+r+" simbol";return t+=e(r,"","a","a")},inputTooShort:function(n){var r=n.minimum-n.input.length,t="Ukucajte bar još "+r+" simbol";return t+=e(r,"","a","a")},loadingMore:function(){return"Preuzimanje još rezultata…"},maximumSelected:function(n){var r="Možete izabrati samo "+n.maximum+" stavk";return r+=e(n.maximum,"u","e","i")},noResults:function(){return"Ništa nije pronađeno"},searching:function(){return"Pretraga…"},removeAllItems:function(){return"Uklonite sve stavke"}}}),e.define,e.require}();
|
||||
3
assets/js/vendor/select2/i18n/ca.js
vendored
Normal file
3
assets/js/vendor/select2/i18n/ca.js
vendored
Normal file
@@ -0,0 +1,3 @@
|
||||
/*! Select2 4.1.0-beta.0 | https://github.com/select2/select2/blob/master/LICENSE.md */
|
||||
|
||||
!function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;e.define("select2/i18n/ca",[],function(){return{errorLoading:function(){return"La càrrega ha fallat"},inputTooLong:function(e){var n=e.input.length-e.maximum,r="Si us plau, elimina "+n+" car";return r+=1==n?"àcter":"àcters"},inputTooShort:function(e){var n=e.minimum-e.input.length,r="Si us plau, introdueix "+n+" car";return r+=1==n?"àcter":"àcters"},loadingMore:function(){return"Carregant més resultats…"},maximumSelected:function(e){var n="Només es pot seleccionar "+e.maximum+" element";return 1!=e.maximum&&(n+="s"),n},noResults:function(){return"No s'han trobat resultats"},searching:function(){return"Cercant…"},removeAllItems:function(){return"Treu tots els elements"}}}),e.define,e.require}();
|
||||
3
assets/js/vendor/select2/i18n/cs.js
vendored
Normal file
3
assets/js/vendor/select2/i18n/cs.js
vendored
Normal file
@@ -0,0 +1,3 @@
|
||||
/*! Select2 4.1.0-beta.0 | https://github.com/select2/select2/blob/master/LICENSE.md */
|
||||
|
||||
!function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;e.define("select2/i18n/cs",[],function(){function e(e,n){switch(e){case 2:return n?"dva":"dvě";case 3:return"tři";case 4:return"čtyři"}return""}return{errorLoading:function(){return"Výsledky nemohly být načteny."},inputTooLong:function(n){var t=n.input.length-n.maximum;return 1==t?"Prosím, zadejte o jeden znak méně.":t<=4?"Prosím, zadejte o "+e(t,!0)+" znaky méně.":"Prosím, zadejte o "+t+" znaků méně."},inputTooShort:function(n){var t=n.minimum-n.input.length;return 1==t?"Prosím, zadejte ještě jeden znak.":t<=4?"Prosím, zadejte ještě další "+e(t,!0)+" znaky.":"Prosím, zadejte ještě dalších "+t+" znaků."},loadingMore:function(){return"Načítají se další výsledky…"},maximumSelected:function(n){var t=n.maximum;return 1==t?"Můžete zvolit jen jednu položku.":t<=4?"Můžete zvolit maximálně "+e(t,!1)+" položky.":"Můžete zvolit maximálně "+t+" položek."},noResults:function(){return"Nenalezeny žádné položky."},searching:function(){return"Vyhledávání…"},removeAllItems:function(){return"Odstraňte všechny položky"}}}),e.define,e.require}();
|
||||
3
assets/js/vendor/select2/i18n/da.js
vendored
Normal file
3
assets/js/vendor/select2/i18n/da.js
vendored
Normal file
@@ -0,0 +1,3 @@
|
||||
/*! Select2 4.1.0-beta.0 | https://github.com/select2/select2/blob/master/LICENSE.md */
|
||||
|
||||
!function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;e.define("select2/i18n/da",[],function(){return{errorLoading:function(){return"Resultaterne kunne ikke indlæses."},inputTooLong:function(e){return"Angiv venligst "+(e.input.length-e.maximum)+" tegn mindre"},inputTooShort:function(e){return"Angiv venligst "+(e.minimum-e.input.length)+" tegn mere"},loadingMore:function(){return"Indlæser flere resultater…"},maximumSelected:function(e){var n="Du kan kun vælge "+e.maximum+" emne";return 1!=e.maximum&&(n+="r"),n},noResults:function(){return"Ingen resultater fundet"},searching:function(){return"Søger…"},removeAllItems:function(){return"Fjern alle elementer"}}}),e.define,e.require}();
|
||||
3
assets/js/vendor/select2/i18n/de.js
vendored
Normal file
3
assets/js/vendor/select2/i18n/de.js
vendored
Normal file
@@ -0,0 +1,3 @@
|
||||
/*! Select2 4.1.0-beta.0 | https://github.com/select2/select2/blob/master/LICENSE.md */
|
||||
|
||||
!function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;e.define("select2/i18n/de",[],function(){return{errorLoading:function(){return"Die Ergebnisse konnten nicht geladen werden."},inputTooLong:function(e){return"Bitte "+(e.input.length-e.maximum)+" Zeichen weniger eingeben"},inputTooShort:function(e){return"Bitte "+(e.minimum-e.input.length)+" Zeichen mehr eingeben"},loadingMore:function(){return"Lade mehr Ergebnisse…"},maximumSelected:function(e){var n="Sie können nur "+e.maximum+" Element";return 1!=e.maximum&&(n+="e"),n+=" auswählen"},noResults:function(){return"Keine Übereinstimmungen gefunden"},searching:function(){return"Suche…"},removeAllItems:function(){return"Entferne alle Elemente"}}}),e.define,e.require}();
|
||||
3
assets/js/vendor/select2/i18n/dsb.js
vendored
Normal file
3
assets/js/vendor/select2/i18n/dsb.js
vendored
Normal file
@@ -0,0 +1,3 @@
|
||||
/*! Select2 4.1.0-beta.0 | https://github.com/select2/select2/blob/master/LICENSE.md */
|
||||
|
||||
!function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var n=jQuery.fn.select2.amd;n.define("select2/i18n/dsb",[],function(){var n=["znamuško","znamušce","znamuška","znamuškow"],e=["zapisk","zapiska","zapiski","zapiskow"],u=function(n,e){return 1===n?e[0]:2===n?e[1]:n>2&&n<=4?e[2]:n>=5?e[3]:void 0};return{errorLoading:function(){return"Wuslědki njejsu se dali zacytaś."},inputTooLong:function(e){var a=e.input.length-e.maximum;return"Pšosym lašuj "+a+" "+u(a,n)},inputTooShort:function(e){var a=e.minimum-e.input.length;return"Pšosym zapódaj nanejmjenjej "+a+" "+u(a,n)},loadingMore:function(){return"Dalšne wuslědki se zacytaju…"},maximumSelected:function(n){return"Móžoš jano "+n.maximum+" "+u(n.maximum,e)+"wubraś."},noResults:function(){return"Žedne wuslědki namakane"},searching:function(){return"Pyta se…"},removeAllItems:function(){return"Remove all items"}}}),n.define,n.require}();
|
||||
3
assets/js/vendor/select2/i18n/el.js
vendored
Normal file
3
assets/js/vendor/select2/i18n/el.js
vendored
Normal file
@@ -0,0 +1,3 @@
|
||||
/*! Select2 4.1.0-beta.0 | https://github.com/select2/select2/blob/master/LICENSE.md */
|
||||
|
||||
!function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var n=jQuery.fn.select2.amd;n.define("select2/i18n/el",[],function(){return{errorLoading:function(){return"Τα αποτελέσματα δεν μπόρεσαν να φορτώσουν."},inputTooLong:function(n){var e=n.input.length-n.maximum,u="Παρακαλώ διαγράψτε "+e+" χαρακτήρ";return 1==e&&(u+="α"),1!=e&&(u+="ες"),u},inputTooShort:function(n){return"Παρακαλώ συμπληρώστε "+(n.minimum-n.input.length)+" ή περισσότερους χαρακτήρες"},loadingMore:function(){return"Φόρτωση περισσότερων αποτελεσμάτων…"},maximumSelected:function(n){var e="Μπορείτε να επιλέξετε μόνο "+n.maximum+" επιλογ";return 1==n.maximum&&(e+="ή"),1!=n.maximum&&(e+="ές"),e},noResults:function(){return"Δεν βρέθηκαν αποτελέσματα"},searching:function(){return"Αναζήτηση…"},removeAllItems:function(){return"Καταργήστε όλα τα στοιχεία"}}}),n.define,n.require}();
|
||||
3
assets/js/vendor/select2/i18n/en.js
vendored
Normal file
3
assets/js/vendor/select2/i18n/en.js
vendored
Normal file
@@ -0,0 +1,3 @@
|
||||
/*! Select2 4.1.0-beta.0 | https://github.com/select2/select2/blob/master/LICENSE.md */
|
||||
|
||||
!function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;e.define("select2/i18n/en",[],function(){return{errorLoading:function(){return"The results could not be loaded."},inputTooLong:function(e){var n=e.input.length-e.maximum,r="Please delete "+n+" character";return 1!=n&&(r+="s"),r},inputTooShort:function(e){return"Please enter "+(e.minimum-e.input.length)+" or more characters"},loadingMore:function(){return"Loading more results…"},maximumSelected:function(e){var n="You can only select "+e.maximum+" item";return 1!=e.maximum&&(n+="s"),n},noResults:function(){return"No results found"},searching:function(){return"Searching…"},removeAllItems:function(){return"Remove all items"}}}),e.define,e.require}();
|
||||
3
assets/js/vendor/select2/i18n/eo.js
vendored
Normal file
3
assets/js/vendor/select2/i18n/eo.js
vendored
Normal file
@@ -0,0 +1,3 @@
|
||||
/*! Select2 4.1.0-beta.0 | https://github.com/select2/select2/blob/master/LICENSE.md */
|
||||
|
||||
!function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var n=jQuery.fn.select2.amd;n.define("select2/i18n/eo",[],function(){return{errorLoading:function(){return"La rezultoj ne povas esti ŝargitaj."},inputTooLong:function(n){var e=n.input.length-n.maximum,r="Bonvolu forigi "+e+" signo";return r+=1==e?"n":"jn"},inputTooShort:function(n){return"Bv. enigi "+(n.minimum-n.input.length)+" aŭ pli multajn signojn"},loadingMore:function(){return"Ŝargado de pliaj rezultoj…"},maximumSelected:function(n){var e="Vi povas elekti nur "+n.maximum+" ero";return 1==n.maximum?e+="n":e+="jn",e},noResults:function(){return"Neniuj rezultoj trovitaj"},searching:function(){return"Serĉado…"},removeAllItems:function(){return"Forigi ĉiujn erojn"}}}),n.define,n.require}();
|
||||
3
assets/js/vendor/select2/i18n/es.js
vendored
Normal file
3
assets/js/vendor/select2/i18n/es.js
vendored
Normal file
@@ -0,0 +1,3 @@
|
||||
/*! Select2 4.1.0-beta.0 | https://github.com/select2/select2/blob/master/LICENSE.md */
|
||||
|
||||
!function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;e.define("select2/i18n/es",[],function(){return{errorLoading:function(){return"No se pudieron cargar los resultados"},inputTooLong:function(e){var n=e.input.length-e.maximum,r="Por favor, elimine "+n+" car";return r+=1==n?"ácter":"acteres"},inputTooShort:function(e){var n=e.minimum-e.input.length,r="Por favor, introduzca "+n+" car";return r+=1==n?"ácter":"acteres"},loadingMore:function(){return"Cargando más resultados…"},maximumSelected:function(e){var n="Sólo puede seleccionar "+e.maximum+" elemento";return 1!=e.maximum&&(n+="s"),n},noResults:function(){return"No se encontraron resultados"},searching:function(){return"Buscando…"},removeAllItems:function(){return"Eliminar todos los elementos"}}}),e.define,e.require}();
|
||||
3
assets/js/vendor/select2/i18n/et.js
vendored
Normal file
3
assets/js/vendor/select2/i18n/et.js
vendored
Normal file
@@ -0,0 +1,3 @@
|
||||
/*! Select2 4.1.0-beta.0 | https://github.com/select2/select2/blob/master/LICENSE.md */
|
||||
|
||||
!function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;e.define("select2/i18n/et",[],function(){return{inputTooLong:function(e){var n=e.input.length-e.maximum,t="Sisesta "+n+" täht";return 1!=n&&(t+="e"),t+=" vähem"},inputTooShort:function(e){var n=e.minimum-e.input.length,t="Sisesta "+n+" täht";return 1!=n&&(t+="e"),t+=" rohkem"},loadingMore:function(){return"Laen tulemusi…"},maximumSelected:function(e){var n="Saad vaid "+e.maximum+" tulemus";return 1==e.maximum?n+="e":n+="t",n+=" valida"},noResults:function(){return"Tulemused puuduvad"},searching:function(){return"Otsin…"},removeAllItems:function(){return"Eemalda kõik esemed"}}}),e.define,e.require}();
|
||||
3
assets/js/vendor/select2/i18n/eu.js
vendored
Normal file
3
assets/js/vendor/select2/i18n/eu.js
vendored
Normal file
@@ -0,0 +1,3 @@
|
||||
/*! Select2 4.1.0-beta.0 | https://github.com/select2/select2/blob/master/LICENSE.md */
|
||||
|
||||
!function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;e.define("select2/i18n/eu",[],function(){return{inputTooLong:function(e){var t=e.input.length-e.maximum,n="Idatzi ";return n+=1==t?"karaktere bat":t+" karaktere",n+=" gutxiago"},inputTooShort:function(e){var t=e.minimum-e.input.length,n="Idatzi ";return n+=1==t?"karaktere bat":t+" karaktere",n+=" gehiago"},loadingMore:function(){return"Emaitza gehiago kargatzen…"},maximumSelected:function(e){return 1===e.maximum?"Elementu bakarra hauta dezakezu":e.maximum+" elementu hauta ditzakezu soilik"},noResults:function(){return"Ez da bat datorrenik aurkitu"},searching:function(){return"Bilatzen…"},removeAllItems:function(){return"Kendu elementu guztiak"}}}),e.define,e.require}();
|
||||
3
assets/js/vendor/select2/i18n/fa.js
vendored
Normal file
3
assets/js/vendor/select2/i18n/fa.js
vendored
Normal file
@@ -0,0 +1,3 @@
|
||||
/*! Select2 4.1.0-beta.0 | https://github.com/select2/select2/blob/master/LICENSE.md */
|
||||
|
||||
!function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var n=jQuery.fn.select2.amd;n.define("select2/i18n/fa",[],function(){return{errorLoading:function(){return"امکان بارگذاری نتایج وجود ندارد."},inputTooLong:function(n){return"لطفاً "+(n.input.length-n.maximum)+" کاراکتر را حذف نمایید"},inputTooShort:function(n){return"لطفاً تعداد "+(n.minimum-n.input.length)+" کاراکتر یا بیشتر وارد نمایید"},loadingMore:function(){return"در حال بارگذاری نتایج بیشتر..."},maximumSelected:function(n){return"شما تنها میتوانید "+n.maximum+" آیتم را انتخاب نمایید"},noResults:function(){return"هیچ نتیجهای یافت نشد"},searching:function(){return"در حال جستجو..."},removeAllItems:function(){return"همه موارد را حذف کنید"}}}),n.define,n.require}();
|
||||
3
assets/js/vendor/select2/i18n/fi.js
vendored
Normal file
3
assets/js/vendor/select2/i18n/fi.js
vendored
Normal file
@@ -0,0 +1,3 @@
|
||||
/*! Select2 4.1.0-beta.0 | https://github.com/select2/select2/blob/master/LICENSE.md */
|
||||
|
||||
!function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var n=jQuery.fn.select2.amd;n.define("select2/i18n/fi",[],function(){return{errorLoading:function(){return"Tuloksia ei saatu ladattua."},inputTooLong:function(n){return"Ole hyvä ja anna "+(n.input.length-n.maximum)+" merkkiä vähemmän"},inputTooShort:function(n){return"Ole hyvä ja anna "+(n.minimum-n.input.length)+" merkkiä lisää"},loadingMore:function(){return"Ladataan lisää tuloksia…"},maximumSelected:function(n){return"Voit valita ainoastaan "+n.maximum+" kpl"},noResults:function(){return"Ei tuloksia"},searching:function(){return"Haetaan…"},removeAllItems:function(){return"Poista kaikki kohteet"}}}),n.define,n.require}();
|
||||
3
assets/js/vendor/select2/i18n/fr.js
vendored
Normal file
3
assets/js/vendor/select2/i18n/fr.js
vendored
Normal file
@@ -0,0 +1,3 @@
|
||||
/*! Select2 4.1.0-beta.0 | https://github.com/select2/select2/blob/master/LICENSE.md */
|
||||
|
||||
!function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;e.define("select2/i18n/fr",[],function(){return{errorLoading:function(){return"Les résultats ne peuvent pas être chargés."},inputTooLong:function(e){var n=e.input.length-e.maximum;return"Supprimez "+n+" caractère"+(n>1?"s":"")},inputTooShort:function(e){var n=e.minimum-e.input.length;return"Saisissez au moins "+n+" caractère"+(n>1?"s":"")},loadingMore:function(){return"Chargement de résultats supplémentaires…"},maximumSelected:function(e){return"Vous pouvez seulement sélectionner "+e.maximum+" élément"+(e.maximum>1?"s":"")},noResults:function(){return"Aucun résultat trouvé"},searching:function(){return"Recherche en cours…"},removeAllItems:function(){return"Supprimer tous les éléments"}}}),e.define,e.require}();
|
||||
3
assets/js/vendor/select2/i18n/gl.js
vendored
Normal file
3
assets/js/vendor/select2/i18n/gl.js
vendored
Normal file
@@ -0,0 +1,3 @@
|
||||
/*! Select2 4.1.0-beta.0 | https://github.com/select2/select2/blob/master/LICENSE.md */
|
||||
|
||||
!function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;e.define("select2/i18n/gl",[],function(){return{errorLoading:function(){return"Non foi posíbel cargar os resultados."},inputTooLong:function(e){var n=e.input.length-e.maximum;return 1===n?"Elimine un carácter":"Elimine "+n+" caracteres"},inputTooShort:function(e){var n=e.minimum-e.input.length;return 1===n?"Engada un carácter":"Engada "+n+" caracteres"},loadingMore:function(){return"Cargando máis resultados…"},maximumSelected:function(e){return 1===e.maximum?"Só pode seleccionar un elemento":"Só pode seleccionar "+e.maximum+" elementos"},noResults:function(){return"Non se atoparon resultados"},searching:function(){return"Buscando…"},removeAllItems:function(){return"Elimina todos os elementos"}}}),e.define,e.require}();
|
||||
3
assets/js/vendor/select2/i18n/he.js
vendored
Normal file
3
assets/js/vendor/select2/i18n/he.js
vendored
Normal file
@@ -0,0 +1,3 @@
|
||||
/*! Select2 4.1.0-beta.0 | https://github.com/select2/select2/blob/master/LICENSE.md */
|
||||
|
||||
!function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var n=jQuery.fn.select2.amd;n.define("select2/i18n/he",[],function(){return{errorLoading:function(){return"שגיאה בטעינת התוצאות"},inputTooLong:function(n){var e=n.input.length-n.maximum,r="נא למחוק ";return r+=1===e?"תו אחד":e+" תווים"},inputTooShort:function(n){var e=n.minimum-n.input.length,r="נא להכניס ";return r+=1===e?"תו אחד":e+" תווים",r+=" או יותר"},loadingMore:function(){return"טוען תוצאות נוספות…"},maximumSelected:function(n){var e="באפשרותך לבחור עד ";return 1===n.maximum?e+="פריט אחד":e+=n.maximum+" פריטים",e},noResults:function(){return"לא נמצאו תוצאות"},searching:function(){return"מחפש…"},removeAllItems:function(){return"הסר את כל הפריטים"}}}),n.define,n.require}();
|
||||
3
assets/js/vendor/select2/i18n/hi.js
vendored
Normal file
3
assets/js/vendor/select2/i18n/hi.js
vendored
Normal file
@@ -0,0 +1,3 @@
|
||||
/*! Select2 4.1.0-beta.0 | https://github.com/select2/select2/blob/master/LICENSE.md */
|
||||
|
||||
!function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var n=jQuery.fn.select2.amd;n.define("select2/i18n/hi",[],function(){return{errorLoading:function(){return"परिणामों को लोड नहीं किया जा सका।"},inputTooLong:function(n){var e=n.input.length-n.maximum,r=e+" अक्षर को हटा दें";return e>1&&(r=e+" अक्षरों को हटा दें "),r},inputTooShort:function(n){return"कृपया "+(n.minimum-n.input.length)+" या अधिक अक्षर दर्ज करें"},loadingMore:function(){return"अधिक परिणाम लोड हो रहे है..."},maximumSelected:function(n){return"आप केवल "+n.maximum+" आइटम का चयन कर सकते हैं"},noResults:function(){return"कोई परिणाम नहीं मिला"},searching:function(){return"खोज रहा है..."},removeAllItems:function(){return"सभी वस्तुओं को हटा दें"}}}),n.define,n.require}();
|
||||
3
assets/js/vendor/select2/i18n/hr.js
vendored
Normal file
3
assets/js/vendor/select2/i18n/hr.js
vendored
Normal file
@@ -0,0 +1,3 @@
|
||||
/*! Select2 4.1.0-beta.0 | https://github.com/select2/select2/blob/master/LICENSE.md */
|
||||
|
||||
!function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var n=jQuery.fn.select2.amd;n.define("select2/i18n/hr",[],function(){function n(n){var e=" "+n+" znak";return n%10<5&&n%10>0&&(n%100<5||n%100>19)?n%10>1&&(e+="a"):e+="ova",e}return{errorLoading:function(){return"Preuzimanje nije uspjelo."},inputTooLong:function(e){return"Unesite "+n(e.input.length-e.maximum)},inputTooShort:function(e){return"Unesite još "+n(e.minimum-e.input.length)},loadingMore:function(){return"Učitavanje rezultata…"},maximumSelected:function(n){return"Maksimalan broj odabranih stavki je "+n.maximum},noResults:function(){return"Nema rezultata"},searching:function(){return"Pretraga…"},removeAllItems:function(){return"Ukloni sve stavke"}}}),n.define,n.require}();
|
||||
3
assets/js/vendor/select2/i18n/hsb.js
vendored
Normal file
3
assets/js/vendor/select2/i18n/hsb.js
vendored
Normal file
@@ -0,0 +1,3 @@
|
||||
/*! Select2 4.1.0-beta.0 | https://github.com/select2/select2/blob/master/LICENSE.md */
|
||||
|
||||
!function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var n=jQuery.fn.select2.amd;n.define("select2/i18n/hsb",[],function(){var n=["znamješko","znamješce","znamješka","znamješkow"],e=["zapisk","zapiskaj","zapiski","zapiskow"],u=function(n,e){return 1===n?e[0]:2===n?e[1]:n>2&&n<=4?e[2]:n>=5?e[3]:void 0};return{errorLoading:function(){return"Wuslědki njedachu so začitać."},inputTooLong:function(e){var a=e.input.length-e.maximum;return"Prošu zhašej "+a+" "+u(a,n)},inputTooShort:function(e){var a=e.minimum-e.input.length;return"Prošu zapodaj znajmjeńša "+a+" "+u(a,n)},loadingMore:function(){return"Dalše wuslědki so začitaja…"},maximumSelected:function(n){return"Móžeš jenož "+n.maximum+" "+u(n.maximum,e)+"wubrać"},noResults:function(){return"Žane wuslědki namakane"},searching:function(){return"Pyta so…"},removeAllItems:function(){return"Remove all items"}}}),n.define,n.require}();
|
||||
3
assets/js/vendor/select2/i18n/hu.js
vendored
Normal file
3
assets/js/vendor/select2/i18n/hu.js
vendored
Normal file
@@ -0,0 +1,3 @@
|
||||
/*! Select2 4.1.0-beta.0 | https://github.com/select2/select2/blob/master/LICENSE.md */
|
||||
|
||||
!function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;e.define("select2/i18n/hu",[],function(){return{errorLoading:function(){return"Az eredmények betöltése nem sikerült."},inputTooLong:function(e){return"Túl hosszú. "+(e.input.length-e.maximum)+" karakterrel több, mint kellene."},inputTooShort:function(e){return"Túl rövid. Még "+(e.minimum-e.input.length)+" karakter hiányzik."},loadingMore:function(){return"Töltés…"},maximumSelected:function(e){return"Csak "+e.maximum+" elemet lehet kiválasztani."},noResults:function(){return"Nincs találat."},searching:function(){return"Keresés…"},removeAllItems:function(){return"Távolítson el minden elemet"}}}),e.define,e.require}();
|
||||
3
assets/js/vendor/select2/i18n/hy.js
vendored
Normal file
3
assets/js/vendor/select2/i18n/hy.js
vendored
Normal file
@@ -0,0 +1,3 @@
|
||||
/*! Select2 4.1.0-beta.0 | https://github.com/select2/select2/blob/master/LICENSE.md */
|
||||
|
||||
!function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var n=jQuery.fn.select2.amd;n.define("select2/i18n/hy",[],function(){return{errorLoading:function(){return"Արդյունքները հնարավոր չէ բեռնել։"},inputTooLong:function(n){return"Խնդրում ենք հեռացնել "+(n.input.length-n.maximum)+" նշան"},inputTooShort:function(n){return"Խնդրում ենք մուտքագրել "+(n.minimum-n.input.length)+" կամ ավել նշաններ"},loadingMore:function(){return"Բեռնվում են նոր արդյունքներ․․․"},maximumSelected:function(n){return"Դուք կարող եք ընտրել առավելագույնը "+n.maximum+" կետ"},noResults:function(){return"Արդյունքներ չեն գտնվել"},searching:function(){return"Որոնում․․․"},removeAllItems:function(){return"Հեռացնել բոլոր տարրերը"}}}),n.define,n.require}();
|
||||
3
assets/js/vendor/select2/i18n/id.js
vendored
Normal file
3
assets/js/vendor/select2/i18n/id.js
vendored
Normal file
@@ -0,0 +1,3 @@
|
||||
/*! Select2 4.1.0-beta.0 | https://github.com/select2/select2/blob/master/LICENSE.md */
|
||||
|
||||
!function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var n=jQuery.fn.select2.amd;n.define("select2/i18n/id",[],function(){return{errorLoading:function(){return"Data tidak boleh diambil."},inputTooLong:function(n){return"Hapuskan "+(n.input.length-n.maximum)+" huruf"},inputTooShort:function(n){return"Masukkan "+(n.minimum-n.input.length)+" huruf lagi"},loadingMore:function(){return"Mengambil data…"},maximumSelected:function(n){return"Anda hanya dapat memilih "+n.maximum+" pilihan"},noResults:function(){return"Tidak ada data yang sesuai"},searching:function(){return"Mencari…"},removeAllItems:function(){return"Hapus semua item"}}}),n.define,n.require}();
|
||||
3
assets/js/vendor/select2/i18n/is.js
vendored
Normal file
3
assets/js/vendor/select2/i18n/is.js
vendored
Normal file
@@ -0,0 +1,3 @@
|
||||
/*! Select2 4.1.0-beta.0 | https://github.com/select2/select2/blob/master/LICENSE.md */
|
||||
|
||||
!function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var n=jQuery.fn.select2.amd;n.define("select2/i18n/is",[],function(){return{inputTooLong:function(n){var t=n.input.length-n.maximum,e="Vinsamlegast styttið texta um "+t+" staf";return t<=1?e:e+"i"},inputTooShort:function(n){var t=n.minimum-n.input.length,e="Vinsamlegast skrifið "+t+" staf";return t>1&&(e+="i"),e+=" í viðbót"},loadingMore:function(){return"Sæki fleiri niðurstöður…"},maximumSelected:function(n){return"Þú getur aðeins valið "+n.maximum+" atriði"},noResults:function(){return"Ekkert fannst"},searching:function(){return"Leita…"},removeAllItems:function(){return"Fjarlægðu öll atriði"}}}),n.define,n.require}();
|
||||
3
assets/js/vendor/select2/i18n/it.js
vendored
Normal file
3
assets/js/vendor/select2/i18n/it.js
vendored
Normal file
@@ -0,0 +1,3 @@
|
||||
/*! Select2 4.1.0-beta.0 | https://github.com/select2/select2/blob/master/LICENSE.md */
|
||||
|
||||
!function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;e.define("select2/i18n/it",[],function(){return{errorLoading:function(){return"I risultati non possono essere caricati."},inputTooLong:function(e){var n=e.input.length-e.maximum,t="Per favore cancella "+n+" caratter";return t+=1!==n?"i":"e"},inputTooShort:function(e){return"Per favore inserisci "+(e.minimum-e.input.length)+" o più caratteri"},loadingMore:function(){return"Caricando più risultati…"},maximumSelected:function(e){var n="Puoi selezionare solo "+e.maximum+" element";return 1!==e.maximum?n+="i":n+="o",n},noResults:function(){return"Nessun risultato trovato"},searching:function(){return"Sto cercando…"},removeAllItems:function(){return"Rimuovi tutti gli oggetti"}}}),e.define,e.require}();
|
||||
3
assets/js/vendor/select2/i18n/ja.js
vendored
Normal file
3
assets/js/vendor/select2/i18n/ja.js
vendored
Normal file
@@ -0,0 +1,3 @@
|
||||
/*! Select2 4.1.0-beta.0 | https://github.com/select2/select2/blob/master/LICENSE.md */
|
||||
|
||||
!function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var n=jQuery.fn.select2.amd;n.define("select2/i18n/ja",[],function(){return{errorLoading:function(){return"結果が読み込まれませんでした"},inputTooLong:function(n){return n.input.length-n.maximum+" 文字を削除してください"},inputTooShort:function(n){return"少なくとも "+(n.minimum-n.input.length)+" 文字を入力してください"},loadingMore:function(){return"読み込み中…"},maximumSelected:function(n){return n.maximum+" 件しか選択できません"},noResults:function(){return"対象が見つかりません"},searching:function(){return"検索しています…"},removeAllItems:function(){return"すべてのアイテムを削除"}}}),n.define,n.require}();
|
||||
3
assets/js/vendor/select2/i18n/ka.js
vendored
Normal file
3
assets/js/vendor/select2/i18n/ka.js
vendored
Normal file
@@ -0,0 +1,3 @@
|
||||
/*! Select2 4.1.0-beta.0 | https://github.com/select2/select2/blob/master/LICENSE.md */
|
||||
|
||||
!function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var n=jQuery.fn.select2.amd;n.define("select2/i18n/ka",[],function(){return{errorLoading:function(){return"მონაცემების ჩატვირთვა შეუძლებელია."},inputTooLong:function(n){return"გთხოვთ აკრიფეთ "+(n.input.length-n.maximum)+" სიმბოლოთი ნაკლები"},inputTooShort:function(n){return"გთხოვთ აკრიფეთ "+(n.minimum-n.input.length)+" სიმბოლო ან მეტი"},loadingMore:function(){return"მონაცემების ჩატვირთვა…"},maximumSelected:function(n){return"თქვენ შეგიძლიათ აირჩიოთ არაუმეტეს "+n.maximum+" ელემენტი"},noResults:function(){return"რეზულტატი არ მოიძებნა"},searching:function(){return"ძიება…"},removeAllItems:function(){return"ამოიღე ყველა ელემენტი"}}}),n.define,n.require}();
|
||||
3
assets/js/vendor/select2/i18n/km.js
vendored
Normal file
3
assets/js/vendor/select2/i18n/km.js
vendored
Normal file
@@ -0,0 +1,3 @@
|
||||
/*! Select2 4.1.0-beta.0 | https://github.com/select2/select2/blob/master/LICENSE.md */
|
||||
|
||||
!function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var n=jQuery.fn.select2.amd;n.define("select2/i18n/km",[],function(){return{errorLoading:function(){return"មិនអាចទាញយកទិន្នន័យ"},inputTooLong:function(n){return"សូមលុបចេញ "+(n.input.length-n.maximum)+" អក្សរ"},inputTooShort:function(n){return"សូមបញ្ចូល"+(n.minimum-n.input.length)+" អក្សរ រឺ ច្រើនជាងនេះ"},loadingMore:function(){return"កំពុងទាញយកទិន្នន័យបន្ថែម..."},maximumSelected:function(n){return"អ្នកអាចជ្រើសរើសបានតែ "+n.maximum+" ជម្រើសប៉ុណ្ណោះ"},noResults:function(){return"មិនមានលទ្ធផល"},searching:function(){return"កំពុងស្វែងរក..."},removeAllItems:function(){return"លុបធាតុទាំងអស់"}}}),n.define,n.require}();
|
||||
3
assets/js/vendor/select2/i18n/ko.js
vendored
Normal file
3
assets/js/vendor/select2/i18n/ko.js
vendored
Normal file
@@ -0,0 +1,3 @@
|
||||
/*! Select2 4.1.0-beta.0 | https://github.com/select2/select2/blob/master/LICENSE.md */
|
||||
|
||||
!function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var n=jQuery.fn.select2.amd;n.define("select2/i18n/ko",[],function(){return{errorLoading:function(){return"결과를 불러올 수 없습니다."},inputTooLong:function(n){return"너무 깁니다. "+(n.input.length-n.maximum)+" 글자 지워주세요."},inputTooShort:function(n){return"너무 짧습니다. "+(n.minimum-n.input.length)+" 글자 더 입력해주세요."},loadingMore:function(){return"불러오는 중…"},maximumSelected:function(n){return"최대 "+n.maximum+"개까지만 선택 가능합니다."},noResults:function(){return"결과가 없습니다."},searching:function(){return"검색 중…"},removeAllItems:function(){return"모든 항목 삭제"}}}),n.define,n.require}();
|
||||
3
assets/js/vendor/select2/i18n/lt.js
vendored
Normal file
3
assets/js/vendor/select2/i18n/lt.js
vendored
Normal file
@@ -0,0 +1,3 @@
|
||||
/*! Select2 4.1.0-beta.0 | https://github.com/select2/select2/blob/master/LICENSE.md */
|
||||
|
||||
!function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var n=jQuery.fn.select2.amd;n.define("select2/i18n/lt",[],function(){function n(n,e,i,t){return n%10==1&&(n%100<11||n%100>19)?e:n%10>=2&&n%10<=9&&(n%100<11||n%100>19)?i:t}return{inputTooLong:function(e){var i=e.input.length-e.maximum,t="Pašalinkite "+i+" simbol";return t+=n(i,"į","ius","ių")},inputTooShort:function(e){var i=e.minimum-e.input.length,t="Įrašykite dar "+i+" simbol";return t+=n(i,"į","ius","ių")},loadingMore:function(){return"Kraunama daugiau rezultatų…"},maximumSelected:function(e){var i="Jūs galite pasirinkti tik "+e.maximum+" element";return i+=n(e.maximum,"ą","us","ų")},noResults:function(){return"Atitikmenų nerasta"},searching:function(){return"Ieškoma…"},removeAllItems:function(){return"Pašalinti visus elementus"}}}),n.define,n.require}();
|
||||
3
assets/js/vendor/select2/i18n/lv.js
vendored
Normal file
3
assets/js/vendor/select2/i18n/lv.js
vendored
Normal file
@@ -0,0 +1,3 @@
|
||||
/*! Select2 4.1.0-beta.0 | https://github.com/select2/select2/blob/master/LICENSE.md */
|
||||
|
||||
!function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;e.define("select2/i18n/lv",[],function(){function e(e,n,u,i){return 11===e?n:e%10==1?u:i}return{inputTooLong:function(n){var u=n.input.length-n.maximum,i="Lūdzu ievadiet par "+u;return(i+=" simbol"+e(u,"iem","u","iem"))+" mazāk"},inputTooShort:function(n){var u=n.minimum-n.input.length,i="Lūdzu ievadiet vēl "+u;return i+=" simbol"+e(u,"us","u","us")},loadingMore:function(){return"Datu ielāde…"},maximumSelected:function(n){var u="Jūs varat izvēlēties ne vairāk kā "+n.maximum;return u+=" element"+e(n.maximum,"us","u","us")},noResults:function(){return"Sakritību nav"},searching:function(){return"Meklēšana…"},removeAllItems:function(){return"Noņemt visus vienumus"}}}),e.define,e.require}();
|
||||
3
assets/js/vendor/select2/i18n/mk.js
vendored
Normal file
3
assets/js/vendor/select2/i18n/mk.js
vendored
Normal file
@@ -0,0 +1,3 @@
|
||||
/*! Select2 4.1.0-beta.0 | https://github.com/select2/select2/blob/master/LICENSE.md */
|
||||
|
||||
!function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var n=jQuery.fn.select2.amd;n.define("select2/i18n/mk",[],function(){return{inputTooLong:function(n){var e=(n.input.length,n.maximum,"Ве молиме внесете "+n.maximum+" помалку карактер");return 1!==n.maximum&&(e+="и"),e},inputTooShort:function(n){var e=(n.minimum,n.input.length,"Ве молиме внесете уште "+n.maximum+" карактер");return 1!==n.maximum&&(e+="и"),e},loadingMore:function(){return"Вчитување резултати…"},maximumSelected:function(n){var e="Можете да изберете само "+n.maximum+" ставк";return 1===n.maximum?e+="а":e+="и",e},noResults:function(){return"Нема пронајдено совпаѓања"},searching:function(){return"Пребарување…"},removeAllItems:function(){return"Отстрани ги сите предмети"}}}),n.define,n.require}();
|
||||
3
assets/js/vendor/select2/i18n/ms.js
vendored
Normal file
3
assets/js/vendor/select2/i18n/ms.js
vendored
Normal file
@@ -0,0 +1,3 @@
|
||||
/*! Select2 4.1.0-beta.0 | https://github.com/select2/select2/blob/master/LICENSE.md */
|
||||
|
||||
!function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var n=jQuery.fn.select2.amd;n.define("select2/i18n/ms",[],function(){return{errorLoading:function(){return"Keputusan tidak berjaya dimuatkan."},inputTooLong:function(n){return"Sila hapuskan "+(n.input.length-n.maximum)+" aksara"},inputTooShort:function(n){return"Sila masukkan "+(n.minimum-n.input.length)+" atau lebih aksara"},loadingMore:function(){return"Sedang memuatkan keputusan…"},maximumSelected:function(n){return"Anda hanya boleh memilih "+n.maximum+" pilihan"},noResults:function(){return"Tiada padanan yang ditemui"},searching:function(){return"Mencari…"},removeAllItems:function(){return"Keluarkan semua item"}}}),n.define,n.require}();
|
||||
3
assets/js/vendor/select2/i18n/nb.js
vendored
Normal file
3
assets/js/vendor/select2/i18n/nb.js
vendored
Normal file
@@ -0,0 +1,3 @@
|
||||
/*! Select2 4.1.0-beta.0 | https://github.com/select2/select2/blob/master/LICENSE.md */
|
||||
|
||||
!function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;e.define("select2/i18n/nb",[],function(){return{errorLoading:function(){return"Kunne ikke hente resultater."},inputTooLong:function(e){return"Vennligst fjern "+(e.input.length-e.maximum)+" tegn"},inputTooShort:function(e){return"Vennligst skriv inn "+(e.minimum-e.input.length)+" tegn til"},loadingMore:function(){return"Laster flere resultater…"},maximumSelected:function(e){return"Du kan velge maks "+e.maximum+" elementer"},noResults:function(){return"Ingen treff"},searching:function(){return"Søker…"},removeAllItems:function(){return"Fjern alle elementer"}}}),e.define,e.require}();
|
||||
3
assets/js/vendor/select2/i18n/ne.js
vendored
Normal file
3
assets/js/vendor/select2/i18n/ne.js
vendored
Normal file
@@ -0,0 +1,3 @@
|
||||
/*! Select2 4.1.0-beta.0 | https://github.com/select2/select2/blob/master/LICENSE.md */
|
||||
|
||||
!function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var n=jQuery.fn.select2.amd;n.define("select2/i18n/ne",[],function(){return{errorLoading:function(){return"नतिजाहरु देखाउन सकिएन।"},inputTooLong:function(n){var e=n.input.length-n.maximum,u="कृपया "+e+" अक्षर मेटाउनुहोस्।";return 1!=e&&(u+="कृपया "+e+" अक्षरहरु मेटाउनुहोस्।"),u},inputTooShort:function(n){return"कृपया बाँकी रहेका "+(n.minimum-n.input.length)+" वा अरु धेरै अक्षरहरु भर्नुहोस्।"},loadingMore:function(){return"अरु नतिजाहरु भरिँदैछन् …"},maximumSelected:function(n){var e="तँपाई "+n.maximum+" वस्तु मात्र छान्न पाउँनुहुन्छ।";return 1!=n.maximum&&(e="तँपाई "+n.maximum+" वस्तुहरु मात्र छान्न पाउँनुहुन्छ।"),e},noResults:function(){return"कुनै पनि नतिजा भेटिएन।"},searching:function(){return"खोजि हुँदैछ…"}}}),n.define,n.require}();
|
||||
3
assets/js/vendor/select2/i18n/nl.js
vendored
Normal file
3
assets/js/vendor/select2/i18n/nl.js
vendored
Normal file
@@ -0,0 +1,3 @@
|
||||
/*! Select2 4.1.0-beta.0 | https://github.com/select2/select2/blob/master/LICENSE.md */
|
||||
|
||||
!function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;e.define("select2/i18n/nl",[],function(){return{errorLoading:function(){return"De resultaten konden niet worden geladen."},inputTooLong:function(e){return"Gelieve "+(e.input.length-e.maximum)+" karakters te verwijderen"},inputTooShort:function(e){return"Gelieve "+(e.minimum-e.input.length)+" of meer karakters in te voeren"},loadingMore:function(){return"Meer resultaten laden…"},maximumSelected:function(e){var n=1==e.maximum?"kan":"kunnen",r="Er "+n+" maar "+e.maximum+" item";return 1!=e.maximum&&(r+="s"),r+=" worden geselecteerd"},noResults:function(){return"Geen resultaten gevonden…"},searching:function(){return"Zoeken…"},removeAllItems:function(){return"Verwijder alle items"}}}),e.define,e.require}();
|
||||
3
assets/js/vendor/select2/i18n/pa.js
vendored
Normal file
3
assets/js/vendor/select2/i18n/pa.js
vendored
Normal file
@@ -0,0 +1,3 @@
|
||||
/*! Select2 4.1.0-beta.0 | https://github.com/select2/select2/blob/master/LICENSE.md */
|
||||
|
||||
!function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var n=jQuery.fn.select2.amd;n.define("select2/i18n/pa",[],function(){return{errorLoading:function(){return"ਨਤੀਜੇ ਲੋਡ ਨਹੀਂ ਕੀਤੇ ਜਾ ਸਕਦੇ ।"},inputTooLong:function(n){var e=n.input.length-n.maximum;return"ਕ੍ਰਿਪਾ ਕਰਕੇ "+e+(1!=e?" ਅੱਖਰਾਂ ਨੂੰ ":" ਅੱਖਰ ")+"ਮਿਟਾਓ ।"},inputTooShort:function(n){var e=n.minimum-n.input.length;return"ਕ੍ਰਿਪਾ ਕਰਕੇ "+e+" ਜਾਂ "+e+" ਤੋਂ ਵੱਧ"+(e>1?" ਅੱਖਰਾਂ ":" ਅੱਖਰ ")+"ਦੀ ਵਰਤੋਂ ਕਰੋ ।"},loadingMore:function(){return"ਹੋਰ ਨਤੀਜੇ ਲੋਡ ਹੋ ਰਹੇ ਹਨ ...।"},maximumSelected:function(n){var e="ਤੁਸੀਂ ਸਿਰਫ਼ "+n.maximum+" ਨਤੀਜਾ ਚੁਣ ਸਕਦੇ ਹੋ ।";return 1!=n.maximum&&(e="ਤੁਸੀਂ ਸਿਰਫ਼ "+n.maximum+" ਨਤੀਜੇ ਚੁਣ ਸਕਦੇ ਹੋ ।"),e},noResults:function(){return"ਨਤੀਜਾ ਨਹੀਂ ਮਿਲ ਰਿਹਾ ਹੈ ।"},searching:function(){return"ਖ਼ੋਜ ਕਰ ਰਹੇਂ ਹਾਂ ...।"},removeAllItems:function(){return"ਸਾਰੇ ਨਤੀਜੇ ਮਿਟਾਓ ।"}}}),n.define,n.require}();
|
||||
3
assets/js/vendor/select2/i18n/pl.js
vendored
Normal file
3
assets/js/vendor/select2/i18n/pl.js
vendored
Normal file
@@ -0,0 +1,3 @@
|
||||
/*! Select2 4.1.0-beta.0 | https://github.com/select2/select2/blob/master/LICENSE.md */
|
||||
|
||||
!function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var n=jQuery.fn.select2.amd;n.define("select2/i18n/pl",[],function(){var n=["znak","znaki","znaków"],e=["element","elementy","elementów"],r=function(n,e){return 1===n?e[0]:n>1&&n<=4?e[1]:n>=5?e[2]:void 0};return{errorLoading:function(){return"Nie można załadować wyników."},inputTooLong:function(e){var t=e.input.length-e.maximum;return"Usuń "+t+" "+r(t,n)},inputTooShort:function(e){var t=e.minimum-e.input.length;return"Podaj przynajmniej "+t+" "+r(t,n)},loadingMore:function(){return"Trwa ładowanie…"},maximumSelected:function(n){return"Możesz zaznaczyć tylko "+n.maximum+" "+r(n.maximum,e)},noResults:function(){return"Brak wyników"},searching:function(){return"Trwa wyszukiwanie…"},removeAllItems:function(){return"Usuń wszystkie przedmioty"}}}),n.define,n.require}();
|
||||
3
assets/js/vendor/select2/i18n/ps.js
vendored
Normal file
3
assets/js/vendor/select2/i18n/ps.js
vendored
Normal file
@@ -0,0 +1,3 @@
|
||||
/*! Select2 4.1.0-beta.0 | https://github.com/select2/select2/blob/master/LICENSE.md */
|
||||
|
||||
!function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var n=jQuery.fn.select2.amd;n.define("select2/i18n/ps",[],function(){return{errorLoading:function(){return"پايلي نه سي ترلاسه کېدای"},inputTooLong:function(n){var e=n.input.length-n.maximum,r="د مهربانۍ لمخي "+e+" توری ړنګ کړئ";return 1!=e&&(r=r.replace("توری","توري")),r},inputTooShort:function(n){return"لږ تر لږه "+(n.minimum-n.input.length)+" يا ډېر توري وليکئ"},loadingMore:function(){return"نوري پايلي ترلاسه کيږي..."},maximumSelected:function(n){var e="تاسو يوازي "+n.maximum+" قلم په نښه کولای سی";return 1!=n.maximum&&(e=e.replace("قلم","قلمونه")),e},noResults:function(){return"پايلي و نه موندل سوې"},searching:function(){return"لټول کيږي..."},removeAllItems:function(){return"ټول توکي لرې کړئ"}}}),n.define,n.require}();
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user