重构代码:使用Libman管理css/js/font等静态资源

This commit is contained in:
Argo-MacBookPro 2018-11-07 14:25:30 +08:00
parent ef25a5b230
commit bea7a08c2f
125 changed files with 6881 additions and 2442 deletions

1
.gitignore vendored
View File

@ -344,7 +344,6 @@ ASALocalRun/
# Net Core Keys
[Kk]eys/
lib/
*.db
Bootstrap.Admin.xml

View File

@ -5,12 +5,12 @@
}
@section css {
<environment include="Development">
<link href="~/css/bootstrap.css" rel="stylesheet" />
<link href="~/css/font-awesome.css" rel="stylesheet" />
<link href="~/lib/bootstrap/dist/css/bootstrap.css" rel="stylesheet" />
<link href="~/lib/font-awesome/css/font-awesome.css" rel="stylesheet" />
</environment>
<environment exclude="Development">
<link href="~/css/bootstrap.min.css" rel="stylesheet" />
<link href="~/css/font-awesome.min.css" rel="stylesheet" />
<link href="~/lib/bootstrap/dist/css/bootstrap.min.css" rel="stylesheet" />
<link href="~/lib/font-awesome/css/font-awesome.min.css" rel="stylesheet" />
</environment>
<link href="~/css/sweetalert.css" rel="stylesheet" />
<link href="~/css/theme.css" rel="stylesheet" asp-append-version="true" />
@ -23,15 +23,15 @@
}
@section javascript {
<environment include="Development">
<script src="~/js/bootstrap.bundle.js"></script>
<script src="~/js/jquery.validate.js"></script>
<script src="~/js/messages_zh.js"></script>
<script src="~/lib/bootstrap/dist/js/bootstrap.bundle.js"></script>
<script src="~/lib/validate/jquery.validate.js"></script>
<script src="~/lib/validate/localization/messages_zh.js"></script>
<script src="~/js/sweetalert.js"></script>
</environment>
<environment exclude="Development">
<script src="~/js/bootstrap.bundle.min.js"></script>
<script src="~/js/jquery.validate.min.js"></script>
<script src="~/js/messages_zh.min.js"></script>
<script src="~/lib/bootstrap/dist/js/bootstrap.bundle.min.js"></script>
<script src="~/lib/validate/jquery.validate.min.js"></script>
<script src="~/lib/validate/localization/messages_zh.min.js"></script>
<script src="~/js/sweetalert.min.js"></script>
</environment>
<script src="~/js/longbow.common.js" asp-append-version="true"></script>

View File

@ -4,24 +4,24 @@
}
@section css {
<environment include="Development">
<link href="~/css/bootstrap-table.css" rel="stylesheet" />
<link href="~/lib/bootstrap-table/dist/bootstrap-table.css" rel="stylesheet" />
<link href="~/css/bootstrap-datetimepicker.css" rel="stylesheet" />
</environment>
<environment exclude="Development">
<link href="~/css/bootstrap-table.min.css" rel="stylesheet" />
<link href="~/lib/bootstrap-table/dist/bootstrap-table.min.css" rel="stylesheet" />
<link href="~/css/bootstrap-datetimepicker.min.css" rel="stylesheet" />
</environment>
<link href="~/css/fa.css" rel="stylesheet" asp-append-version="true" />
}
@section javascript {
<environment include="Development">
<script src="~/js/bootstrap-table.js"></script>
<script src="~/js/bootstrap-table-zh-CN.js"></script>
<script src="~/lib/bootstrap-table/dist/bootstrap-table.js"></script>
<script src="~/lib/bootstrap-table/dist/locale/bootstrap-table-zh-CN.js"></script>
<script src="~/js/bootstrap-datetimepicker.js"></script>
</environment>
<environment exclude="Development">
<script src="~/js/bootstrap-table.min.js"></script>
<script src="~/js/bootstrap-table-zh-CN.min.js"></script>
<script src="~/lib/bootstrap-table/dist/bootstrap-table.min.js"></script>
<script src="~/lib/bootstrap-table/dist/locale/bootstrap-table-zh-CN.min.js"></script>
<script src="~/js/bootstrap-datetimepicker.min.js"></script>
</environment>
<script src="~/js/bootstrap-datetimepicker.zh-CN.js"></script>

View File

@ -4,23 +4,23 @@
}
@section css {
<environment include="Development">
<link href="~/css/bootstrap-table.css" rel="stylesheet" />
<link href="~/lib/bootstrap-table/dist/bootstrap-table.css" rel="stylesheet" />
<link href="~/css/bootstrap-datetimepicker.css" rel="stylesheet" />
</environment>
<environment exclude="Development">
<link href="~/css/bootstrap-table.min.css" rel="stylesheet" />
<link href="~/lib/bootstrap-table/dist/bootstrap-table.min.css" rel="stylesheet" />
<link href="~/css/bootstrap-datetimepicker.min.css" rel="stylesheet" />
</environment>
}
@section javascript {
<environment include="Development">
<script src="~/js/bootstrap-table.js"></script>
<script src="~/js/bootstrap-table-zh-CN.js"></script>
<script src="~/lib/bootstrap-table/dist/bootstrap-table.js"></script>
<script src="~/lib/bootstrap-table/dist/locale/bootstrap-table-zh-CN.js"></script>
<script src="~/js/bootstrap-datetimepicker.js"></script>
</environment>
<environment exclude="Development">
<script src="~/js/bootstrap-table.min.js"></script>
<script src="~/js/bootstrap-table-zh-CN.min.js"></script>
<script src="~/lib/bootstrap-table/dist/bootstrap-table.min.js"></script>
<script src="~/lib/bootstrap-table/dist/locale/bootstrap-table-zh-CN.min.js"></script>
<script src="~/js/bootstrap-datetimepicker.min.js"></script>
</environment>
<script src="~/js/bootstrap-datetimepicker.zh-CN.js"></script>

View File

@ -4,20 +4,20 @@
}
@section css {
<environment include="Development">
<link href="~/css/bootstrap-table.css" rel="stylesheet" />
<link href="~/lib/bootstrap-table/dist/bootstrap-table.css" rel="stylesheet" />
</environment>
<environment exclude="Development">
<link href="~/css/bootstrap-table.min.css" rel="stylesheet" />
<link href="~/lib/bootstrap-table/dist/bootstrap-table.min.css" rel="stylesheet" />
</environment>
}
@section javascript {
<environment include="Development">
<script src="~/js/bootstrap-table.js"></script>
<script src="~/js/bootstrap-table-zh-CN.js"></script>
<script src="~/lib/bootstrap-table/dist/bootstrap-table.js"></script>
<script src="~/lib/bootstrap-table/dist/locale/bootstrap-table-zh-CN.js"></script>
</environment>
<environment exclude="Development">
<script src="~/js/bootstrap-table.min.js"></script>
<script src="~/js/bootstrap-table-zh-CN.min.js"></script>
<script src="~/lib/bootstrap-table/dist/bootstrap-table.min.js"></script>
<script src="~/lib/bootstrap-table/dist/locale/bootstrap-table-zh-CN.min.js"></script>
</environment>
<script src="~/js/noti.js" asp-append-version="true"></script>
}

View File

@ -13,16 +13,16 @@
}
@section javascript {
<environment include="Development">
<script src="~/js/fileinput.js"></script>
<script src="~/js/jquery.validate.js"></script>
<script src="~/js/messages_zh.js"></script>
<script src="~/lib/fileinput/js/fileinput.js"></script>
<script src="~/lib/validate/jquery.validate.js"></script>
<script src="~/lib/validate/localization/messages_zh.js"></script>
</environment>
<environment exclude="Development">
<script src="~/js/fileinput.min.js"></script>
<script src="~/js/jquery.validate.min.js"></script>
<script src="~/js/messages_zh.min.js"></script>
<script src="~/lib/fileinput/js/fileinput.min.js"></script>
<script src="~/lib/validate/jquery.validate.min.js"></script>
<script src="~/lib/validate/localization/messages_zh.min.js"></script>
</environment>
<script src="~/js/fileinput.zh.js"></script>
<script src="~/lib/fileinput/js/locales/zh.js"></script>
<script src="~/js/theme.js"></script>
<script src="~/js/longbow.dataentity.js" asp-append-version="true"></script>
<script src="~/js/longbow.validate.js" asp-append-version="true"></script>

View File

@ -4,12 +4,12 @@
}
@section javascript {
<environment include="Development">
<script src="~/js/jquery.validate.js"></script>
<script src="~/js/messages_zh.js"></script>
<script src="~/lib/validate/jquery.validate.js"></script>
<script src="~/lib/validate/localization/messages_zh.js"></script>
</environment>
<environment exclude="Development">
<script src="~/js/jquery.validate.min.js"></script>
<script src="~/js/messages_zh.min.js"></script>
<script src="~/lib/validate/jquery.validate.min.js"></script>
<script src="~/lib/validate/localization/messages_zh.min.js"></script>
</environment>
<script src="~/js/longbow.dataentity.js" asp-append-version="true"></script>
<script src="~/js/longbow.validate.js" asp-append-version="true"></script>

View File

@ -3,11 +3,11 @@
}
@section css {
<environment include="Development">
<link href="~/css/toastr.css" rel="stylesheet" />
<link href="~/lib/toastr/nuget/content/content/toastr.css" rel="stylesheet" />
<link href="~/css/jquery.mCustomScrollbar.css" rel="stylesheet" />
</environment>
<environment exclude="Development">
<link href="~/css/toastr.min.css" rel="stylesheet" />
<link href="~/lib/toastr/nuget/content/content/toastr.min.css" rel="stylesheet" />
<link href="~/css/jquery.mCustomScrollbar.min.css" rel="stylesheet" />
</environment>
<link href="~/css/nprogress.css" rel="stylesheet" />
@ -18,16 +18,18 @@
<environment include="Development">
<script src="~/js/sweetalert.js"></script>
<script src="~/js/jquery.mCustomScrollbar.js"></script>
<script src="~/js/signalr.js"></script>
<script src="~/js/toastr.js"></script>
<script src="~/lib/signalr/dist/browser/signalr.js"></script>
<script src="~/lib/toastr/nuget/content/scripts/toastr.js"></script>
<script src="~/lib/dcjqaccordion/js/jquery.dcjqaccordion.2.7.js"></script>
</environment>
<environment exclude="Development">
<script src="~/js/sweetalert.min.js"></script>
<script src="~/js/jquery.mCustomScrollbar.concat.min.js"></script>
<script src="~/js/signalr.min.js"></script>
<script src="~/js/toastr.min.js"></script>
<script src="~/lib/signalr/dist/browser/signalr.min.js"></script>
<script src="~/lib/toastr/nuget/content/scripts/toastr.min.js"></script>
<script src="~/lib/dcjqaccordion/js/jquery.dcjqaccordion.2.7.min.js"></script>
</environment>
<script src="~/js/jquery.dcjqaccordion.2.7.js"></script>
<script src="~/lib/dcjqaccordion/js/jquery.cookie.js"></script>
<script src="~/js/common-scripts.js" asp-append-version="true"></script>
<script src="~/js/log.js" asp-append-version="true"></script>
@RenderSection("javascript", false)

View File

@ -4,12 +4,12 @@
}
@section css {
<environment include="Development">
<link href="~/css/bootstrap.css" rel="stylesheet" />
<link href="~/css/font-awesome.css" rel="stylesheet" />
<link href="~/lib/bootstrap/dist/css/bootstrap.css" rel="stylesheet" />
<link href="~/lib/font-awesome/css/font-awesome.css" rel="stylesheet" />
</environment>
<environment exclude="Development">
<link href="~/css/bootstrap.min.css" rel="stylesheet" />
<link href="~/css/font-awesome.min.css" rel="stylesheet" />
<link href="~/lib/bootstrap/dist/css/bootstrap.min.css" rel="stylesheet" />
<link href="~/lib/font-awesome/css/font-awesome.min.css" rel="stylesheet" />
</environment>
@RenderSection("css", false)
<link href="~/css/site.css" rel="stylesheet" asp-append-version="true" />
@ -23,10 +23,10 @@
}
@section javascript {
<environment include="Development">
<script src="~/js/bootstrap.bundle.js"></script>
<script src="~/lib/bootstrap/dist/js/bootstrap.bundle.js"></script>
</environment>
<environment exclude="Development">
<script src="~/js/bootstrap.bundle.min.js"></script>
<script src="~/lib/bootstrap/dist/js/bootstrap.bundle.min.js"></script>
</environment>
<script src="~/js/nprogress.js"></script>
<script src="~/js/longbow.common.js" asp-append-version="true"></script>

View File

@ -3,25 +3,25 @@
}
@section css {
<environment include="Development">
<link href="~/css/bootstrap-table.css" rel="stylesheet" />
<link href="~/lib/bootstrap-table/dist/bootstrap-table.css" rel="stylesheet" />
</environment>
<environment exclude="Development">
<link href="~/css/bootstrap-table.min.css" rel="stylesheet" />
<link href="~/lib/bootstrap-table/dist/bootstrap-table.min.css" rel="stylesheet" />
</environment>
@RenderSection("css", false)
}
@section javascript {
<environment include="Development">
<script src="~/js/bootstrap-table.js"></script>
<script src="~/js/bootstrap-table-zh-CN.js"></script>
<script src="~/js/jquery.validate.js"></script>
<script src="~/js/messages_zh.js"></script>
<script src="~/lib/bootstrap-table/dist/bootstrap-table.js"></script>
<script src="~/lib/bootstrap-table/dist/locale/bootstrap-table-zh-CN.js"></script>
<script src="~/lib/validate/jquery.validate.js"></script>
<script src="~/lib/validate/localization/messages_zh.js"></script>
</environment>
<environment exclude="Development">
<script src="~/js/bootstrap-table.min.js"></script>
<script src="~/js/bootstrap-table-zh-CN.min.js"></script>
<script src="~/js/jquery.validate.min.js"></script>
<script src="~/js/messages_zh.min.js"></script>
<script src="~/lib/bootstrap-table/dist/bootstrap-table.min.js"></script>
<script src="~/lib/bootstrap-table/dist/locale/bootstrap-table-zh-CN.min.js"></script>
<script src="~/lib/validate/jquery.validate.min.js"></script>
<script src="~/lib/validate/localization/messages_zh.min.js"></script>
</environment>
<script src="~/js/longbow.dataentity.js" asp-append-version="true"></script>
<script src="~/js/longbow.validate.js" asp-append-version="true"></script>

View File

@ -21,10 +21,10 @@
<a id="pathBase" href="~/" hidden></a>
<!-- jQuery文件。务必在bootstrap.min.js 之前引入 -->
<environment include="Development">
<script src="~/js/jquery-3.3.1.js"></script>
<script src="~/lib/jquery/dist/jquery.js"></script>
</environment>
<environment exclude="Development">
<script src="~/js/jquery-3.3.1.min.js"></script>
<script src="~/lib/jquery/dist/jquery.min.js"></script>
</environment>
@RenderSection("javascript", false)
</body>

View File

@ -4,7 +4,7 @@
"libraries": [
{
"library": "@aspnet/signalr@1.0.4",
"destination": "wwwroot/lib/@aspnet/signalr/",
"destination": "wwwroot/lib/signalr/",
"files": [
"dist/browser/signalr.js",
"dist/browser/signalr.js.map",
@ -14,10 +14,94 @@
},
{
"library": "jquery@3.3.1",
"destination": "wwwroot/lib/@aspnet/jquery/",
"destination": "wwwroot/lib/jquery/",
"files": [
"dist/jquery.js",
"dist/jquery.min.js"
"dist/jquery.min.js",
"dist/jquery.min.map"
]
},
{
"provider": "cdnjs",
"library": "jquery-validate@1.18.0",
"destination": "wwwroot/lib/validate",
"files": [
"jquery.validate.js",
"jquery.validate.min.js",
"localization/messages_zh.js",
"localization/messages_zh.min.js"
]
},
{
"library": "toastr@2.1.4",
"destination": "wwwroot/lib/toastr/",
"files": [
"nuget/content/scripts/toastr.js",
"nuget/content/scripts/toastr.min.js",
"nuget/content/scripts/toastr.min.js.map",
"nuget/content/content/toastr.css",
"nuget/content/content/toastr.min.css"
]
},
{
"library": "bootstrap-table@1.12.1",
"destination": "wwwroot/lib/bootstrap-table/",
"files": [
"dist/bootstrap-table.js",
"dist/bootstrap-table.min.js",
"dist/bootstrap-table.css",
"dist/bootstrap-table.min.css",
"dist/locale/bootstrap-table-zh-CN.js",
"dist/locale/bootstrap-table-zh-CN.min.js"
]
},
{
"library": "bootstrap@4.1.3",
"destination": "wwwroot/lib/bootstrap/",
"files": [
"dist/css/bootstrap.css",
"dist/css/bootstrap.css.map",
"dist/css/bootstrap.min.css",
"dist/css/bootstrap.min.css.map",
"dist/js/bootstrap.bundle.js",
"dist/js/bootstrap.bundle.js.map",
"dist/js/bootstrap.bundle.min.js",
"dist/js/bootstrap.bundle.min.js.map"
]
},
{
"library": "font-awesome@4.7.0",
"destination": "wwwroot/lib/font-awesome/",
"files": [
"css/font-awesome.css",
"css/font-awesome.css.map",
"css/font-awesome.min.css",
"fonts/FontAwesome.otf",
"fonts/fontawesome-webfont.eot",
"fonts/fontawesome-webfont.svg",
"fonts/fontawesome-webfont.ttf",
"fonts/fontawesome-webfont.woff",
"fonts/fontawesome-webfont.woff2"
]
},
{
"library": "dcjqaccordion@2.7.1",
"destination": "wwwroot/lib/dcjqaccordion/",
"files": [
"js/jquery.dcjqaccordion.2.7.js",
"js/jquery.dcjqaccordion.2.7.min.js",
"js/jquery.cookie.js"
]
},
{
"library": "bootstrap-fileinput@4.5.1",
"destination": "wwwroot/lib/fileinput/",
"files": [
"css/fileinput.css",
"css/fileinput.min.css",
"js/fileinput.js",
"js/fileinput.min.js",
"js/locales/zh.js"
]
}
]

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because it is too large Load Diff

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@ -1,6 +1,6 @@
/**
* @author zhixin wen <wenzhixin2010@gmail.com>
* version: 1.11.0
* version: 1.12.1
* https://github.com/wenzhixin/bootstrap-table/
*/
@ -72,7 +72,7 @@
outline: 0 solid transparent;
}
.fixed-table-container thead th:first-child {
.fixed-table-container thead th:first-child:not([data-not-first-th]) {
border-left: none;
border-top-left-radius: 4px;
-webkit-border-top-left-radius: 4px;
@ -133,10 +133,6 @@
text-align: center;
}
.fixed-table-container .bs-checkbox .th-inner {
padding: 8px 0;
}
.fixed-table-container input[type="radio"],
.fixed-table-container input[type="checkbox"] {
margin: 0 auto !important;
@ -285,7 +281,7 @@
padding: 0 !important;
}
.pull-right .dropdown-menu {
.bootstrap-table .pull-right .dropdown-menu {
right: 0;
left: auto;
}
@ -304,3 +300,19 @@ div.fixed-table-scroll-outer {
height: 150px;
overflow: hidden;
}
/* for get correct heights */
.fixed-table-toolbar:after, .fixed-table-pagination:after {
content: "";
display: block;
clear: both;
}
.fullscreen {
position: fixed;
top: 0;
left: 0;
z-index: 1050;
width: 100%!important;
background: #FFF;
}

View File

@ -1165,8 +1165,8 @@
sprintf(' btn-%s', this.options.buttonsClass) +
sprintf(' btn-%s', this.options.iconSize) +
'" type="button" name="toggle" aria-label="toggle" title="%s">',
this.options.formatToggle()),
sprintf('<i class="%s %s"></i>', this.options.iconsPrefix, this.options.icons.toggleOff),
this.options.formatToggle()),
sprintf('<i class="%s %s"></i>', this.options.iconsPrefix, this.options.icons.toggle),
'</button>');
}

File diff suppressed because one or more lines are too long

View File

@ -0,0 +1,13 @@
/* Page */
body,html,div,blockquote,img,label,p,h1,h2,h3,h4,h5,h6,pre,ul,ol,li,dl,dt,dd,form,a,fieldset,input,th,td{border:0;outline:none;margin:0;padding:0;}
ul, ul li{list-style: none;}
ul.text {margin-bottom: 1em; line-height: 1.5em;}
.text-center {text-align: center;}
body {font: normal 13px Arial, sans-serif;}
h2 {font: normal 26px Arial, sans-serif; padding: 20px 0; margin: 0 0 30px 0;}
.wrap {width: 960px; margin: 0 auto;}
.demo-container {padding: 20px; float: left; width: 260px;}
.demo-container h4 {font-size: 14px; margin: 0 0 5px 0;}
.clear {clear: both;}
.dcjq-count {float: right;}

View File

@ -0,0 +1,8 @@
.black .accordion{font: bold 13px Arial, sans-serif;}
.black .accordion, .black .accordion li {margin: 0; padding: 0; border: none;}
.black .accordion a {padding: 10px 10px 10px 28px; background: #000 url(images/bg_graphite.png) repeat-x 0 0; text-decoration:none; display: block; color: #fff; font-weight: normal;border-bottom: 1px solid #fff;}
.black .accordion ul a {background: #343434;}
.black .accordion a.dcjq-parent, .black .accordion a.dcjq-parent:hover {background: #000 url(images/graphite_arrow_right.png) no-repeat 0 0; font-weight: bold; color: #fff;}
.black .accordion a.dcjq-parent.active {background: #000 url(images/graphite_arrow_down.png) no-repeat 0 0;}
.black .accordion a:hover {background: #121212;}
.black .accordion a:active{}

View File

@ -0,0 +1,8 @@
.blue .accordion{ border-top: 1px solid #013d6c; border-right: 1px solid #013d6c; border-left: 1px solid #013d6c;}
.blue .accordion, .blue .accordion li {margin: 0; padding: 0; border: none;}
.blue .accordion a {padding: 10px 10px 10px 15px; background: #0D5995; text-decoration:none; display: block; color: #fff; border-bottom: 1px solid #013d6c; border-top: 1px solid #4695d3;}
.blue .accordion ul a {padding: 10px 10px 10px 25px;}
.blue .accordion a.dcjq-parent, .blue .accordion a.dcjq-parent:hover {padding: 10px 10px 10px 15px;}
.blue .accordion a.dcjq-parent.active {background: #0D5995 url(images/checkers.png) repeat 0 0;}
.blue .accordion a:hover {background: #05477c;}
.blue .accordion a:active{}

Binary file not shown.

After

Width:  |  Height:  |  Size: 247 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 156 B

View File

@ -0,0 +1,96 @@
/**
* Cookie plugin
*
* Copyright (c) 2006 Klaus Hartl (stilbuero.de)
* Dual licensed under the MIT and GPL licenses:
* http://www.opensource.org/licenses/mit-license.php
* http://www.gnu.org/licenses/gpl.html
*
*/
/**
* Create a cookie with the given name and value and other optional parameters.
*
* @example $.cookie('the_cookie', 'the_value');
* @desc Set the value of a cookie.
* @example $.cookie('the_cookie', 'the_value', { expires: 7, path: '/', domain: 'jquery.com', secure: true });
* @desc Create a cookie with all available options.
* @example $.cookie('the_cookie', 'the_value');
* @desc Create a session cookie.
* @example $.cookie('the_cookie', null);
* @desc Delete a cookie by passing null as value. Keep in mind that you have to use the same path and domain
* used when the cookie was set.
*
* @param String name The name of the cookie.
* @param String value The value of the cookie.
* @param Object options An object literal containing key/value pairs to provide optional cookie attributes.
* @option Number|Date expires Either an integer specifying the expiration date from now on in days or a Date object.
* If a negative value is specified (e.g. a date in the past), the cookie will be deleted.
* If set to null or omitted, the cookie will be a session cookie and will not be retained
* when the the browser exits.
* @option String path The value of the path atribute of the cookie (default: path of page that created the cookie).
* @option String domain The value of the domain attribute of the cookie (default: domain of page that created the cookie).
* @option Boolean secure If true, the secure attribute of the cookie will be set and the cookie transmission will
* require a secure protocol (like HTTPS).
* @type undefined
*
* @name $.cookie
* @cat Plugins/Cookie
* @author Klaus Hartl/klaus.hartl@stilbuero.de
*/
/**
* Get the value of a cookie with the given name.
*
* @example $.cookie('the_cookie');
* @desc Get the value of a cookie.
*
* @param String name The name of the cookie.
* @return The value of the cookie.
* @type String
*
* @name $.cookie
* @cat Plugins/Cookie
* @author Klaus Hartl/klaus.hartl@stilbuero.de
*/
jQuery.cookie = function(name, value, options) {
if (typeof value != 'undefined') { // name and value given, set cookie
options = options || {};
if (value === null) {
value = '';
options.expires = -1;
}
var expires = '';
if (options.expires && (typeof options.expires == 'number' || options.expires.toUTCString)) {
var date;
if (typeof options.expires == 'number') {
date = new Date();
date.setTime(date.getTime() + (options.expires * 24 * 60 * 60 * 1000));
} else {
date = options.expires;
}
expires = '; expires=' + date.toUTCString(); // use expires attribute, max-age is not supported by IE
}
// CAUTION: Needed to parenthesize options.path and options.domain
// in the following expressions, otherwise they evaluate to undefined
// in the packed version for some reason...
var path = options.path ? '; path=' + (options.path) : '';
var domain = options.domain ? '; domain=' + (options.domain) : '';
var secure = options.secure ? '; secure' : '';
document.cookie = [name, '=', encodeURIComponent(value), expires, path, domain, secure].join('');
} else { // only name given, get cookie
var cookieValue = null;
if (document.cookie && document.cookie != '') {
var cookies = document.cookie.split(';');
for (var i = 0; i < cookies.length; i++) {
var cookie = jQuery.trim(cookies[i]);
// Does this cookie string begin with the name we want?
if (cookie.substring(0, name.length + 1) == (name + '=')) {
cookieValue = decodeURIComponent(cookie.substring(name.length + 1));
break;
}
}
}
return cookieValue;
}
};

View File

@ -1,225 +1,198 @@
/*
* DC jQuery Vertical Accordion Menu - jQuery vertical accordion menu plugin
* Copyright (c) 2011 Design Chemical
*
* Dual licensed under the MIT and GPL licenses:
* http://www.opensource.org/licenses/mit-license.php
* http://www.gnu.org/licenses/gpl.html
*
*/
(function($){
$.fn.dcAccordion = function(options) {
//set default options
var defaults = {
classParent : 'dcjq-parent',
classActive : 'active',
classArrow : 'dcjq-icon',
classCount : 'dcjq-count',
classExpand : 'dcjq-current-parent',
eventType : 'click',
hoverDelay : 300,
menuClose : true,
autoClose : true,
autoExpand : false,
speed : 'slow',
saveState : true,
disableLink : true,
showCount : false,
// cookie : 'dcjq-accordion'
};
//call in the default otions
var options = $.extend(defaults, options);
this.each(function(options){
var obj = this;
setUpAccordion();
// if(defaults.saveState == true){
// checkCookie(defaults.cookie, obj);
// }
if(defaults.autoExpand == true){
$('li.'+defaults.classExpand+' > a').addClass(defaults.classActive);
}
resetAccordion();
if(defaults.eventType == 'hover'){
var config = {
sensitivity: 2, // number = sensitivity threshold (must be 1 or higher)
interval: defaults.hoverDelay, // number = milliseconds for onMouseOver polling interval
over: linkOver, // function = onMouseOver callback (REQUIRED)
timeout: defaults.hoverDelay, // number = milliseconds delay before onMouseOut
out: linkOut // function = onMouseOut callback (REQUIRED)
};
$('li a',obj).hoverIntent(config);
var configMenu = {
sensitivity: 2, // number = sensitivity threshold (must be 1 or higher)
interval: 1000, // number = milliseconds for onMouseOver polling interval
over: menuOver, // function = onMouseOver callback (REQUIRED)
timeout: 1000, // number = milliseconds delay before onMouseOut
out: menuOut // function = onMouseOut callback (REQUIRED)
};
$(obj).hoverIntent(configMenu);
// Disable parent links
if(defaults.disableLink == true){
$('li a',obj).click(function(e){
if($(this).siblings('ul').length >0){
e.preventDefault();
}
});
}
} else {
$('li a',obj).click(function(e){
$activeLi = $(this).parent('li');
$parentsLi = $activeLi.parents('li');
$parentsUl = $activeLi.parents('ul');
// Prevent browsing to link if has child links
if(defaults.disableLink == true){
if($(this).siblings('ul').length >0){
e.preventDefault();
}
}
// Auto close sibling menus
if(defaults.autoClose == true){
autoCloseAccordion($parentsLi, $parentsUl);
}
if ($('> ul',$activeLi).is(':visible')){
$('ul',$activeLi).slideUp(defaults.speed);
$('a',$activeLi).removeClass(defaults.classActive);
} else {
$(this).siblings('ul').slideToggle(defaults.speed);
$('> a',$activeLi).addClass(defaults.classActive);
}
// // Write cookie if save state is on
// if(defaults.saveState == true){
// createCookie(defaults.cookie, obj);
// }
});
}
// Set up accordion
function setUpAccordion(){
$arrow = '<span class="'+defaults.classArrow+'"></span>';
var classParentLi = defaults.classParent+'-li';
$('> ul',obj).show();
$('li',obj).each(function(){
if($('> ul',this).length > 0){
$(this).addClass(classParentLi);
$('> a',this).addClass(defaults.classParent).append($arrow);
}
});
$('> ul',obj).hide();
if(defaults.showCount == true){
$('li.'+classParentLi,obj).each(function(){
if(defaults.disableLink == true){
var getCount = parseInt($('ul a:not(.'+defaults.classParent+')',this).length);
} else {
var getCount = parseInt($('ul a',this).length);
}
$('> a',this).append(' <span class="'+defaults.classCount+'">'+getCount+'</span>');
});
}
}
function linkOver(){
$activeLi = $(this).parent('li');
$parentsLi = $activeLi.parents('li');
$parentsUl = $activeLi.parents('ul');
// Auto close sibling menus
if(defaults.autoClose == true){
autoCloseAccordion($parentsLi, $parentsUl);
}
if ($('> ul',$activeLi).is(':visible')){
$('ul',$activeLi).slideUp(defaults.speed);
$('a',$activeLi).removeClass(defaults.classActive);
} else {
$(this).siblings('ul').slideToggle(defaults.speed);
$('> a',$activeLi).addClass(defaults.classActive);
}
// Write cookie if save state is on
if(defaults.saveState == true){
createCookie(defaults.cookie, obj);
}
}
function linkOut(){
}
function menuOver(){
}
function menuOut(){
if(defaults.menuClose == true){
$('ul',obj).slideUp(defaults.speed);
// Reset active links
$('a',obj).removeClass(defaults.classActive);
createCookie(defaults.cookie, obj);
}
}
// Auto-Close Open Menu Items
function autoCloseAccordion($parentsLi, $parentsUl){
$('ul',obj).not($parentsUl).slideUp(defaults.speed);
// Reset active links
$('a',obj).removeClass(defaults.classActive);
$('> a',$parentsLi).addClass(defaults.classActive);
}
// Reset accordion using active links
function resetAccordion(){
$('ul',obj).hide();
$allActiveLi = $('a.'+defaults.classActive,obj);
$allActiveLi.siblings('ul').show();
}
});
// Retrieve cookie value and set active items
// function checkCookie(cookieId, obj){
// var cookieVal = $.cookie(cookieId);
// if(cookieVal != null){
// // create array from cookie string
// var activeArray = cookieVal.split(',');
// $.each(activeArray, function(index,value){
// var $cookieLi = $('li:eq('+value+')',obj);
// $('> a',$cookieLi).addClass(defaults.classActive);
// var $parentsLi = $cookieLi.parents('li');
// $('> a',$parentsLi).addClass(defaults.classActive);
// });
// }
// }
// Write cookie
// function createCookie(cookieId, obj){
// var activeIndex = [];
// // Create array of active items index value
// $('li a.'+defaults.classActive,obj).each(function(i){
// var $arrayItem = $(this).parent('li');
// var itemIndex = $('li',obj).index($arrayItem);
// activeIndex.push(itemIndex);
// });
// // Store in cookie
// $.cookie(cookieId, activeIndex, { path: '/' });
// }
};
/*
* DC jQuery Vertical Accordion Menu - jQuery vertical accordion menu plugin
* Copyright (c) 2011 Design Chemical
*
* Dual licensed under the MIT and GPL licenses:
* http://www.opensource.org/licenses/mit-license.php
* http://www.gnu.org/licenses/gpl.html
*
*/
(function($){
$.fn.dcAccordion = function(options) {
//set default options
var defaults = {
classParent : 'dcjq-parent',
classActive : 'active', classArrow : 'dcjq-icon', classCount : 'dcjq-count',
classExpand : 'dcjq-current-parent',
eventType : 'click',
hoverDelay : 300,
menuClose : true,
autoClose : true,
autoExpand : false,
speed : 'slow',
saveState : true,
disableLink : true, showCount : false,
cookie : 'dcjq-accordion'
};
//call in the default otions
var options = $.extend(defaults, options);
this.each(function(options){
var obj = this;
setUpAccordion();
if(defaults.saveState == true){
checkCookie(defaults.cookie, obj);
}
if(defaults.autoExpand == true){
$('li.'+defaults.classExpand+' > a').addClass(defaults.classActive);
}
resetAccordion();
if(defaults.eventType == 'hover'){
var config = {
sensitivity: 2, // number = sensitivity threshold (must be 1 or higher)
interval: defaults.hoverDelay, // number = milliseconds for onMouseOver polling interval
over: linkOver, // function = onMouseOver callback (REQUIRED)
timeout: defaults.hoverDelay, // number = milliseconds delay before onMouseOut
out: linkOut // function = onMouseOut callback (REQUIRED)
};
$('li a',obj).hoverIntent(config);
var configMenu = {
sensitivity: 2, // number = sensitivity threshold (must be 1 or higher)
interval: 1000, // number = milliseconds for onMouseOver polling interval
over: menuOver, // function = onMouseOver callback (REQUIRED)
timeout: 1000, // number = milliseconds delay before onMouseOut
out: menuOut // function = onMouseOut callback (REQUIRED)
};
$(obj).hoverIntent(configMenu);
// Disable parent links
if(defaults.disableLink == true){
$('li a',obj).click(function(e){
if($(this).siblings('ul').length >0){
e.preventDefault();
}
});
}
} else {
$('li a',obj).click(function(e){
$activeLi = $(this).parent('li');
$parentsLi = $activeLi.parents('li');
$parentsUl = $activeLi.parents('ul');
// Prevent browsing to link if has child links
if(defaults.disableLink == true){
if($(this).siblings('ul').length >0){
e.preventDefault();
}
}
// Auto close sibling menus
if(defaults.autoClose == true){
autoCloseAccordion($parentsLi, $parentsUl);
}
if ($('> ul',$activeLi).is(':visible')){
$('ul',$activeLi).slideUp(defaults.speed);
$('a',$activeLi).removeClass(defaults.classActive);
} else {
$(this).siblings('ul').slideToggle(defaults.speed);
$('> a',$activeLi).addClass(defaults.classActive);
}
// Write cookie if save state is on
if(defaults.saveState == true){
createCookie(defaults.cookie, obj);
}
});
}
// Set up accordion
function setUpAccordion(){
$arrow = '<span class="'+defaults.classArrow+'"></span>';
var classParentLi = defaults.classParent+'-li';
$('> ul',obj).show();
$('li',obj).each(function(){
if($('> ul',this).length > 0){ $(this).addClass(classParentLi);
$('> a',this).addClass(defaults.classParent).append($arrow);
}
});
$('> ul',obj).hide();
if(defaults.showCount == true){
$('li.'+classParentLi,obj).each(function(){
if(defaults.disableLink == true){
var getCount = parseInt($('ul a:not(.'+defaults.classParent+')',this).length);
} else {
var getCount = parseInt($('ul a',this).length);
}
$('> a',this).append(' <span class="'+defaults.classCount+'">('+getCount+')</span>');
});
}
}
function linkOver(){
$activeLi = $(this).parent('li');
$parentsLi = $activeLi.parents('li');
$parentsUl = $activeLi.parents('ul');
// Auto close sibling menus
if(defaults.autoClose == true){
autoCloseAccordion($parentsLi, $parentsUl);
}
if ($('> ul',$activeLi).is(':visible')){
$('ul',$activeLi).slideUp(defaults.speed);
$('a',$activeLi).removeClass(defaults.classActive);
} else {
$(this).siblings('ul').slideToggle(defaults.speed);
$('> a',$activeLi).addClass(defaults.classActive);
}
// Write cookie if save state is on
if(defaults.saveState == true){
createCookie(defaults.cookie, obj);
}
}
function linkOut(){
}
function menuOver(){
}
function menuOut(){
if(defaults.menuClose == true){
$('ul',obj).slideUp(defaults.speed);
// Reset active links
$('a',obj).removeClass(defaults.classActive);
createCookie(defaults.cookie, obj);
}
}
// Auto-Close Open Menu Items
function autoCloseAccordion($parentsLi, $parentsUl){
$('ul',obj).not($parentsUl).slideUp(defaults.speed);
// Reset active links
$('a',obj).removeClass(defaults.classActive);
$('> a',$parentsLi).addClass(defaults.classActive);
}
// Reset accordion using active links
function resetAccordion(){
$('ul',obj).hide();
$allActiveLi = $('a.'+defaults.classActive,obj);
$allActiveLi.siblings('ul').show();
}
});
// Retrieve cookie value and set active items
function checkCookie(cookieId, obj){
var cookieVal = $.cookie(cookieId);
if(cookieVal != null){
// create array from cookie string
var activeArray = cookieVal.split(',');
$.each(activeArray, function(index,value){
var $cookieLi = $('li:eq('+value+')',obj);
$('> a',$cookieLi).addClass(defaults.classActive);
var $parentsLi = $cookieLi.parents('li');
$('> a',$parentsLi).addClass(defaults.classActive);
});
}
}
// Write cookie
function createCookie(cookieId, obj){
var activeIndex = [];
// Create array of active items index value
$('li a.'+defaults.classActive,obj).each(function(i){
var $arrayItem = $(this).parent('li');
var itemIndex = $('li',obj).index($arrayItem);
activeIndex.push(itemIndex);
});
// Store in cookie
$.cookie(cookieId, activeIndex, { path: '/' });
}
};
})(jQuery);

View File

@ -0,0 +1 @@
(function($){$.fn.dcAccordion=function(options){var defaults={classParent:'dcjq-parent',classActive:'active',classArrow:'dcjq-icon',classCount:'dcjq-count',classExpand:'dcjq-current-parent',eventType:'click',hoverDelay:300,menuClose:true,autoClose:true,autoExpand:false,speed:'slow',saveState:true,disableLink:true,showCount:false,cookie:'dcjq-accordion'};var options=$.extend(defaults,options);this.each(function(options){var obj=this;setUpAccordion();if(defaults.saveState==true){checkCookie(defaults.cookie,obj)}if(defaults.autoExpand==true){$('li.'+defaults.classExpand+' > a').addClass(defaults.classActive)}resetAccordion();if(defaults.eventType=='hover'){var config={sensitivity:2,interval:defaults.hoverDelay,over:linkOver,timeout:defaults.hoverDelay,out:linkOut};$('li a',obj).hoverIntent(config);var configMenu={sensitivity:2,interval:1000,over:menuOver,timeout:1000,out:menuOut};$(obj).hoverIntent(configMenu);if(defaults.disableLink==true){$('li a',obj).click(function(e){if($(this).siblings('ul').length>0){e.preventDefault()}})}}else{$('li a',obj).click(function(e){$activeLi=$(this).parent('li');$parentsLi=$activeLi.parents('li');$parentsUl=$activeLi.parents('ul');if(defaults.disableLink==true){if($(this).siblings('ul').length>0){e.preventDefault()}}if(defaults.autoClose==true){autoCloseAccordion($parentsLi,$parentsUl)}if($('> ul',$activeLi).is(':visible')){$('ul',$activeLi).slideUp(defaults.speed);$('a',$activeLi).removeClass(defaults.classActive)}else{$(this).siblings('ul').slideToggle(defaults.speed);$('> a',$activeLi).addClass(defaults.classActive)}if(defaults.saveState==true){createCookie(defaults.cookie,obj)}})}function setUpAccordion(){$arrow='<span class="'+defaults.classArrow+'"></span>';var classParentLi=defaults.classParent+'-li';$('> ul',obj).show();$('li',obj).each(function(){if($('> ul',this).length>0){$(this).addClass(classParentLi);$('> a',this).addClass(defaults.classParent).append($arrow)}});$('> ul',obj).hide();if(defaults.showCount==true){$('li.'+classParentLi,obj).each(function(){if(defaults.disableLink==true){var getCount=parseInt($('ul a:not(.'+defaults.classParent+')',this).length)}else{var getCount=parseInt($('ul a',this).length)}$('> a',this).append(' <span class="'+defaults.classCount+'">('+getCount+')</span>')})}}function linkOver(){$activeLi=$(this).parent('li');$parentsLi=$activeLi.parents('li');$parentsUl=$activeLi.parents('ul');if(defaults.autoClose==true){autoCloseAccordion($parentsLi,$parentsUl)}if($('> ul',$activeLi).is(':visible')){$('ul',$activeLi).slideUp(defaults.speed);$('a',$activeLi).removeClass(defaults.classActive)}else{$(this).siblings('ul').slideToggle(defaults.speed);$('> a',$activeLi).addClass(defaults.classActive)}if(defaults.saveState==true){createCookie(defaults.cookie,obj)}}function linkOut(){}function menuOver(){}function menuOut(){if(defaults.menuClose==true){$('ul',obj).slideUp(defaults.speed);$('a',obj).removeClass(defaults.classActive);createCookie(defaults.cookie,obj)}}function autoCloseAccordion($parentsLi,$parentsUl){$('ul',obj).not($parentsUl).slideUp(defaults.speed);$('a',obj).removeClass(defaults.classActive);$('> a',$parentsLi).addClass(defaults.classActive)}function resetAccordion(){$('ul',obj).hide();$allActiveLi=$('a.'+defaults.classActive,obj);$allActiveLi.siblings('ul').show()}});function checkCookie(cookieId,obj){var cookieVal=$.cookie(cookieId);if(cookieVal!=null){var activeArray=cookieVal.split(',');$.each(activeArray,function(index,value){var $cookieLi=$('li:eq('+value+')',obj);$('> a',$cookieLi).addClass(defaults.classActive);var $parentsLi=$cookieLi.parents('li');$('> a',$parentsLi).addClass(defaults.classActive)})}}function createCookie(cookieId,obj){var activeIndex=[];$('li a.'+defaults.classActive,obj).each(function(i){var $arrayItem=$(this).parent('li');var itemIndex=$('li',obj).index($arrayItem);activeIndex.push(itemIndex)});$.cookie(cookieId,activeIndex,{path:'/'})}}})(jQuery);

View File

@ -0,0 +1,9 @@
/**
* hoverIntent r5 // 2007.03.27 // jQuery 1.1.2+
* <http://cherne.net/brian/resources/jquery.hoverIntent.html>
*
* @param f onMouseOver function || An object with configuration options
* @param g onMouseOut function || Nothing (use configuration options object)
* @author Brian Cherne <brian@cherne.net>
*/
(function($){$.fn.hoverIntent=function(f,g){var cfg={sensitivity:7,interval:100,timeout:0};cfg=$.extend(cfg,g?{over:f,out:g}:f);var cX,cY,pX,pY;var track=function(ev){cX=ev.pageX;cY=ev.pageY;};var compare=function(ev,ob){ob.hoverIntent_t=clearTimeout(ob.hoverIntent_t);if((Math.abs(pX-cX)+Math.abs(pY-cY))<cfg.sensitivity){$(ob).unbind("mousemove",track);ob.hoverIntent_s=1;return cfg.over.apply(ob,[ev]);}else{pX=cX;pY=cY;ob.hoverIntent_t=setTimeout(function(){compare(ev,ob);},cfg.interval);}};var delay=function(ev,ob){ob.hoverIntent_t=clearTimeout(ob.hoverIntent_t);ob.hoverIntent_s=0;return cfg.out.apply(ob,[ev]);};var handleHover=function(e){var p=(e.type=="mouseover"?e.fromElement:e.toElement)||e.relatedTarget;while(p&&p!=this){try{p=p.parentNode;}catch(e){p=this;}}if(p==this){return false;}var ev=jQuery.extend({},e);var ob=this;if(ob.hoverIntent_t){ob.hoverIntent_t=clearTimeout(ob.hoverIntent_t);}if(e.type=="mouseover"){pX=ev.pageX;pY=ev.pageY;$(ob).bind("mousemove",track);if(ob.hoverIntent_s!=1){ob.hoverIntent_t=setTimeout(function(){compare(ev,ob);},cfg.interval);}}else{$(ob).unbind("mousemove",track);if(ob.hoverIntent_s==1){ob.hoverIntent_t=setTimeout(function(){delay(ev,ob);},cfg.timeout);}}};return this.mouseover(handleHover).mouseout(handleHover);};})(jQuery);

View File

@ -1,5 +1,5 @@
/*!
* bootstrap-fileinput v4.4.9
* bootstrap-fileinput v4.5.1
* http://plugins.krajee.com/file-input
*
* Krajee default styling for bootstrap-fileinput.
@ -58,8 +58,8 @@
.krajee-default .file-thumb-progress .progress, .krajee-default .file-thumb-progress .progress-bar {
height: 11px;
font-family: Verdana, Helvetica, sans-serif;
font-size: 9px;
line-height: 10px;
}
.krajee-default .file-caption-info, .krajee-default .file-size-info {
@ -86,34 +86,6 @@
width: 100%;
}
.rotate-2 {
transform: rotateY(180deg);
}
.rotate-3 {
transform: rotate(180deg);
}
.rotate-4 {
transform: rotate(180deg) rotateY(180deg);
}
.rotate-5 {
transform: rotate(270deg) rotateY(180deg);
}
.rotate-6 {
transform: rotate(90deg);
}
.rotate-7 {
transform: rotate(90deg) rotateY(180deg);
}
.rotate-8 {
transform: rotate(270deg);
}
.file-loading:before {
content: " Loading...";
display: inline-block;
@ -225,8 +197,8 @@
.krajee-default.file-preview-frame {
margin: 8px;
border: 1px solid #ddd;
box-shadow: 1px 1px 5px 0 #a2958a;
border: 1px solid rgba(0,0,0,0.2);
box-shadow: 0 0 10px 0 rgba(0,0,0,0.2);
padding: 6px;
float: left;
text-align: center;
@ -237,12 +209,17 @@
height: 160px;
}
.krajee-default.file-preview-frame .kv-file-content.kv-pdf-rendered {
width: 400px;
}
.krajee-default.file-preview-frame .file-thumbnail-footer {
height: 70px;
}
.krajee-default.file-preview-frame:not(.file-preview-error):hover {
box-shadow: 3px 3px 5px 0 #333;
border: 1px solid rgba(0,0,0,0.3);
box-shadow: 0 0 10px 0 rgba(0,0,0,0.4);
}
.krajee-default .file-preview-text {
@ -305,14 +282,13 @@
.kv-upload-progress .progress {
height: 20px;
line-height: 20px;
margin: 10px 0;
overflow: hidden;
}
.kv-upload-progress .progress-bar {
height: 20px;
line-height: 20px;
font-family: Verdana, Helvetica, sans-serif;
}
/*noinspection CssOverwrittenProperties*/
@ -432,39 +408,15 @@
opacity: 0.65;
}
@media (min-width: 576px) {
.file-zoom-dialog .modal-dialog {
max-width: 500px;
}
}
@media (min-width: 992px) {
.file-zoom-dialog .modal-lg {
max-width: 800px;
}
}
.file-zoom-fullscreen.modal {
position: fixed;
top: 0;
right: 0;
bottom: 0;
left: 0;
}
.file-zoom-fullscreen .modal-dialog {
position: fixed;
min-width: 100%;
margin: 0;
padding: 0;
width: 100%;
height: 100%;
max-width: 100%;
max-height: 100%;
}
.file-zoom-fullscreen .modal-content {
border-radius: 0;
box-shadow: none;
min-height: 100vh;
}
.file-zoom-fullscreen .modal-body {
@ -493,10 +445,6 @@
max-height: 100%;
}
.file-zoom-content .is-portrait-gt4 {
margin-top: 60px;
}
.file-zoom-content > .file-object.type-image {
height: auto;
min-height: inherit;
@ -507,7 +455,19 @@
height: 30px;
}
@media screen and (max-width: 767px) {
@media (min-width: 576px) {
.file-zoom-dialog .modal-dialog {
max-width: 500px;
}
}
@media (min-width: 992px) {
.file-zoom-dialog .modal-lg {
max-width: 800px;
}
}
@media (max-width: 767px) {
.file-preview-thumbnails {
display: flex;
justify-content: center;
@ -520,12 +480,18 @@
}
}
@media screen and (max-width: 350px) {
@media (max-width: 350px) {
.krajee-default.file-preview-frame .kv-file-content {
width: 160px;
}
}
@media (max-width: 420px) {
.krajee-default.file-preview-frame .kv-file-content.kv-pdf-rendered {
width: 100%;
}
}
.file-loading[dir=rtl]:before {
background: transparent url(../img/loading.gif) top right no-repeat;
padding-left: 0;
@ -551,4 +517,4 @@
.file-preview-initial.sortable-chosen {
background-color: #d9edf7;
}
}

File diff suppressed because one or more lines are too long

View File

@ -1,5 +1,5 @@
/*!
* bootstrap-fileinput v4.4.9
* bootstrap-fileinput v4.5.1
* http://plugins.krajee.com/file-input
*
* Author: Kartik Visweswaran
@ -336,7 +336,10 @@
uniqId: function () {
return Math.round(new Date().getTime()) + '_' + Math.round(Math.random() * 100);
},
htmlEncode: function (str) {
htmlEncode: function (str, undefVal) {
if (str === undefined) {
return undefVal || null;
}
return str.replace(/&/g, '&amp;')
.replace(/</g, '&lt;')
.replace(/>/g, '&gt;')
@ -430,68 +433,65 @@
}
$cache.remove();
},
setOrientation: function (buffer, callback) {
var scanner = new DataView(buffer), idx = 0, value = 1, // Non-rotated is the default
maxBytes, uInt16, exifLength;
if (scanner.getUint16(idx) !== 0xFFD8 || buffer.length < 2) { // not a proper JPEG
if (callback) {
callback();
}
return;
}
idx += 2;
maxBytes = scanner.byteLength;
while (idx < maxBytes - 2) {
uInt16 = scanner.getUint16(idx);
idx += 2;
switch (uInt16) {
case 0xFFE1: // Start of EXIF
exifLength = scanner.getUint16(idx);
maxBytes = exifLength - idx;
idx += 2;
break;
case 0x0112: // Orientation tag
value = scanner.getUint16(idx + 6, false);
maxBytes = 0; // Stop scanning
break;
}
}
if (callback) {
callback(value);
}
},
validateOrientation: function (file, callback) {
if (!window.FileReader || !window.DataView) {
return; // skip orientation if pre-requisite libraries not supported by browser
}
var reader = new FileReader(), buffer;
reader.onloadend = function () {
buffer = reader.result;
$h.setOrientation(buffer, callback);
};
reader.readAsArrayBuffer(file);
},
adjustOrientedImage: function ($img, isZoom) {
var offsetContTop, offsetTop, newTop;
if (!$img.hasClass('is-portrait-gt4')) {
return;
}
if (isZoom) {
$img.css({width: $img.parent().height()});
return;
} else {
$img.css({height: 'auto', width: $img.height()});
}
offsetContTop = $img.parent().offset().top;
offsetTop = $img.offset().top;
newTop = offsetContTop - offsetTop;
$img.css('margin-top', newTop);
},
closeButton: function (css) {
css = css ? 'close ' + css : 'close';
return '<button type="button" class="' + css + '" aria-label="Close">\n' +
' <span aria-hidden="true">&times;</span>\n' +
'</button>';
},
getRotation: function (value) {
switch (value) {
case 2:
return 'rotateY(180deg)';
case 3:
return 'rotate(180deg)';
case 4:
return 'rotate(180deg) rotateY(180deg)';
case 5:
return 'rotate(270deg) rotateY(180deg)';
case 6:
return 'rotate(90deg)';
case 7:
return 'rotate(90deg) rotateY(180deg)';
case 8:
return 'rotate(270deg)';
default:
return '';
}
},
setTransform: function (el, val) {
if (!el) {
return;
}
el.style.transform = val;
el.style.webkitTransform = val;
el.style['-moz-transform'] = val;
el.style['-ms-transform'] = val;
el.style['-o-transform'] = val;
},
setImageOrientation: function ($img, $zoomImg, value) {
if (!$img || !$img.length) {
return;
}
var ev = 'load.fileinputimageorient';
$img.off(ev).on(ev, function () {
var img = $img.get(0), zoomImg = $zoomImg && $zoomImg.length ? $zoomImg.get(0) : null,
h = img.offsetHeight, w = img.offsetWidth, r = $h.getRotation(value);
$img.data('orientation', value);
if (zoomImg) {
$zoomImg.data('orientation', value);
}
if (value < 5) {
$h.setTransform(img, r);
$h.setTransform(zoomImg, r);
return;
}
var offsetAngle = Math.atan(w / h), origFactor = Math.sqrt(Math.pow(h, 2) + Math.pow(w, 2)),
scale = !origFactor ? 1 : (h / Math.cos(Math.PI / 2 + offsetAngle)) / origFactor,
s = ' scale(' + Math.abs(scale) + ')';
$h.setTransform(img, r + s);
$h.setTransform(zoomImg, r + s);
});
}
};
FileInput = function (element, options) {
@ -578,13 +578,13 @@
if (self.isDisabled) {
$el.attr('disabled', true);
}
self.isClickable = self.browseOnZoneClick && self.showPreview &&
(self.dropZoneEnabled || !$h.isEmpty(self.defaultPreviewContent));
self.isAjaxUpload = $h.hasFileUploadSupport() && !$h.isEmpty(self.uploadUrl);
self.dropZoneEnabled = $h.hasDragDropSupport() && self.dropZoneEnabled;
if (!self.isAjaxUpload) {
self.dropZoneEnabled = self.dropZoneEnabled && $h.canAssignFilesToInput();
}
self.isClickable = self.browseOnZoneClick && self.showPreview &&
(self.dropZoneEnabled || !$h.isEmpty(self.defaultPreviewContent));
self.slug = typeof options.slugCallback === "function" ? options.slugCallback : self._slugDefault;
self.mainTemplate = self.showCaption ? self._getLayoutTemplate('main1') : self._getLayoutTemplate('main2');
self.captionTemplate = self._getLayoutTemplate('caption');
@ -761,6 +761,9 @@
tOther = '<div class="kv-preview-data file-preview-other-frame"' + tStyle + '>\n' + $h.DEFAULT_PREVIEW + '\n</div>\n';
tZoomCache = '<div class="kv-zoom-cache" style="display:none">{zoomContent}</div>';
vDefaultDim = {width: "100%", height: "100%", 'min-height': "480px"};
if (self._isPdfRendered()) {
tPdf = self.pdfRendererTemplate.replace('{renderer}', self.pdfRendererUrl);
}
self.defaults = {
layoutTemplates: {
main1: tMain1,
@ -817,7 +820,7 @@
audio: {width: "100%", height: "30px"},
flash: {width: "213px", height: "160px"},
object: {width: "213px", height: "160px"},
pdf: {width: "213px", height: "160px"},
pdf: {width: "100%", height: "160px"},
other: {width: "213px", height: "160px"}
},
previewSettingsSmall: {
@ -934,13 +937,16 @@
self._initPreviewTemplates();
},
_initPreviewTemplates: function () {
var self = this, cfg = self.defaults, tags = self.previewMarkupTags, tagBef, tagAft = tags.tagAfter;
$.each(cfg.previewContentTemplates, function (key, value) {
var self = this, tags = self.previewMarkupTags, tagBef, tagAft = tags.tagAfter;
$.each(self.previewContentTemplates, function (key, value) {
if ($h.isEmpty(self.previewTemplates[key])) {
tagBef = tags.tagBefore2;
if (key === 'generic' || key === 'image' || key === 'html' || key === 'text') {
tagBef = tags.tagBefore1;
}
if (self._isPdfRendered() && key === 'pdf') {
tagBef = tagBef.replace('kv-file-content', 'kv-file-content kv-pdf-rendered');
}
self.previewTemplates[key] = tagBef + value + tagAft;
}
});
@ -1128,6 +1134,11 @@
};
self.previewCache.init();
},
_isPdfRendered: function () {
var self = this, useLib = self.usePdfRenderer,
flag = typeof useLib === "function" ? useLib() : !!useLib;
return flag && self.pdfRendererUrl;
},
_handler: function ($el, event, callback) {
var self = this, ns = self.namespace, ev = event.split(' ').join(ns + ' ') + ns;
if (!$el || !$el.length) {
@ -1140,6 +1151,7 @@
if (id) {
msg = '"' + id + '": ' + msg;
}
msg = 'bootstrap-fileinput: ' + msg;
if (typeof window.console.log !== "undefined") {
window.console.log(msg);
} else {
@ -1391,7 +1403,7 @@
},
_listen: function () {
var self = this, $el = self.$element, $form = self.$form, $cont = self.$container, fullScreenEvents;
self._handler($el, 'click', function(e) {
self._handler($el, 'click', function (e) {
if ($el.hasClass('file-no-browse')) {
if ($el.data('zoneClicked')) {
$el.data('zoneClicked', false);
@ -1809,10 +1821,6 @@
});
}
$modal.data('previewId', pid);
var $img = $body.find('img');
if ($img.length) {
$h.adjustOrientedImage($img, true);
}
self._handler($prev, 'click', function () {
self._zoomSlideShow('prev', pid);
});
@ -1904,10 +1912,10 @@
});
});
},
_inputFileCount: function() {
_inputFileCount: function () {
return this.$element.get(0).files.length;
},
_refreshPreview: function() {
_refreshPreview: function () {
var self = this, files;
if (!self._inputFileCount() || !self.showPreview || !self.isPreviewable) {
return;
@ -2926,25 +2934,7 @@
self._clearDefaultPreview();
self._addToPreview($preview, content);
var $img = $preview.find('#' + previewId + ' img');
if ($img.length && self.autoOrientImage) {
$h.validateOrientation(file, function (value) {
if (!value) {
self._validateImage(previewId, caption, ftype, fsize, iData);
return;
}
var $zoomImg = $preview.find('#zoom-' + previewId + ' img'), css = 'rotate-' + value;
if (value > 4) {
css += ($img.width() > $img.height() ? ' is-portrait-gt4' : ' is-landscape-gt4');
}
$h.addCss($img, css);
$h.addCss($zoomImg, css);
self._raise('fileimageoriented', {'$img': $img, 'file': file});
self._validateImage(previewId, caption, ftype, fsize, iData);
$h.adjustOrientedImage($img);
});
} else {
self._validateImage(previewId, caption, ftype, fsize, iData);
}
self._validateImageOrientation($img, file, previewId, caption, ftype, fsize, iData);
} else {
self._previewDefault(file, previewId);
}
@ -2973,6 +2963,7 @@
}
},
_slugDefault: function (text) {
// noinspection RegExpRedundantEscape
return $h.isEmpty(text) ? '' : String(text).replace(/[\[\]\/\{}:;#%=\(\)\*\+\?\\\^\$\|<>&"']/g, '_');
},
_updateFileDetails: function (numFiles) {
@ -3089,6 +3080,7 @@
return null;
}
/** @namespace file.webkitRelativePath */
/** @namespace file.fileName */
relativePath = String(file.webkitRelativePath || file.fileName || file.name || null);
if (!relativePath) {
return null;
@ -3154,9 +3146,33 @@
self._showUploadError(msg, params);
self._setPreviewError($thumb, i, null);
},
_validateImage: function (previewId, fname, ftype, fsize, iData) {
_getExifObj: function (iData) {
var self = this, exifObj = null;
try {
exifObj = window.piexif ? window.piexif.load(iData) : null;
} catch (err) {
exifObj = null;
}
if (!exifObj) {
self._log('Error loading the piexif.js library.');
}
return exifObj;
},
_validateImageOrientation: function ($img, file, previewId, caption, ftype, fsize, iData) {
var self = this, exifObj, value;
exifObj = $img.length && self.autoOrientImage ? self._getExifObj(iData) : null;
value = exifObj ? exifObj["0th"][piexif.ImageIFD.Orientation] : null; // jshint ignore:line
if (!value) {
self._validateImage(previewId, caption, ftype, fsize, iData, exifObj);
return;
}
$h.setImageOrientation($img, self.$preview.find('#zoom-' + previewId + ' img'), value);
self._raise('fileimageoriented', {'$img': $img, 'file': file});
self._validateImage(previewId, caption, ftype, fsize, iData, exifObj);
},
_validateImage: function (previewId, fname, ftype, fsize, iData, exifObj) {
var self = this, $preview = self.$preview, params, w1, w2, $thumb = $preview.find("#" + previewId),
i = $thumb.attr('data-fileindex'), $img = $thumb.find('img'), exifObject;
i = $thumb.attr('data-fileindex'), $img = $thumb.find('img');
fname = fname || 'Untitled';
$img.one('load', function () {
w1 = $thumb.width();
@ -3172,11 +3188,6 @@
self._checkDimensions(i, 'Large', $img, $thumb, fname, 'Height', params);
}
self._raise('fileimageloaded', [previewId]);
try {
exifObject = window.piexif ? window.piexif.load(iData) : null;
} catch (err) {
exifObject = null;
}
self.loadedImages.push({
ind: i,
img: $img,
@ -3186,9 +3197,9 @@
siz: fsize,
validated: false,
imgData: iData,
exifObj: exifObject
exifObj: exifObj
});
$thumb.data('exif', exifObject);
$thumb.data('exif', exifObj);
self._validateAllImages();
}).one('error', function () {
self._raise('fileimageloaderror', [previewId]);
@ -3301,15 +3312,22 @@
}
},
_initClickable: function () {
var self = this, $zone;
var self = this, $zone, $tmpZone;
if (!self.isClickable) {
return;
}
$zone = self.isAjaxUpload ? self.$dropZone : self.$preview.find('.file-default-preview');
$zone = self.$dropZone;
if (!self.isAjaxUpload) {
$tmpZone = self.$preview.find('.file-default-preview');
if ($tmpZone.length) {
$zone = $tmpZone;
}
}
$h.addCss($zone, 'clickable');
$zone.attr('tabindex', -1);
self._handler($zone, 'click', function (e) {
var $tar = $(e.target), $el = self.$element;
var $tar = $(e.target);
if (!$(self.elErrorContainer + ':visible').length &&
(!$tar.parents('.file-preview-thumbnails').length || $tar.parents('.file-default-preview').length)) {
self.$element.data('zoneClicked', true).trigger('click');
@ -3537,8 +3555,7 @@
},
_browse: function (e) {
var self = this;
self._raise('filebrowse');
if (e && e.isDefaultPrevented()) {
if (e && e.isDefaultPrevented() || !self._raise('filebrowse')) {
return;
}
if (self.isError && !self.isAjaxUpload) {
@ -3776,7 +3793,8 @@
var node = ctr + i, previewId = previewInitId + "-" + node, file = files[i], fSizeKB, j, msg,
fnText = settings.text, fnImage = settings.image, fnHtml = settings.html, typ, chk, typ1, typ2,
caption = file && file.name ? self.slug(file.name) : '', fileSize = (file && file.size || 0) / 1000,
fileExtExpr = '', previewData = file ? $h.objUrl.createObjectURL(file) : null, fileCount = 0, strTypes = '',
fileExtExpr = '', previewData = file ? $h.objUrl.createObjectURL(file) : null, fileCount = 0,
strTypes = '',
func, knownTypes = 0, isText, isHtml, isImage, txtFlag, processFileLoaded = function () {
var msg = msgProgress.setTokens({
'index': i + 1,
@ -3806,7 +3824,7 @@
return;
}
if (caption.length === 0) {
msg = self.msgInvalidFileName.replace('{name}', $h.htmlEncode(file.name));
msg = self.msgInvalidFileName.replace('{name}', $h.htmlEncode(file.name, '[unknown]'));
throwError(msg, file, previewId, i);
return;
}
@ -4174,7 +4192,7 @@
options = $.extend(true, {}, self.options, options);
}
self._init(options, true);
self._listen();
self._listen();
return $el;
},
zoom: function (frameId) {
@ -4259,7 +4277,7 @@
showUploadedThumbs: true,
browseOnZoneClick: false,
autoReplace: false,
autoOrientImage: true, // for JPEG images based on EXIF orientation tag
autoOrientImage: false, // if `true` applicable for JPEG images only
required: false,
rtl: false,
hideThumbnailContent: false,
@ -4301,6 +4319,8 @@
borderless: 'btn btn-sm btn-kv btn-default btn-outline-secondary',
close: 'btn btn-sm btn-kv btn-default btn-outline-secondary'
},
previewTemplates: {},
previewContentTemplates: {},
preferIconicPreview: false,
preferIconicZoomPreview: false,
allowedPreviewTypes: undefined,
@ -4374,6 +4394,7 @@
reversePreviewOrder: false
};
// noinspection HtmlUnknownAttribute
$.fn.fileinputLocales.en = {
fileSingle: 'file',
filePlural: 'files',
@ -4446,7 +4467,12 @@
fullscreen: 'Toggle full screen',
borderless: 'Toggle borderless mode',
close: 'Close detailed preview'
}
},
usePdfRenderer: function () {
return !!navigator.userAgent.match(/(iPod|iPhone|iPad|Android)/i);
},
pdfRendererUrl: '',
pdfRendererTemplate: '<iframe class="kv-preview-data file-preview-pdf" src="{renderer}?file={data}" {style}></iframe>'
};
$.fn.fileinput.Constructor = FileInput;
@ -4454,4 +4480,10 @@
/**
* Convert automatically file inputs with class 'file' into a bootstrap fileinput control.
*/
$(document).ready(function () {
var $input = $('input.file[type=file]');
if ($input.length) {
$input.fileinput();
}
});
}));

File diff suppressed because one or more lines are too long

View File

@ -1,4 +1,4 @@
/*!
/*!
* FileInput Chinese Translations
*
* This file must be loaded after 'fileinput.js'. Patterns in braces '{}', or

File diff suppressed because one or more lines are too long

View File

Before

Width:  |  Height:  |  Size: 434 KiB

After

Width:  |  Height:  |  Size: 434 KiB

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@ -1,8 +1,13 @@
/*
* Note that this is toastr v2.1.3, the "latest" version in url has no more maintenance,
* please go to https://cdnjs.com/libraries/toastr.js and pick a certain version you want to use,
* make sure you copy the url from the website since the url may change between versions.
* */
/*
* Toastr
* Copyright 2012-2014 John Papa and Hans Fjällemark.
* All Rights Reserved.
* Use, reproduction, distribution, and modification of this code is subject to the terms and
* conditions of the MIT license, available at http://www.opensource.org/licenses/mit-license.php
*
* Author: John Papa and Hans Fjällemark
* Project: https://github.com/CodeSeven/toastr
*/
.toast-title {
font-weight: bold;
}
@ -12,10 +17,10 @@
}
.toast-message a,
.toast-message label {
color: #FFFFFF;
color: #ffffff;
}
.toast-message a:hover {
color: #CCCCCC;
color: #cccccc;
text-decoration: none;
}
.toast-close-button {
@ -25,13 +30,12 @@
float: right;
font-size: 20px;
font-weight: bold;
color: #FFFFFF;
color: #ffffff;
-webkit-text-shadow: 0 1px 0 #ffffff;
text-shadow: 0 1px 0 #ffffff;
opacity: 0.8;
-ms-filter: progid:DXImageTransform.Microsoft.Alpha(Opacity=80);
filter: alpha(opacity=80);
line-height: 1;
}
.toast-close-button:hover,
.toast-close-button:focus {
@ -42,11 +46,6 @@
-ms-filter: progid:DXImageTransform.Microsoft.Alpha(Opacity=40);
filter: alpha(opacity=40);
}
.rtl .toast-close-button {
left: -0.3em;
float: left;
right: 0.3em;
}
/*Additional properties for button version
iOS requires the button element instead of an anchor tag.
If you want the anchor version, it requires `href="#"`.*/
@ -57,16 +56,6 @@ button.toast-close-button {
border: 0;
-webkit-appearance: none;
}
.toast-top-center {
top: 0;
right: 0;
width: 100%;
}
.toast-bottom-center {
bottom: 0;
right: 0;
width: 100%;
}
.toast-top-full-width {
top: 0;
right: 0;
@ -96,8 +85,8 @@ button.toast-close-button {
#toast-container {
position: fixed;
z-index: 999999;
pointer-events: none;
/*overrides*/
}
#toast-container * {
-moz-box-sizing: border-box;
@ -105,9 +94,6 @@ button.toast-close-button {
box-sizing: border-box;
}
#toast-container > div {
position: relative;
pointer-events: auto;
overflow: hidden;
margin: 0 0 6px;
padding: 15px 15px 15px 50px;
width: 300px;
@ -119,17 +105,12 @@ button.toast-close-button {
-moz-box-shadow: 0 0 12px #999999;
-webkit-box-shadow: 0 0 12px #999999;
box-shadow: 0 0 12px #999999;
color: #FFFFFF;
color: #ffffff;
opacity: 0.8;
-ms-filter: progid:DXImageTransform.Microsoft.Alpha(Opacity=80);
filter: alpha(opacity=80);
}
#toast-container > div.rtl {
direction: rtl;
padding: 15px 50px 15px 15px;
background-position: right 15px center;
}
#toast-container > div:hover {
#toast-container > :hover {
-moz-box-shadow: 0 0 12px #000000;
-webkit-box-shadow: 0 0 12px #000000;
box-shadow: 0 0 12px #000000;
@ -150,42 +131,25 @@ button.toast-close-button {
#toast-container > .toast-warning {
background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABgAAAAYCAYAAADgdz34AAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsMAAA7DAcdvqGQAAAGYSURBVEhL5ZSvTsNQFMbXZGICMYGYmJhAQIJAICYQPAACiSDB8AiICQQJT4CqQEwgJvYASAQCiZiYmJhAIBATCARJy+9rTsldd8sKu1M0+dLb057v6/lbq/2rK0mS/TRNj9cWNAKPYIJII7gIxCcQ51cvqID+GIEX8ASG4B1bK5gIZFeQfoJdEXOfgX4QAQg7kH2A65yQ87lyxb27sggkAzAuFhbbg1K2kgCkB1bVwyIR9m2L7PRPIhDUIXgGtyKw575yz3lTNs6X4JXnjV+LKM/m3MydnTbtOKIjtz6VhCBq4vSm3ncdrD2lk0VgUXSVKjVDJXJzijW1RQdsU7F77He8u68koNZTz8Oz5yGa6J3H3lZ0xYgXBK2QymlWWA+RWnYhskLBv2vmE+hBMCtbA7KX5drWyRT/2JsqZ2IvfB9Y4bWDNMFbJRFmC9E74SoS0CqulwjkC0+5bpcV1CZ8NMej4pjy0U+doDQsGyo1hzVJttIjhQ7GnBtRFN1UarUlH8F3xict+HY07rEzoUGPlWcjRFRr4/gChZgc3ZL2d8oAAAAASUVORK5CYII=") !important;
}
#toast-container.toast-top-center > div,
#toast-container.toast-bottom-center > div {
width: 300px;
margin-left: auto;
margin-right: auto;
}
#toast-container.toast-top-full-width > div,
#toast-container.toast-bottom-full-width > div {
width: 96%;
margin-left: auto;
margin-right: auto;
margin: auto;
}
.toast {
background-color: #030303;
}
.toast-success {
background-color: #51A351;
background-color: #51a351;
}
.toast-error {
background-color: #BD362F;
background-color: #bd362f;
}
.toast-info {
background-color: #2F96B4;
background-color: #2f96b4;
}
.toast-warning {
background-color: #F89406;
}
.toast-progress {
position: absolute;
left: 0;
bottom: 0;
height: 4px;
background-color: #000000;
opacity: 0.4;
-ms-filter: progid:DXImageTransform.Microsoft.Alpha(Opacity=40);
filter: alpha(opacity=40);
background-color: #f89406;
}
/*Responsive Design*/
@media all and (max-width: 240px) {
@ -193,41 +157,24 @@ button.toast-close-button {
padding: 8px 8px 8px 50px;
width: 11em;
}
#toast-container > div.rtl {
padding: 8px 50px 8px 8px;
}
#toast-container .toast-close-button {
right: -0.2em;
top: -0.2em;
}
#toast-container .rtl .toast-close-button {
left: -0.2em;
right: 0.2em;
}
}
@media all and (min-width: 241px) and (max-width: 480px) {
#toast-container > div {
padding: 8px 8px 8px 50px;
width: 18em;
}
#toast-container > div.rtl {
padding: 8px 50px 8px 8px;
}
#toast-container .toast-close-button {
right: -0.2em;
top: -0.2em;
}
#toast-container .rtl .toast-close-button {
left: -0.2em;
right: 0.2em;
}
}
@media all and (min-width: 481px) and (max-width: 768px) {
#toast-container > div {
padding: 15px 15px 15px 50px;
width: 25em;
}
#toast-container > div.rtl {
padding: 15px 50px 15px 15px;
}
}

File diff suppressed because one or more lines are too long

View File

@ -1,16 +1,14 @@
/*
/*
* Toastr
* Copyright 2012-2015
* Authors: John Papa, Hans Fjällemark, and Tim Ferrell.
* Copyright 2012-2014 John Papa and Hans Fjällemark.
* All Rights Reserved.
* Use, reproduction, distribution, and modification of this code is subject to the terms and
* conditions of the MIT license, available at http://www.opensource.org/licenses/mit-license.php
*
* Author: John Papa and Hans Fjällemark
* ARIA Support: Greta Krafsig
*
* Project: https://github.com/CodeSeven/toastr
*/
/* global define */
; (function (define) {
define(['jquery'], function ($) {
return (function () {
@ -33,16 +31,13 @@
options: {},
subscribe: subscribe,
success: success,
version: '2.1.1',
version: '2.0.3',
warning: warning
};
var previousToast;
return toastr;
////////////////
//#region Accessible Methods
function error(message, title, optionsOverride) {
return notify({
type: toastType.error,
@ -59,7 +54,7 @@
if ($container.length) {
return $container;
}
if (create) {
if(create) {
$container = createContainer(options);
}
return $container;
@ -99,10 +94,10 @@
});
}
function clear($toastElement, clearOptions) {
function clear($toastElement) {
var options = getOptions();
if (!$container) { getContainer(options); }
if (!clearToast($toastElement, options, clearOptions)) {
if (!clearToast($toastElement, options)) {
clearContainer(options);
}
}
@ -118,19 +113,19 @@
$container.remove();
}
}
//#endregion
// internal functions
//#region Internal Methods
function clearContainer (options) {
function clearContainer(options){
var toastsToClear = $container.children();
for (var i = toastsToClear.length - 1; i >= 0; i--) {
clearToast($(toastsToClear[i]), options);
}
};
}
function clearToast ($toastElement, options, clearOptions) {
var force = clearOptions && clearOptions.force ? clearOptions.force : false;
if ($toastElement && (force || $(':focus', $toastElement).length === 0)) {
function clearToast($toastElement, options){
if ($toastElement && $(':focus', $toastElement).length === 0) {
$toastElement[options.hideMethod]({
duration: options.hideDuration,
easing: options.hideEasing,
@ -177,14 +172,12 @@
},
iconClass: 'toast-info',
positionClass: 'toast-top-right',
timeOut: 5000, // Set timeOut and extendedTimeOut to 0 to make it sticky
timeOut: 5000, // Set timeOut and extendedTimeout to 0 to make it sticky
titleClass: 'toast-title',
messageClass: 'toast-message',
target: 'body',
closeHtml: '<button type="button">&times;</button>',
newestOnTop: true,
preventDuplicates: false,
progressBar: false
closeHtml: '<button>&times;</button>',
newestOnTop: true
};
}
@ -194,44 +187,87 @@
}
function notify(map) {
var options = getOptions();
var iconClass = map.iconClass || options.iconClass;
var options = getOptions(),
iconClass = map.iconClass || options.iconClass;
if (typeof (map.optionsOverride) !== 'undefined') {
options = $.extend(options, map.optionsOverride);
iconClass = map.optionsOverride.iconClass || iconClass;
}
if (shouldExit(options, map)) { return; }
toastId++;
$container = getContainer(options, true);
var intervalId = null,
$toastElement = $('<div/>'),
$titleElement = $('<div/>'),
$messageElement = $('<div/>'),
$closeElement = $(options.closeHtml),
response = {
toastId: toastId,
state: 'visible',
startTime: new Date(),
options: options,
map: map
};
var intervalId = null;
var $toastElement = $('<div/>');
var $titleElement = $('<div/>');
var $messageElement = $('<div/>');
var $progressElement = $('<div/>');
var $closeElement = $(options.closeHtml);
var progressBar = {
intervalId: null,
hideEta: null,
maxHideTime: null
};
var response = {
toastId: toastId,
state: 'visible',
startTime: new Date(),
options: options,
map: map
};
if (map.iconClass) {
$toastElement.addClass(options.toastClass).addClass(iconClass);
}
personalizeToast();
if (map.title) {
$titleElement.append(map.title).addClass(options.titleClass);
$toastElement.append($titleElement);
}
displayToast();
if (map.message) {
$messageElement.append(map.message).addClass(options.messageClass);
$toastElement.append($messageElement);
}
handleEvents();
if (options.closeButton) {
$closeElement.addClass('toast-close-button').attr("role", "button");
$toastElement.prepend($closeElement);
}
$toastElement.hide();
if (options.newestOnTop) {
$container.prepend($toastElement);
} else {
$container.append($toastElement);
}
$toastElement[options.showMethod](
{ duration: options.showDuration, easing: options.showEasing, complete: options.onShown }
);
if (options.timeOut > 0) {
intervalId = setTimeout(hideToast, options.timeOut);
}
$toastElement.hover(stickAround, delayedHideToast);
if (!options.onclick && options.tapToDismiss) {
$toastElement.click(hideToast);
}
if (options.closeButton && $closeElement) {
$closeElement.click(function (event) {
if( event.stopPropagation ) {
event.stopPropagation();
} else if( event.cancelBubble !== undefined && event.cancelBubble !== true ) {
event.cancelBubble = true;
}
hideToast(true);
});
}
if (options.onclick) {
$toastElement.click(function () {
options.onclick();
hideToast();
});
}
publish(response);
@ -241,115 +277,10 @@
return $toastElement;
function personalizeToast() {
setIcon();
setTitle();
setMessage();
setCloseButton();
setProgressBar();
setSequence();
}
function handleEvents() {
$toastElement.hover(stickAround, delayedHideToast);
if (!options.onclick && options.tapToDismiss) {
$toastElement.click(hideToast);
}
if (options.closeButton && $closeElement) {
$closeElement.click(function (event) {
if (event.stopPropagation) {
event.stopPropagation();
} else if (event.cancelBubble !== undefined && event.cancelBubble !== true) {
event.cancelBubble = true;
}
hideToast(true);
});
}
if (options.onclick) {
$toastElement.click(function () {
options.onclick();
hideToast();
});
}
}
function displayToast() {
$toastElement.hide();
$toastElement[options.showMethod](
{duration: options.showDuration, easing: options.showEasing, complete: options.onShown}
);
if (options.timeOut > 0) {
intervalId = setTimeout(hideToast, options.timeOut);
progressBar.maxHideTime = parseFloat(options.timeOut);
progressBar.hideEta = new Date().getTime() + progressBar.maxHideTime;
if (options.progressBar) {
progressBar.intervalId = setInterval(updateProgress, 10);
}
}
}
function setIcon() {
if (map.iconClass) {
$toastElement.addClass(options.toastClass).addClass(iconClass);
}
}
function setSequence() {
if (options.newestOnTop) {
$container.prepend($toastElement);
} else {
$container.append($toastElement);
}
}
function setTitle() {
if (map.title) {
$titleElement.append(map.title).addClass(options.titleClass);
$toastElement.append($titleElement);
}
}
function setMessage() {
if (map.message) {
$messageElement.append(map.message).addClass(options.messageClass);
$toastElement.append($messageElement);
}
}
function setCloseButton() {
if (options.closeButton) {
$closeElement.addClass('toast-close-button').attr('role', 'button');
$toastElement.prepend($closeElement);
}
}
function setProgressBar() {
if (options.progressBar) {
$progressElement.addClass('toast-progress');
$toastElement.prepend($progressElement);
}
}
function shouldExit(options, map) {
if (options.preventDuplicates) {
if (map.message === previousToast) {
return true;
} else {
previousToast = map.message;
}
}
return false;
}
function hideToast(override) {
if ($(':focus', $toastElement).length && !override) {
return;
}
clearTimeout(progressBar.intervalId);
return $toastElement[options.hideMethod]({
duration: options.hideDuration,
easing: options.hideEasing,
@ -368,23 +299,15 @@
function delayedHideToast() {
if (options.timeOut > 0 || options.extendedTimeOut > 0) {
intervalId = setTimeout(hideToast, options.extendedTimeOut);
progressBar.maxHideTime = parseFloat(options.extendedTimeOut);
progressBar.hideEta = new Date().getTime() + progressBar.maxHideTime;
}
}
function stickAround() {
clearTimeout(intervalId);
progressBar.hideEta = 0;
$toastElement.stop(true, true)[options.showMethod](
{duration: options.showDuration, easing: options.showEasing}
{ duration: options.showDuration, easing: options.showEasing }
);
}
function updateProgress() {
var percentage = ((progressBar.hideEta - (new Date().getTime())) / progressBar.maxHideTime) * 100;
$progressElement.width(percentage + '%');
}
}
function getOptions() {
@ -400,9 +323,9 @@
$toastElement = null;
if ($container.children().length === 0) {
$container.remove();
previousToast = undefined;
}
}
//#endregion
})();
});
@ -412,4 +335,4 @@
} else {
window['toastr'] = factory(window['jQuery']);
}
}));
}));

View File

@ -0,0 +1 @@
!function(a){a(["jquery"],function(a){return function(){function b(a,b,c){return o({type:u.error,iconClass:p().iconClasses.error,message:a,optionsOverride:c,title:b})}function c(b,c){return b||(b=p()),r=a("#"+b.containerId),r.length?r:(c&&(r=l(b)),r)}function d(a,b,c){return o({type:u.info,iconClass:p().iconClasses.info,message:a,optionsOverride:c,title:b})}function e(a){s=a}function f(a,b,c){return o({type:u.success,iconClass:p().iconClasses.success,message:a,optionsOverride:c,title:b})}function g(a,b,c){return o({type:u.warning,iconClass:p().iconClasses.warning,message:a,optionsOverride:c,title:b})}function h(a){var b=p();r||c(b),k(a,b)||j(b)}function i(b){var d=p();return r||c(d),b&&0===a(":focus",b).length?void q(b):void(r.children().length&&r.remove())}function j(b){for(var c=r.children(),d=c.length-1;d>=0;d--)k(a(c[d]),b)}function k(b,c){return b&&0===a(":focus",b).length?(b[c.hideMethod]({duration:c.hideDuration,easing:c.hideEasing,complete:function(){q(b)}}),!0):!1}function l(b){return r=a("<div/>").attr("id",b.containerId).addClass(b.positionClass).attr("aria-live","polite").attr("role","alert"),r.appendTo(a(b.target)),r}function m(){return{tapToDismiss:!0,toastClass:"toast",containerId:"toast-container",debug:!1,showMethod:"fadeIn",showDuration:300,showEasing:"swing",onShown:void 0,hideMethod:"fadeOut",hideDuration:1e3,hideEasing:"swing",onHidden:void 0,extendedTimeOut:1e3,iconClasses:{error:"toast-error",info:"toast-info",success:"toast-success",warning:"toast-warning"},iconClass:"toast-info",positionClass:"toast-top-right",timeOut:5e3,titleClass:"toast-title",messageClass:"toast-message",target:"body",closeHtml:"<button>&times;</button>",newestOnTop:!0}}function n(a){s&&s(a)}function o(b){function d(b){return!a(":focus",j).length||b?j[g.hideMethod]({duration:g.hideDuration,easing:g.hideEasing,complete:function(){q(j),g.onHidden&&"hidden"!==o.state&&g.onHidden(),o.state="hidden",o.endTime=new Date,n(o)}}):void 0}function e(){(g.timeOut>0||g.extendedTimeOut>0)&&(i=setTimeout(d,g.extendedTimeOut))}function f(){clearTimeout(i),j.stop(!0,!0)[g.showMethod]({duration:g.showDuration,easing:g.showEasing})}var g=p(),h=b.iconClass||g.iconClass;"undefined"!=typeof b.optionsOverride&&(g=a.extend(g,b.optionsOverride),h=b.optionsOverride.iconClass||h),t++,r=c(g,!0);var i=null,j=a("<div/>"),k=a("<div/>"),l=a("<div/>"),m=a(g.closeHtml),o={toastId:t,state:"visible",startTime:new Date,options:g,map:b};return b.iconClass&&j.addClass(g.toastClass).addClass(h),b.title&&(k.append(b.title).addClass(g.titleClass),j.append(k)),b.message&&(l.append(b.message).addClass(g.messageClass),j.append(l)),g.closeButton&&(m.addClass("toast-close-button").attr("role","button"),j.prepend(m)),j.hide(),g.newestOnTop?r.prepend(j):r.append(j),j[g.showMethod]({duration:g.showDuration,easing:g.showEasing,complete:g.onShown}),g.timeOut>0&&(i=setTimeout(d,g.timeOut)),j.hover(f,e),!g.onclick&&g.tapToDismiss&&j.click(d),g.closeButton&&m&&m.click(function(a){a.stopPropagation?a.stopPropagation():void 0!==a.cancelBubble&&a.cancelBubble!==!0&&(a.cancelBubble=!0),d(!0)}),g.onclick&&j.click(function(){g.onclick(),d()}),n(o),g.debug&&console&&console.log(o),j}function p(){return a.extend({},m(),v.options)}function q(a){r||(r=c()),a.is(":visible")||(a.remove(),a=null,0===r.children().length&&r.remove())}var r,s,t=0,u={error:"error",info:"info",success:"success",warning:"warning"},v={clear:h,remove:i,error:b,getContainer:c,info:d,options:{},subscribe:e,success:f,version:"2.0.3",warning:g};return v}()})}("function"==typeof define&&define.amd?define:function(a,b){"undefined"!=typeof module&&module.exports?module.exports=b(require("jquery")):window.toastr=b(window.jQuery)});

File diff suppressed because one or more lines are too long

View File

@ -1,9 +1,9 @@
/*!
* jQuery Validation Plugin v1.17.0
* jQuery Validation Plugin v1.18.0
*
* https://jqueryvalidation.org/
*
* Copyright (c) 2017 Jörn Zaefferer
* Copyright (c) 2018 Jörn Zaefferer
* Released under the MIT license
*/
(function( factory ) {
@ -67,6 +67,7 @@ $.extend( $.fn, {
// Prevent form submit to be able to see console output
event.preventDefault();
}
function handle() {
var hidden, result;
@ -82,7 +83,7 @@ $.extend( $.fn, {
.appendTo( validator.currentForm );
}
if ( validator.settings.submitHandler ) {
if ( validator.settings.submitHandler && !validator.settings.debug ) {
result = validator.settings.submitHandler.call( validator, validator.currentForm, event );
if ( hidden ) {
@ -149,7 +150,7 @@ $.extend( $.fn, {
return;
}
if ( !element.form && element.hasAttribute( "contenteditable" ) ) {
if ( !element.form && element.isContentEditable ) {
element.form = this.closest( "form" )[ 0 ];
element.name = this.attr( "name" );
}
@ -393,7 +394,8 @@ $.extend( $.validator, {
this.invalid = {};
this.reset();
var groups = ( this.groups = {} ),
var currentForm = this.currentForm,
groups = ( this.groups = {} ),
rules;
$.each( this.settings.groups, function( key, value ) {
if ( typeof value === "string" ) {
@ -411,11 +413,17 @@ $.extend( $.validator, {
function delegate( event ) {
// Set form expando on contenteditable
if ( !this.form && this.hasAttribute( "contenteditable" ) ) {
if ( !this.form && this.isContentEditable ) {
this.form = $( this ).closest( "form" )[ 0 ];
this.name = $( this ).attr( "name" );
}
// Ignore the element if it belongs to another form. This will happen mainly
// when setting the `form` attribute of an input to the id of another form.
if ( currentForm !== this.form ) {
return;
}
var validator = $.data( this.form, "validator" ),
eventType = "on" + event.type.replace( /^validate/, "" ),
settings = validator.settings;
@ -644,11 +652,16 @@ $.extend( $.validator, {
}
// Set form expando on contenteditable
if ( this.hasAttribute( "contenteditable" ) ) {
if ( this.isContentEditable ) {
this.form = $( this ).closest( "form" )[ 0 ];
this.name = name;
}
// Ignore elements that belong to other/nested forms
if ( this.form !== validator.currentForm ) {
return false;
}
// Select only the first element for each name, and only those with rules specified
if ( name in rulesCache || !validator.objectLength( $( this ).rules() ) ) {
return false;
@ -702,7 +715,7 @@ $.extend( $.validator, {
return element.validity.badInput ? "NaN" : $element.val();
}
if ( element.hasAttribute( "contenteditable" ) ) {
if ( element.isContentEditable ) {
val = $element.text();
} else {
val = $element.val();
@ -763,10 +776,6 @@ $.extend( $.validator, {
if ( normalizer ) {
val = normalizer.call( element, val );
if ( typeof val !== "string" ) {
throw new TypeError( "The normalizer should return a string value." );
}
// Delete the normalizer from rules to avoid treating it as a pre-defined method.
delete rules.normalizer;
}
@ -1142,7 +1151,19 @@ $.extend( $.validator, {
.removeData( "validator" )
.find( ".validate-equalTo-blur" )
.off( ".validate-equalTo" )
.removeClass( "validate-equalTo-blur" );
.removeClass( "validate-equalTo-blur" )
.find( ".validate-lessThan-blur" )
.off( ".validate-lessThan" )
.removeClass( "validate-lessThan-blur" )
.find( ".validate-lessThanEqual-blur" )
.off( ".validate-lessThanEqual" )
.removeClass( "validate-lessThanEqual-blur" )
.find( ".validate-greaterThanEqual-blur" )
.off( ".validate-greaterThanEqual" )
.removeClass( "validate-greaterThanEqual-blur" )
.find( ".validate-greaterThan-blur" )
.off( ".validate-greaterThan" )
.removeClass( "validate-greaterThan-blur" );
}
},
@ -1246,6 +1267,12 @@ $.extend( $.validator, {
for ( method in $.validator.methods ) {
value = $element.data( "rule" + method.charAt( 0 ).toUpperCase() + method.substring( 1 ).toLowerCase() );
// Cast empty attributes like `data-rule-required` to `true`
if ( value === "" ) {
value = true;
}
this.normalizeAttributeRule( rules, type, method, value );
}
return rules;
@ -1371,7 +1398,7 @@ $.extend( $.validator, {
if ( this.checkable( element ) ) {
return this.getLength( value, element ) > 0;
}
return value.length > 0;
return value !== undefined && value !== null && value.length > 0;
},
// https://jqueryvalidation.org/email-method/
@ -1395,9 +1422,26 @@ $.extend( $.validator, {
},
// https://jqueryvalidation.org/date-method/
date: function( value, element ) {
return this.optional( element ) || !/Invalid|NaN/.test( new Date( value ).toString() );
},
date: ( function() {
var called = false;
return function( value, element ) {
if ( !called ) {
called = true;
if ( this.settings.debug && window.console ) {
console.warn(
"The `date` method is deprecated and will be removed in version '2.0.0'.\n" +
"Please don't use it, since it relies on the Date constructor, which\n" +
"behaves very differently across browsers and locales. Use `dateISO`\n" +
"instead or one of the locale specific methods in `localizations/`\n" +
"and `additional-methods.js`."
);
}
}
return this.optional( element ) || !/Invalid|NaN/.test( new Date( value ).toString() );
};
}() ),
// https://jqueryvalidation.org/dateISO-method/
dateISO: function( value, element ) {

File diff suppressed because one or more lines are too long

View File

@ -28,6 +28,7 @@ $.extend( $.validator.messages, {
minlength: $.validator.format( "最少要输入 {0} 个字符" ),
rangelength: $.validator.format( "请输入长度在 {0} 到 {1} 之间的字符串" ),
range: $.validator.format( "请输入范围在 {0} 到 {1} 之间的数值" ),
step: $.validator.format( "请输入 {0} 的整数倍值" ),
max: $.validator.format( "请输入不大于 {0} 的数值" ),
min: $.validator.format( "请输入不小于 {0} 的数值" )
} );

View File

@ -1,4 +1,4 @@
/*! jQuery Validation Plugin - v1.17.0 - 7/29/2017
/*! jQuery Validation Plugin - v1.18.0 - 9/9/2018
* https://jqueryvalidation.org/
* Copyright (c) 2017 Jörn Zaefferer; Licensed MIT */
!function(a){"function"==typeof define&&define.amd?define(["jquery","../jquery.validate.min"],a):"object"==typeof module&&module.exports?module.exports=a(require("jquery")):a(jQuery)}(function(a){return a.extend(a.validator.messages,{required:"这是必填字段",remote:"请修正此字段",email:"请输入有效的电子邮件地址",url:"请输入有效的网址",date:"请输入有效的日期",dateISO:"请输入有效的日期 (YYYY-MM-DD)",number:"请输入有效的数字",digits:"只能输入数字",creditcard:"请输入有效的信用卡号码",equalTo:"你的输入不相同",extension:"请输入有效的后缀",maxlength:a.validator.format("最多可以输入 {0} 个字符"),minlength:a.validator.format("最少要输入 {0} 个字符"),rangelength:a.validator.format("请输入长度在 {0} 到 {1} 之间的字符串"),range:a.validator.format("请输入范围在 {0} 到 {1} 之间的数值"),max:a.validator.format("请输入不大于 {0} 的数值"),min:a.validator.format("请输入不小于 {0} 的数值")}),a});
* Copyright (c) 2018 Jörn Zaefferer; Licensed MIT */
!function(a){"function"==typeof define&&define.amd?define(["jquery","../jquery.validate.min"],a):"object"==typeof module&&module.exports?module.exports=a(require("jquery")):a(jQuery)}(function(a){return a.extend(a.validator.messages,{required:"这是必填字段",remote:"请修正此字段",email:"请输入有效的电子邮件地址",url:"请输入有效的网址",date:"请输入有效的日期",dateISO:"请输入有效的日期 (YYYY-MM-DD)",number:"请输入有效的数字",digits:"只能输入数字",creditcard:"请输入有效的信用卡号码",equalTo:"你的输入不相同",extension:"请输入有效的后缀",maxlength:a.validator.format("最多可以输入 {0} 个字符"),minlength:a.validator.format("最少要输入 {0} 个字符"),rangelength:a.validator.format("请输入长度在 {0} 到 {1} 之间的字符串"),range:a.validator.format("请输入范围在 {0} 到 {1} 之间的数值"),step:a.validator.format("请输入 {0} 的整数倍值"),max:a.validator.format("请输入不大于 {0} 的数值"),min:a.validator.format("请输入不小于 {0} 的数值")}),a});

View File

@ -4,15 +4,15 @@
}
@section css {
<environment include="Development">
<link href="~/css/bootstrap.css" rel="stylesheet" />
<link href="~/css/font-awesome.css" rel="stylesheet" />
<link href="~/css/toastr.css" rel="stylesheet" />
<link href="~/lib/bootstrap/dist/css/bootstrap.css" rel="stylesheet" />
<link href="~/lib/font-awesome/css/font-awesome.css" rel="stylesheet" />
<link href="~/lib/toastr/nuget/content/content/toastr.css" rel="stylesheet" />
<link href="~/css/jquery.mCustomScrollbar.css" rel="stylesheet" />
</environment>
<environment exclude="Development">
<link href="~/css/bootstrap.min.css" rel="stylesheet">
<link href="~/css/font-awesome.min.css" rel="stylesheet" />
<link href="~/css/toastr.min.css" rel="stylesheet" />
<link href="~/lib/bootstrap/dist/css/bootstrap.min.css" rel="stylesheet" />
<link href="~/lib/font-awesome/css/font-awesome.min.css" rel="stylesheet" />
<link href="~/lib/toastr/nuget/content/content/toastr.min.css" rel="stylesheet" />
<link href="~/css/jquery.mCustomScrollbar.min.css" rel="stylesheet" />
</environment>
@RenderSection("css", false)
@ -27,18 +27,20 @@
}
@section javascript {
<environment include="Development">
<script src="~/js/bootstrap.bundle.js"></script>
<script src="~/lib/bootstrap/dist/js/bootstrap.bundle.js"></script>
<script src="~/js/jquery.mCustomScrollbar.js"></script>
<script src="~/js/toastr.js"></script>
<script src="~/js/signalr.js"></script>
<script src="~/lib/toastr/nuget/content/scripts/toastr.js"></script>
<script src="~/lib/signalr/dist/browser/signalr.js"></script>
<script src="~/lib/dcjqaccordion/js/jquery.dcjqaccordion.2.7.js"></script>
</environment>
<environment exclude="Development">
<script src="~/js/bootstrap.bundle.min.js"></script>
<script src="~/lib/bootstrap/dist/js/bootstrap.bundle.min.js"></script>
<script src="~/js/jquery.mCustomScrollbar.concat.min.js"></script>
<script src="~/js/toastr.min.js"></script>
<script src="~/js/signalr.min.js"></script>
<script src="~/lib/toastr/nuget/content/scripts/toastr.min.js"></script>
<script src="~/lib/signalr/dist/browser/signalr.min.js"></script>
<script src="~/lib/dcjqaccordion/js/jquery.dcjqaccordion.2.7.min.js"></script>
</environment>
<script src="~/js/jquery.dcjqaccordion.2.7.js"></script>
<script src="~/lib/dcjqaccordion/js/jquery.cookie.js"></script>
<script src="~/js/longbow.common.js" asp-append-version="true"></script>
<script src="~/js/common-scripts.js" asp-append-version="true"></script>
@RenderSection("javascript", false)

View File

@ -21,10 +21,10 @@
<a id="pathBase" href="~/" hidden></a>
<!-- jQuery文件。务必在bootstrap.min.js 之前引入 -->
<environment include="Development">
<script src="~/js/jquery-3.3.1.js"></script>
<script src="~/lib/jquery/dist/jquery.js"></script>
</environment>
<environment exclude="Development">
<script src="~/js/jquery-3.3.1.min.js"></script>
<script src="~/lib/jquery/dist/jquery.min.js"></script>
</environment>
@RenderSection("javascript", false)
</body>

View File

@ -4,7 +4,7 @@
"libraries": [
{
"library": "@aspnet/signalr@1.0.4",
"destination": "wwwroot/lib/@aspnet/signalr/",
"destination": "wwwroot/lib/signalr/",
"files": [
"dist/browser/signalr.js",
"dist/browser/signalr.js.map",
@ -14,10 +14,83 @@
},
{
"library": "jquery@3.3.1",
"destination": "wwwroot/lib/@aspnet/jquery/",
"destination": "wwwroot/lib/jquery/",
"files": [
"dist/jquery.js",
"dist/jquery.min.js"
"dist/jquery.min.js",
"dist/jquery.min.map"
]
},
{
"provider": "cdnjs",
"library": "jquery-validate@1.18.0",
"destination": "wwwroot/lib/validate",
"files": [
"jquery.validate.js",
"jquery.validate.min.js",
"localization/messages_zh.js",
"localization/messages_zh.min.js"
]
},
{
"library": "toastr@2.1.4",
"destination": "wwwroot/lib/toastr/",
"files": [
"nuget/content/scripts/toastr.js",
"nuget/content/scripts/toastr.min.js",
"nuget/content/scripts/toastr.min.js.map",
"nuget/content/content/toastr.css",
"nuget/content/content/toastr.min.css"
]
},
{
"library": "bootstrap-table@1.12.1",
"destination": "wwwroot/lib/bootstrap-table/",
"files": [
"dist/bootstrap-table.js",
"dist/bootstrap-table.min.js",
"dist/bootstrap-table.css",
"dist/bootstrap-table.min.css",
"dist/locale/bootstrap-table-zh-CN.js",
"dist/locale/bootstrap-table-zh-CN.min.js"
]
},
{
"library": "bootstrap@4.1.3",
"destination": "wwwroot/lib/bootstrap/",
"files": [
"dist/css/bootstrap.css",
"dist/css/bootstrap.css.map",
"dist/css/bootstrap.min.css",
"dist/css/bootstrap.min.css.map",
"dist/js/bootstrap.bundle.js",
"dist/js/bootstrap.bundle.js.map",
"dist/js/bootstrap.bundle.min.js",
"dist/js/bootstrap.bundle.min.js.map"
]
},
{
"library": "dcjqaccordion@2.7.1",
"destination": "wwwroot/lib/dcjqaccordion/",
"files": [
"js/jquery.dcjqaccordion.2.7.js",
"js/jquery.dcjqaccordion.2.7.min.js",
"js/jquery.cookie.js"
]
},
{
"library": "font-awesome@4.7.0",
"destination": "wwwroot/lib/font-awesome/",
"files": [
"css/font-awesome.css",
"css/font-awesome.css.map",
"css/font-awesome.min.css",
"fonts/FontAwesome.otf",
"fonts/fontawesome-webfont.eot",
"fonts/fontawesome-webfont.svg",
"fonts/fontawesome-webfont.ttf",
"fonts/fontawesome-webfont.woff",
"fonts/fontawesome-webfont.woff2"
]
}
]

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@ -1,6 +1,6 @@
/**
* @author zhixin wen <wenzhixin2010@gmail.com>
* version: 1.11.0
* version: 1.12.1
* https://github.com/wenzhixin/bootstrap-table/
*/
@ -72,7 +72,7 @@
outline: 0 solid transparent;
}
.fixed-table-container thead th:first-child {
.fixed-table-container thead th:first-child:not([data-not-first-th]) {
border-left: none;
border-top-left-radius: 4px;
-webkit-border-top-left-radius: 4px;
@ -133,10 +133,6 @@
text-align: center;
}
.fixed-table-container .bs-checkbox .th-inner {
padding: 8px 0;
}
.fixed-table-container input[type="radio"],
.fixed-table-container input[type="checkbox"] {
margin: 0 auto !important;
@ -285,7 +281,7 @@
padding: 0 !important;
}
.pull-right .dropdown-menu {
.bootstrap-table .pull-right .dropdown-menu {
right: 0;
left: auto;
}
@ -304,3 +300,19 @@ div.fixed-table-scroll-outer {
height: 150px;
overflow: hidden;
}
/* for get correct heights */
.fixed-table-toolbar:after, .fixed-table-pagination:after {
content: "";
display: block;
clear: both;
}
.fullscreen {
position: fixed;
top: 0;
left: 0;
z-index: 1050;
width: 100%!important;
background: #FFF;
}

View File

@ -1165,8 +1165,8 @@
sprintf(' btn-%s', this.options.buttonsClass) +
sprintf(' btn-%s', this.options.iconSize) +
'" type="button" name="toggle" aria-label="toggle" title="%s">',
this.options.formatToggle()),
sprintf('<i class="%s %s"></i>', this.options.iconsPrefix, this.options.icons.toggleOff),
this.options.formatToggle()),
sprintf('<i class="%s %s"></i>', this.options.iconsPrefix, this.options.icons.toggle),
'</button>');
}

File diff suppressed because one or more lines are too long

View File

@ -0,0 +1,96 @@
/**
* Cookie plugin
*
* Copyright (c) 2006 Klaus Hartl (stilbuero.de)
* Dual licensed under the MIT and GPL licenses:
* http://www.opensource.org/licenses/mit-license.php
* http://www.gnu.org/licenses/gpl.html
*
*/
/**
* Create a cookie with the given name and value and other optional parameters.
*
* @example $.cookie('the_cookie', 'the_value');
* @desc Set the value of a cookie.
* @example $.cookie('the_cookie', 'the_value', { expires: 7, path: '/', domain: 'jquery.com', secure: true });
* @desc Create a cookie with all available options.
* @example $.cookie('the_cookie', 'the_value');
* @desc Create a session cookie.
* @example $.cookie('the_cookie', null);
* @desc Delete a cookie by passing null as value. Keep in mind that you have to use the same path and domain
* used when the cookie was set.
*
* @param String name The name of the cookie.
* @param String value The value of the cookie.
* @param Object options An object literal containing key/value pairs to provide optional cookie attributes.
* @option Number|Date expires Either an integer specifying the expiration date from now on in days or a Date object.
* If a negative value is specified (e.g. a date in the past), the cookie will be deleted.
* If set to null or omitted, the cookie will be a session cookie and will not be retained
* when the the browser exits.
* @option String path The value of the path atribute of the cookie (default: path of page that created the cookie).
* @option String domain The value of the domain attribute of the cookie (default: domain of page that created the cookie).
* @option Boolean secure If true, the secure attribute of the cookie will be set and the cookie transmission will
* require a secure protocol (like HTTPS).
* @type undefined
*
* @name $.cookie
* @cat Plugins/Cookie
* @author Klaus Hartl/klaus.hartl@stilbuero.de
*/
/**
* Get the value of a cookie with the given name.
*
* @example $.cookie('the_cookie');
* @desc Get the value of a cookie.
*
* @param String name The name of the cookie.
* @return The value of the cookie.
* @type String
*
* @name $.cookie
* @cat Plugins/Cookie
* @author Klaus Hartl/klaus.hartl@stilbuero.de
*/
jQuery.cookie = function(name, value, options) {
if (typeof value != 'undefined') { // name and value given, set cookie
options = options || {};
if (value === null) {
value = '';
options.expires = -1;
}
var expires = '';
if (options.expires && (typeof options.expires == 'number' || options.expires.toUTCString)) {
var date;
if (typeof options.expires == 'number') {
date = new Date();
date.setTime(date.getTime() + (options.expires * 24 * 60 * 60 * 1000));
} else {
date = options.expires;
}
expires = '; expires=' + date.toUTCString(); // use expires attribute, max-age is not supported by IE
}
// CAUTION: Needed to parenthesize options.path and options.domain
// in the following expressions, otherwise they evaluate to undefined
// in the packed version for some reason...
var path = options.path ? '; path=' + (options.path) : '';
var domain = options.domain ? '; domain=' + (options.domain) : '';
var secure = options.secure ? '; secure' : '';
document.cookie = [name, '=', encodeURIComponent(value), expires, path, domain, secure].join('');
} else { // only name given, get cookie
var cookieValue = null;
if (document.cookie && document.cookie != '') {
var cookies = document.cookie.split(';');
for (var i = 0; i < cookies.length; i++) {
var cookie = jQuery.trim(cookies[i]);
// Does this cookie string begin with the name we want?
if (cookie.substring(0, name.length + 1) == (name + '=')) {
cookieValue = decodeURIComponent(cookie.substring(name.length + 1));
break;
}
}
}
return cookieValue;
}
};

View File

@ -1,225 +1,198 @@
/*
* DC jQuery Vertical Accordion Menu - jQuery vertical accordion menu plugin
* Copyright (c) 2011 Design Chemical
*
* Dual licensed under the MIT and GPL licenses:
* http://www.opensource.org/licenses/mit-license.php
* http://www.gnu.org/licenses/gpl.html
*
*/
(function($){
$.fn.dcAccordion = function(options) {
//set default options
var defaults = {
classParent : 'dcjq-parent',
classActive : 'active',
classArrow : 'dcjq-icon',
classCount : 'dcjq-count',
classExpand : 'dcjq-current-parent',
eventType : 'click',
hoverDelay : 300,
menuClose : true,
autoClose : true,
autoExpand : false,
speed : 'slow',
saveState : true,
disableLink : true,
showCount : false,
// cookie : 'dcjq-accordion'
};
//call in the default otions
var options = $.extend(defaults, options);
this.each(function(options){
var obj = this;
setUpAccordion();
// if(defaults.saveState == true){
// checkCookie(defaults.cookie, obj);
// }
if(defaults.autoExpand == true){
$('li.'+defaults.classExpand+' > a').addClass(defaults.classActive);
}
resetAccordion();
if(defaults.eventType == 'hover'){
var config = {
sensitivity: 2, // number = sensitivity threshold (must be 1 or higher)
interval: defaults.hoverDelay, // number = milliseconds for onMouseOver polling interval
over: linkOver, // function = onMouseOver callback (REQUIRED)
timeout: defaults.hoverDelay, // number = milliseconds delay before onMouseOut
out: linkOut // function = onMouseOut callback (REQUIRED)
};
$('li a',obj).hoverIntent(config);
var configMenu = {
sensitivity: 2, // number = sensitivity threshold (must be 1 or higher)
interval: 1000, // number = milliseconds for onMouseOver polling interval
over: menuOver, // function = onMouseOver callback (REQUIRED)
timeout: 1000, // number = milliseconds delay before onMouseOut
out: menuOut // function = onMouseOut callback (REQUIRED)
};
$(obj).hoverIntent(configMenu);
// Disable parent links
if(defaults.disableLink == true){
$('li a',obj).click(function(e){
if($(this).siblings('ul').length >0){
e.preventDefault();
}
});
}
} else {
$('li a',obj).click(function(e){
$activeLi = $(this).parent('li');
$parentsLi = $activeLi.parents('li');
$parentsUl = $activeLi.parents('ul');
// Prevent browsing to link if has child links
if(defaults.disableLink == true){
if($(this).siblings('ul').length >0){
e.preventDefault();
}
}
// Auto close sibling menus
if(defaults.autoClose == true){
autoCloseAccordion($parentsLi, $parentsUl);
}
if ($('> ul',$activeLi).is(':visible')){
$('ul',$activeLi).slideUp(defaults.speed);
$('a',$activeLi).removeClass(defaults.classActive);
} else {
$(this).siblings('ul').slideToggle(defaults.speed);
$('> a',$activeLi).addClass(defaults.classActive);
}
// // Write cookie if save state is on
// if(defaults.saveState == true){
// createCookie(defaults.cookie, obj);
// }
});
}
// Set up accordion
function setUpAccordion(){
$arrow = '<span class="'+defaults.classArrow+'"></span>';
var classParentLi = defaults.classParent+'-li';
$('> ul',obj).show();
$('li',obj).each(function(){
if($('> ul',this).length > 0){
$(this).addClass(classParentLi);
$('> a',this).addClass(defaults.classParent).append($arrow);
}
});
$('> ul',obj).hide();
if(defaults.showCount == true){
$('li.'+classParentLi,obj).each(function(){
if(defaults.disableLink == true){
var getCount = parseInt($('ul a:not(.'+defaults.classParent+')',this).length);
} else {
var getCount = parseInt($('ul a',this).length);
}
$('> a',this).append(' <span class="'+defaults.classCount+'">'+getCount+'</span>');
});
}
}
function linkOver(){
$activeLi = $(this).parent('li');
$parentsLi = $activeLi.parents('li');
$parentsUl = $activeLi.parents('ul');
// Auto close sibling menus
if(defaults.autoClose == true){
autoCloseAccordion($parentsLi, $parentsUl);
}
if ($('> ul',$activeLi).is(':visible')){
$('ul',$activeLi).slideUp(defaults.speed);
$('a',$activeLi).removeClass(defaults.classActive);
} else {
$(this).siblings('ul').slideToggle(defaults.speed);
$('> a',$activeLi).addClass(defaults.classActive);
}
// Write cookie if save state is on
if(defaults.saveState == true){
createCookie(defaults.cookie, obj);
}
}
function linkOut(){
}
function menuOver(){
}
function menuOut(){
if(defaults.menuClose == true){
$('ul',obj).slideUp(defaults.speed);
// Reset active links
$('a',obj).removeClass(defaults.classActive);
createCookie(defaults.cookie, obj);
}
}
// Auto-Close Open Menu Items
function autoCloseAccordion($parentsLi, $parentsUl){
$('ul',obj).not($parentsUl).slideUp(defaults.speed);
// Reset active links
$('a',obj).removeClass(defaults.classActive);
$('> a',$parentsLi).addClass(defaults.classActive);
}
// Reset accordion using active links
function resetAccordion(){
$('ul',obj).hide();
$allActiveLi = $('a.'+defaults.classActive,obj);
$allActiveLi.siblings('ul').show();
}
});
// Retrieve cookie value and set active items
// function checkCookie(cookieId, obj){
// var cookieVal = $.cookie(cookieId);
// if(cookieVal != null){
// // create array from cookie string
// var activeArray = cookieVal.split(',');
// $.each(activeArray, function(index,value){
// var $cookieLi = $('li:eq('+value+')',obj);
// $('> a',$cookieLi).addClass(defaults.classActive);
// var $parentsLi = $cookieLi.parents('li');
// $('> a',$parentsLi).addClass(defaults.classActive);
// });
// }
// }
// Write cookie
// function createCookie(cookieId, obj){
// var activeIndex = [];
// // Create array of active items index value
// $('li a.'+defaults.classActive,obj).each(function(i){
// var $arrayItem = $(this).parent('li');
// var itemIndex = $('li',obj).index($arrayItem);
// activeIndex.push(itemIndex);
// });
// // Store in cookie
// $.cookie(cookieId, activeIndex, { path: '/' });
// }
};
/*
* DC jQuery Vertical Accordion Menu - jQuery vertical accordion menu plugin
* Copyright (c) 2011 Design Chemical
*
* Dual licensed under the MIT and GPL licenses:
* http://www.opensource.org/licenses/mit-license.php
* http://www.gnu.org/licenses/gpl.html
*
*/
(function($){
$.fn.dcAccordion = function(options) {
//set default options
var defaults = {
classParent : 'dcjq-parent',
classActive : 'active', classArrow : 'dcjq-icon', classCount : 'dcjq-count',
classExpand : 'dcjq-current-parent',
eventType : 'click',
hoverDelay : 300,
menuClose : true,
autoClose : true,
autoExpand : false,
speed : 'slow',
saveState : true,
disableLink : true, showCount : false,
cookie : 'dcjq-accordion'
};
//call in the default otions
var options = $.extend(defaults, options);
this.each(function(options){
var obj = this;
setUpAccordion();
if(defaults.saveState == true){
checkCookie(defaults.cookie, obj);
}
if(defaults.autoExpand == true){
$('li.'+defaults.classExpand+' > a').addClass(defaults.classActive);
}
resetAccordion();
if(defaults.eventType == 'hover'){
var config = {
sensitivity: 2, // number = sensitivity threshold (must be 1 or higher)
interval: defaults.hoverDelay, // number = milliseconds for onMouseOver polling interval
over: linkOver, // function = onMouseOver callback (REQUIRED)
timeout: defaults.hoverDelay, // number = milliseconds delay before onMouseOut
out: linkOut // function = onMouseOut callback (REQUIRED)
};
$('li a',obj).hoverIntent(config);
var configMenu = {
sensitivity: 2, // number = sensitivity threshold (must be 1 or higher)
interval: 1000, // number = milliseconds for onMouseOver polling interval
over: menuOver, // function = onMouseOver callback (REQUIRED)
timeout: 1000, // number = milliseconds delay before onMouseOut
out: menuOut // function = onMouseOut callback (REQUIRED)
};
$(obj).hoverIntent(configMenu);
// Disable parent links
if(defaults.disableLink == true){
$('li a',obj).click(function(e){
if($(this).siblings('ul').length >0){
e.preventDefault();
}
});
}
} else {
$('li a',obj).click(function(e){
$activeLi = $(this).parent('li');
$parentsLi = $activeLi.parents('li');
$parentsUl = $activeLi.parents('ul');
// Prevent browsing to link if has child links
if(defaults.disableLink == true){
if($(this).siblings('ul').length >0){
e.preventDefault();
}
}
// Auto close sibling menus
if(defaults.autoClose == true){
autoCloseAccordion($parentsLi, $parentsUl);
}
if ($('> ul',$activeLi).is(':visible')){
$('ul',$activeLi).slideUp(defaults.speed);
$('a',$activeLi).removeClass(defaults.classActive);
} else {
$(this).siblings('ul').slideToggle(defaults.speed);
$('> a',$activeLi).addClass(defaults.classActive);
}
// Write cookie if save state is on
if(defaults.saveState == true){
createCookie(defaults.cookie, obj);
}
});
}
// Set up accordion
function setUpAccordion(){
$arrow = '<span class="'+defaults.classArrow+'"></span>';
var classParentLi = defaults.classParent+'-li';
$('> ul',obj).show();
$('li',obj).each(function(){
if($('> ul',this).length > 0){ $(this).addClass(classParentLi);
$('> a',this).addClass(defaults.classParent).append($arrow);
}
});
$('> ul',obj).hide();
if(defaults.showCount == true){
$('li.'+classParentLi,obj).each(function(){
if(defaults.disableLink == true){
var getCount = parseInt($('ul a:not(.'+defaults.classParent+')',this).length);
} else {
var getCount = parseInt($('ul a',this).length);
}
$('> a',this).append(' <span class="'+defaults.classCount+'">('+getCount+')</span>');
});
}
}
function linkOver(){
$activeLi = $(this).parent('li');
$parentsLi = $activeLi.parents('li');
$parentsUl = $activeLi.parents('ul');
// Auto close sibling menus
if(defaults.autoClose == true){
autoCloseAccordion($parentsLi, $parentsUl);
}
if ($('> ul',$activeLi).is(':visible')){
$('ul',$activeLi).slideUp(defaults.speed);
$('a',$activeLi).removeClass(defaults.classActive);
} else {
$(this).siblings('ul').slideToggle(defaults.speed);
$('> a',$activeLi).addClass(defaults.classActive);
}
// Write cookie if save state is on
if(defaults.saveState == true){
createCookie(defaults.cookie, obj);
}
}
function linkOut(){
}
function menuOver(){
}
function menuOut(){
if(defaults.menuClose == true){
$('ul',obj).slideUp(defaults.speed);
// Reset active links
$('a',obj).removeClass(defaults.classActive);
createCookie(defaults.cookie, obj);
}
}
// Auto-Close Open Menu Items
function autoCloseAccordion($parentsLi, $parentsUl){
$('ul',obj).not($parentsUl).slideUp(defaults.speed);
// Reset active links
$('a',obj).removeClass(defaults.classActive);
$('> a',$parentsLi).addClass(defaults.classActive);
}
// Reset accordion using active links
function resetAccordion(){
$('ul',obj).hide();
$allActiveLi = $('a.'+defaults.classActive,obj);
$allActiveLi.siblings('ul').show();
}
});
// Retrieve cookie value and set active items
function checkCookie(cookieId, obj){
var cookieVal = $.cookie(cookieId);
if(cookieVal != null){
// create array from cookie string
var activeArray = cookieVal.split(',');
$.each(activeArray, function(index,value){
var $cookieLi = $('li:eq('+value+')',obj);
$('> a',$cookieLi).addClass(defaults.classActive);
var $parentsLi = $cookieLi.parents('li');
$('> a',$parentsLi).addClass(defaults.classActive);
});
}
}
// Write cookie
function createCookie(cookieId, obj){
var activeIndex = [];
// Create array of active items index value
$('li a.'+defaults.classActive,obj).each(function(i){
var $arrayItem = $(this).parent('li');
var itemIndex = $('li',obj).index($arrayItem);
activeIndex.push(itemIndex);
});
// Store in cookie
$.cookie(cookieId, activeIndex, { path: '/' });
}
};
})(jQuery);

View File

@ -0,0 +1 @@
(function($){$.fn.dcAccordion=function(options){var defaults={classParent:'dcjq-parent',classActive:'active',classArrow:'dcjq-icon',classCount:'dcjq-count',classExpand:'dcjq-current-parent',eventType:'click',hoverDelay:300,menuClose:true,autoClose:true,autoExpand:false,speed:'slow',saveState:true,disableLink:true,showCount:false,cookie:'dcjq-accordion'};var options=$.extend(defaults,options);this.each(function(options){var obj=this;setUpAccordion();if(defaults.saveState==true){checkCookie(defaults.cookie,obj)}if(defaults.autoExpand==true){$('li.'+defaults.classExpand+' > a').addClass(defaults.classActive)}resetAccordion();if(defaults.eventType=='hover'){var config={sensitivity:2,interval:defaults.hoverDelay,over:linkOver,timeout:defaults.hoverDelay,out:linkOut};$('li a',obj).hoverIntent(config);var configMenu={sensitivity:2,interval:1000,over:menuOver,timeout:1000,out:menuOut};$(obj).hoverIntent(configMenu);if(defaults.disableLink==true){$('li a',obj).click(function(e){if($(this).siblings('ul').length>0){e.preventDefault()}})}}else{$('li a',obj).click(function(e){$activeLi=$(this).parent('li');$parentsLi=$activeLi.parents('li');$parentsUl=$activeLi.parents('ul');if(defaults.disableLink==true){if($(this).siblings('ul').length>0){e.preventDefault()}}if(defaults.autoClose==true){autoCloseAccordion($parentsLi,$parentsUl)}if($('> ul',$activeLi).is(':visible')){$('ul',$activeLi).slideUp(defaults.speed);$('a',$activeLi).removeClass(defaults.classActive)}else{$(this).siblings('ul').slideToggle(defaults.speed);$('> a',$activeLi).addClass(defaults.classActive)}if(defaults.saveState==true){createCookie(defaults.cookie,obj)}})}function setUpAccordion(){$arrow='<span class="'+defaults.classArrow+'"></span>';var classParentLi=defaults.classParent+'-li';$('> ul',obj).show();$('li',obj).each(function(){if($('> ul',this).length>0){$(this).addClass(classParentLi);$('> a',this).addClass(defaults.classParent).append($arrow)}});$('> ul',obj).hide();if(defaults.showCount==true){$('li.'+classParentLi,obj).each(function(){if(defaults.disableLink==true){var getCount=parseInt($('ul a:not(.'+defaults.classParent+')',this).length)}else{var getCount=parseInt($('ul a',this).length)}$('> a',this).append(' <span class="'+defaults.classCount+'">('+getCount+')</span>')})}}function linkOver(){$activeLi=$(this).parent('li');$parentsLi=$activeLi.parents('li');$parentsUl=$activeLi.parents('ul');if(defaults.autoClose==true){autoCloseAccordion($parentsLi,$parentsUl)}if($('> ul',$activeLi).is(':visible')){$('ul',$activeLi).slideUp(defaults.speed);$('a',$activeLi).removeClass(defaults.classActive)}else{$(this).siblings('ul').slideToggle(defaults.speed);$('> a',$activeLi).addClass(defaults.classActive)}if(defaults.saveState==true){createCookie(defaults.cookie,obj)}}function linkOut(){}function menuOver(){}function menuOut(){if(defaults.menuClose==true){$('ul',obj).slideUp(defaults.speed);$('a',obj).removeClass(defaults.classActive);createCookie(defaults.cookie,obj)}}function autoCloseAccordion($parentsLi,$parentsUl){$('ul',obj).not($parentsUl).slideUp(defaults.speed);$('a',obj).removeClass(defaults.classActive);$('> a',$parentsLi).addClass(defaults.classActive)}function resetAccordion(){$('ul',obj).hide();$allActiveLi=$('a.'+defaults.classActive,obj);$allActiveLi.siblings('ul').show()}});function checkCookie(cookieId,obj){var cookieVal=$.cookie(cookieId);if(cookieVal!=null){var activeArray=cookieVal.split(',');$.each(activeArray,function(index,value){var $cookieLi=$('li:eq('+value+')',obj);$('> a',$cookieLi).addClass(defaults.classActive);var $parentsLi=$cookieLi.parents('li');$('> a',$parentsLi).addClass(defaults.classActive)})}}function createCookie(cookieId,obj){var activeIndex=[];$('li a.'+defaults.classActive,obj).each(function(i){var $arrayItem=$(this).parent('li');var itemIndex=$('li',obj).index($arrayItem);activeIndex.push(itemIndex)});$.cookie(cookieId,activeIndex,{path:'/'})}}})(jQuery);

Some files were not shown because too many files have changed in this diff Show More