0
0
mirror of https://github.com/twbs/bootstrap.git synced 2024-11-29 11:24:18 +01:00

grunt action

This commit is contained in:
Mark Otto 2015-03-09 14:08:20 +00:00
parent 8d6c89ec3d
commit 01d1090ed2
6 changed files with 4442 additions and 2361 deletions

View File

@ -37,7 +37,10 @@ a {
background-color: transparent;
}
a:active, a:hover {
a:active {
outline: 0;
}
a:hover {
outline: 0;
}
@ -197,69 +200,54 @@ td, th {
-webkit-box-shadow: none !important;
box-shadow: none !important;
}
a, a:visited {
text-decoration: underline;
}
a[href]:after {
content: " (" attr(href) ")";
}
abbr[title]:after {
content: " (" attr(title) ")";
}
a[href^="#"]:after, a[href^="javascript:"]:after {
content: "";
}
pre, blockquote {
border: 1px solid #999;
page-break-inside: avoid;
}
thead {
display: table-header-group;
}
tr, img {
page-break-inside: avoid;
}
img {
max-width: 100% !important;
}
p, h2, h3 {
orphans: 3;
widows: 3;
}
h2, h3 {
page-break-after: avoid;
}
.navbar {
display: none;
}
.btn > .caret, .dropup > .btn > .caret {
border-top-color: #000 !important;
}
.label {
border: 1px solid #000;
}
.table {
border-collapse: collapse !important;
}
.table td, .table th {
background-color: #fff !important;
}
.table-bordered th, .table-bordered td {
border: 1px solid #ddd !important;
}
@ -275,10 +263,26 @@ html {
box-sizing: inherit;
}
@-moz-viewport {
width: device-width;
}
@-ms-viewport {
width: device-width;
}
@-webkit-viewport {
width: device-width;
}
@viewport {
width: device-width;
}
html {
font-size: 16px;
-webkit-tap-highlight-color: rgba(0, 0, 0, 0);
-webkit-tap-highlight-color: transparent;
}
body {
@ -299,7 +303,7 @@ a {
color: #0275d8;
text-decoration: none;
}
a:hover, a:focus {
a:focus, a:hover {
color: #014c8c;
text-decoration: underline;
}
@ -872,207 +876,156 @@ pre code {
.col-sm-1, .col-sm-2, .col-sm-3, .col-sm-4, .col-sm-5, .col-sm-6, .col-sm-7, .col-sm-8, .col-sm-9, .col-sm-10, .col-sm-11, .col-sm-12 {
float: left;
}
.col-sm-1 {
width: 8.333333%;
}
.col-sm-2 {
width: 16.666667%;
}
.col-sm-3 {
width: 25%;
}
.col-sm-4 {
width: 33.333333%;
}
.col-sm-5 {
width: 41.666667%;
}
.col-sm-6 {
width: 50%;
}
.col-sm-7 {
width: 58.333333%;
}
.col-sm-8 {
width: 66.666667%;
}
.col-sm-9 {
width: 75%;
}
.col-sm-10 {
width: 83.333333%;
}
.col-sm-11 {
width: 91.666667%;
}
.col-sm-12 {
width: 100%;
}
.col-sm-pull-0 {
right: auto;
}
.col-sm-pull-1 {
right: 8.333333%;
}
.col-sm-pull-2 {
right: 16.666667%;
}
.col-sm-pull-3 {
right: 25%;
}
.col-sm-pull-4 {
right: 33.333333%;
}
.col-sm-pull-5 {
right: 41.666667%;
}
.col-sm-pull-6 {
right: 50%;
}
.col-sm-pull-7 {
right: 58.333333%;
}
.col-sm-pull-8 {
right: 66.666667%;
}
.col-sm-pull-9 {
right: 75%;
}
.col-sm-pull-10 {
right: 83.333333%;
}
.col-sm-pull-11 {
right: 91.666667%;
}
.col-sm-pull-12 {
right: 100%;
}
.col-sm-push-0 {
left: auto;
}
.col-sm-push-1 {
left: 8.333333%;
}
.col-sm-push-2 {
left: 16.666667%;
}
.col-sm-push-3 {
left: 25%;
}
.col-sm-push-4 {
left: 33.333333%;
}
.col-sm-push-5 {
left: 41.666667%;
}
.col-sm-push-6 {
left: 50%;
}
.col-sm-push-7 {
left: 58.333333%;
}
.col-sm-push-8 {
left: 66.666667%;
}
.col-sm-push-9 {
left: 75%;
}
.col-sm-push-10 {
left: 83.333333%;
}
.col-sm-push-11 {
left: 91.666667%;
}
.col-sm-push-12 {
left: 100%;
}
.col-sm-offset-0 {
margin-left: 0;
}
.col-sm-offset-1 {
margin-left: 8.333333%;
}
.col-sm-offset-2 {
margin-left: 16.666667%;
}
.col-sm-offset-3 {
margin-left: 25%;
}
.col-sm-offset-4 {
margin-left: 33.333333%;
}
.col-sm-offset-5 {
margin-left: 41.666667%;
}
.col-sm-offset-6 {
margin-left: 50%;
}
.col-sm-offset-7 {
margin-left: 58.333333%;
}
.col-sm-offset-8 {
margin-left: 66.666667%;
}
.col-sm-offset-9 {
margin-left: 75%;
}
.col-sm-offset-10 {
margin-left: 83.333333%;
}
.col-sm-offset-11 {
margin-left: 91.666667%;
}
.col-sm-offset-12 {
margin-left: 100%;
}
@ -1082,207 +1035,156 @@ pre code {
.col-md-1, .col-md-2, .col-md-3, .col-md-4, .col-md-5, .col-md-6, .col-md-7, .col-md-8, .col-md-9, .col-md-10, .col-md-11, .col-md-12 {
float: left;
}
.col-md-1 {
width: 8.333333%;
}
.col-md-2 {
width: 16.666667%;
}
.col-md-3 {
width: 25%;
}
.col-md-4 {
width: 33.333333%;
}
.col-md-5 {
width: 41.666667%;
}
.col-md-6 {
width: 50%;
}
.col-md-7 {
width: 58.333333%;
}
.col-md-8 {
width: 66.666667%;
}
.col-md-9 {
width: 75%;
}
.col-md-10 {
width: 83.333333%;
}
.col-md-11 {
width: 91.666667%;
}
.col-md-12 {
width: 100%;
}
.col-md-pull-0 {
right: auto;
}
.col-md-pull-1 {
right: 8.333333%;
}
.col-md-pull-2 {
right: 16.666667%;
}
.col-md-pull-3 {
right: 25%;
}
.col-md-pull-4 {
right: 33.333333%;
}
.col-md-pull-5 {
right: 41.666667%;
}
.col-md-pull-6 {
right: 50%;
}
.col-md-pull-7 {
right: 58.333333%;
}
.col-md-pull-8 {
right: 66.666667%;
}
.col-md-pull-9 {
right: 75%;
}
.col-md-pull-10 {
right: 83.333333%;
}
.col-md-pull-11 {
right: 91.666667%;
}
.col-md-pull-12 {
right: 100%;
}
.col-md-push-0 {
left: auto;
}
.col-md-push-1 {
left: 8.333333%;
}
.col-md-push-2 {
left: 16.666667%;
}
.col-md-push-3 {
left: 25%;
}
.col-md-push-4 {
left: 33.333333%;
}
.col-md-push-5 {
left: 41.666667%;
}
.col-md-push-6 {
left: 50%;
}
.col-md-push-7 {
left: 58.333333%;
}
.col-md-push-8 {
left: 66.666667%;
}
.col-md-push-9 {
left: 75%;
}
.col-md-push-10 {
left: 83.333333%;
}
.col-md-push-11 {
left: 91.666667%;
}
.col-md-push-12 {
left: 100%;
}
.col-md-offset-0 {
margin-left: 0;
}
.col-md-offset-1 {
margin-left: 8.333333%;
}
.col-md-offset-2 {
margin-left: 16.666667%;
}
.col-md-offset-3 {
margin-left: 25%;
}
.col-md-offset-4 {
margin-left: 33.333333%;
}
.col-md-offset-5 {
margin-left: 41.666667%;
}
.col-md-offset-6 {
margin-left: 50%;
}
.col-md-offset-7 {
margin-left: 58.333333%;
}
.col-md-offset-8 {
margin-left: 66.666667%;
}
.col-md-offset-9 {
margin-left: 75%;
}
.col-md-offset-10 {
margin-left: 83.333333%;
}
.col-md-offset-11 {
margin-left: 91.666667%;
}
.col-md-offset-12 {
margin-left: 100%;
}
@ -1292,207 +1194,156 @@ pre code {
.col-lg-1, .col-lg-2, .col-lg-3, .col-lg-4, .col-lg-5, .col-lg-6, .col-lg-7, .col-lg-8, .col-lg-9, .col-lg-10, .col-lg-11, .col-lg-12 {
float: left;
}
.col-lg-1 {
width: 8.333333%;
}
.col-lg-2 {
width: 16.666667%;
}
.col-lg-3 {
width: 25%;
}
.col-lg-4 {
width: 33.333333%;
}
.col-lg-5 {
width: 41.666667%;
}
.col-lg-6 {
width: 50%;
}
.col-lg-7 {
width: 58.333333%;
}
.col-lg-8 {
width: 66.666667%;
}
.col-lg-9 {
width: 75%;
}
.col-lg-10 {
width: 83.333333%;
}
.col-lg-11 {
width: 91.666667%;
}
.col-lg-12 {
width: 100%;
}
.col-lg-pull-0 {
right: auto;
}
.col-lg-pull-1 {
right: 8.333333%;
}
.col-lg-pull-2 {
right: 16.666667%;
}
.col-lg-pull-3 {
right: 25%;
}
.col-lg-pull-4 {
right: 33.333333%;
}
.col-lg-pull-5 {
right: 41.666667%;
}
.col-lg-pull-6 {
right: 50%;
}
.col-lg-pull-7 {
right: 58.333333%;
}
.col-lg-pull-8 {
right: 66.666667%;
}
.col-lg-pull-9 {
right: 75%;
}
.col-lg-pull-10 {
right: 83.333333%;
}
.col-lg-pull-11 {
right: 91.666667%;
}
.col-lg-pull-12 {
right: 100%;
}
.col-lg-push-0 {
left: auto;
}
.col-lg-push-1 {
left: 8.333333%;
}
.col-lg-push-2 {
left: 16.666667%;
}
.col-lg-push-3 {
left: 25%;
}
.col-lg-push-4 {
left: 33.333333%;
}
.col-lg-push-5 {
left: 41.666667%;
}
.col-lg-push-6 {
left: 50%;
}
.col-lg-push-7 {
left: 58.333333%;
}
.col-lg-push-8 {
left: 66.666667%;
}
.col-lg-push-9 {
left: 75%;
}
.col-lg-push-10 {
left: 83.333333%;
}
.col-lg-push-11 {
left: 91.666667%;
}
.col-lg-push-12 {
left: 100%;
}
.col-lg-offset-0 {
margin-left: 0;
}
.col-lg-offset-1 {
margin-left: 8.333333%;
}
.col-lg-offset-2 {
margin-left: 16.666667%;
}
.col-lg-offset-3 {
margin-left: 25%;
}
.col-lg-offset-4 {
margin-left: 33.333333%;
}
.col-lg-offset-5 {
margin-left: 41.666667%;
}
.col-lg-offset-6 {
margin-left: 50%;
}
.col-lg-offset-7 {
margin-left: 58.333333%;
}
.col-lg-offset-8 {
margin-left: 66.666667%;
}
.col-lg-offset-9 {
margin-left: 75%;
}
.col-lg-offset-10 {
margin-left: 83.333333%;
}
.col-lg-offset-11 {
margin-left: 91.666667%;
}
.col-lg-offset-12 {
margin-left: 100%;
}
@ -1502,207 +1353,156 @@ pre code {
.col-xl-1, .col-xl-2, .col-xl-3, .col-xl-4, .col-xl-5, .col-xl-6, .col-xl-7, .col-xl-8, .col-xl-9, .col-xl-10, .col-xl-11, .col-xl-12 {
float: left;
}
.col-xl-1 {
width: 8.333333%;
}
.col-xl-2 {
width: 16.666667%;
}
.col-xl-3 {
width: 25%;
}
.col-xl-4 {
width: 33.333333%;
}
.col-xl-5 {
width: 41.666667%;
}
.col-xl-6 {
width: 50%;
}
.col-xl-7 {
width: 58.333333%;
}
.col-xl-8 {
width: 66.666667%;
}
.col-xl-9 {
width: 75%;
}
.col-xl-10 {
width: 83.333333%;
}
.col-xl-11 {
width: 91.666667%;
}
.col-xl-12 {
width: 100%;
}
.col-xl-pull-0 {
right: auto;
}
.col-xl-pull-1 {
right: 8.333333%;
}
.col-xl-pull-2 {
right: 16.666667%;
}
.col-xl-pull-3 {
right: 25%;
}
.col-xl-pull-4 {
right: 33.333333%;
}
.col-xl-pull-5 {
right: 41.666667%;
}
.col-xl-pull-6 {
right: 50%;
}
.col-xl-pull-7 {
right: 58.333333%;
}
.col-xl-pull-8 {
right: 66.666667%;
}
.col-xl-pull-9 {
right: 75%;
}
.col-xl-pull-10 {
right: 83.333333%;
}
.col-xl-pull-11 {
right: 91.666667%;
}
.col-xl-pull-12 {
right: 100%;
}
.col-xl-push-0 {
left: auto;
}
.col-xl-push-1 {
left: 8.333333%;
}
.col-xl-push-2 {
left: 16.666667%;
}
.col-xl-push-3 {
left: 25%;
}
.col-xl-push-4 {
left: 33.333333%;
}
.col-xl-push-5 {
left: 41.666667%;
}
.col-xl-push-6 {
left: 50%;
}
.col-xl-push-7 {
left: 58.333333%;
}
.col-xl-push-8 {
left: 66.666667%;
}
.col-xl-push-9 {
left: 75%;
}
.col-xl-push-10 {
left: 83.333333%;
}
.col-xl-push-11 {
left: 91.666667%;
}
.col-xl-push-12 {
left: 100%;
}
.col-xl-offset-0 {
margin-left: 0;
}
.col-xl-offset-1 {
margin-left: 8.333333%;
}
.col-xl-offset-2 {
margin-left: 16.666667%;
}
.col-xl-offset-3 {
margin-left: 25%;
}
.col-xl-offset-4 {
margin-left: 33.333333%;
}
.col-xl-offset-5 {
margin-left: 41.666667%;
}
.col-xl-offset-6 {
margin-left: 50%;
}
.col-xl-offset-7 {
margin-left: 58.333333%;
}
.col-xl-offset-8 {
margin-left: 66.666667%;
}
.col-xl-offset-9 {
margin-left: 75%;
}
.col-xl-offset-10 {
margin-left: 83.333333%;
}
.col-xl-offset-11 {
margin-left: 91.666667%;
}
.col-xl-offset-12 {
margin-left: 100%;
}
@ -1783,7 +1583,13 @@ table td[class*="col-"], table th[class*="col-"] {
background-color: #f5f5f5;
}
.table-hover > tbody > tr > td.active:hover, .table-hover > tbody > tr > th.active:hover, .table-hover > tbody > tr.active:hover > td, .table-hover > tbody > tr:hover > .active, .table-hover > tbody > tr.active:hover > th {
.table-hover > tbody > tr > td.active:hover, .table-hover > tbody > tr > th.active:hover {
background-color: #e8e8e8;
}
.table-hover > tbody > tr.active:hover > td, .table-hover > tbody > tr.active:hover > th {
background-color: #e8e8e8;
}
.table-hover > tbody > tr:hover > .active {
background-color: #e8e8e8;
}
@ -1791,7 +1597,13 @@ table td[class*="col-"], table th[class*="col-"] {
background-color: #dff0d8;
}
.table-hover > tbody > tr > td.success:hover, .table-hover > tbody > tr > th.success:hover, .table-hover > tbody > tr.success:hover > td, .table-hover > tbody > tr:hover > .success, .table-hover > tbody > tr.success:hover > th {
.table-hover > tbody > tr > td.success:hover, .table-hover > tbody > tr > th.success:hover {
background-color: #d0e9c6;
}
.table-hover > tbody > tr.success:hover > td, .table-hover > tbody > tr.success:hover > th {
background-color: #d0e9c6;
}
.table-hover > tbody > tr:hover > .success {
background-color: #d0e9c6;
}
@ -1799,7 +1611,13 @@ table td[class*="col-"], table th[class*="col-"] {
background-color: #d9edf7;
}
.table-hover > tbody > tr > td.info:hover, .table-hover > tbody > tr > th.info:hover, .table-hover > tbody > tr.info:hover > td, .table-hover > tbody > tr:hover > .info, .table-hover > tbody > tr.info:hover > th {
.table-hover > tbody > tr > td.info:hover, .table-hover > tbody > tr > th.info:hover {
background-color: #c4e3f3;
}
.table-hover > tbody > tr.info:hover > td, .table-hover > tbody > tr.info:hover > th {
background-color: #c4e3f3;
}
.table-hover > tbody > tr:hover > .info {
background-color: #c4e3f3;
}
@ -1807,7 +1625,13 @@ table td[class*="col-"], table th[class*="col-"] {
background-color: #fcf8e3;
}
.table-hover > tbody > tr > td.warning:hover, .table-hover > tbody > tr > th.warning:hover, .table-hover > tbody > tr.warning:hover > td, .table-hover > tbody > tr:hover > .warning, .table-hover > tbody > tr.warning:hover > th {
.table-hover > tbody > tr > td.warning:hover, .table-hover > tbody > tr > th.warning:hover {
background-color: #faf2cc;
}
.table-hover > tbody > tr.warning:hover > td, .table-hover > tbody > tr.warning:hover > th {
background-color: #faf2cc;
}
.table-hover > tbody > tr:hover > .warning {
background-color: #faf2cc;
}
@ -1815,7 +1639,13 @@ table td[class*="col-"], table th[class*="col-"] {
background-color: #f2dede;
}
.table-hover > tbody > tr > td.danger:hover, .table-hover > tbody > tr > th.danger:hover, .table-hover > tbody > tr.danger:hover > td, .table-hover > tbody > tr:hover > .danger, .table-hover > tbody > tr.danger:hover > th {
.table-hover > tbody > tr > td.danger:hover, .table-hover > tbody > tr > th.danger:hover {
background-color: #ebcccc;
}
.table-hover > tbody > tr.danger:hover > td, .table-hover > tbody > tr.danger:hover > th {
background-color: #ebcccc;
}
.table-hover > tbody > tr:hover > .danger {
background-color: #ebcccc;
}
@ -1974,10 +1804,12 @@ output {
opacity: 1;
}
.form-control:disabled, .form-control[readonly], fieldset[disabled] .form-control {
cursor: not-allowed;
background-color: #eceeef;
opacity: 1;
}
.form-control[disabled], fieldset[disabled] .form-control {
cursor: false;
}
textarea.form-control {
height: auto;
@ -2030,6 +1862,7 @@ input[type="search"] {
}
.radio-inline, .checkbox-inline {
position: relative;
display: inline-block;
padding-left: 20px;
margin-bottom: 0;
@ -2044,18 +1877,19 @@ input[type="search"] {
}
input[type="radio"]:disabled, input[type="radio"].disabled, fieldset[disabled] input[type="radio"], input[type="checkbox"]:disabled, input[type="checkbox"].disabled, fieldset[disabled] input[type="checkbox"] {
cursor: not-allowed;
cursor: false;
}
.radio-inline.disabled, fieldset[disabled] .radio-inline, .checkbox-inline.disabled, fieldset[disabled] .checkbox-inline {
cursor: not-allowed;
cursor: false;
}
.radio.disabled label, fieldset[disabled] .radio label, .checkbox.disabled label, fieldset[disabled] .checkbox label {
cursor: not-allowed;
cursor: false;
}
.form-control-static {
min-height: 2rem;
padding-top: 1.5rem;
padding-bottom: 1.5rem;
margin-bottom: 0;
@ -2098,6 +1932,7 @@ textarea.input-sm, .input-group-sm > textarea.form-control, .input-group-sm > te
}
.form-group-sm .form-control-static {
height: 2.025rem;
min-height: 1.85rem;
padding: .3rem .75rem;
font-size: .85rem;
line-height: 1.5;
@ -2136,6 +1971,7 @@ textarea.input-lg, .input-group-lg > textarea.form-control, .input-group-lg > te
}
.form-group-lg .form-control-static {
height: 3.316667rem;
min-height: 2.25rem;
padding: .75rem 1.5rem;
font-size: 1.25rem;
line-height: 1.333333;
@ -2259,17 +2095,14 @@ textarea.input-lg, .input-group-lg > textarea.form-control, .input-group-lg > te
margin-bottom: 0;
vertical-align: middle;
}
.form-inline .form-control, .navbar-form .form-control {
display: inline-block;
width: auto;
vertical-align: middle;
}
.form-inline .form-control-static, .navbar-form .form-control-static {
display: inline-block;
}
.form-inline .input-group, .navbar-form .input-group {
display: inline-table;
vertical-align: middle;
@ -2277,16 +2110,13 @@ textarea.input-lg, .input-group-lg > textarea.form-control, .input-group-lg > te
.form-inline .input-group .input-group-addon, .navbar-form .input-group .input-group-addon, .form-inline .input-group .input-group-btn, .navbar-form .input-group .input-group-btn, .form-inline .input-group .form-control, .navbar-form .input-group .form-control {
width: auto;
}
.form-inline .input-group > .form-control, .navbar-form .input-group > .form-control {
width: 100%;
}
.form-inline .control-label, .navbar-form .control-label {
margin-bottom: 0;
vertical-align: middle;
}
.form-inline .radio, .navbar-form .radio, .form-inline .checkbox, .navbar-form .checkbox {
display: inline-block;
margin-top: 0;
@ -2296,12 +2126,10 @@ textarea.input-lg, .input-group-lg > textarea.form-control, .input-group-lg > te
.form-inline .radio label, .navbar-form .radio label, .form-inline .checkbox label, .navbar-form .checkbox label {
padding-left: 0;
}
.form-inline .radio input[type="radio"], .navbar-form .radio input[type="radio"], .form-inline .checkbox input[type="checkbox"], .navbar-form .checkbox input[type="checkbox"] {
position: relative;
margin-left: 0;
}
.form-inline .has-feedback .form-control-feedback, .navbar-form .has-feedback .form-control-feedback {
top: 0;
}
@ -2375,7 +2203,10 @@ textarea.input-lg, .input-group-lg > textarea.form-control, .input-group-lg > te
outline: 5px auto -webkit-focus-ring-color;
outline-offset: -2px;
}
.btn:hover, .btn:focus, .btn.focus {
.btn:focus, .btn:hover {
text-decoration: none;
}
.btn.focus {
text-decoration: none;
}
.btn:active, .btn.active {
@ -2386,7 +2217,7 @@ textarea.input-lg, .input-group-lg > textarea.form-control, .input-group-lg > te
}
.btn.disabled, .btn:disabled, fieldset[disabled] .btn {
pointer-events: none;
cursor: not-allowed;
cursor: false;
-webkit-box-shadow: none;
box-shadow: none;
opacity: .65;
@ -2397,7 +2228,12 @@ textarea.input-lg, .input-group-lg > textarea.form-control, .input-group-lg > te
background-color: #0275d8;
border-color: #0267bf;
}
.btn-primary:hover, .btn-primary:focus, .btn-primary.focus, .btn-primary:active, .btn-primary.active, .open > .btn-primary.dropdown-toggle {
.btn-primary:focus, .btn-primary.focus, .btn-primary:active, .btn-primary.active, .open > .btn-primary.dropdown-toggle {
color: #fff;
background-color: #025aa5;
border-color: #014682;
}
.btn-primary:hover {
color: #fff;
background-color: #025aa5;
border-color: #014682;
@ -2407,7 +2243,11 @@ textarea.input-lg, .input-group-lg > textarea.form-control, .input-group-lg > te
-webkit-box-shadow: inset 0 3px 5px rgba(0, 0, 0, .125);
box-shadow: inset 0 3px 5px rgba(0, 0, 0, .125);
}
.btn-primary.disabled, .btn-primary.disabled:hover, .btn-primary.disabled:focus, .btn-primary.disabled.focus, .btn-primary.disabled:active, .btn-primary.disabled.active, .btn-primary:disabled, .btn-primary:disabled:hover, .btn-primary:disabled:focus, .btn-primary:disabled.focus, .btn-primary:disabled:active, .btn-primary:disabled.active, fieldset[disabled] .btn-primary, fieldset[disabled] .btn-primary:hover, fieldset[disabled] .btn-primary:focus, fieldset[disabled] .btn-primary.focus, fieldset[disabled] .btn-primary:active, fieldset[disabled] .btn-primary.active {
.btn-primary.disabled, .btn-primary.disabled:focus, .btn-primary.disabled.focus, .btn-primary.disabled:active, .btn-primary.disabled.active, .btn-primary:disabled, .btn-primary:disabled:focus, .btn-primary:disabled.focus, .btn-primary:disabled:active, .btn-primary:disabled.active, fieldset[disabled] .btn-primary, fieldset[disabled] .btn-primary:focus, fieldset[disabled] .btn-primary.focus, fieldset[disabled] .btn-primary:active, fieldset[disabled] .btn-primary.active {
background-color: #0275d8;
border-color: #0267bf;
}
.btn-primary.disabled:hover, .btn-primary:disabled:hover, fieldset[disabled] .btn-primary:hover {
background-color: #0275d8;
border-color: #0267bf;
}
@ -2421,7 +2261,12 @@ textarea.input-lg, .input-group-lg > textarea.form-control, .input-group-lg > te
background-color: #fff;
border-color: #eceeef;
}
.btn-secondary:hover, .btn-secondary:focus, .btn-secondary.focus, .btn-secondary:active, .btn-secondary.active, .open > .btn-secondary.dropdown-toggle {
.btn-secondary:focus, .btn-secondary.focus, .btn-secondary:active, .btn-secondary.active, .open > .btn-secondary.dropdown-toggle {
color: #373a3c;
background-color: #e6e6e6;
border-color: #cbd0d3;
}
.btn-secondary:hover {
color: #373a3c;
background-color: #e6e6e6;
border-color: #cbd0d3;
@ -2431,7 +2276,11 @@ textarea.input-lg, .input-group-lg > textarea.form-control, .input-group-lg > te
-webkit-box-shadow: inset 0 3px 5px rgba(0, 0, 0, .125);
box-shadow: inset 0 3px 5px rgba(0, 0, 0, .125);
}
.btn-secondary.disabled, .btn-secondary.disabled:hover, .btn-secondary.disabled:focus, .btn-secondary.disabled.focus, .btn-secondary.disabled:active, .btn-secondary.disabled.active, .btn-secondary:disabled, .btn-secondary:disabled:hover, .btn-secondary:disabled:focus, .btn-secondary:disabled.focus, .btn-secondary:disabled:active, .btn-secondary:disabled.active, fieldset[disabled] .btn-secondary, fieldset[disabled] .btn-secondary:hover, fieldset[disabled] .btn-secondary:focus, fieldset[disabled] .btn-secondary.focus, fieldset[disabled] .btn-secondary:active, fieldset[disabled] .btn-secondary.active {
.btn-secondary.disabled, .btn-secondary.disabled:focus, .btn-secondary.disabled.focus, .btn-secondary.disabled:active, .btn-secondary.disabled.active, .btn-secondary:disabled, .btn-secondary:disabled:focus, .btn-secondary:disabled.focus, .btn-secondary:disabled:active, .btn-secondary:disabled.active, fieldset[disabled] .btn-secondary, fieldset[disabled] .btn-secondary:focus, fieldset[disabled] .btn-secondary.focus, fieldset[disabled] .btn-secondary:active, fieldset[disabled] .btn-secondary.active {
background-color: #fff;
border-color: #eceeef;
}
.btn-secondary.disabled:hover, .btn-secondary:disabled:hover, fieldset[disabled] .btn-secondary:hover {
background-color: #fff;
border-color: #eceeef;
}
@ -2445,7 +2294,12 @@ textarea.input-lg, .input-group-lg > textarea.form-control, .input-group-lg > te
background-color: #5bc0de;
border-color: #46b8da;
}
.btn-info:hover, .btn-info:focus, .btn-info.focus, .btn-info:active, .btn-info.active, .open > .btn-info.dropdown-toggle {
.btn-info:focus, .btn-info.focus, .btn-info:active, .btn-info.active, .open > .btn-info.dropdown-toggle {
color: #fff;
background-color: #31b0d5;
border-color: #269abc;
}
.btn-info:hover {
color: #fff;
background-color: #31b0d5;
border-color: #269abc;
@ -2455,7 +2309,11 @@ textarea.input-lg, .input-group-lg > textarea.form-control, .input-group-lg > te
-webkit-box-shadow: inset 0 3px 5px rgba(0, 0, 0, .125);
box-shadow: inset 0 3px 5px rgba(0, 0, 0, .125);
}
.btn-info.disabled, .btn-info.disabled:hover, .btn-info.disabled:focus, .btn-info.disabled.focus, .btn-info.disabled:active, .btn-info.disabled.active, .btn-info:disabled, .btn-info:disabled:hover, .btn-info:disabled:focus, .btn-info:disabled.focus, .btn-info:disabled:active, .btn-info:disabled.active, fieldset[disabled] .btn-info, fieldset[disabled] .btn-info:hover, fieldset[disabled] .btn-info:focus, fieldset[disabled] .btn-info.focus, fieldset[disabled] .btn-info:active, fieldset[disabled] .btn-info.active {
.btn-info.disabled, .btn-info.disabled:focus, .btn-info.disabled.focus, .btn-info.disabled:active, .btn-info.disabled.active, .btn-info:disabled, .btn-info:disabled:focus, .btn-info:disabled.focus, .btn-info:disabled:active, .btn-info:disabled.active, fieldset[disabled] .btn-info, fieldset[disabled] .btn-info:focus, fieldset[disabled] .btn-info.focus, fieldset[disabled] .btn-info:active, fieldset[disabled] .btn-info.active {
background-color: #5bc0de;
border-color: #46b8da;
}
.btn-info.disabled:hover, .btn-info:disabled:hover, fieldset[disabled] .btn-info:hover {
background-color: #5bc0de;
border-color: #46b8da;
}
@ -2469,7 +2327,12 @@ textarea.input-lg, .input-group-lg > textarea.form-control, .input-group-lg > te
background-color: #5cb85c;
border-color: #4cae4c;
}
.btn-success:hover, .btn-success:focus, .btn-success.focus, .btn-success:active, .btn-success.active, .open > .btn-success.dropdown-toggle {
.btn-success:focus, .btn-success.focus, .btn-success:active, .btn-success.active, .open > .btn-success.dropdown-toggle {
color: #fff;
background-color: #449d44;
border-color: #398439;
}
.btn-success:hover {
color: #fff;
background-color: #449d44;
border-color: #398439;
@ -2479,7 +2342,11 @@ textarea.input-lg, .input-group-lg > textarea.form-control, .input-group-lg > te
-webkit-box-shadow: inset 0 3px 5px rgba(0, 0, 0, .125);
box-shadow: inset 0 3px 5px rgba(0, 0, 0, .125);
}
.btn-success.disabled, .btn-success.disabled:hover, .btn-success.disabled:focus, .btn-success.disabled.focus, .btn-success.disabled:active, .btn-success.disabled.active, .btn-success:disabled, .btn-success:disabled:hover, .btn-success:disabled:focus, .btn-success:disabled.focus, .btn-success:disabled:active, .btn-success:disabled.active, fieldset[disabled] .btn-success, fieldset[disabled] .btn-success:hover, fieldset[disabled] .btn-success:focus, fieldset[disabled] .btn-success.focus, fieldset[disabled] .btn-success:active, fieldset[disabled] .btn-success.active {
.btn-success.disabled, .btn-success.disabled:focus, .btn-success.disabled.focus, .btn-success.disabled:active, .btn-success.disabled.active, .btn-success:disabled, .btn-success:disabled:focus, .btn-success:disabled.focus, .btn-success:disabled:active, .btn-success:disabled.active, fieldset[disabled] .btn-success, fieldset[disabled] .btn-success:focus, fieldset[disabled] .btn-success.focus, fieldset[disabled] .btn-success:active, fieldset[disabled] .btn-success.active {
background-color: #5cb85c;
border-color: #4cae4c;
}
.btn-success.disabled:hover, .btn-success:disabled:hover, fieldset[disabled] .btn-success:hover {
background-color: #5cb85c;
border-color: #4cae4c;
}
@ -2493,7 +2360,12 @@ textarea.input-lg, .input-group-lg > textarea.form-control, .input-group-lg > te
background-color: #f0ad4e;
border-color: #eea236;
}
.btn-warning:hover, .btn-warning:focus, .btn-warning.focus, .btn-warning:active, .btn-warning.active, .open > .btn-warning.dropdown-toggle {
.btn-warning:focus, .btn-warning.focus, .btn-warning:active, .btn-warning.active, .open > .btn-warning.dropdown-toggle {
color: #fff;
background-color: #ec971f;
border-color: #d58512;
}
.btn-warning:hover {
color: #fff;
background-color: #ec971f;
border-color: #d58512;
@ -2503,7 +2375,11 @@ textarea.input-lg, .input-group-lg > textarea.form-control, .input-group-lg > te
-webkit-box-shadow: inset 0 3px 5px rgba(0, 0, 0, .125);
box-shadow: inset 0 3px 5px rgba(0, 0, 0, .125);
}
.btn-warning.disabled, .btn-warning.disabled:hover, .btn-warning.disabled:focus, .btn-warning.disabled.focus, .btn-warning.disabled:active, .btn-warning.disabled.active, .btn-warning:disabled, .btn-warning:disabled:hover, .btn-warning:disabled:focus, .btn-warning:disabled.focus, .btn-warning:disabled:active, .btn-warning:disabled.active, fieldset[disabled] .btn-warning, fieldset[disabled] .btn-warning:hover, fieldset[disabled] .btn-warning:focus, fieldset[disabled] .btn-warning.focus, fieldset[disabled] .btn-warning:active, fieldset[disabled] .btn-warning.active {
.btn-warning.disabled, .btn-warning.disabled:focus, .btn-warning.disabled.focus, .btn-warning.disabled:active, .btn-warning.disabled.active, .btn-warning:disabled, .btn-warning:disabled:focus, .btn-warning:disabled.focus, .btn-warning:disabled:active, .btn-warning:disabled.active, fieldset[disabled] .btn-warning, fieldset[disabled] .btn-warning:focus, fieldset[disabled] .btn-warning.focus, fieldset[disabled] .btn-warning:active, fieldset[disabled] .btn-warning.active {
background-color: #f0ad4e;
border-color: #eea236;
}
.btn-warning.disabled:hover, .btn-warning:disabled:hover, fieldset[disabled] .btn-warning:hover {
background-color: #f0ad4e;
border-color: #eea236;
}
@ -2517,7 +2393,12 @@ textarea.input-lg, .input-group-lg > textarea.form-control, .input-group-lg > te
background-color: #d9534f;
border-color: #d43f3a;
}
.btn-danger:hover, .btn-danger:focus, .btn-danger.focus, .btn-danger:active, .btn-danger.active, .open > .btn-danger.dropdown-toggle {
.btn-danger:focus, .btn-danger.focus, .btn-danger:active, .btn-danger.active, .open > .btn-danger.dropdown-toggle {
color: #fff;
background-color: #c9302c;
border-color: #ac2925;
}
.btn-danger:hover {
color: #fff;
background-color: #c9302c;
border-color: #ac2925;
@ -2527,7 +2408,11 @@ textarea.input-lg, .input-group-lg > textarea.form-control, .input-group-lg > te
-webkit-box-shadow: inset 0 3px 5px rgba(0, 0, 0, .125);
box-shadow: inset 0 3px 5px rgba(0, 0, 0, .125);
}
.btn-danger.disabled, .btn-danger.disabled:hover, .btn-danger.disabled:focus, .btn-danger.disabled.focus, .btn-danger.disabled:active, .btn-danger.disabled.active, .btn-danger:disabled, .btn-danger:disabled:hover, .btn-danger:disabled:focus, .btn-danger:disabled.focus, .btn-danger:disabled:active, .btn-danger:disabled.active, fieldset[disabled] .btn-danger, fieldset[disabled] .btn-danger:hover, fieldset[disabled] .btn-danger:focus, fieldset[disabled] .btn-danger.focus, fieldset[disabled] .btn-danger:active, fieldset[disabled] .btn-danger.active {
.btn-danger.disabled, .btn-danger.disabled:focus, .btn-danger.disabled.focus, .btn-danger.disabled:active, .btn-danger.disabled.active, .btn-danger:disabled, .btn-danger:disabled:focus, .btn-danger:disabled.focus, .btn-danger:disabled:active, .btn-danger:disabled.active, fieldset[disabled] .btn-danger, fieldset[disabled] .btn-danger:focus, fieldset[disabled] .btn-danger.focus, fieldset[disabled] .btn-danger:active, fieldset[disabled] .btn-danger.active {
background-color: #d9534f;
border-color: #d43f3a;
}
.btn-danger.disabled:hover, .btn-danger:disabled:hover, fieldset[disabled] .btn-danger:hover {
background-color: #d9534f;
border-color: #d43f3a;
}
@ -2546,15 +2431,18 @@ textarea.input-lg, .input-group-lg > textarea.form-control, .input-group-lg > te
-webkit-box-shadow: none;
box-shadow: none;
}
.btn-link, .btn-link:hover, .btn-link:focus, .btn-link:active {
.btn-link, .btn-link:focus, .btn-link:active {
border-color: transparent;
}
.btn-link:hover, .btn-link:focus {
.btn-link:hover {
border-color: transparent;
}
.btn-link:focus, .btn-link:hover {
color: #014c8c;
text-decoration: underline;
background-color: transparent;
}
.btn-link:disabled:hover, .btn-link:disabled:focus, fieldset[disabled] .btn-link:hover, fieldset[disabled] .btn-link:focus {
.btn-link:disabled:focus, .btn-link:disabled:hover, fieldset[disabled] .btn-link:focus, fieldset[disabled] .btn-link:hover {
color: #818a91;
text-decoration: none;
}
@ -2683,25 +2571,25 @@ input[type="submit"].btn-block, input[type="reset"].btn-block, input[type="butto
white-space: nowrap;
}
.dropdown-menu > li > a:hover, .dropdown-menu > li > a:focus {
.dropdown-menu > li > a:focus, .dropdown-menu > li > a:hover {
color: #2b2d2f;
text-decoration: none;
background-color: #f5f5f5;
}
.dropdown-menu > .active > a, .dropdown-menu > .active > a:hover, .dropdown-menu > .active > a:focus {
.dropdown-menu > .active > a, .dropdown-menu > .active > a:focus, .dropdown-menu > .active > a:hover {
color: #fff;
text-decoration: none;
background-color: #0275d8;
outline: 0;
}
.dropdown-menu > .disabled > a, .dropdown-menu > .disabled > a:hover, .dropdown-menu > .disabled > a:focus {
.dropdown-menu > .disabled > a, .dropdown-menu > .disabled > a:focus, .dropdown-menu > .disabled > a:hover {
color: #818a91;
}
.dropdown-menu > .disabled > a:hover, .dropdown-menu > .disabled > a:focus {
.dropdown-menu > .disabled > a:focus, .dropdown-menu > .disabled > a:hover {
text-decoration: none;
cursor: not-allowed;
cursor: false;
background-color: transparent;
background-image: none;
filter: "progid:DXImageTransform.Microsoft.gradient(enabled = false)";
@ -2767,7 +2655,10 @@ input[type="submit"].btn-block, input[type="reset"].btn-block, input[type="butto
position: relative;
float: left;
}
.btn-group > .btn:hover, .btn-group > .btn:focus, .btn-group > .btn:active, .btn-group > .btn.active, .btn-group-vertical > .btn:hover, .btn-group-vertical > .btn:focus, .btn-group-vertical > .btn:active, .btn-group-vertical > .btn.active {
.btn-group > .btn:focus, .btn-group > .btn:active, .btn-group > .btn.active, .btn-group-vertical > .btn:focus, .btn-group-vertical > .btn:active, .btn-group-vertical > .btn.active {
z-index: 2;
}
.btn-group > .btn:hover, .btn-group-vertical > .btn:hover {
z-index: 2;
}
@ -3021,7 +2912,7 @@ input[type="submit"].btn-block, input[type="reset"].btn-block, input[type="butto
.input-group-btn > .btn + .btn {
margin-left: -1px;
}
.input-group-btn > .btn:hover, .input-group-btn > .btn:focus, .input-group-btn > .btn:active {
.input-group-btn > .btn:focus, .input-group-btn > .btn:active, .input-group-btn > .btn:hover {
z-index: 2;
}
.input-group-btn:first-child > .btn, .input-group-btn:first-child > .btn-group {
@ -3171,6 +3062,10 @@ input[type="submit"].btn-block, input[type="reset"].btn-block, input[type="butto
border-left: .35rem solid transparent;
}
.select select:hover {
background-color: #ddd;
}
@-moz-document url-prefix() {
.select select {
padding-right: 1rem;
@ -3188,11 +3083,9 @@ input[type="submit"].btn-block, input[type="reset"].btn-block, input[type="butto
z-index: 1;
padding: .5rem 1.5rem .5rem 1rem;
}
.select:after {
z-index: 5;
}
.select:before {
position: absolute;
top: 0;
@ -3204,8 +3097,7 @@ input[type="submit"].btn-block, input[type="reset"].btn-block, input[type="butto
content: "";
background-color: #eee;
}
.select select:hover, .select select:focus, .select select:active {
.select select:focus, .select select:active, .select select:hover {
color: #555;
background-color: #eee;
}
@ -3293,16 +3185,16 @@ input[type="submit"].btn-block, input[type="reset"].btn-block, input[type="butto
padding: .6em 1em;
line-height: 1.5;
}
.nav-link:hover, .nav-link:focus {
.nav-link:focus, .nav-link:hover {
text-decoration: none;
background-color: #eceeef;
}
.disabled > .nav-link, .nav-link.disabled {
color: #818a91;
}
.disabled > .nav-link, .disabled > .nav-link:hover, .disabled > .nav-link:focus, .nav-link.disabled, .nav-link.disabled:hover, .nav-link.disabled:focus {
.disabled > .nav-link, .disabled > .nav-link:focus, .disabled > .nav-link:hover, .nav-link.disabled, .nav-link.disabled:focus, .nav-link.disabled:hover {
color: #818a91;
cursor: not-allowed;
cursor: false;
background-color: transparent;
}
@ -3321,15 +3213,15 @@ input[type="submit"].btn-block, input[type="reset"].btn-block, input[type="butto
border: 1px solid transparent;
border-radius: .25rem .25rem 0 0;
}
.nav-tabs .nav-link:hover, .nav-tabs .nav-link:focus {
.nav-tabs .nav-link:focus, .nav-tabs .nav-link:hover {
border-color: #eceeef #eceeef #ddd;
}
.nav-tabs .open > .nav-link, .nav-tabs .open > .nav-link:hover, .nav-tabs .open > .nav-link:focus, .nav-tabs .active > .nav-link, .nav-tabs .active > .nav-link:hover, .nav-tabs .active > .nav-link:focus, .nav-tabs .nav-link.open, .nav-tabs .nav-link.open:hover, .nav-tabs .nav-link.open:focus, .nav-tabs .nav-link.active, .nav-tabs .nav-link.active:hover, .nav-tabs .nav-link.active:focus {
.nav-tabs .open > .nav-link, .nav-tabs .open > .nav-link:focus, .nav-tabs .open > .nav-link:hover, .nav-tabs .active > .nav-link, .nav-tabs .active > .nav-link:focus, .nav-tabs .active > .nav-link:hover, .nav-tabs .nav-link.open, .nav-tabs .nav-link.open:focus, .nav-tabs .nav-link.open:hover, .nav-tabs .nav-link.active, .nav-tabs .nav-link.active:focus, .nav-tabs .nav-link.active:hover {
color: #55595c;
background-color: #fff;
border-color: #ddd #ddd transparent;
}
.nav-tabs .disabled > .nav-link, .nav-tabs .disabled > .nav-link:hover, .nav-tabs .disabled > .nav-link:focus, .nav-tabs .nav-link.disabled, .nav-tabs .nav-link.disabled:hover, .nav-tabs .nav-link.disabled:focus {
.nav-tabs .disabled > .nav-link, .nav-tabs .disabled > .nav-link:focus, .nav-tabs .disabled > .nav-link:hover, .nav-tabs .nav-link.disabled, .nav-tabs .nav-link.disabled:focus, .nav-tabs .nav-link.disabled:hover {
color: #818a91;
background-color: transparent;
border-color: transparent;
@ -3345,7 +3237,7 @@ input[type="submit"].btn-block, input[type="reset"].btn-block, input[type="butto
display: block;
border-radius: .25rem;
}
.nav-pills .open > .nav-link, .nav-pills .open > .nav-link:hover, .nav-pills .open > .nav-link:focus, .nav-pills .active > .nav-link, .nav-pills .active > .nav-link:hover, .nav-pills .active > .nav-link:focus, .nav-pills .nav-link.open, .nav-pills .nav-link.open:hover, .nav-pills .nav-link.open:focus, .nav-pills .nav-link.active, .nav-pills .nav-link.active:hover, .nav-pills .nav-link.active:focus {
.nav-pills .open > .nav-link, .nav-pills .open > .nav-link:focus, .nav-pills .open > .nav-link:hover, .nav-pills .active > .nav-link, .nav-pills .active > .nav-link:focus, .nav-pills .active > .nav-link:hover, .nav-pills .nav-link.open, .nav-pills .nav-link.open:focus, .nav-pills .nav-link.open:hover, .nav-pills .nav-link.active, .nav-pills .nav-link.active:focus, .nav-pills .nav-link.active:hover {
color: #fff;
cursor: default;
background-color: #0275d8;
@ -3431,7 +3323,7 @@ input[type="submit"].btn-block, input[type="reset"].btn-block, input[type="butto
font-size: 1.25rem;
line-height: 1;
}
.navbar-brand > a:hover, .navbar-brand > a:focus {
.navbar-brand > a:focus, .navbar-brand > a:hover {
text-decoration: none;
}
.navbar-brand > img {
@ -3448,7 +3340,7 @@ input[type="submit"].btn-block, input[type="reset"].btn-block, input[type="butto
background: none;
border: 0;
}
.navbar-toggler:hover, .navbar-toggler:focus {
.navbar-toggler:focus, .navbar-toggler:hover {
text-decoration: none;
}
@ -3507,7 +3399,6 @@ input[type="submit"].btn-block, input[type="reset"].btn-block, input[type="butto
.navbar-left {
float: left !important;
}
.navbar-right {
float: right !important;
margin-right: -1rem;
@ -3524,7 +3415,7 @@ input[type="submit"].btn-block, input[type="reset"].btn-block, input[type="butto
.navbar-default .navbar-brand {
color: #777;
}
.navbar-default .navbar-brand:hover, .navbar-default .navbar-brand:focus {
.navbar-default .navbar-brand:focus, .navbar-default .navbar-brand:hover {
color: #5e5e5e;
background-color: transparent;
}
@ -3534,22 +3425,22 @@ input[type="submit"].btn-block, input[type="reset"].btn-block, input[type="butto
.navbar-default .navbar-nav > li > a {
color: #777;
}
.navbar-default .navbar-nav > li > a:hover, .navbar-default .navbar-nav > li > a:focus {
.navbar-default .navbar-nav > li > a:focus, .navbar-default .navbar-nav > li > a:hover {
color: #333;
background-color: transparent;
}
.navbar-default .navbar-nav > .active > a, .navbar-default .navbar-nav > .active > a:hover, .navbar-default .navbar-nav > .active > a:focus {
.navbar-default .navbar-nav > .active > a, .navbar-default .navbar-nav > .active > a:focus, .navbar-default .navbar-nav > .active > a:hover {
color: #555;
background-color: #e7e7e7;
}
.navbar-default .navbar-nav > .disabled > a, .navbar-default .navbar-nav > .disabled > a:hover, .navbar-default .navbar-nav > .disabled > a:focus {
.navbar-default .navbar-nav > .disabled > a, .navbar-default .navbar-nav > .disabled > a:focus, .navbar-default .navbar-nav > .disabled > a:hover {
color: #ccc;
background-color: transparent;
}
.navbar-default .navbar-toggle {
border-color: #ddd;
}
.navbar-default .navbar-toggle:hover, .navbar-default .navbar-toggle:focus {
.navbar-default .navbar-toggle:focus, .navbar-default .navbar-toggle:hover {
background-color: #ddd;
}
.navbar-default .navbar-toggle .icon-bar {
@ -3558,7 +3449,7 @@ input[type="submit"].btn-block, input[type="reset"].btn-block, input[type="butto
.navbar-default .navbar-collapse, .navbar-default .navbar-form {
border-color: #e7e7e7;
}
.navbar-default .navbar-nav > .open > a, .navbar-default .navbar-nav > .open > a:hover, .navbar-default .navbar-nav > .open > a:focus {
.navbar-default .navbar-nav > .open > a, .navbar-default .navbar-nav > .open > a:focus, .navbar-default .navbar-nav > .open > a:hover {
color: #555;
background-color: #e7e7e7;
}
@ -3571,10 +3462,10 @@ input[type="submit"].btn-block, input[type="reset"].btn-block, input[type="butto
.navbar-default .btn-link {
color: #777;
}
.navbar-default .btn-link:hover, .navbar-default .btn-link:focus {
.navbar-default .btn-link:focus, .navbar-default .btn-link:hover {
color: #333;
}
.navbar-default .btn-link:disabled:hover, .navbar-default .btn-link:disabled:focus, fieldset[disabled] .navbar-default .btn-link:hover, fieldset[disabled] .navbar-default .btn-link:focus {
.navbar-default .btn-link:disabled:focus, .navbar-default .btn-link:disabled:hover, fieldset[disabled] .navbar-default .btn-link:focus, fieldset[disabled] .navbar-default .btn-link:hover {
color: #ccc;
}
@ -3585,10 +3476,10 @@ input[type="submit"].btn-block, input[type="reset"].btn-block, input[type="butto
.navbar-inverse .navbar-toggler, .navbar-inverse .navbar-brand > a, .navbar-inverse .nav-pills > .nav-item > .nav-link {
color: #aab0b5;
}
.navbar-inverse .navbar-toggler:hover, .navbar-inverse .navbar-toggler:focus, .navbar-inverse .navbar-brand > a:hover, .navbar-inverse .navbar-brand > a:focus, .navbar-inverse .nav-pills > .nav-item > .nav-link:hover, .navbar-inverse .nav-pills > .nav-item > .nav-link:focus {
.navbar-inverse .navbar-toggler:focus, .navbar-inverse .navbar-toggler:hover, .navbar-inverse .navbar-brand > a:focus, .navbar-inverse .navbar-brand > a:hover, .navbar-inverse .nav-pills > .nav-item > .nav-link:focus, .navbar-inverse .nav-pills > .nav-item > .nav-link:hover {
color: #fff;
}
.navbar-inverse .nav-pills > .nav-item > .nav-link:hover, .navbar-inverse .nav-pills > .nav-item > .nav-link:focus {
.navbar-inverse .nav-pills > .nav-item > .nav-link:focus, .navbar-inverse .nav-pills > .nav-item > .nav-link:hover {
color: #fff;
background-color: #1f2021;
}
@ -3599,7 +3490,7 @@ input[type="submit"].btn-block, input[type="reset"].btn-block, input[type="butto
.navbar-inverse .navbar-brand {
color: #aab0b5;
}
.navbar-inverse .navbar-brand:hover, .navbar-inverse .navbar-brand:focus {
.navbar-inverse .navbar-brand:focus, .navbar-inverse .navbar-brand:hover {
color: #fff;
background-color: transparent;
}
@ -3609,22 +3500,22 @@ input[type="submit"].btn-block, input[type="reset"].btn-block, input[type="butto
.navbar-inverse .navbar-nav > li > a {
color: #aab0b5;
}
.navbar-inverse .navbar-nav > li > a:hover, .navbar-inverse .navbar-nav > li > a:focus {
.navbar-inverse .navbar-nav > li > a:focus, .navbar-inverse .navbar-nav > li > a:hover {
color: #fff;
background-color: transparent;
}
.navbar-inverse .navbar-nav > .active > a, .navbar-inverse .navbar-nav > .active > a:hover, .navbar-inverse .navbar-nav > .active > a:focus {
.navbar-inverse .navbar-nav > .active > a, .navbar-inverse .navbar-nav > .active > a:focus, .navbar-inverse .navbar-nav > .active > a:hover {
color: #fff;
background-color: #1f2021;
}
.navbar-inverse .navbar-nav > .disabled > a, .navbar-inverse .navbar-nav > .disabled > a:hover, .navbar-inverse .navbar-nav > .disabled > a:focus {
.navbar-inverse .navbar-nav > .disabled > a, .navbar-inverse .navbar-nav > .disabled > a:focus, .navbar-inverse .navbar-nav > .disabled > a:hover {
color: #444;
background-color: transparent;
}
.navbar-inverse .navbar-collapse, .navbar-inverse .navbar-form {
border-color: #262829;
}
.navbar-inverse .navbar-nav > .open > a, .navbar-inverse .navbar-nav > .open > a:hover, .navbar-inverse .navbar-nav > .open > a:focus {
.navbar-inverse .navbar-nav > .open > a, .navbar-inverse .navbar-nav > .open > a:focus, .navbar-inverse .navbar-nav > .open > a:hover {
color: #fff;
background-color: #1f2021;
}
@ -3637,10 +3528,10 @@ input[type="submit"].btn-block, input[type="reset"].btn-block, input[type="butto
.navbar-inverse .btn-link {
color: #aab0b5;
}
.navbar-inverse .btn-link:hover, .navbar-inverse .btn-link:focus {
.navbar-inverse .btn-link:focus, .navbar-inverse .btn-link:hover {
color: #fff;
}
.navbar-inverse .btn-link:disabled:hover, .navbar-inverse .btn-link:disabled:focus, fieldset[disabled] .navbar-inverse .btn-link:hover, fieldset[disabled] .navbar-inverse .btn-link:focus {
.navbar-inverse .btn-link:disabled:focus, .navbar-inverse .btn-link:disabled:hover, fieldset[disabled] .navbar-inverse .btn-link:focus, fieldset[disabled] .navbar-inverse .btn-link:hover {
color: #444;
}
@ -3716,7 +3607,7 @@ input[type="submit"].btn-block, input[type="reset"].btn-block, input[type="butto
.card-inverse .card-link, .card-inverse .card-text, .card-inverse .card-blockquote > footer {
color: rgba(255, 255, 255, .65);
}
.card-inverse .card-link:hover, .card-inverse .card-link:focus {
.card-inverse .card-link:focus, .card-inverse .card-link:hover {
color: #fff;
}
@ -3843,21 +3734,21 @@ input[type="submit"].btn-block, input[type="reset"].btn-block, input[type="butto
border-top-right-radius: .25rem;
border-bottom-right-radius: .25rem;
}
.pagination > li > a:hover, .pagination > li > a:focus, .pagination > li > span:hover, .pagination > li > span:focus {
.pagination > li > a:focus, .pagination > li > a:hover, .pagination > li > span:focus, .pagination > li > span:hover {
color: #014c8c;
background-color: #eceeef;
border-color: #ddd;
}
.pagination > .active > a, .pagination > .active > a:hover, .pagination > .active > a:focus, .pagination > .active > span, .pagination > .active > span:hover, .pagination > .active > span:focus {
.pagination > .active > a, .pagination > .active > a:focus, .pagination > .active > a:hover, .pagination > .active > span, .pagination > .active > span:focus, .pagination > .active > span:hover {
z-index: 2;
color: #fff;
cursor: default;
background-color: #0275d8;
border-color: #0275d8;
}
.pagination > .disabled > span, .pagination > .disabled > span:hover, .pagination > .disabled > span:focus, .pagination > .disabled > a, .pagination > .disabled > a:hover, .pagination > .disabled > a:focus {
.pagination > .disabled > span, .pagination > .disabled > span:focus, .pagination > .disabled > span:hover, .pagination > .disabled > a, .pagination > .disabled > a:focus, .pagination > .disabled > a:hover {
color: #818a91;
cursor: not-allowed;
cursor: false;
background-color: #fff;
border-color: #ddd;
}
@ -3911,13 +3802,18 @@ input[type="submit"].btn-block, input[type="reset"].btn-block, input[type="butto
border: 1px solid #ddd;
border-radius: 15px;
}
.pager li > a:hover, .pager li > a:focus {
.pager li > a:focus, .pager li > a:hover {
text-decoration: none;
background-color: #eceeef;
}
.pager .disabled > a, .pager .disabled > a:hover, .pager .disabled > a:focus, .pager .disabled > span {
.pager .disabled > a, .pager .disabled > a:focus, .pager .disabled > a:hover {
color: #818a91;
cursor: not-allowed;
cursor: false;
background-color: #fff;
}
.pager .disabled > span {
color: #818a91;
cursor: false;
background-color: #fff;
}
@ -3949,7 +3845,7 @@ input[type="submit"].btn-block, input[type="reset"].btn-block, input[type="butto
top: -1px;
}
a.label:hover, a.label:focus {
a.label:focus, a.label:hover {
color: #fff;
text-decoration: none;
cursor: pointer;
@ -3958,42 +3854,42 @@ a.label:hover, a.label:focus {
.label-default {
background-color: #818a91;
}
.label-default[href]:hover, .label-default[href]:focus {
.label-default[href]:focus, .label-default[href]:hover {
background-color: #687077;
}
.label-primary {
background-color: #0275d8;
}
.label-primary[href]:hover, .label-primary[href]:focus {
.label-primary[href]:focus, .label-primary[href]:hover {
background-color: #025aa5;
}
.label-success {
background-color: #5cb85c;
}
.label-success[href]:hover, .label-success[href]:focus {
.label-success[href]:focus, .label-success[href]:hover {
background-color: #449d44;
}
.label-info {
background-color: #5bc0de;
}
.label-info[href]:hover, .label-info[href]:focus {
.label-info[href]:focus, .label-info[href]:hover {
background-color: #31b0d5;
}
.label-warning {
background-color: #f0ad4e;
}
.label-warning[href]:hover, .label-warning[href]:focus {
.label-warning[href]:focus, .label-warning[href]:hover {
background-color: #ec971f;
}
.label-danger {
background-color: #d9534f;
}
.label-danger[href]:hover, .label-danger[href]:focus {
.label-danger[href]:focus, .label-danger[href]:hover {
background-color: #c9302c;
}
@ -4031,7 +3927,7 @@ a.label:hover, a.label:focus {
margin-left: 3px;
}
a.badge:hover, a.badge:focus {
a.badge:focus, a.badge:hover {
color: #fff;
text-decoration: none;
cursor: pointer;
@ -4057,7 +3953,6 @@ a.badge:hover, a.badge:focus {
.jumbotron {
padding: 4rem 2rem;
}
.jumbotron-heading {
font-size: 4.5rem;
}
@ -4153,6 +4048,7 @@ a.badge:hover, a.badge:focus {
from {
background-position: 1 0;
}
to {
background-position: 0 0;
}
@ -4162,6 +4058,7 @@ a.badge:hover, a.badge:focus {
from {
background-position: 1 0;
}
to {
background-position: 0 0;
}
@ -4220,7 +4117,6 @@ a.badge:hover, a.badge:focus {
-webkit-box-shadow: inset 0 .1rem .1rem rgba(0, 0, 0, .1);
box-shadow: inset 0 .1rem .1rem rgba(0, 0, 0, .1);
}
.progress-bar {
display: inline-block;
height: 1;
@ -4229,14 +4125,12 @@ a.badge:hover, a.badge:focus {
border-top-left-radius: .25rem;
border-bottom-left-radius: .25rem;
}
.progress[width^="0"] {
min-width: 2rem;
color: #818a91;
background-color: transparent;
background-image: none;
}
.progress[width="100%"] {
border-top-right-radius: .25rem;
border-bottom-right-radius: .25rem;
@ -4410,33 +4304,33 @@ a.list-group-item {
a.list-group-item .list-group-item-heading {
color: #333;
}
a.list-group-item:hover, a.list-group-item:focus {
a.list-group-item:focus, a.list-group-item:hover {
color: #555;
text-decoration: none;
background-color: #f5f5f5;
}
.list-group-item.disabled, .list-group-item.disabled:hover, .list-group-item.disabled:focus {
.list-group-item.disabled, .list-group-item.disabled:focus, .list-group-item.disabled:hover {
color: #818a91;
cursor: not-allowed;
cursor: false;
background-color: #eceeef;
}
.list-group-item.disabled .list-group-item-heading, .list-group-item.disabled:hover .list-group-item-heading, .list-group-item.disabled:focus .list-group-item-heading {
.list-group-item.disabled .list-group-item-heading, .list-group-item.disabled:focus .list-group-item-heading, .list-group-item.disabled:hover .list-group-item-heading {
color: inherit;
}
.list-group-item.disabled .list-group-item-text, .list-group-item.disabled:hover .list-group-item-text, .list-group-item.disabled:focus .list-group-item-text {
.list-group-item.disabled .list-group-item-text, .list-group-item.disabled:focus .list-group-item-text, .list-group-item.disabled:hover .list-group-item-text {
color: #818a91;
}
.list-group-item.active, .list-group-item.active:hover, .list-group-item.active:focus {
.list-group-item.active, .list-group-item.active:focus, .list-group-item.active:hover {
z-index: 2;
color: #fff;
background-color: #0275d8;
border-color: #0275d8;
}
.list-group-item.active .list-group-item-heading, .list-group-item.active .list-group-item-heading > small, .list-group-item.active .list-group-item-heading > .small, .list-group-item.active:hover .list-group-item-heading, .list-group-item.active:hover .list-group-item-heading > small, .list-group-item.active:hover .list-group-item-heading > .small, .list-group-item.active:focus .list-group-item-heading, .list-group-item.active:focus .list-group-item-heading > small, .list-group-item.active:focus .list-group-item-heading > .small {
.list-group-item.active .list-group-item-heading, .list-group-item.active .list-group-item-heading > small, .list-group-item.active .list-group-item-heading > .small, .list-group-item.active:focus .list-group-item-heading, .list-group-item.active:focus .list-group-item-heading > small, .list-group-item.active:focus .list-group-item-heading > .small, .list-group-item.active:hover .list-group-item-heading, .list-group-item.active:hover .list-group-item-heading > small, .list-group-item.active:hover .list-group-item-heading > .small {
color: inherit;
}
.list-group-item.active .list-group-item-text, .list-group-item.active:hover .list-group-item-text, .list-group-item.active:focus .list-group-item-text {
.list-group-item.active .list-group-item-text, .list-group-item.active:focus .list-group-item-text, .list-group-item.active:hover .list-group-item-text {
color: #a8d6fe;
}
@ -4451,11 +4345,11 @@ a.list-group-item-state {
a.list-group-item-state .list-group-item-heading {
color: inherit;
}
a.list-group-item-state:hover, a.list-group-item-state:focus {
a.list-group-item-state:focus, a.list-group-item-state:hover {
color: #3c763d;
background-color: #d0e9c6;
}
a.list-group-item-state.active, a.list-group-item-state.active:hover, a.list-group-item-state.active:focus {
a.list-group-item-state.active, a.list-group-item-state.active:focus, a.list-group-item-state.active:hover {
color: #fff;
background-color: #3c763d;
border-color: #3c763d;
@ -4472,11 +4366,11 @@ a.list-group-item-state {
a.list-group-item-state .list-group-item-heading {
color: inherit;
}
a.list-group-item-state:hover, a.list-group-item-state:focus {
a.list-group-item-state:focus, a.list-group-item-state:hover {
color: #31708f;
background-color: #c4e3f3;
}
a.list-group-item-state.active, a.list-group-item-state.active:hover, a.list-group-item-state.active:focus {
a.list-group-item-state.active, a.list-group-item-state.active:focus, a.list-group-item-state.active:hover {
color: #fff;
background-color: #31708f;
border-color: #31708f;
@ -4493,11 +4387,11 @@ a.list-group-item-state {
a.list-group-item-state .list-group-item-heading {
color: inherit;
}
a.list-group-item-state:hover, a.list-group-item-state:focus {
a.list-group-item-state:focus, a.list-group-item-state:hover {
color: #8a6d3b;
background-color: #faf2cc;
}
a.list-group-item-state.active, a.list-group-item-state.active:hover, a.list-group-item-state.active:focus {
a.list-group-item-state.active, a.list-group-item-state.active:focus, a.list-group-item-state.active:hover {
color: #fff;
background-color: #8a6d3b;
border-color: #8a6d3b;
@ -4514,11 +4408,11 @@ a.list-group-item-state {
a.list-group-item-state .list-group-item-heading {
color: inherit;
}
a.list-group-item-state:hover, a.list-group-item-state:focus {
a.list-group-item-state:focus, a.list-group-item-state:hover {
color: #a94442;
background-color: #ebcccc;
}
a.list-group-item-state.active, a.list-group-item-state.active:hover, a.list-group-item-state.active:focus {
a.list-group-item-state.active, a.list-group-item-state.active:focus, a.list-group-item-state.active:hover {
color: #fff;
background-color: #a94442;
border-color: #a94442;
@ -4550,10 +4444,12 @@ a.list-group-item-state.active, a.list-group-item-state.active:hover, a.list-gro
height: 100%;
border: 0;
}
.embed-responsive.embed-responsive-16by9 {
.embed-responsive-16by9 {
padding-bottom: 56.25%;
}
.embed-responsive.embed-responsive-4by3 {
.embed-responsive-4by3 {
padding-bottom: 75%;
}
@ -4566,7 +4462,7 @@ a.list-group-item-state.active, a.list-group-item-state.active:hover, a.list-gro
text-shadow: 0 1px 0 #fff;
opacity: .2;
}
.close:hover, .close:focus {
.close:focus, .close:hover {
color: #000;
text-decoration: none;
cursor: pointer;
@ -4703,12 +4599,10 @@ button.close {
width: 600px;
margin: 30px auto;
}
.modal-content {
-webkit-box-shadow: 0 5px 15px rgba(0, 0, 0, .5);
box-shadow: 0 5px 15px rgba(0, 0, 0, .5);
}
.modal-sm {
width: 300px;
}
@ -5038,7 +4932,7 @@ button.close {
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#00000000', endColorstr='#80000000', GradientType=1);
background-repeat: repeat-x;
}
.carousel-control:hover, .carousel-control:focus {
.carousel-control:focus, .carousel-control:hover {
color: #fff;
text-decoration: none;
outline: 0;
@ -5088,7 +4982,7 @@ button.close {
margin: 1px;
text-indent: -999px;
cursor: pointer;
background-color: rgba(0, 0, 0, 0);
background-color: transparent;
border: 1px solid #fff;
border-radius: 10px;
}
@ -5128,13 +5022,11 @@ button.close {
.carousel-control .icon-next {
margin-right: -15px;
}
.carousel-caption {
right: 20%;
left: 20%;
padding-bottom: 30px;
}
.carousel-indicators {
bottom: 20px;
}
@ -5387,10 +5279,6 @@ a.bg-danger:hover {
display: none !important;
}
@-ms-viewport {
width: device-width;
}
.visible-print-block {
display: none !important;
}

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@ -15,2294 +15,4417 @@ if (typeof jQuery === 'undefined') {
}
}(jQuery);
/* ========================================================================
* Bootstrap: transition.js v3.3.2
* http://getbootstrap.com/javascript/#transitions
* ========================================================================
* Copyright 2011-2015 Twitter, Inc.
* Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
* ======================================================================== */
+function ($) {
'use strict';
// CSS TRANSITION SUPPORT (Shoutout: http://www.modernizr.com/)
// ============================================================
function transitionEnd() {
var el = document.createElement('bootstrap')
var transEndEventNames = {
WebkitTransition : 'webkitTransitionEnd',
MozTransition : 'transitionend',
OTransition : 'oTransitionEnd otransitionend',
transition : 'transitionend'
}
for (var name in transEndEventNames) {
if (el.style[name] !== undefined) {
return { end: transEndEventNames[name] }
}
}
return false // explicit for ie8 ( ._.)
}
// http://blog.alexmaccaw.com/css-transitions
$.fn.emulateTransitionEnd = function (duration) {
var called = false
var $el = this
$(this).one('bsTransitionEnd', function () { called = true })
var callback = function () { if (!called) $($el).trigger($.support.transition.end) }
setTimeout(callback, duration)
return this
}
$(function () {
$.support.transition = transitionEnd()
if (!$.support.transition) return
$.event.special.bsTransitionEnd = {
bindType: $.support.transition.end,
delegateType: $.support.transition.end,
handle: function (e) {
if ($(e.target).is(this)) return e.handleObj.handler.apply(this, arguments)
}
}
})
}(jQuery);
/* ========================================================================
* Bootstrap: alert.js v3.3.2
/** =======================================================================
* Bootstrap: util.js v4.0.0
* http://getbootstrap.com/javascript/#alerts
* ========================================================================
* Copyright 2011-2015 Twitter, Inc.
* Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
* ======================================================================== */
* ========================================================================
* @fileoverview - Bootstrap's private util helper. Adds private util
* helpers for things like accesibility and transitions. These methods are
* shared across all bootstrap plugins.
* ========================================================================
*/
'use strict';
+function ($) {
'use strict';
/**
* @type {Object}
*/
var Bootstrap = {}
// ALERT CLASS DEFINITION
// ======================
var dismiss = '[data-dismiss="alert"]'
var Alert = function (el) {
$(el).on('click', dismiss, this.close)
/**
* @const
* @type {string}
*/
Bootstrap.TRANSITION_END = 'bsTransitionEnd'
/**
* @const
* @type {Object}
*/
Bootstrap.TransitionEndEvent = {
'WebkitTransition' : 'webkitTransitionEnd',
'MozTransition' : 'transitionend',
'OTransition' : 'oTransitionEnd otransitionend',
'transition' : 'transitionend'
}
/**
* @param {Function} childConstructor
* @param {Function} parentConstructor
*/
Bootstrap.inherits = function(childConstructor, parentConstructor) {
/** @constructor */
function tempConstructor() {}
tempConstructor.prototype = parentConstructor.prototype
childConstructor.prototype = new tempConstructor()
/** @override */
childConstructor.prototype.constructor = childConstructor
}
/**
* @param {Element} element
* @return {string|null}
*/
Bootstrap.getSelectorFromElement = function (element) {
var selector = element.getAttribute('data-target')
if (!selector) {
selector = element.getAttribute('href') || ''
selector = /^#[a-z]/i.test(selector) ? selector : null
}
Alert.VERSION = '3.3.2'
Alert.TRANSITION_DURATION = 150
Alert.prototype.close = function (e) {
var $this = $(this)
var selector = $this.attr('data-target')
if (!selector) {
selector = $this.attr('href')
selector = selector && selector.replace(/.*(?=#[^\s]*$)/, '') // strip for ie7
}
var $parent = $(selector)
if (e) e.preventDefault()
if (!$parent.length) {
$parent = $this.closest('.alert')
}
$parent.trigger(e = $.Event('close.bs.alert'))
if (e.isDefaultPrevented()) return
$parent.removeClass('in')
function removeElement() {
// detach from parent, fire event then clean up data
$parent.detach().trigger('closed.bs.alert').remove()
}
$.support.transition && $parent.hasClass('fade') ?
$parent
.one('bsTransitionEnd', removeElement)
.emulateTransitionEnd(Alert.TRANSITION_DURATION) :
removeElement()
}
return selector
}
// ALERT PLUGIN DEFINITION
// =======================
/**
* @param {string} prefix
* @return {string}
*/
Bootstrap.getUID = function (prefix) {
do prefix += ~~(Math.random() * 1000000)
while (document.getElementById(prefix))
return prefix
}
function Plugin(option) {
return this.each(function () {
var $this = $(this)
var data = $this.data('bs.alert')
if (!data) $this.data('bs.alert', (data = new Alert(this)))
if (typeof option == 'string') data[option].call($this)
/**
* @return {Object}
*/
Bootstrap.getSpecialTransitionEndEvent = function () {
return {
bindType: Bootstrap.transition.end,
delegateType: Bootstrap.transition.end,
handle: /** @param {jQuery.Event} event */ (function (event) {
if ($(event.target).is(this)) {
return event.handleObj.handler.apply(this, arguments)
}
})
}
var old = $.fn.alert
$.fn.alert = Plugin
$.fn.alert.Constructor = Alert
}
// ALERT NO CONFLICT
// =================
/**
* @param {Element} element
*/
Bootstrap.reflow = function (element) {
new Function('bs',"return bs")(element.offsetHeight)
}
$.fn.alert.noConflict = function () {
$.fn.alert = old
return this
/**
* @return {Object|boolean}
*/
Bootstrap.transitionEndTest = function () {
if (window['QUnit']) {
return false
}
var el = document.createElement('bootstrap')
for (var name in Bootstrap.TransitionEndEvent) {
if (el.style[name] !== undefined) {
return { end: Bootstrap.TransitionEndEvent[name] }
}
}
return false
}
// ALERT DATA-API
// ==============
$(document).on('click.bs.alert.data-api', dismiss, Alert.prototype.close)
/**
* @param {number} duration
* @this {Element}
* @return {Object}
*/
Bootstrap.transitionEndEmulator = function (duration) {
var called = false
}(jQuery);
$(this).one(Bootstrap.TRANSITION_END, function () {
called = true
})
/* ========================================================================
* Bootstrap: button.js v3.3.2
var callback = function () {
if (!called) {
$(this).trigger(Bootstrap.transition.end)
}
}.bind(this)
setTimeout(callback, duration)
return this
}
/**
* ------------------------------------------------------------------------
* jQuery Interface
* ------------------------------------------------------------------------
*/
$.fn.emulateTransitionEnd = Bootstrap.transitionEndEmulator
$(function () {
Bootstrap.transition = Bootstrap.transitionEndTest()
if (!Bootstrap.transition) {
return
}
$.event.special[Bootstrap.TRANSITION_END] = Bootstrap.getSpecialTransitionEndEvent()
})
/** =======================================================================
* Bootstrap: alert.js v4.0.0
* http://getbootstrap.com/javascript/#alerts
* ========================================================================
* Copyright 2011-2015 Twitter, Inc.
* Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
* ========================================================================
* @fileoverview - Bootstrap's generic alert component. Add dismiss
* functionality to all alert messages with this plugin.
*
* Public Methods & Properties:
*
* + $.alert
* + $.alert.noConflict
* + $.alert.Constructor
* + $.alert.Constructor.VERSION
* + $.alert.Constructor.prototype.close
*
* ========================================================================
*/
'use strict';
/**
* Our Alert class.
* @param {Element=} opt_element
* @constructor
*/
var Alert = function (opt_element) {
if (opt_element) {
$(opt_element).on('click', Alert._DISMISS_SELECTOR, Alert._handleDismiss(this))
}
}
/**
* @const
* @type {string}
*/
Alert['VERSION'] = '4.0.0'
/**
* @const
* @type {string}
* @private
*/
Alert._NAME = 'alert'
/**
* @const
* @type {string}
* @private
*/
Alert._DATA_KEY = 'bs.alert'
/**
* @const
* @type {string}
* @private
*/
Alert._DISMISS_SELECTOR = '[data-dismiss="alert"]'
/**
* @const
* @type {number}
* @private
*/
Alert._TRANSITION_DURATION = 150
/**
* @const
* @type {Function}
* @private
*/
Alert._JQUERY_NO_CONFLICT = $.fn[Alert._NAME]
/**
* @const
* @enum {string}
* @private
*/
Alert._Event = {
CLOSE : 'close.bs.alert',
CLOSED : 'closed.bs.alert'
}
/**
* @const
* @enum {string}
* @private
*/
Alert._ClassName = {
ALERT : 'alert',
FADE : 'fade',
IN : 'in'
}
/**
* Provides the jQuery Interface for the alert component.
* @param {string=} opt_config
* @this {jQuery}
* @return {jQuery}
* @private
*/
Alert._jQueryInterface = function (opt_config) {
return this.each(function () {
var $this = $(this)
var data = $this.data(Alert._DATA_KEY)
if (!data) {
data = new Alert(this)
$this.data(Alert._DATA_KEY, data)
}
if (opt_config === 'close') {
data[opt_config](this)
}
})
}
/**
* Close the alert component
* @param {Alert} alertInstance
* @return {Function}
* @private
*/
Alert._handleDismiss = function (alertInstance) {
return function (event) {
if (event) {
event.preventDefault()
}
alertInstance['close'](this)
}
}
/**
* Close the alert component
* @param {Element} element
*/
Alert.prototype['close'] = function (element) {
var rootElement = this._getRootElement(element)
var customEvent = this._triggerCloseEvent(rootElement)
if (customEvent.isDefaultPrevented()) return
this._removeElement(rootElement)
}
/**
* Tries to get the alert's root element
* @return {Element}
* @private
*/
Alert.prototype._getRootElement = function (element) {
var parent = false
var selector = Bootstrap.getSelectorFromElement(element)
if (selector) {
parent = $(selector)[0]
}
if (!parent) {
parent = $(element).closest('.' + Alert._ClassName.ALERT)[0]
}
return parent
}
/**
* Trigger close event on element
* @return {$.Event}
* @private
*/
Alert.prototype._triggerCloseEvent = function (element) {
var closeEvent = $.Event(Alert._Event.CLOSE)
$(element).trigger(closeEvent)
return closeEvent
}
/**
* Trigger closed event and remove element from dom
* @private
*/
Alert.prototype._removeElement = function (element) {
$(element).removeClass(Alert._ClassName.IN)
if (!Bootstrap.transition || !$(element).hasClass(Alert._ClassName.FADE)) {
this._destroyElement(element)
return
}
$(element)
.one(Bootstrap.TRANSITION_END, this._destroyElement.bind(this, element))
.emulateTransitionEnd(Alert._TRANSITION_DURATION)
}
/**
* clean up any lingering jquery data and kill element
* @private
*/
Alert.prototype._destroyElement = function (element) {
$(element)
.detach()
.trigger(Alert._Event.CLOSED)
.remove()
}
/**
* ------------------------------------------------------------------------
* jQuery Interface + noConflict implementaiton
* ------------------------------------------------------------------------
*/
/**
* @const
* @type {Function}
*/
$.fn[Alert._NAME] = Alert._jQueryInterface
/**
* @const
* @type {Function}
*/
$.fn[Alert._NAME]['Constructor'] = Alert
/**
* @return {Function}
*/
$.fn[Alert._NAME]['noConflict'] = function () {
$.fn[Alert._NAME] = Alert._JQUERY_NO_CONFLICT
return Alert._jQueryInterface
}
/**
* ------------------------------------------------------------------------
* Data Api implementation
* ------------------------------------------------------------------------
*/
$(document).on('click.bs.alert.data-api', Alert._DISMISS_SELECTOR, Alert._handleDismiss(new Alert))
/** =======================================================================
* Bootstrap: button.js v4.0.0
* http://getbootstrap.com/javascript/#buttons
* ========================================================================
* Copyright 2011-2015 Twitter, Inc.
* Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
* ======================================================================== */
* ========================================================================
* @fileoverview - Bootstrap's generic button component.
*
* Note (@fat): Deprecated "setState" imo, better solutions for managing a
* buttons state should exist outside this plugin.
*
* Public Methods & Properties:
*
* + $.button
* + $.button.noConflict
* + $.button.Constructor
* + $.button.Constructor.VERSION
* + $.button.Constructor.prototype.toggle
*
* ========================================================================
*/
'use strict';
+function ($) {
'use strict';
/**
* Our Button class.
* @param {Element!} element
* @constructor
*/
var Button = function (element) {
// BUTTON PUBLIC CLASS DEFINITION
// ==============================
/** @private {Element} */
this._element = element
var Button = function (element, options) {
this.$element = $(element)
this.options = $.extend({}, Button.DEFAULTS, options)
this.isLoading = false
}
}
Button.VERSION = '3.3.2'
Button.DEFAULTS = {
loadingText: 'loading...'
}
/**
* @const
* @type {string}
*/
Button['VERSION'] = '4.0.0'
Button.prototype.setState = function (state) {
var d = 'disabled'
var $el = this.$element
var val = $el.is('input') ? 'val' : 'html'
var data = $el.data()
state = state + 'Text'
/**
* @const
* @type {string}
* @private
*/
Button._NAME = 'button'
if (data.resetText == null) $el.data('resetText', $el[val]())
// push to event loop to allow forms to submit
setTimeout($.proxy(function () {
$el[val](data[state] == null ? this.options[state] : data[state])
/**
* @const
* @type {string}
* @private
*/
Button._DATA_KEY = 'bs.button'
if (state == 'loadingText') {
this.isLoading = true
$el.addClass(d).attr(d, d)
} else if (this.isLoading) {
this.isLoading = false
$el.removeClass(d).removeAttr(d)
}
}, this), 0)
}
Button.prototype.toggle = function () {
var changed = true
var $parent = this.$element.closest('[data-toggle="buttons"]')
/**
* @const
* @type {Function}
* @private
*/
Button._JQUERY_NO_CONFLICT = $.fn[Button._NAME]
if ($parent.length) {
var $input = this.$element.find('input')
if ($input.prop('type') == 'radio') {
if ($input.prop('checked') && this.$element.hasClass('active')) changed = false
else $parent.find('.active').removeClass('active')
}
if (changed) $input.prop('checked', !this.$element.hasClass('active')).trigger('change')
} else {
this.$element.attr('aria-pressed', !this.$element.hasClass('active'))
/**
* @const
* @enum {string}
* @private
*/
Button._ClassName = {
ACTIVE : 'active',
BUTTON : 'btn',
FOCUS : 'focus'
}
/**
* @const
* @enum {string}
* @private
*/
Button._Selector = {
DATA_TOGGLE_CARROT : '[data-toggle^="button"]',
DATA_TOGGLE : '[data-toggle="buttons"]',
INPUT : 'input',
ACTIVE : '.active',
BUTTON : '.btn'
}
/**
* Provides the jQuery Interface for the Button component.
* @param {string=} opt_config
* @this {jQuery}
* @return {jQuery}
* @private
*/
Button._jQueryInterface = function (opt_config) {
return this.each(function () {
var data = $(this).data(Button._DATA_KEY)
if (!data) {
data = new Button(this)
$(this).data(Button._DATA_KEY, data)
}
if (changed) this.$element.toggleClass('active')
if (opt_config === 'toggle') {
data[opt_config]()
}
})
}
/**
* Toggle's the button active state
*/
Button.prototype['toggle'] = function () {
var triggerChangeEvent = true
var rootElement = $(this._element).closest(Button._Selector.DATA_TOGGLE)[0]
if (rootElement) {
var input = $(this._element).find(Button._Selector.INPUT)[0]
if (input) {
if (input.type == 'radio') {
if (input.checked && $(this._element).hasClass(Button._ClassName.ACTIVE)) {
triggerChangeEvent = false
} else {
var activeElement = $(rootElement).find(Button._Selector.ACTIVE)[0]
if (activeElement) {
$(activeElement).removeClass(Button._ClassName.ACTIVE)
}
}
}
if (triggerChangeEvent) {
input.checked = !$(this._element).hasClass(Button._ClassName.ACTIVE)
$(this._element).trigger('change')
}
}
} else {
this._element.setAttribute('aria-pressed', !$(this._element).hasClass(Button._ClassName.ACTIVE))
}
// BUTTON PLUGIN DEFINITION
// ========================
function Plugin(option) {
return this.each(function () {
var $this = $(this)
var data = $this.data('bs.button')
var options = typeof option == 'object' && option
if (!data) $this.data('bs.button', (data = new Button(this, options)))
if (option == 'toggle') data.toggle()
else if (option) data.setState(option)
})
if (triggerChangeEvent) {
$(this._element).toggleClass(Button._ClassName.ACTIVE)
}
var old = $.fn.button
$.fn.button = Plugin
$.fn.button.Constructor = Button
}
// BUTTON NO CONFLICT
// ==================
/**
* ------------------------------------------------------------------------
* jQuery Interface + noConflict implementaiton
* ------------------------------------------------------------------------
*/
$.fn.button.noConflict = function () {
$.fn.button = old
return this
}
/**
* @const
* @type {Function}
*/
$.fn[Button._NAME] = Button._jQueryInterface
// BUTTON DATA-API
// ===============
/**
* @const
* @type {Function}
*/
$.fn[Button._NAME]['Constructor'] = Button
$(document)
.on('click.bs.button.data-api', '[data-toggle^="button"]', function (e) {
var $btn = $(e.target)
if (!$btn.hasClass('btn')) $btn = $btn.closest('.btn')
Plugin.call($btn, 'toggle')
e.preventDefault()
})
.on('focus.bs.button.data-api blur.bs.button.data-api', '[data-toggle^="button"]', function (e) {
$(e.target).closest('.btn').toggleClass('focus', /^focus(in)?$/.test(e.type))
})
}(jQuery);
/**
* @const
* @type {Function}
*/
$.fn[Button._NAME]['noConflict'] = function () {
$.fn[Button._NAME] = Button._JQUERY_NO_CONFLICT
return this
}
/* ========================================================================
* Bootstrap: carousel.js v3.3.2
/**
* ------------------------------------------------------------------------
* Data Api implementation
* ------------------------------------------------------------------------
*/
$(document)
.on('click.bs.button.data-api', Button._Selector.DATA_TOGGLE_CARROT, function (event) {
event.preventDefault()
var button = event.target
if (!$(button).hasClass(Button._ClassName.BUTTON)) {
button = $(button).closest(Button._Selector.BUTTON)
}
Button._jQueryInterface.call($(button), 'toggle')
})
.on('focus.bs.button.data-api blur.bs.button.data-api', Button._Selector.DATA_TOGGLE_CARROT, function (event) {
var button = $(event.target).closest(Button._Selector.BUTTON)[0]
$(button).toggleClass(Button._ClassName.FOCUS, /^focus(in)?$/.test(event.type))
})
/** =======================================================================
* Bootstrap: carousel.js v4.0.0
* http://getbootstrap.com/javascript/#carousel
* ========================================================================
* Copyright 2011-2015 Twitter, Inc.
* Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
* ======================================================================== */
* ========================================================================
* @fileoverview - Bootstrap's carousel. A slideshow component for cycling
* through elements, like a carousel. Nested carousels are not supported.
*
* Public Methods & Properties:
*
* + $.carousel
* + $.carousel.noConflict
* + $.carousel.Constructor
* + $.carousel.Constructor.VERSION
* + $.carousel.Constructor.Defaults
* + $.carousel.Constructor.Defaults.interval
* + $.carousel.Constructor.Defaults.pause
* + $.carousel.Constructor.Defaults.wrap
* + $.carousel.Constructor.Defaults.keyboard
* + $.carousel.Constructor.Defaults.slide
* + $.carousel.Constructor.prototype.next
* + $.carousel.Constructor.prototype.prev
* + $.carousel.Constructor.prototype.pause
* + $.carousel.Constructor.prototype.cycle
*
* ========================================================================
*/
'use strict';
+function ($) {
'use strict';
/**
* Our carousel class.
* @param {Element!} element
* @param {Object=} opt_config
* @constructor
*/
var Carousel = function (element, opt_config) {
// CAROUSEL CLASS DEFINITION
// =========================
/** @private {Element} */
this._element = $(element)[0]
var Carousel = function (element, options) {
this.$element = $(element)
this.$indicators = this.$element.find('.carousel-indicators')
this.options = options
this.paused = null
this.sliding = null
this.interval = null
this.$active = null
this.$items = null
/** @private {Element} */
this._indicatorsElement = $(this._element).find(Carousel._Selector.INDICATORS)[0]
this.options.keyboard && this.$element.on('keydown.bs.carousel', $.proxy(this.keydown, this))
/** @private {?Object} */
this._config = opt_config || null
this.options.pause == 'hover' && !('ontouchstart' in document.documentElement) && this.$element
.on('mouseenter.bs.carousel', $.proxy(this.pause, this))
.on('mouseleave.bs.carousel', $.proxy(this.cycle, this))
}
/** @private {boolean} */
this._isPaused = false
Carousel.VERSION = '3.3.2'
/** @private {boolean} */
this._isSliding = false
Carousel.TRANSITION_DURATION = 600
/** @private {?number} */
this._interval = null
Carousel.DEFAULTS = {
interval: 5000,
pause: 'hover',
wrap: true,
keyboard: true
}
/** @private {?Element} */
this._activeElement = null
Carousel.prototype.keydown = function (e) {
if (/input|textarea/i.test(e.target.tagName)) return
switch (e.which) {
case 37: this.prev(); break
case 39: this.next(); break
default: return
/** @private {?Array} */
this._items = null
this._addEventListeners()
}
/**
* @const
* @type {string}
*/
Carousel['VERSION'] = '4.0.0'
/**
* @const
* @type {Object}
*/
Carousel['Defaults'] = {
'interval' : 5000,
'pause' : 'hover',
'wrap' : true,
'keyboard' : true,
'slide' : false
}
/**
* @const
* @type {string}
* @private
*/
Carousel._NAME = 'carousel'
/**
* @const
* @type {string}
* @private
*/
Carousel._DATA_KEY = 'bs.carousel'
/**
* @const
* @type {number}
* @private
*/
Carousel._TRANSITION_DURATION = 600
/**
* @const
* @enum {string}
* @private
*/
Carousel._Direction = {
NEXT : 'next',
PREVIOUS : 'prev'
}
/**
* @const
* @enum {string}
* @private
*/
Carousel._Event = {
SLIDE : 'slide.bs.carousel',
SLID : 'slid.bs.carousel'
}
/**
* @const
* @enum {string}
* @private
*/
Carousel._ClassName = {
CAROUSEL : 'carousel',
ACTIVE : 'active',
SLIDE : 'slide',
RIGHT : 'right',
LEFT : 'left',
ITEM : 'carousel-item'
}
/**
* @const
* @enum {string}
* @private
*/
Carousel._Selector = {
ACTIVE : '.active',
ACTIVE_ITEM : '.active.carousel-item',
ITEM : '.carousel-item',
NEXT_PREV : '.next, .prev',
INDICATORS : '.carousel-indicators'
}
/**
* @const
* @type {Function}
* @private
*/
Carousel._JQUERY_NO_CONFLICT = $.fn[Carousel._NAME]
/**
* @param {Object=} opt_config
* @this {jQuery}
* @return {jQuery}
* @private
*/
Carousel._jQueryInterface = function (opt_config) {
return this.each(function () {
var data = $(this).data(Carousel._DATA_KEY)
var config = $.extend({}, Carousel['Defaults'], $(this).data(), typeof opt_config == 'object' && opt_config)
var action = typeof opt_config == 'string' ? opt_config : config.slide
if (!data) {
data = new Carousel(this, config)
$(this).data(Carousel._DATA_KEY, data)
}
e.preventDefault()
}
if (typeof opt_config == 'number') {
data.to(opt_config)
Carousel.prototype.cycle = function (e) {
e || (this.paused = false)
} else if (action) {
data[action]()
this.interval && clearInterval(this.interval)
this.options.interval
&& !this.paused
&& (this.interval = setInterval($.proxy(this.next, this), this.options.interval))
return this
}
Carousel.prototype.getItemIndex = function (item) {
this.$items = item.parent().children('.carousel-item')
return this.$items.index(item || this.$active)
}
Carousel.prototype.getItemForDirection = function (direction, active) {
var activeIndex = this.getItemIndex(active)
var willWrap = (direction == 'prev' && activeIndex === 0)
|| (direction == 'next' && activeIndex == (this.$items.length - 1))
if (willWrap && !this.options.wrap) return active
var delta = direction == 'prev' ? -1 : 1
var itemIndex = (activeIndex + delta) % this.$items.length
return this.$items.eq(itemIndex)
}
Carousel.prototype.to = function (pos) {
var that = this
var activeIndex = this.getItemIndex(this.$active = this.$element.find('.carousel-item.active'))
if (pos > (this.$items.length - 1) || pos < 0) return
if (this.sliding) return this.$element.one('slid.bs.carousel', function () { that.to(pos) }) // yes, "slid"
if (activeIndex == pos) return this.pause().cycle()
return this.slide(pos > activeIndex ? 'next' : 'prev', this.$items.eq(pos))
}
Carousel.prototype.pause = function (e) {
e || (this.paused = true)
if (this.$element.find('.next, .prev').length && $.support.transition) {
this.$element.trigger($.support.transition.end)
this.cycle(true)
} else if (config.interval) {
data['pause']()
data['cycle']()
}
})
}
this.interval = clearInterval(this.interval)
return this
/**
* Click handler for data api
* @param {Event} event
* @this {Element}
* @private
*/
Carousel._dataApiClickHandler = function (event) {
var selector = Bootstrap.getSelectorFromElement(this)
if (!selector) {
return
}
Carousel.prototype.next = function () {
if (this.sliding) return
return this.slide('next')
var target = $(selector)[0]
if (!target || !$(target).hasClass(Carousel._ClassName.CAROUSEL)) {
return
}
Carousel.prototype.prev = function () {
if (this.sliding) return
return this.slide('prev')
var config = $.extend({}, $(target).data(), $(this).data())
var slideIndex = this.getAttribute('data-slide-to')
if (slideIndex) {
config.interval = false
}
Carousel.prototype.slide = function (type, next) {
var $active = this.$element.find('.carousel-item.active')
var $next = next || this.getItemForDirection(type, $active)
var isCycling = this.interval
var direction = type == 'next' ? 'left' : 'right'
var that = this
Carousel._jQueryInterface.call($(target), config)
if ($next.hasClass('active')) return (this.sliding = false)
var relatedTarget = $next[0]
var slideEvent = $.Event('slide.bs.carousel', {
relatedTarget: relatedTarget,
direction: direction
})
this.$element.trigger(slideEvent)
if (slideEvent.isDefaultPrevented()) return
this.sliding = true
isCycling && this.pause()
if (this.$indicators.length) {
this.$indicators.find('.active').removeClass('active')
var $nextIndicator = $(this.$indicators.children()[this.getItemIndex($next)])
$nextIndicator && $nextIndicator.addClass('active')
}
var slidEvent = $.Event('slid.bs.carousel', { relatedTarget: relatedTarget, direction: direction }) // yes, "slid"
if ($.support.transition && this.$element.hasClass('slide')) {
$next.addClass(type)
$next[0].offsetWidth // force reflow
$active.addClass(direction)
$next.addClass(direction)
$active
.one('bsTransitionEnd', function () {
$next.removeClass([type, direction].join(' ')).addClass('active')
$active.removeClass(['active', direction].join(' '))
that.sliding = false
setTimeout(function () {
that.$element.trigger(slidEvent)
}, 0)
})
.emulateTransitionEnd(Carousel.TRANSITION_DURATION)
} else {
$active.removeClass('active')
$next.addClass('active')
this.sliding = false
this.$element.trigger(slidEvent)
}
isCycling && this.cycle()
return this
if (slideIndex) {
$(target).data(Carousel._DATA_KEY).to(slideIndex)
}
event.preventDefault()
}
// CAROUSEL PLUGIN DEFINITION
// ==========================
function Plugin(option) {
return this.each(function () {
var $this = $(this)
var data = $this.data('bs.carousel')
var options = $.extend({}, Carousel.DEFAULTS, $this.data(), typeof option == 'object' && option)
var action = typeof option == 'string' ? option : options.slide
/**
* Advance the carousel to the next slide
*/
Carousel.prototype['next'] = function () {
if (!this._isSliding) {
this._slide(Carousel._Direction.NEXT)
}
}
if (!data) $this.data('bs.carousel', (data = new Carousel(this, options)))
if (typeof option == 'number') data.to(option)
else if (action) data[action]()
else if (options.interval) data.pause().cycle()
})
/**
* Return the carousel to the previous slide
*/
Carousel.prototype['prev'] = function () {
if (!this._isSliding) {
this._slide(Carousel._Direction.PREVIOUS)
}
}
/**
* Pause the carousel cycle
* @param {Event=} opt_event
*/
Carousel.prototype['pause'] = function (opt_event) {
if (!opt_event) {
this._isPaused = true
}
var old = $.fn.carousel
$.fn.carousel = Plugin
$.fn.carousel.Constructor = Carousel
// CAROUSEL NO CONFLICT
// ====================
$.fn.carousel.noConflict = function () {
$.fn.carousel = old
return this
if ($(this._element).find(Carousel._Selector.NEXT_PREV)[0] && Bootstrap.transition) {
$(this._element).trigger(Bootstrap.transition.end)
this['cycle'](true)
}
clearInterval(this._interval)
this._interval = null
}
// CAROUSEL DATA-API
// =================
var clickHandler = function (e) {
var href
var $this = $(this)
var $target = $($this.attr('data-target') || (href = $this.attr('href')) && href.replace(/.*(?=#[^\s]+$)/, '')) // strip for ie7
if (!$target.hasClass('carousel')) return
var options = $.extend({}, $target.data(), $this.data())
var slideIndex = $this.attr('data-slide-to')
if (slideIndex) options.interval = false
Plugin.call($target, options)
if (slideIndex) {
$target.data('bs.carousel').to(slideIndex)
}
e.preventDefault()
/**
* Cycle to the next carousel item
* @param {Event|boolean=} opt_event
*/
Carousel.prototype['cycle'] = function (opt_event) {
if (!opt_event) {
this._isPaused = false
}
$(document)
.on('click.bs.carousel.data-api', '[data-slide]', clickHandler)
.on('click.bs.carousel.data-api', '[data-slide-to]', clickHandler)
if (this._interval) {
clearInterval(this._interval)
this._interval = null
}
$(window).on('load', function () {
$('[data-ride="carousel"]').each(function () {
var $carousel = $(this)
Plugin.call($carousel, $carousel.data())
})
if (this._config['interval'] && !this._isPaused) {
this._interval = setInterval(this['next'].bind(this), this._config['interval'])
}
}
/**
* @return {Object}
*/
Carousel.prototype['getConfig'] = function () {
return this._config
}
/**
* Move active carousel item to specified index
* @param {number} index
*/
Carousel.prototype.to = function (index) {
this._activeElement = $(this._element).find(Carousel._Selector.ACTIVE_ITEM)[0]
var activeIndex = this._getItemIndex(this._activeElement)
if (index > (this._items.length - 1) || index < 0) {
return
}
if (this._isSliding) {
$(this._element).one(Carousel._Event.SLID, function () { this.to(index) }.bind(this))
return
}
if (activeIndex == index) {
this['pause']()
this['cycle']()
return
}
var direction = index > activeIndex ?
Carousel._Direction.NEXT :
Carousel._Direction.PREVIOUS
this._slide(direction, this._items[index])
}
/**
* Add event listeners to root element
* @private
*/
Carousel.prototype._addEventListeners = function () {
if (this._config['keyboard']) {
$(this._element).on('keydown.bs.carousel', this._keydown.bind(this))
}
if (this._config['pause'] == 'hover' && !('ontouchstart' in document.documentElement)) {
$(this._element)
.on('mouseenter.bs.carousel', this['pause'].bind(this))
.on('mouseleave.bs.carousel', this['cycle'].bind(this))
}
}
/**
* Keydown handler
* @param {Event} event
* @private
*/
Carousel.prototype._keydown = function (event) {
event.preventDefault()
if (/input|textarea/i.test(event.target.tagName)) return
switch (event.which) {
case 37: this['prev'](); break
case 39: this['next'](); break
default: return
}
}
/**
* Get item index
* @param {Element} element
* @return {number}
* @private
*/
Carousel.prototype._getItemIndex = function (element) {
this._items = $.makeArray($(element).parent().find(Carousel._Selector.ITEM))
return this._items.indexOf(element)
}
/**
* Get next displayed item based on direction
* @param {Carousel._Direction} direction
* @param {Element} activeElement
* @return {Element}
* @private
*/
Carousel.prototype._getItemByDirection = function (direction, activeElement) {
var activeIndex = this._getItemIndex(activeElement)
var isGoingToWrap = (direction === Carousel._Direction.PREVIOUS && activeIndex === 0) ||
(direction === Carousel._Direction.NEXT && activeIndex == (this._items.length - 1))
if (isGoingToWrap && !this._config['wrap']) {
return activeElement
}
var delta = direction == Carousel._Direction.PREVIOUS ? -1 : 1
var itemIndex = (activeIndex + delta) % this._items.length
return itemIndex === -1 ? this._items[this._items.length - 1] : this._items[itemIndex]
}
/**
* Trigger slide event on element
* @param {Element} relatedTarget
* @param {Carousel._ClassName} directionalClassname
* @return {$.Event}
* @private
*/
Carousel.prototype._triggerSlideEvent = function (relatedTarget, directionalClassname) {
var slideEvent = $.Event(Carousel._Event.SLIDE, {
relatedTarget: relatedTarget,
direction: directionalClassname
})
}(jQuery);
$(this._element).trigger(slideEvent)
/* ========================================================================
* Bootstrap: collapse.js v3.3.2
return slideEvent
}
/**
* Set the active indicator if available
* @param {Element} element
* @private
*/
Carousel.prototype._setActiveIndicatorElement = function (element) {
if (this._indicatorsElement) {
$(this._indicatorsElement)
.find(Carousel._Selector.ACTIVE)
.removeClass(Carousel._ClassName.ACTIVE)
var nextIndicator = this._indicatorsElement.children[this._getItemIndex(element)]
if (nextIndicator) {
$(nextIndicator).addClass(Carousel._ClassName.ACTIVE)
}
}
}
/**
* Slide the carousel element in a direction
* @param {Carousel._Direction} direction
* @param {Element=} opt_nextElement
*/
Carousel.prototype._slide = function (direction, opt_nextElement) {
var activeElement = $(this._element).find(Carousel._Selector.ACTIVE_ITEM)[0]
var nextElement = opt_nextElement || activeElement && this._getItemByDirection(direction, activeElement)
var isCycling = !!this._interval
var directionalClassName = direction == Carousel._Direction.NEXT ?
Carousel._ClassName.LEFT :
Carousel._ClassName.RIGHT
if (nextElement && $(nextElement).hasClass(Carousel._ClassName.ACTIVE)) {
this._isSliding = false
return
}
var slideEvent = this._triggerSlideEvent(nextElement, directionalClassName)
if (slideEvent.isDefaultPrevented()) {
return
}
if (!activeElement || !nextElement) {
// some weirdness is happening, so we bail (maybe throw exception here alerting user that they're dom is off
return
}
this._isSliding = true
if (isCycling) {
this['pause']()
}
this._setActiveIndicatorElement(nextElement)
var slidEvent = $.Event(Carousel._Event.SLID, { relatedTarget: nextElement, direction: directionalClassName })
if (Bootstrap.transition && $(this._element).hasClass(Carousel._ClassName.SLIDE)) {
$(nextElement).addClass(direction)
Bootstrap.reflow(nextElement)
$(activeElement).addClass(directionalClassName)
$(nextElement).addClass(directionalClassName)
$(activeElement)
.one(Bootstrap.TRANSITION_END, function () {
$(nextElement)
.removeClass(directionalClassName)
.removeClass(direction)
$(nextElement).addClass(Carousel._ClassName.ACTIVE)
$(activeElement)
.removeClass(Carousel._ClassName.ACTIVE)
.removeClass(direction)
.removeClass(directionalClassName)
this._isSliding = false
setTimeout(function () {
$(this._element).trigger(slidEvent)
}.bind(this), 0)
}.bind(this))
.emulateTransitionEnd(Carousel._TRANSITION_DURATION)
} else {
$(activeElement).removeClass(Carousel._ClassName.ACTIVE)
$(nextElement).addClass(Carousel._ClassName.ACTIVE)
this._isSliding = false
$(this._element).trigger(slidEvent)
}
if (isCycling) {
this['cycle']()
}
}
/**
* ------------------------------------------------------------------------
* jQuery Interface + noConflict implementaiton
* ------------------------------------------------------------------------
*/
/**
* @const
* @type {Function}
*/
$.fn[Carousel._NAME] = Carousel._jQueryInterface
/**
* @const
* @type {Function}
*/
$.fn[Carousel._NAME]['Constructor'] = Carousel
/**
* @const
* @type {Function}
*/
$.fn[Carousel._NAME]['noConflict'] = function () {
$.fn[Carousel._NAME] = Carousel._JQUERY_NO_CONFLICT
return this
}
/**
* ------------------------------------------------------------------------
* Data Api implementation
* ------------------------------------------------------------------------
*/
$(document)
.on('click.bs.carousel.data-api', '[data-slide], [data-slide-to]', Carousel._dataApiClickHandler)
$(window).on('load', function () {
$('[data-ride="carousel"]').each(function () {
var $carousel = $(this)
Carousel._jQueryInterface.call($carousel, /** @type {Object} */ ($carousel.data()))
})
})
/** =======================================================================
* Bootstrap: collapse.js v4.0.0
* http://getbootstrap.com/javascript/#collapse
* ========================================================================
* Copyright 2011-2015 Twitter, Inc.
* Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
* ======================================================================== */
* ========================================================================
* @fileoverview - Bootstrap's collapse plugin. Flexible support for
* collapsible components like accordions and navigation.
*
* Public Methods & Properties:
*
* + $.carousel
* + $.carousel.noConflict
* + $.carousel.Constructor
* + $.carousel.Constructor.VERSION
* + $.carousel.Constructor.Defaults
* + $.carousel.Constructor.Defaults.toggle
* + $.carousel.Constructor.Defaults.trigger
* + $.carousel.Constructor.Defaults.parent
* + $.carousel.Constructor.prototype.toggle
* + $.carousel.Constructor.prototype.show
* + $.carousel.Constructor.prototype.hide
*
* ========================================================================
*/
'use strict';
+function ($) {
'use strict';
/**
* Our collapse class.
* @param {Element!} element
* @param {Object=} opt_config
* @constructor
*/
var Collapse = function (element, opt_config) {
// COLLAPSE PUBLIC CLASS DEFINITION
// ================================
/** @private {Element} */
this._element = element
var Collapse = function (element, options) {
this.$element = $(element)
this.options = $.extend({}, Collapse.DEFAULTS, options)
this.$trigger = $(this.options.trigger).filter('[href="#' + element.id + '"], [data-target="#' + element.id + '"]')
this.transitioning = null
/** @private {Object} */
this._config = $.extend({}, Collapse['Defaults'], opt_config)
if (this.options.parent) {
this.$parent = this.getParent()
} else {
this.addAriaAndCollapsedClass(this.$element, this.$trigger)
}
/** @private {Element} */
this._trigger = typeof this._config['trigger'] == 'string' ?
$(this._config['trigger'])[0] : this._config['trigger']
if (this.options.toggle) this.toggle()
/** @private {boolean} */
this._isTransitioning = false
/** @private {?Element} */
this._parent = this._config['parent'] ? this._getParent() : null
if (!this._config['parent']) {
this._addAriaAndCollapsedClass(this._element, this._trigger)
}
Collapse.VERSION = '3.3.2'
Collapse.TRANSITION_DURATION = 350
Collapse.DEFAULTS = {
toggle: true,
trigger: '[data-toggle="collapse"]'
if (this._config['toggle']) {
this['toggle']()
}
Collapse.prototype.dimension = function () {
var hasWidth = this.$element.hasClass('width')
return hasWidth ? 'width' : 'height'
}
Collapse.prototype.show = function () {
if (this.transitioning || this.$element.hasClass('in')) return
var activesData
var actives = this.$parent && this.$parent.children('.panel').children('.in, .collapsing')
if (actives && actives.length) {
activesData = actives.data('bs.collapse')
if (activesData && activesData.transitioning) return
}
var startEvent = $.Event('show.bs.collapse')
this.$element.trigger(startEvent)
if (startEvent.isDefaultPrevented()) return
if (actives && actives.length) {
Plugin.call(actives, 'hide')
activesData || actives.data('bs.collapse', null)
}
var dimension = this.dimension()
this.$element
.removeClass('collapse')
.addClass('collapsing')[dimension](0)
.attr('aria-expanded', true)
this.$trigger
.removeClass('collapsed')
.attr('aria-expanded', true)
this.transitioning = 1
var complete = function () {
this.$element
.removeClass('collapsing')
.addClass('collapse in')[dimension]('')
this.transitioning = 0
this.$element
.trigger('shown.bs.collapse')
}
if (!$.support.transition) return complete.call(this)
var scrollSize = $.camelCase(['scroll', dimension].join('-'))
this.$element
.one('bsTransitionEnd', $.proxy(complete, this))
.emulateTransitionEnd(Collapse.TRANSITION_DURATION)[dimension](this.$element[0][scrollSize])
}
Collapse.prototype.hide = function () {
if (this.transitioning || !this.$element.hasClass('in')) return
var startEvent = $.Event('hide.bs.collapse')
this.$element.trigger(startEvent)
if (startEvent.isDefaultPrevented()) return
var dimension = this.dimension()
this.$element[dimension](this.$element[dimension]())[0].offsetHeight
this.$element
.addClass('collapsing')
.removeClass('collapse in')
.attr('aria-expanded', false)
this.$trigger
.addClass('collapsed')
.attr('aria-expanded', false)
this.transitioning = 1
var complete = function () {
this.transitioning = 0
this.$element
.removeClass('collapsing')
.addClass('collapse')
.trigger('hidden.bs.collapse')
}
if (!$.support.transition) return complete.call(this)
this.$element
[dimension](0)
.one('bsTransitionEnd', $.proxy(complete, this))
.emulateTransitionEnd(Collapse.TRANSITION_DURATION)
}
Collapse.prototype.toggle = function () {
this[this.$element.hasClass('in') ? 'hide' : 'show']()
}
Collapse.prototype.getParent = function () {
return $(this.options.parent)
.find('[data-toggle="collapse"][data-parent="' + this.options.parent + '"]')
.each($.proxy(function (i, element) {
var $element = $(element)
this.addAriaAndCollapsedClass(getTargetFromTrigger($element), $element)
}, this))
.end()
}
Collapse.prototype.addAriaAndCollapsedClass = function ($element, $trigger) {
var isOpen = $element.hasClass('in')
$element.attr('aria-expanded', isOpen)
$trigger
.toggleClass('collapsed', !isOpen)
.attr('aria-expanded', isOpen)
}
function getTargetFromTrigger($trigger) {
var href
var target = $trigger.attr('data-target')
|| (href = $trigger.attr('href')) && href.replace(/.*(?=#[^\s]+$)/, '') // strip for ie7
return $(target)
}
}
// COLLAPSE PLUGIN DEFINITION
// ==========================
function Plugin(option) {
return this.each(function () {
var $this = $(this)
var data = $this.data('bs.collapse')
var options = $.extend({}, Collapse.DEFAULTS, $this.data(), typeof option == 'object' && option)
if (!data && options.toggle && option == 'show') options.toggle = false
if (!data) $this.data('bs.collapse', (data = new Collapse(this, options)))
if (typeof option == 'string') data[option]()
})
}
var old = $.fn.collapse
$.fn.collapse = Plugin
$.fn.collapse.Constructor = Collapse
/**
* @const
* @type {string}
*/
Collapse['VERSION'] = '4.0.0'
// COLLAPSE NO CONFLICT
// ====================
$.fn.collapse.noConflict = function () {
$.fn.collapse = old
return this
}
/**
* @const
* @type {Object}
*/
Collapse['Defaults'] = {
'toggle' : true,
'trigger' : '[data-toggle="collapse"]',
'parent' : null
}
// COLLAPSE DATA-API
// =================
/**
* @const
* @type {string}
* @private
*/
Collapse._NAME = 'collapse'
$(document).on('click.bs.collapse.data-api', '[data-toggle="collapse"]', function (e) {
/**
* @const
* @type {string}
* @private
*/
Collapse._DATA_KEY = 'bs.collapse'
/**
* @const
* @type {number}
* @private
*/
Collapse._TRANSITION_DURATION = 600
/**
* @const
* @type {Function}
* @private
*/
Collapse._JQUERY_NO_CONFLICT = $.fn[Collapse._NAME]
/**
* @const
* @enum {string}
* @private
*/
Collapse._Event = {
SHOW : 'show.bs.collapse',
SHOWN : 'shown.bs.collapse',
HIDE : 'hide.bs.collapse',
HIDDEN : 'hidden.bs.collapse'
}
/**
* @const
* @enum {string}
* @private
*/
Collapse._ClassName = {
IN : 'in',
COLLAPSE : 'collapse',
COLLAPSING : 'collapsing',
COLLAPSED : 'collapsed'
}
/**
* @const
* @enum {string}
* @private
*/
Collapse._Dimension = {
WIDTH : 'width',
HEIGHT : 'height'
}
/**
* @const
* @enum {string}
* @private
*/
Collapse._Selector = {
ACTIVES : '.panel > .in, .panel > .collapsing'
}
/**
* Provides the jQuery Interface for the alert component.
* @param {Object|string=} opt_config
* @this {jQuery}
* @return {jQuery}
* @private
*/
Collapse._jQueryInterface = function (opt_config) {
return this.each(function () {
var $this = $(this)
var data = $this.data(Collapse._DATA_KEY)
var config = $.extend({}, Collapse['Defaults'], $this.data(), typeof opt_config == 'object' && opt_config)
if (!$this.attr('data-target')) e.preventDefault()
if (!data && config['toggle'] && opt_config == 'show') {
config['toggle'] = false
}
var $target = getTargetFromTrigger($this)
var data = $target.data('bs.collapse')
var option = data ? 'toggle' : $.extend({}, $this.data(), { trigger: this })
if (!data) {
data = new Collapse(this, config)
$this.data(Collapse._DATA_KEY, data)
}
Plugin.call($target, option)
if (typeof opt_config == 'string') {
data[opt_config]()
}
})
}
}(jQuery);
/* ========================================================================
* Bootstrap: dropdown.js v3.3.2
* http://getbootstrap.com/javascript/#dropdowns
/**
* Function for getting target element from element
* @return {Element}
* @private
*/
Collapse._getTargetFromElement = function (element) {
var selector = Bootstrap.getSelectorFromElement(element)
return selector ? $(selector)[0] : null
}
/**
* Toggles the collapse element based on the presence of the 'in' class
*/
Collapse.prototype['toggle'] = function () {
if ($(this._element).hasClass(Collapse._ClassName.IN)) {
this['hide']()
} else {
this['show']()
}
}
/**
* Show's the collapsing element
*/
Collapse.prototype['show'] = function () {
if (this._isTransitioning || $(this._element).hasClass(Collapse._ClassName.IN)) {
return
}
var activesData, actives
if (this._parent) {
actives = $.makeArray($(Collapse._Selector.ACTIVES))
if (!actives.length) {
actives = null
}
}
if (actives) {
activesData = $(actives).data(Collapse._DATA_KEY)
if (activesData && activesData._isTransitioning) {
return
}
}
var startEvent = $.Event(Collapse._Event.SHOW)
$(this._element).trigger(startEvent)
if (startEvent.isDefaultPrevented()) {
return
}
if (actives) {
Collapse._jQueryInterface.call($(actives), 'hide')
if (!activesData) {
$(actives).data(Collapse._DATA_KEY, null)
}
}
var dimension = this._getDimension()
$(this._element)
.removeClass(Collapse._ClassName.COLLAPSE)
.addClass(Collapse._ClassName.COLLAPSING)
this._element.style[dimension] = 0
this._element.setAttribute('aria-expanded', true)
if (this._trigger) {
$(this._trigger).removeClass(Collapse._ClassName.COLLAPSED)
this._trigger.setAttribute('aria-expanded', true)
}
this['setTransitioning'](true)
var complete = function () {
$(this._element)
.removeClass(Collapse._ClassName.COLLAPSING)
.addClass(Collapse._ClassName.COLLAPSE)
.addClass(Collapse._ClassName.IN)
this._element.style[dimension] = ''
this['setTransitioning'](false)
$(this._element).trigger(Collapse._Event.SHOWN)
}.bind(this)
if (!Bootstrap.transition) {
complete()
return
}
var scrollSize = 'scroll' + (dimension[0].toUpperCase() + dimension.slice(1))
$(this._element)
.one(Bootstrap.TRANSITION_END, complete)
.emulateTransitionEnd(Collapse._TRANSITION_DURATION)
this._element.style[dimension] = this._element[scrollSize] + 'px'
}
/**
* Hides's the collapsing element
*/
Collapse.prototype['hide'] = function () {
if (this._isTransitioning || !$(this._element).hasClass(Collapse._ClassName.IN)) {
return
}
var startEvent = $.Event(Collapse._Event.HIDE)
$(this._element).trigger(startEvent)
if (startEvent.isDefaultPrevented()) return
var dimension = this._getDimension()
var offsetDimension = dimension === Collapse._Dimension.WIDTH ?
'offsetWidth' : 'offsetHeight'
this._element.style[dimension] = this._element[offsetDimension] + 'px'
Bootstrap.reflow(this._element)
$(this._element)
.addClass(Collapse._ClassName.COLLAPSING)
.removeClass(Collapse._ClassName.COLLAPSE)
.removeClass(Collapse._ClassName.IN)
this._element.setAttribute('aria-expanded', false)
if (this._trigger) {
$(this._trigger).addClass(Collapse._ClassName.COLLAPSED)
this._trigger.setAttribute('aria-expanded', false)
}
this['setTransitioning'](true)
var complete = function () {
this['setTransitioning'](false)
$(this._element)
.removeClass(Collapse._ClassName.COLLAPSING)
.addClass(Collapse._ClassName.COLLAPSE)
.trigger(Collapse._Event.HIDDEN)
}.bind(this)
this._element.style[dimension] = 0
if (!Bootstrap.transition) {
return complete()
}
$(this._element)
.one(Bootstrap.TRANSITION_END, complete)
.emulateTransitionEnd(Collapse._TRANSITION_DURATION)
}
/**
* @param {boolean} isTransitioning
*/
Collapse.prototype['setTransitioning'] = function (isTransitioning) {
this._isTransitioning = isTransitioning
}
/**
* Returns the collapsing dimension
* @return {string}
* @private
*/
Collapse.prototype._getDimension = function () {
var hasWidth = $(this._element).hasClass(Collapse._Dimension.WIDTH)
return hasWidth ? Collapse._Dimension.WIDTH : Collapse._Dimension.HEIGHT
}
/**
* Returns the parent element
* @return {Element}
* @private
*/
Collapse.prototype._getParent = function () {
var selector = '[data-toggle="collapse"][data-parent="' + this._config['parent'] + '"]'
var parent = $(this._config['parent'])[0]
var elements = /** @type {Array.<Element>} */ ($.makeArray($(parent).find(selector)))
for (var i = 0; i < elements.length; i++) {
this._addAriaAndCollapsedClass(Collapse._getTargetFromElement(elements[i]), elements[i])
}
return parent
}
/**
* Returns the parent element
* @param {Element} element
* @param {Element} trigger
* @private
*/
Collapse.prototype._addAriaAndCollapsedClass = function (element, trigger) {
if (element) {
var isOpen = $(element).hasClass(Collapse._ClassName.IN)
element.setAttribute('aria-expanded', isOpen)
if (trigger) {
trigger.setAttribute('aria-expanded', isOpen)
$(trigger).toggleClass(Collapse._ClassName.COLLAPSED, !isOpen)
}
}
}
/**
* ------------------------------------------------------------------------
* jQuery Interface + noConflict implementaiton
* ------------------------------------------------------------------------
*/
/**
* @const
* @type {Function}
*/
$.fn[Collapse._NAME] = Collapse._jQueryInterface
/**
* @const
* @type {Function}
*/
$.fn[Collapse._NAME]['Constructor'] = Collapse
/**
* @const
* @type {Function}
*/
$.fn[Collapse._NAME]['noConflict'] = function () {
$.fn[Collapse._NAME] = Collapse._JQUERY_NO_CONFLICT
return this
}
/**
* ------------------------------------------------------------------------
* Data Api implementation
* ------------------------------------------------------------------------
*/
$(document).on('click.bs.collapse.data-api', '[data-toggle="collapse"]', function (event) {
event.preventDefault()
var target = Collapse._getTargetFromElement(this)
var data = $(target).data(Collapse._DATA_KEY)
var config = data ? 'toggle' : $.extend({}, $(this).data(), { trigger: this })
Collapse._jQueryInterface.call($(target), config)
})
/** =======================================================================
* Bootstrap: dropdown.js v4.0.0
* http://getbootstrap.com/javascript/#dropdown
* ========================================================================
* Copyright 2011-2015 Twitter, Inc.
* Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
* ======================================================================== */
* ========================================================================
* @fileoverview - Add dropdown menus to nearly anything with this simple
* plugin, including the navbar, tabs, and pills.
*
* Public Methods & Properties:
*
* + $.dropdown
* + $.dropdown.noConflict
* + $.dropdown.Constructor
* + $.dropdown.Constructor.VERSION
* + $.dropdown.Constructor.prototype.toggle
*
* ========================================================================
*/
'use strict';
+function ($) {
'use strict';
/**
* Our dropdown class.
* @param {Element!} element
* @constructor
*/
var Dropdown = function (element) {
$(element).on('click.bs.dropdown', this['toggle'])
}
// DROPDOWN CLASS DEFINITION
// =========================
var backdrop = '.dropdown-backdrop'
var toggle = '[data-toggle="dropdown"]'
var Dropdown = function (element) {
$(element).on('click.bs.dropdown', this.toggle)
}
/**
* @const
* @type {string}
*/
Dropdown['VERSION'] = '4.0.0'
Dropdown.VERSION = '3.3.2'
Dropdown.prototype.toggle = function (e) {
var $this = $(this)
/**
* @const
* @type {string}
* @private
*/
Dropdown._NAME = 'dropdown'
if ($this.is('.disabled, :disabled')) return
var $parent = getParent($this)
var isActive = $parent.hasClass('open')
/**
* @const
* @type {string}
* @private
*/
Dropdown._DATA_KEY = 'bs.dropdown'
clearMenus()
if (!isActive) {
if ('ontouchstart' in document.documentElement && !$parent.closest('.navbar-nav').length) {
// if mobile we use a backdrop because click events don't delegate
$('<div class="dropdown-backdrop"/>').insertAfter($(this)).on('click', clearMenus)
}
/**
* @const
* @type {Function}
* @private
*/
Dropdown._JQUERY_NO_CONFLICT = $.fn[Dropdown._NAME]
var relatedTarget = { relatedTarget: this }
$parent.trigger(e = $.Event('show.bs.dropdown', relatedTarget))
if (e.isDefaultPrevented()) return
/**
* @const
* @enum {string}
* @private
*/
Dropdown._Event = {
HIDE : 'hide.bs.dropdown',
HIDDEN : 'hidden.bs.dropdown',
SHOW : 'show.bs.dropdown',
SHOWN : 'shown.bs.dropdown'
}
$this
.trigger('focus')
.attr('aria-expanded', 'true')
$parent
.toggleClass('open')
.trigger('shown.bs.dropdown', relatedTarget)
/**
* @const
* @enum {string}
* @private
*/
Dropdown._ClassName = {
BACKDROP : 'dropdown-backdrop',
DISABLED : 'disabled',
OPEN : 'open'
}
/**
* @const
* @enum {string}
* @private
*/
Dropdown._Selector = {
BACKDROP : '.dropdown-backdrop',
DATA_TOGGLE : '[data-toggle="dropdown"]',
FORM_CHILD : '.dropdown form',
ROLE_MENU : '[role="menu"]',
ROLE_LISTBOX : '[role="listbox"]',
NAVBAR_NAV : '.navbar-nav',
VISIBLE_ITEMS : '[role="menu"] li:not(.divider) a, [role="listbox"] li:not(.divider) a'
}
/**
* Provides the jQuery Interface for the alert component.
* @param {string=} opt_config
* @this {jQuery}
* @return {jQuery}
* @private
*/
Dropdown._jQueryInterface = function (opt_config) {
return this.each(function () {
var data = $(this).data(Dropdown._DATA_KEY)
if (!data) {
$(this).data(Dropdown._DATA_KEY, (data = new Dropdown(this)))
}
if (typeof opt_config === 'string') {
data[opt_config].call(this)
}
})
}
/**
* @param {Event=} opt_event
* @private
*/
Dropdown._clearMenus = function (opt_event) {
if (opt_event && opt_event.which == 3) {
return
}
var backdrop = $(Dropdown._Selector.BACKDROP)[0]
if (backdrop) {
backdrop.parentNode.removeChild(backdrop)
}
var toggles = /** @type {Array.<Element>} */ ($.makeArray($(Dropdown._Selector.DATA_TOGGLE)))
for (var i = 0; i < toggles.length; i++) {
var parent = Dropdown._getParentFromElement(toggles[i])
var relatedTarget = { 'relatedTarget': toggles[i] }
if (!$(parent).hasClass(Dropdown._ClassName.OPEN)) {
continue
}
var hideEvent = $.Event(Dropdown._Event.HIDE, relatedTarget)
$(parent).trigger(hideEvent)
if (hideEvent.isDefaultPrevented()) {
continue
}
toggles[i].setAttribute('aria-expanded', 'false')
$(parent)
.removeClass(Dropdown._ClassName.OPEN)
.trigger(Dropdown._Event.HIDDEN, relatedTarget)
}
}
/**
* @param {Element} element
* @return {Element}
* @private
*/
Dropdown._getParentFromElement = function (element) {
var selector = Bootstrap.getSelectorFromElement(element)
if (selector) {
var parent = $(selector)[0]
}
return /** @type {Element} */ (parent || element.parentNode)
}
/**
* @param {Event} event
* @this {Element}
* @private
*/
Dropdown._dataApiKeydownHandler = function (event) {
if (!/(38|40|27|32)/.test(event.which) || /input|textarea/i.test(event.target.tagName)) {
return
}
event.preventDefault()
event.stopPropagation()
if (this.disabled || $(this).hasClass(Dropdown._ClassName.DISABLED)) {
return
}
var parent = Dropdown._getParentFromElement(this)
var isActive = $(parent).hasClass(Dropdown._ClassName.OPEN)
if ((!isActive && event.which != 27) || (isActive && event.which == 27)) {
if (event.which == 27) {
var toggle = $(parent).find(Dropdown._Selector.DATA_TOGGLE)[0]
$(toggle).trigger('focus')
}
$(this).trigger('click')
return
}
var items = $.makeArray($(Dropdown._Selector.VISIBLE_ITEMS))
items = items.filter(function (item) {
return item.offsetWidth || item.offsetHeight
})
if (!items.length) {
return
}
var index = items.indexOf(event.target)
if (event.which == 38 && index > 0) index-- // up
if (event.which == 40 && index < items.length - 1) index++ // down
if (!~index) index = 0
items[index].focus()
}
/**
* Toggles the dropdown
* @this {Element}
* @return {boolean|undefined}
*/
Dropdown.prototype['toggle'] = function () {
if (this.disabled || $(this).hasClass(Dropdown._ClassName.DISABLED)) {
return
}
var parent = Dropdown._getParentFromElement(this)
var isActive = $(parent).hasClass(Dropdown._ClassName.OPEN)
Dropdown._clearMenus()
if (isActive) {
return false
}
Dropdown.prototype.keydown = function (e) {
if (!/(38|40|27|32)/.test(e.which) || /input|textarea/i.test(e.target.tagName)) return
var $this = $(this)
e.preventDefault()
e.stopPropagation()
if ($this.is('.disabled, :disabled')) return
var $parent = getParent($this)
var isActive = $parent.hasClass('open')
if ((!isActive && e.which != 27) || (isActive && e.which == 27)) {
if (e.which == 27) $parent.find(toggle).trigger('focus')
return $this.trigger('click')
}
var desc = ' li:not(.disabled):visible a'
var $items = $parent.find('[role="menu"]' + desc + ', [role="listbox"]' + desc)
if (!$items.length) return
var index = $items.index(e.target)
if (e.which == 38 && index > 0) index-- // up
if (e.which == 40 && index < $items.length - 1) index++ // down
if (!~index) index = 0
$items.eq(index).trigger('focus')
if ('ontouchstart' in document.documentElement && !$(parent).closest(Dropdown._Selector.NAVBAR_NAV).length) {
// if mobile we use a backdrop because click events don't delegate
var dropdown = document.createElement('div')
dropdown.className = Dropdown._ClassName.BACKDROP
this.parentNode.insertBefore(this, dropdown)
$(dropdown).on('click', Dropdown._clearMenus)
}
function clearMenus(e) {
if (e && e.which === 3) return
$(backdrop).remove()
$(toggle).each(function () {
var $this = $(this)
var $parent = getParent($this)
var relatedTarget = { relatedTarget: this }
var relatedTarget = { 'relatedTarget': this }
var showEvent = $.Event(Dropdown._Event.SHOW, relatedTarget)
if (!$parent.hasClass('open')) return
$(parent).trigger(showEvent)
$parent.trigger(e = $.Event('hide.bs.dropdown', relatedTarget))
if (e.isDefaultPrevented()) return
$this.attr('aria-expanded', 'false')
$parent.removeClass('open').trigger('hidden.bs.dropdown', relatedTarget)
})
if (showEvent.isDefaultPrevented()) {
return
}
function getParent($this) {
var selector = $this.attr('data-target')
this.focus()
this.setAttribute('aria-expanded', 'true')
if (!selector) {
selector = $this.attr('href')
selector = selector && /#[A-Za-z]/.test(selector) && selector.replace(/.*(?=#[^\s]*$)/, '') // strip for ie7
}
$(parent).toggleClass(Dropdown._ClassName.OPEN)
var $parent = selector && $(selector)
$(parent).trigger(Dropdown._Event.SHOWN, relatedTarget)
return $parent && $parent.length ? $parent : $this.parent()
}
return false
}
// DROPDOWN PLUGIN DEFINITION
// ==========================
/**
* ------------------------------------------------------------------------
* jQuery Interface + noConflict implementaiton
* ------------------------------------------------------------------------
*/
function Plugin(option) {
return this.each(function () {
var $this = $(this)
var data = $this.data('bs.dropdown')
if (!data) $this.data('bs.dropdown', (data = new Dropdown(this)))
if (typeof option == 'string') data[option].call($this)
})
}
var old = $.fn.dropdown
$.fn.dropdown = Plugin
$.fn.dropdown.Constructor = Dropdown
/**
* @const
* @type {Function}
*/
$.fn[Dropdown._NAME] = Dropdown._jQueryInterface
// DROPDOWN NO CONFLICT
// ====================
$.fn.dropdown.noConflict = function () {
$.fn.dropdown = old
return this
}
/**
* @const
* @type {Function}
*/
$.fn[Dropdown._NAME]['Constructor'] = Dropdown
// APPLY TO STANDARD DROPDOWN ELEMENTS
// ===================================
/**
* @const
* @type {Function}
*/
$.fn[Dropdown._NAME]['noConflict'] = function () {
$.fn[Dropdown._NAME] = Dropdown._JQUERY_NO_CONFLICT
return this
}
$(document)
.on('click.bs.dropdown.data-api', clearMenus)
.on('click.bs.dropdown.data-api', '.dropdown form', function (e) { e.stopPropagation() })
.on('click.bs.dropdown.data-api', toggle, Dropdown.prototype.toggle)
.on('keydown.bs.dropdown.data-api', toggle, Dropdown.prototype.keydown)
.on('keydown.bs.dropdown.data-api', '[role="menu"]', Dropdown.prototype.keydown)
.on('keydown.bs.dropdown.data-api', '[role="listbox"]', Dropdown.prototype.keydown)
}(jQuery);
/**
* ------------------------------------------------------------------------
* Data Api implementation
* ------------------------------------------------------------------------
*/
/* ========================================================================
* Bootstrap: modal.js v3.3.2
* http://getbootstrap.com/javascript/#modals
$(document)
.on('click.bs.dropdown.data-api', Dropdown._clearMenus)
.on('click.bs.dropdown.data-api', Dropdown._Selector.FORM_CHILD, function (e) { e.stopPropagation() })
.on('click.bs.dropdown.data-api', Dropdown._Selector.DATA_TOGGLE, Dropdown.prototype['toggle'])
.on('keydown.bs.dropdown.data-api', Dropdown._Selector.DATA_TOGGLE, Dropdown._dataApiKeydownHandler)
.on('keydown.bs.dropdown.data-api', Dropdown._Selector.ROLE_MENU, Dropdown._dataApiKeydownHandler)
.on('keydown.bs.dropdown.data-api', Dropdown._Selector.ROLE_LISTBOX, Dropdown._dataApiKeydownHandler)
/** =======================================================================
* Bootstrap: modal.js v4.0.0
* http://getbootstrap.com/javascript/#modal
* ========================================================================
* Copyright 2011-2015 Twitter, Inc.
* Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
* ======================================================================== */
* ========================================================================
* @fileoverview - Bootstrap's modal plugin. Modals are streamlined, but
* flexible, dialog prompts with the minimum required functionality and
* smart defaults.
*
* Public Methods & Properties:
*
* + $.modal
* + $.modal.noConflict
* + $.modal.Constructor
* + $.modal.Constructor.VERSION
* + $.modal.Constructor.Defaults
* + $.modal.Constructor.Defaults.backdrop
* + $.modal.Constructor.Defaults.keyboard
* + $.modal.Constructor.Defaults.show
* + $.modal.Constructor.prototype.toggle
* + $.modal.Constructor.prototype.show
* + $.modal.Constructor.prototype.hide
*
* ========================================================================
*/
'use strict';
+function ($) {
'use strict';
/**
* Our modal class.
* @param {Element} element
* @param {Object} config
* @constructor
*/
var Modal = function (element, config) {
// MODAL CLASS DEFINITION
// ======================
/** @private {Object} */
this._config = config
var Modal = function (element, options) {
this.options = options
this.$body = $(document.body)
this.$element = $(element)
this.$backdrop = null
this.isShown = null
this.originalBodyPad = null
this.scrollbarWidth = 0
/** @private {Element} */
this._element = element
if (this.options.remote) {
this.$element
.find('.modal-content')
.load(this.options.remote, $.proxy(function () {
this.$element.trigger('loaded.bs.modal')
}, this))
/** @private {Element} */
this._backdrop = null
/** @private {boolean} */
this._isShown = false
/** @private {boolean} */
this._isBodyOverflowing = false
/** @private {number} */
this._scrollbarWidth = 0
}
/**
* @const
* @type {string}
*/
Modal['VERSION'] = '4.0.0'
/**
* @const
* @type {Object}
*/
Modal['Defaults'] = {
'backdrop' : true,
'keyboard' : true,
'show' : true
}
/**
* @const
* @type {string}
* @private
*/
Modal._NAME = 'modal'
/**
* @const
* @type {string}
* @private
*/
Modal._DATA_KEY = 'bs.modal'
/**
* @const
* @type {number}
* @private
*/
Modal._TRANSITION_DURATION = 300
/**
* @const
* @type {number}
* @private
*/
Modal._BACKDROP_TRANSITION_DURATION = 150
/**
* @const
* @type {Function}
* @private
*/
Modal._JQUERY_NO_CONFLICT = $.fn[Modal._NAME]
/**
* @const
* @enum {string}
* @private
*/
Modal._Event = {
HIDE : 'hide.bs.modal',
HIDDEN : 'hidden.bs.modal',
SHOW : 'show.bs.modal',
SHOWN : 'shown.bs.modal'
}
/**
* @const
* @enum {string}
* @private
*/
Modal._ClassName = {
BACKDROP : 'modal-backdrop',
OPEN : 'modal-open',
FADE : 'fade',
IN : 'in'
}
/**
* @const
* @enum {string}
* @private
*/
Modal._Selector = {
DIALOG : '.modal-dialog',
DATA_TOGGLE : '[data-toggle="modal"]',
DATA_DISMISS : '[data-dismiss="modal"]',
SCROLLBAR_MEASURER : 'modal-scrollbar-measure'
}
/**
* Provides the jQuery Interface for the alert component.
* @param {Object|string=} opt_config
* @param {Element=} opt_relatedTarget
* @this {jQuery}
* @return {jQuery}
* @private
*/
Modal._jQueryInterface = function Plugin(opt_config, opt_relatedTarget) {
return this.each(function () {
var data = $(this).data(Modal._DATA_KEY)
var config = $.extend({}, Modal['Defaults'], $(this).data(), typeof opt_config == 'object' && opt_config)
if (!data) {
data = new Modal(this, config)
$(this).data(Modal._DATA_KEY, data)
}
}
Modal.VERSION = '3.3.2'
if (typeof opt_config == 'string') {
data[opt_config](opt_relatedTarget)
Modal.TRANSITION_DURATION = 300
Modal.BACKDROP_TRANSITION_DURATION = 150
Modal.DEFAULTS = {
backdrop: true,
keyboard: true,
show: true
}
Modal.prototype.toggle = function (_relatedTarget) {
return this.isShown ? this.hide() : this.show(_relatedTarget)
}
Modal.prototype.show = function (_relatedTarget) {
var that = this
var e = $.Event('show.bs.modal', { relatedTarget: _relatedTarget })
this.$element.trigger(e)
if (this.isShown || e.isDefaultPrevented()) return
this.isShown = true
this.checkScrollbar()
this.setScrollbar()
this.$body.addClass('modal-open')
this.escape()
this.resize()
this.$element.on('click.dismiss.bs.modal', '[data-dismiss="modal"]', $.proxy(this.hide, this))
this.backdrop(function () {
var transition = $.support.transition && that.$element.hasClass('fade')
if (!that.$element.parent().length) {
that.$element.appendTo(that.$body) // don't move modals dom position
}
that.$element
.show()
.scrollTop(0)
if (that.options.backdrop) that.adjustBackdrop()
that.adjustDialog()
if (transition) {
that.$element[0].offsetWidth // force reflow
}
that.$element
.addClass('in')
.attr('aria-hidden', false)
that.enforceFocus()
var e = $.Event('shown.bs.modal', { relatedTarget: _relatedTarget })
transition ?
that.$element.find('.modal-dialog') // wait for modal to slide in
.one('bsTransitionEnd', function () {
that.$element.trigger('focus').trigger(e)
})
.emulateTransitionEnd(Modal.TRANSITION_DURATION) :
that.$element.trigger('focus').trigger(e)
})
}
Modal.prototype.hide = function (e) {
if (e) e.preventDefault()
e = $.Event('hide.bs.modal')
this.$element.trigger(e)
if (!this.isShown || e.isDefaultPrevented()) return
this.isShown = false
this.escape()
this.resize()
$(document).off('focusin.bs.modal')
this.$element
.removeClass('in')
.attr('aria-hidden', true)
.off('click.dismiss.bs.modal')
$.support.transition && this.$element.hasClass('fade') ?
this.$element
.one('bsTransitionEnd', $.proxy(this.hideModal, this))
.emulateTransitionEnd(Modal.TRANSITION_DURATION) :
this.hideModal()
}
Modal.prototype.enforceFocus = function () {
$(document)
.off('focusin.bs.modal') // guard against infinite focus loop
.on('focusin.bs.modal', $.proxy(function (e) {
if (this.$element[0] !== e.target && !this.$element.has(e.target).length) {
this.$element.trigger('focus')
}
}, this))
}
Modal.prototype.escape = function () {
if (this.isShown && this.options.keyboard) {
this.$element.on('keydown.dismiss.bs.modal', $.proxy(function (e) {
e.which == 27 && this.hide()
}, this))
} else if (!this.isShown) {
this.$element.off('keydown.dismiss.bs.modal')
} else if (config['show']) {
data['show'](opt_relatedTarget)
}
}
Modal.prototype.resize = function () {
if (this.isShown) {
$(window).on('resize.bs.modal', $.proxy(this.handleUpdate, this))
} else {
$(window).off('resize.bs.modal')
}
}
Modal.prototype.hideModal = function () {
var that = this
this.$element.hide()
this.backdrop(function () {
that.$body.removeClass('modal-open')
that.resetAdjustments()
that.resetScrollbar()
that.$element.trigger('hidden.bs.modal')
})
}
Modal.prototype.removeBackdrop = function () {
this.$backdrop && this.$backdrop.remove()
this.$backdrop = null
}
Modal.prototype.backdrop = function (callback) {
var that = this
var animate = this.$element.hasClass('fade') ? 'fade' : ''
if (this.isShown && this.options.backdrop) {
var doAnimate = $.support.transition && animate
this.$backdrop = $('<div class="modal-backdrop ' + animate + '" />')
.prependTo(this.$element)
.on('click.dismiss.bs.modal', $.proxy(function (e) {
if (e.target !== e.currentTarget) return
this.options.backdrop == 'static'
? this.$element[0].focus.call(this.$element[0])
: this.hide.call(this)
}, this))
if (doAnimate) this.$backdrop[0].offsetWidth // force reflow
this.$backdrop.addClass('in')
if (!callback) return
doAnimate ?
this.$backdrop
.one('bsTransitionEnd', callback)
.emulateTransitionEnd(Modal.BACKDROP_TRANSITION_DURATION) :
callback()
} else if (!this.isShown && this.$backdrop) {
this.$backdrop.removeClass('in')
var callbackRemove = function () {
that.removeBackdrop()
callback && callback()
}
$.support.transition && this.$element.hasClass('fade') ?
this.$backdrop
.one('bsTransitionEnd', callbackRemove)
.emulateTransitionEnd(Modal.BACKDROP_TRANSITION_DURATION) :
callbackRemove()
} else if (callback) {
callback()
}
}
// these following methods are used to handle overflowing modals
Modal.prototype.handleUpdate = function () {
if (this.options.backdrop) this.adjustBackdrop()
this.adjustDialog()
}
Modal.prototype.adjustBackdrop = function () {
this.$backdrop
.css('height', 0)
.css('height', this.$element[0].scrollHeight)
}
Modal.prototype.adjustDialog = function () {
var modalIsOverflowing = this.$element[0].scrollHeight > document.documentElement.clientHeight
this.$element.css({
paddingLeft: !this.bodyIsOverflowing && modalIsOverflowing ? this.scrollbarWidth : '',
paddingRight: this.bodyIsOverflowing && !modalIsOverflowing ? this.scrollbarWidth : ''
})
}
Modal.prototype.resetAdjustments = function () {
this.$element.css({
paddingLeft: '',
paddingRight: ''
})
}
Modal.prototype.checkScrollbar = function () {
var fullWindowWidth = window.innerWidth
if (!fullWindowWidth) { // workaround for missing window.innerWidth in IE8
var documentElementRect = document.documentElement.getBoundingClientRect()
fullWindowWidth = documentElementRect.right - Math.abs(documentElementRect.left)
}
this.bodyIsOverflowing = document.body.clientWidth < fullWindowWidth
this.scrollbarWidth = this.measureScrollbar()
}
Modal.prototype.setScrollbar = function () {
var bodyPad = parseInt((this.$body.css('padding-right') || 0), 10)
this.originalBodyPad = document.body.style.paddingRight || ''
if (this.bodyIsOverflowing) this.$body.css('padding-right', bodyPad + this.scrollbarWidth)
}
Modal.prototype.resetScrollbar = function () {
this.$body.css('padding-right', this.originalBodyPad)
}
Modal.prototype.measureScrollbar = function () { // thx walsh
var scrollDiv = document.createElement('div')
scrollDiv.className = 'modal-scrollbar-measure'
this.$body.append(scrollDiv)
var scrollbarWidth = scrollDiv.offsetWidth - scrollDiv.clientWidth
this.$body[0].removeChild(scrollDiv)
return scrollbarWidth
}
// MODAL PLUGIN DEFINITION
// =======================
function Plugin(option, _relatedTarget) {
return this.each(function () {
var $this = $(this)
var data = $this.data('bs.modal')
var options = $.extend({}, Modal.DEFAULTS, $this.data(), typeof option == 'object' && option)
if (!data) $this.data('bs.modal', (data = new Modal(this, options)))
if (typeof option == 'string') data[option](_relatedTarget)
else if (options.show) data.show(_relatedTarget)
})
}
var old = $.fn.modal
$.fn.modal = Plugin
$.fn.modal.Constructor = Modal
// MODAL NO CONFLICT
// =================
$.fn.modal.noConflict = function () {
$.fn.modal = old
return this
}
// MODAL DATA-API
// ==============
$(document).on('click.bs.modal.data-api', '[data-toggle="modal"]', function (e) {
var $this = $(this)
var href = $this.attr('href')
var $target = $($this.attr('data-target') || (href && href.replace(/.*(?=#[^\s]+$)/, ''))) // strip for ie7
var option = $target.data('bs.modal') ? 'toggle' : $.extend({ remote: !/#/.test(href) && href }, $target.data(), $this.data())
if ($this.is('a')) e.preventDefault()
$target.one('show.bs.modal', function (showEvent) {
if (showEvent.isDefaultPrevented()) return // only register focus restorer if modal will actually get shown
$target.one('hidden.bs.modal', function () {
$this.is(':visible') && $this.trigger('focus')
})
})
Plugin.call($target, option, this)
})
}(jQuery);
/* ========================================================================
* Bootstrap: tooltip.js v3.3.2
* http://getbootstrap.com/javascript/#tooltip
* Inspired by the original jQuery.tipsy by Jason Frame
* ========================================================================
* Copyright 2011-2015 Twitter, Inc.
* Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
* ======================================================================== */
}
+function ($) {
'use strict';
/**
* @param {Element} relatedTarget
*/
Modal.prototype['toggle'] = function (relatedTarget) {
return this._isShown ? this['hide']() : this['show'](relatedTarget)
}
// TOOLTIP PUBLIC CLASS DEFINITION
// ===============================
var Tooltip = function (element, options) {
this.type = null
this.options = null
this.enabled = null
this.timeout = null
this.hoverState = null
this.$element = null
/**
* @param {Element} relatedTarget
*/
Modal.prototype['show'] = function (relatedTarget) {
var showEvent = $.Event(Modal._Event.SHOW, { relatedTarget: relatedTarget })
this.init('tooltip', element, options)
$(this._element).trigger(showEvent)
if (this._isShown || showEvent.isDefaultPrevented()) {
return
}
Tooltip.VERSION = '3.3.2'
this._isShown = true
Tooltip.TRANSITION_DURATION = 150
this._checkScrollbar()
this._setScrollbar()
Tooltip.DEFAULTS = {
animation: true,
placement: 'top',
selector: false,
template: '<div class="tooltip" role="tooltip"><div class="tooltip-arrow"></div><div class="tooltip-inner"></div></div>',
trigger: 'hover focus',
title: '',
delay: 0,
html: false,
container: false,
viewport: {
selector: 'body',
padding: 0
}
$(document.body).addClass(Modal._ClassName.OPEN)
this._escape()
this._resize()
$(this._element).on('click.dismiss.bs.modal', Modal._Selector.DATA_DISMISS, this['hide'].bind(this))
this._showBackdrop(this._showElement.bind(this, relatedTarget))
}
/**
* @param {Event} event
*/
Modal.prototype['hide'] = function (event) {
if (event) {
event.preventDefault()
}
Tooltip.prototype.init = function (type, element, options) {
this.enabled = true
this.type = type
this.$element = $(element)
this.options = this.getOptions(options)
this.$viewport = this.options.viewport && $(this.options.viewport.selector || this.options.viewport)
var hideEvent = $.Event(Modal._Event.HIDE)
if (this.$element[0] instanceof document.constructor && !this.options.selector) {
throw new Error('`selector` option must be specified when initializing ' + this.type + ' on the window.document object!');
}
$(this._element).trigger(hideEvent)
var triggers = this.options.trigger.split(' ')
if (!this._isShown || hideEvent.isDefaultPrevented()) {
return
}
for (var i = triggers.length; i--;) {
var trigger = triggers[i]
this._isShown = false
if (trigger == 'click') {
this.$element.on('click.' + this.type, this.options.selector, $.proxy(this.toggle, this))
} else if (trigger != 'manual') {
var eventIn = trigger == 'hover' ? 'mouseenter' : 'focusin'
var eventOut = trigger == 'hover' ? 'mouseleave' : 'focusout'
this._escape()
this._resize()
this.$element.on(eventIn + '.' + this.type, this.options.selector, $.proxy(this.enter, this))
this.$element.on(eventOut + '.' + this.type, this.options.selector, $.proxy(this.leave, this))
$(document).off('focusin.bs.modal')
$(this._element).removeClass(Modal._ClassName.IN)
this._element.setAttribute('aria-hidden', true)
$(this._element).off('click.dismiss.bs.modal')
if (Bootstrap.transition && $(this._element).hasClass(Modal._ClassName.FADE)) {
$(this._element)
.one(Bootstrap.TRANSITION_END, this._hideModal.bind(this))
.emulateTransitionEnd(Modal._TRANSITION_DURATION)
} else {
this._hideModal()
}
}
/**
* @param {Element} relatedTarget
* @private
*/
Modal.prototype._showElement = function (relatedTarget) {
var transition = Bootstrap.transition && $(this._element).hasClass(Modal._ClassName.FADE)
if (!this._element.parentNode || this._element.parentNode.nodeType != Node.ELEMENT_NODE) {
document.body.appendChild(this._element) // don't move modals dom position
}
this._element.style.display = 'block'
this._element.scrollTop = 0
if (this._config['backdrop']) {
this._adjustBackdrop()
}
if (transition) {
Bootstrap.reflow(this._element)
}
$(this._element).addClass(Modal._ClassName.IN)
this._element.setAttribute('aria-hidden', false)
this._enforceFocus()
var shownEvent = $.Event(Modal._Event.SHOWN, { relatedTarget: relatedTarget })
var transitionComplete = function () {
this._element.focus()
$(this._element).trigger(shownEvent)
}.bind(this)
if (transition) {
var dialog = $(this._element).find(Modal._Selector.DIALOG)[0]
$(dialog)
.one(Bootstrap.TRANSITION_END, transitionComplete)
.emulateTransitionEnd(Modal._TRANSITION_DURATION)
} else {
transitionComplete()
}
}
/**
* @private
*/
Modal.prototype._enforceFocus = function () {
$(document)
.off('focusin.bs.modal') // guard against infinite focus loop
.on('focusin.bs.modal', function (e) {
if (this._element !== e.target && !$(this._element).has(e.target).length) {
this._element.focus()
}
}
}.bind(this))
}
this.options.selector ?
(this._options = $.extend({}, this.options, { trigger: 'manual', selector: '' })) :
this.fixTitle()
}
Tooltip.prototype.getDefaults = function () {
return Tooltip.DEFAULTS
}
Tooltip.prototype.getOptions = function (options) {
options = $.extend({}, this.getDefaults(), this.$element.data(), options)
if (options.delay && typeof options.delay == 'number') {
options.delay = {
show: options.delay,
hide: options.delay
/**
* @private
*/
Modal.prototype._escape = function () {
if (this._isShown && this._config['keyboard']) {
$(this._element).on('keydown.dismiss.bs.modal', function (event) {
if (event.which === 27) {
this['hide']()
}
}.bind(this))
} else if (!this._isShown) {
$(this._element).off('keydown.dismiss.bs.modal')
}
}
/**
* @private
*/
Modal.prototype._resize = function () {
if (this._isShown) {
$(window).on('resize.bs.modal', this._handleUpdate.bind(this))
} else {
$(window).off('resize.bs.modal')
}
}
/**
* @private
*/
Modal.prototype._hideModal = function () {
this._element.style.display = 'none'
this._showBackdrop(function () {
$(document.body).removeClass(Modal._ClassName.OPEN)
this._resetAdjustments()
this._resetScrollbar()
$(this._element).trigger(Modal._Event.HIDDEN)
}.bind(this))
}
/**
* @private
*/
Modal.prototype._removeBackdrop = function () {
if (this._backdrop) {
this._backdrop.parentNode.removeChild(this._backdrop)
this._backdrop = null
}
}
/**
* @param {Function} callback
* @private
*/
Modal.prototype._showBackdrop = function (callback) {
var animate = $(this._element).hasClass(Modal._ClassName.FADE) ? Modal._ClassName.FADE : ''
if (this._isShown && this._config['backdrop']) {
var doAnimate = Bootstrap.transition && animate
this._backdrop = document.createElement('div')
this._backdrop.className = Modal._ClassName.BACKDROP
if (animate) {
$(this._backdrop).addClass(animate)
}
return options
}
$(this._element).prepend(this._backdrop)
Tooltip.prototype.getDelegateOptions = function () {
var options = {}
var defaults = this.getDefaults()
$(this._backdrop).on('click.dismiss.bs.modal', function (event) {
if (event.target !== event.currentTarget) return
this._config['backdrop'] === 'static'
? this._element.focus()
: this['hide']()
}.bind(this))
this._options && $.each(this._options, function (key, value) {
if (defaults[key] != value) options[key] = value
})
if (doAnimate) {
Bootstrap.reflow(this._backdrop)
}
return options
}
$(this._backdrop).addClass(Modal._ClassName.IN)
Tooltip.prototype.enter = function (obj) {
var self = obj instanceof this.constructor ?
obj : $(obj.currentTarget).data('bs.' + this.type)
if (self && self.$tip && self.$tip.is(':visible')) {
self.hoverState = 'in'
if (!callback) {
return
}
if (!self) {
self = new this.constructor(obj.currentTarget, this.getDelegateOptions())
$(obj.currentTarget).data('bs.' + this.type, self)
if (!doAnimate) {
callback()
return
}
clearTimeout(self.timeout)
$(this._backdrop)
.one(Bootstrap.TRANSITION_END, callback)
.emulateTransitionEnd(Modal._BACKDROP_TRANSITION_DURATION)
self.hoverState = 'in'
} else if (!this._isShown && this._backdrop) {
$(this._backdrop).removeClass(Modal._ClassName.IN)
if (!self.options.delay || !self.options.delay.show) return self.show()
self.timeout = setTimeout(function () {
if (self.hoverState == 'in') self.show()
}, self.options.delay.show)
}
Tooltip.prototype.leave = function (obj) {
var self = obj instanceof this.constructor ?
obj : $(obj.currentTarget).data('bs.' + this.type)
if (!self) {
self = new this.constructor(obj.currentTarget, this.getDelegateOptions())
$(obj.currentTarget).data('bs.' + this.type, self)
}
clearTimeout(self.timeout)
self.hoverState = 'out'
if (!self.options.delay || !self.options.delay.hide) return self.hide()
self.timeout = setTimeout(function () {
if (self.hoverState == 'out') self.hide()
}, self.options.delay.hide)
}
Tooltip.prototype.show = function () {
var e = $.Event('show.bs.' + this.type)
if (this.hasContent() && this.enabled) {
this.$element.trigger(e)
var inDom = $.contains(this.$element[0].ownerDocument.documentElement, this.$element[0])
if (e.isDefaultPrevented() || !inDom) return
var that = this
var $tip = this.tip()
var tipId = this.getUID(this.type)
this.setContent()
$tip.attr('id', tipId)
this.$element.attr('aria-describedby', tipId)
if (this.options.animation) $tip.addClass('fade')
var placement = typeof this.options.placement == 'function' ?
this.options.placement.call(this, $tip[0], this.$element[0]) :
this.options.placement
var autoToken = /\s?auto?\s?/i
var autoPlace = autoToken.test(placement)
if (autoPlace) placement = placement.replace(autoToken, '') || 'top'
$tip
.detach()
.css({ top: 0, left: 0, display: 'block' })
.addClass(this.type + '-' + placement)
.data('bs.' + this.type, this)
this.options.container ? $tip.appendTo(this.options.container) : $tip.insertAfter(this.$element)
var pos = this.getPosition()
var actualWidth = $tip[0].offsetWidth
var actualHeight = $tip[0].offsetHeight
if (autoPlace) {
var origPlacement = placement
var $container = this.options.container ? $(this.options.container) : this.$element.parent()
var containerDim = this.getPosition($container)
placement = placement == 'bottom' && pos.bottom + actualHeight > containerDim.bottom ? 'top' :
placement == 'top' && pos.top - actualHeight < containerDim.top ? 'bottom' :
placement == 'right' && pos.right + actualWidth > containerDim.width ? 'left' :
placement == 'left' && pos.left - actualWidth < containerDim.left ? 'right' :
placement
$tip
.removeClass(this.type + '-' + origPlacement)
.addClass(this.type + '-' + placement)
var callbackRemove = function () {
this._removeBackdrop()
if (callback) {
callback()
}
}.bind(this)
var calculatedOffset = this.getCalculatedOffset(placement, pos, actualWidth, actualHeight)
this.applyPlacement(calculatedOffset, placement)
var complete = function () {
var prevHoverState = that.hoverState
that.$element.trigger('shown.bs.' + that.type)
that.hoverState = null
if (prevHoverState == 'out') that.leave(that)
}
$.support.transition && this.$tip.hasClass('fade') ?
$tip
.one('bsTransitionEnd', complete)
.emulateTransitionEnd(Tooltip.TRANSITION_DURATION) :
complete()
}
}
Tooltip.prototype.applyPlacement = function (offset, placement) {
var $tip = this.tip()
var width = $tip[0].offsetWidth
var height = $tip[0].offsetHeight
// manually read margins because getBoundingClientRect includes difference
var marginTop = parseInt($tip.css('margin-top'), 10)
var marginLeft = parseInt($tip.css('margin-left'), 10)
// we must check for NaN for IE9
if (isNaN(marginTop)) marginTop = 0
if (isNaN(marginLeft)) marginLeft = 0
offset.top = offset.top + marginTop
offset.left = offset.left + marginLeft
// $.fn.offset doesn't round pixel values
// so we use setOffset directly with our own function B-0
$.offset.setOffset($tip[0], $.extend({
using: function (props) {
$tip.css({
top: Math.round(props.top),
left: Math.round(props.left)
})
}
}, offset), 0)
$tip.addClass('in')
// check to see if placing tip in new offset caused the tip to resize itself
var actualWidth = $tip[0].offsetWidth
var actualHeight = $tip[0].offsetHeight
if (placement == 'top' && actualHeight != height) {
offset.top = offset.top + height - actualHeight
}
var delta = this.getViewportAdjustedDelta(placement, offset, actualWidth, actualHeight)
if (delta.left) offset.left += delta.left
else offset.top += delta.top
var isVertical = /top|bottom/.test(placement)
var arrowDelta = isVertical ? delta.left * 2 - width + actualWidth : delta.top * 2 - height + actualHeight
var arrowOffsetPosition = isVertical ? 'offsetWidth' : 'offsetHeight'
$tip.offset(offset)
this.replaceArrow(arrowDelta, $tip[0][arrowOffsetPosition], isVertical)
}
Tooltip.prototype.replaceArrow = function (delta, dimension, isVertical) {
this.arrow()
.css(isVertical ? 'left' : 'top', 50 * (1 - delta / dimension) + '%')
.css(isVertical ? 'top' : 'left', '')
}
Tooltip.prototype.setContent = function () {
var $tip = this.tip()
var title = this.getTitle()
$tip.find('.tooltip-inner')[this.options.html ? 'html' : 'text'](title)
$tip.removeClass('fade in tooltip-top tooltip-bottom tooltip-left tooltip-right')
}
Tooltip.prototype.hide = function (callback) {
var that = this
var $tip = $(this.$tip)
var e = $.Event('hide.bs.' + this.type)
function complete() {
if (that.hoverState != 'in') $tip.detach()
that.$element
.removeAttr('aria-describedby')
.trigger('hidden.bs.' + that.type)
callback && callback()
}
this.$element.trigger(e)
if (e.isDefaultPrevented()) return
$tip.removeClass('in')
$.support.transition && $tip.hasClass('fade') ?
$tip
.one('bsTransitionEnd', complete)
.emulateTransitionEnd(Tooltip.TRANSITION_DURATION) :
complete()
this.hoverState = null
return this
}
Tooltip.prototype.fixTitle = function () {
var $e = this.$element
if ($e.attr('title') || typeof ($e.attr('data-original-title')) != 'string') {
$e.attr('data-original-title', $e.attr('title') || '').attr('title', '')
}
}
Tooltip.prototype.hasContent = function () {
return this.getTitle()
}
Tooltip.prototype.getPosition = function ($element) {
$element = $element || this.$element
var el = $element[0]
var isBody = el.tagName == 'BODY'
var elRect = el.getBoundingClientRect()
if (elRect.width == null) {
// width and height are missing in IE8, so compute them manually; see https://github.com/twbs/bootstrap/issues/14093
elRect = $.extend({}, elRect, { width: elRect.right - elRect.left, height: elRect.bottom - elRect.top })
}
var elOffset = isBody ? { top: 0, left: 0 } : $element.offset()
var scroll = { scroll: isBody ? document.documentElement.scrollTop || document.body.scrollTop : $element.scrollTop() }
var outerDims = isBody ? { width: $(window).width(), height: $(window).height() } : null
return $.extend({}, elRect, scroll, outerDims, elOffset)
}
Tooltip.prototype.getCalculatedOffset = function (placement, pos, actualWidth, actualHeight) {
return placement == 'bottom' ? { top: pos.top + pos.height, left: pos.left + pos.width / 2 - actualWidth / 2 } :
placement == 'top' ? { top: pos.top - actualHeight, left: pos.left + pos.width / 2 - actualWidth / 2 } :
placement == 'left' ? { top: pos.top + pos.height / 2 - actualHeight / 2, left: pos.left - actualWidth } :
/* placement == 'right' */ { top: pos.top + pos.height / 2 - actualHeight / 2, left: pos.left + pos.width }
}
Tooltip.prototype.getViewportAdjustedDelta = function (placement, pos, actualWidth, actualHeight) {
var delta = { top: 0, left: 0 }
if (!this.$viewport) return delta
var viewportPadding = this.options.viewport && this.options.viewport.padding || 0
var viewportDimensions = this.getPosition(this.$viewport)
if (/right|left/.test(placement)) {
var topEdgeOffset = pos.top - viewportPadding - viewportDimensions.scroll
var bottomEdgeOffset = pos.top + viewportPadding - viewportDimensions.scroll + actualHeight
if (topEdgeOffset < viewportDimensions.top) { // top overflow
delta.top = viewportDimensions.top - topEdgeOffset
} else if (bottomEdgeOffset > viewportDimensions.top + viewportDimensions.height) { // bottom overflow
delta.top = viewportDimensions.top + viewportDimensions.height - bottomEdgeOffset
}
if (Bootstrap.transition && $(this._element).hasClass(Modal._ClassName.FADE)) {
$(this._backdrop)
.one(Bootstrap.TRANSITION_END, callbackRemove)
.emulateTransitionEnd(Modal._BACKDROP_TRANSITION_DURATION)
} else {
var leftEdgeOffset = pos.left - viewportPadding
var rightEdgeOffset = pos.left + viewportPadding + actualWidth
if (leftEdgeOffset < viewportDimensions.left) { // left overflow
delta.left = viewportDimensions.left - leftEdgeOffset
} else if (rightEdgeOffset > viewportDimensions.width) { // right overflow
delta.left = viewportDimensions.left + viewportDimensions.width - rightEdgeOffset
}
callbackRemove()
}
return delta
} else if (callback) {
callback()
}
}
/**
* ------------------------------------------------------------------------
* the following methods are used to handle overflowing modals
* todo (fat): these should probably be refactored into a
* ------------------------------------------------------------------------
*/
/**
* @private
*/
Modal.prototype._handleUpdate = function () {
if (this._config['backdrop']) this._adjustBackdrop()
this._adjustDialog()
}
/**
* @private
*/
Modal.prototype._adjustBackdrop = function () {
this._backdrop.style.height = 0 // todo (fat): no clue why we do this
this._backdrop.style.height = this._element.scrollHeight + 'px'
}
/**
* @private
*/
Modal.prototype._adjustDialog = function () {
var isModalOverflowing = this._element.scrollHeight > document.documentElement.clientHeight
if (!this._isBodyOverflowing && isModalOverflowing) {
this._element.style.paddingLeft = this._scrollbarWidth + 'px'
}
Tooltip.prototype.getTitle = function () {
var title
var $e = this.$element
var o = this.options
if (this._isBodyOverflowing && !isModalOverflowing) {
this._element.style.paddingRight = this._scrollbarWidth + 'px'
}
}
title = $e.attr('data-original-title')
|| (typeof o.title == 'function' ? o.title.call($e[0]) : o.title)
return title
/**
* @private
*/
Modal.prototype._resetAdjustments = function () {
this._element.style.paddingLeft = ''
this._element.style.paddingRight = ''
}
/**
* @private
*/
Modal.prototype._checkScrollbar = function () {
this._isBodyOverflowing = document.body.scrollHeight > document.documentElement.clientHeight
this._scrollbarWidth = this._getScrollbarWidth()
}
/**
* @private
*/
Modal.prototype._setScrollbar = function () {
var bodyPadding = parseInt(($(document.body).css('padding-right') || 0), 10)
if (this._isBodyOverflowing) {
document.body.style.paddingRight = bodyPadding + this._scrollbarWidth + 'px'
}
}
/**
* @private
*/
Modal.prototype._resetScrollbar = function () {
document.body.style.paddingRight = ''
}
/**
* @private
*/
Modal.prototype._getScrollbarWidth = function () { // thx walsh
var scrollDiv = document.createElement('div')
scrollDiv.className = Modal._Selector.SCROLLBAR_MEASURER
document.body.appendChild(scrollDiv)
var scrollbarWidth = scrollDiv.offsetWidth - scrollDiv.clientWidth
document.body.removeChild(scrollDiv)
return scrollbarWidth
}
/**
* ------------------------------------------------------------------------
* jQuery Interface + noConflict implementaiton
* ------------------------------------------------------------------------
*/
/**
* @const
* @type {Function}
*/
$.fn[Modal._NAME] = Modal._jQueryInterface
/**
* @const
* @type {Function}
*/
$.fn[Modal._NAME]['Constructor'] = Modal
/**
* @const
* @type {Function}
*/
$.fn[Modal._NAME]['noConflict'] = function () {
$.fn[Modal._NAME] = Modal._JQUERY_NO_CONFLICT
return this
}
/**
* ------------------------------------------------------------------------
* Data Api implementation
* ------------------------------------------------------------------------
*/
$(document).on('click.bs.modal.data-api', Modal._Selector.DATA_TOGGLE, function (event) {
var selector = Bootstrap.getSelectorFromElement(this)
if (selector) {
var target = $(selector)[0]
}
Tooltip.prototype.getUID = function (prefix) {
do prefix += ~~(Math.random() * 1000000)
while (document.getElementById(prefix))
return prefix
var config = $(target).data(Modal._DATA_KEY) ? 'toggle' : $.extend({}, $(target).data(), $(this).data())
if (this.tagName == 'A') {
event.preventDefault()
}
Tooltip.prototype.tip = function () {
return (this.$tip = this.$tip || $(this.options.template))
}
Tooltip.prototype.arrow = function () {
return (this.$arrow = this.$arrow || this.tip().find('.tooltip-arrow'))
}
Tooltip.prototype.enable = function () {
this.enabled = true
}
Tooltip.prototype.disable = function () {
this.enabled = false
}
Tooltip.prototype.toggleEnabled = function () {
this.enabled = !this.enabled
}
Tooltip.prototype.toggle = function (e) {
var self = this
if (e) {
self = $(e.currentTarget).data('bs.' + this.type)
if (!self) {
self = new this.constructor(e.currentTarget, this.getDelegateOptions())
$(e.currentTarget).data('bs.' + this.type, self)
}
var $target = $(target).one(Modal._Event.SHOW, function (showEvent) {
if (showEvent.isDefaultPrevented()) {
return // only register focus restorer if modal will actually get shown
}
self.tip().hasClass('in') ? self.leave(self) : self.enter(self)
}
$target.one(Modal._Event.HIDDEN, function () {
if ($(this).is(':visible')) {
this.focus()
}
}.bind(this))
}.bind(this))
Tooltip.prototype.destroy = function () {
var that = this
clearTimeout(this.timeout)
this.hide(function () {
that.$element.off('.' + that.type).removeData('bs.' + that.type)
})
}
Modal._jQueryInterface.call($(target), config, this)
})
// TOOLTIP PLUGIN DEFINITION
// =========================
function Plugin(option) {
return this.each(function () {
var $this = $(this)
var data = $this.data('bs.tooltip')
var options = typeof option == 'object' && option
if (!data && option == 'destroy') return
if (!data) $this.data('bs.tooltip', (data = new Tooltip(this, options)))
if (typeof option == 'string') data[option]()
})
}
var old = $.fn.tooltip
$.fn.tooltip = Plugin
$.fn.tooltip.Constructor = Tooltip
// TOOLTIP NO CONFLICT
// ===================
$.fn.tooltip.noConflict = function () {
$.fn.tooltip = old
return this
}
}(jQuery);
/* ========================================================================
* Bootstrap: popover.js v3.3.2
* http://getbootstrap.com/javascript/#popovers
* ========================================================================
* Copyright 2011-2015 Twitter, Inc.
* Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
* ======================================================================== */
+function ($) {
'use strict';
// POPOVER PUBLIC CLASS DEFINITION
// ===============================
var Popover = function (element, options) {
this.init('popover', element, options)
}
if (!$.fn.tooltip) throw new Error('Popover requires tooltip.js')
Popover.VERSION = '3.3.2'
Popover.DEFAULTS = $.extend({}, $.fn.tooltip.Constructor.DEFAULTS, {
placement: 'right',
trigger: 'click',
content: '',
template: '<div class="popover" role="tooltip"><div class="popover-arrow"></div><h3 class="popover-title"></h3><div class="popover-content"></div></div>'
})
// NOTE: POPOVER EXTENDS tooltip.js
// ================================
Popover.prototype = $.extend({}, $.fn.tooltip.Constructor.prototype)
Popover.prototype.constructor = Popover
Popover.prototype.getDefaults = function () {
return Popover.DEFAULTS
}
Popover.prototype.setContent = function () {
var $tip = this.tip()
var title = this.getTitle()
var content = this.getContent()
$tip.find('.popover-title')[this.options.html ? 'html' : 'text'](title)
$tip.find('.popover-content').children().detach().end()[ // we use append for html objects to maintain js events
this.options.html ? (typeof content == 'string' ? 'html' : 'append') : 'text'
](content)
$tip.removeClass('fade popover-top popover-bottom popover-left popover-right in')
// IE8 doesn't accept hiding via the `:empty` pseudo selector, we have to do
// this manually by checking the contents.
if (!$tip.find('.popover-title').html()) $tip.find('.popover-title').hide()
}
Popover.prototype.hasContent = function () {
return this.getTitle() || this.getContent()
}
Popover.prototype.getContent = function () {
var $e = this.$element
var o = this.options
return $e.attr('data-content')
|| (typeof o.content == 'function' ?
o.content.call($e[0]) :
o.content)
}
Popover.prototype.arrow = function () {
return (this.$arrow = this.$arrow || this.tip().find('.popover-arrow'))
}
// POPOVER PLUGIN DEFINITION
// =========================
function Plugin(option) {
return this.each(function () {
var $this = $(this)
var data = $this.data('bs.popover')
var options = typeof option == 'object' && option
if (!data && option == 'destroy') return
if (!data) $this.data('bs.popover', (data = new Popover(this, options)))
if (typeof option == 'string') data[option]()
})
}
var old = $.fn.popover
$.fn.popover = Plugin
$.fn.popover.Constructor = Popover
// POPOVER NO CONFLICT
// ===================
$.fn.popover.noConflict = function () {
$.fn.popover = old
return this
}
}(jQuery);
/* ========================================================================
* Bootstrap: scrollspy.js v3.3.2
/** =======================================================================
* Bootstrap: scrollspy.js v4.0.0
* http://getbootstrap.com/javascript/#scrollspy
* ========================================================================
* Copyright 2011-2015 Twitter, Inc.
* Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
* ======================================================================== */
* ========================================================================
* @fileoverview - Bootstrap's scrollspy plugin.
*
* Public Methods & Properties:
*
* + $.scrollspy
* + $.scrollspy.noConflict
* + $.scrollspy.Constructor
* + $.scrollspy.Constructor.VERSION
* + $.scrollspy.Constructor.Defaults
* + $.scrollspy.Constructor.Defaults.offset
* + $.scrollspy.Constructor.prototype.refresh
*
* ========================================================================
*/
'use strict';
+function ($) {
'use strict';
/**
* Our scrollspy class.
* @param {Element!} element
* @param {Object=} opt_config
* @constructor
*/
function ScrollSpy(element, opt_config) {
// SCROLLSPY CLASS DEFINITION
// ==========================
/** @private {Element|Window} */
this._scrollElement = element.tagName == 'BODY' ? window : element
function ScrollSpy(element, options) {
this.$body = $(document.body)
this.$scrollElement = $(element).is(document.body) ? $(window) : $(element)
this.options = $.extend({}, ScrollSpy.DEFAULTS, options)
this.selector = (this.options.target || '') + ' .nav li > a'
this.offsets = []
this.targets = []
this.activeTarget = null
this.scrollHeight = 0
/** @private {Object} */
this._config = $.extend({}, ScrollSpy['Defaults'], opt_config)
this.$scrollElement.on('scroll.bs.scrollspy', $.proxy(this.process, this))
this.refresh()
this.process()
}
/** @private {string} */
this._selector = (this._config.target || '') + ' .nav li > a'
ScrollSpy.VERSION = '3.3.2'
/** @private {Array} */
this._offsets = []
ScrollSpy.DEFAULTS = {
offset: 10
}
/** @private {Array} */
this._targets = []
ScrollSpy.prototype.getScrollHeight = function () {
return this.$scrollElement[0].scrollHeight || Math.max(this.$body[0].scrollHeight, document.documentElement.scrollHeight)
}
/** @private {Element} */
this._activeTarget = null
ScrollSpy.prototype.refresh = function () {
var that = this
var offsetMethod = 'offset'
var offsetBase = 0
/** @private {number} */
this._scrollHeight = 0
this.offsets = []
this.targets = []
this.scrollHeight = this.getScrollHeight()
$(this._scrollElement).on('scroll.bs.scrollspy', this._process.bind(this))
if (!$.isWindow(this.$scrollElement[0])) {
offsetMethod = 'position'
offsetBase = this.$scrollElement.scrollTop()
this['refresh']()
this._process()
}
/**
* @const
* @type {string}
*/
ScrollSpy['VERSION'] = '4.0.0'
/**
* @const
* @type {Object}
*/
ScrollSpy['Defaults'] = {
'offset': 10
}
/**
* @const
* @type {string}
* @private
*/
ScrollSpy._NAME = 'scrollspy'
/**
* @const
* @type {string}
* @private
*/
ScrollSpy._DATA_KEY = 'bs.scrollspy'
/**
* @const
* @type {Function}
* @private
*/
ScrollSpy._JQUERY_NO_CONFLICT = $.fn[ScrollSpy._NAME]
/**
* @const
* @enum {string}
* @private
*/
ScrollSpy._Event = {
ACTIVATE: 'activate.bs.scrollspy'
}
/**
* @const
* @enum {string}
* @private
*/
ScrollSpy._ClassName = {
DROPDOWN_MENU : 'dropdown-menu',
ACTIVE : 'active'
}
/**
* @const
* @enum {string}
* @private
*/
ScrollSpy._Selector = {
DATA_SPY : '[data-spy="scroll"]',
ACTIVE : '.active',
LI_DROPDOWN : 'li.dropdown',
LI : 'li'
}
/**
* @param {Object=} opt_config
* @this {jQuery}
* @return {jQuery}
* @private
*/
ScrollSpy._jQueryInterface = function (opt_config) {
return this.each(function () {
var data = $(this).data(ScrollSpy._DATA_KEY)
var config = typeof opt_config === 'object' && opt_config || null
if (!data) {
data = new ScrollSpy(this, config)
$(this).data(ScrollSpy._DATA_KEY, data)
}
this.$body
.find(this.selector)
.map(function () {
var $el = $(this)
var href = $el.data('target') || $el.attr('href')
var $href = /^#./.test(href) && $(href)
return ($href
&& $href.length
&& $href.is(':visible')
&& [[$href[offsetMethod]().top + offsetBase, href]]) || null
})
.sort(function (a, b) { return a[0] - b[0] })
.each(function () {
that.offsets.push(this[0])
that.targets.push(this[1])
})
}
ScrollSpy.prototype.process = function () {
var scrollTop = this.$scrollElement.scrollTop() + this.options.offset
var scrollHeight = this.getScrollHeight()
var maxScroll = this.options.offset + scrollHeight - this.$scrollElement.height()
var offsets = this.offsets
var targets = this.targets
var activeTarget = this.activeTarget
var i
if (this.scrollHeight != scrollHeight) {
this.refresh()
if (typeof opt_config === 'string') {
data[opt_config]()
}
if (scrollTop >= maxScroll) {
return activeTarget != (i = targets[targets.length - 1]) && this.activate(i)
}
if (activeTarget && scrollTop < offsets[0]) {
this.activeTarget = null
return this.clear()
}
for (i = offsets.length; i--;) {
activeTarget != targets[i]
&& scrollTop >= offsets[i]
&& (!offsets[i + 1] || scrollTop <= offsets[i + 1])
&& this.activate(targets[i])
}
}
ScrollSpy.prototype.activate = function (target) {
this.activeTarget = target
this.clear()
var selector = this.selector +
'[data-target="' + target + '"],' +
this.selector + '[href="' + target + '"]'
var active = $(selector)
.parents('li')
.addClass('active')
if (active.parent('.dropdown-menu').length) {
active = active
.closest('li.dropdown')
.addClass('active')
}
active.trigger('activate.bs.scrollspy')
}
ScrollSpy.prototype.clear = function () {
$(this.selector)
.parentsUntil(this.options.target, '.active')
.removeClass('active')
}
// SCROLLSPY PLUGIN DEFINITION
// ===========================
function Plugin(option) {
return this.each(function () {
var $this = $(this)
var data = $this.data('bs.scrollspy')
var options = typeof option == 'object' && option
if (!data) $this.data('bs.scrollspy', (data = new ScrollSpy(this, options)))
if (typeof option == 'string') data[option]()
})
}
var old = $.fn.scrollspy
$.fn.scrollspy = Plugin
$.fn.scrollspy.Constructor = ScrollSpy
// SCROLLSPY NO CONFLICT
// =====================
$.fn.scrollspy.noConflict = function () {
$.fn.scrollspy = old
return this
}
// SCROLLSPY DATA-API
// ==================
$(window).on('load.bs.scrollspy.data-api', function () {
$('[data-spy="scroll"]').each(function () {
var $spy = $(this)
Plugin.call($spy, $spy.data())
})
})
}
}(jQuery);
/* ========================================================================
* Bootstrap: tab.js v3.3.2
/**
* Refresh the scrollspy target cache
*/
ScrollSpy.prototype['refresh'] = function () {
var offsetMethod = 'offset'
var offsetBase = 0
if (this._scrollElement !== this._scrollElement.window) {
offsetMethod = 'position'
offsetBase = this._getScrollTop()
}
this._offsets = []
this._targets = []
this._scrollHeight = this._getScrollHeight()
var targets = /** @type {Array.<Element>} */ ($.makeArray($(this._selector)))
targets
.map(function (element, index) {
var target
var targetSelector = Bootstrap.getSelectorFromElement(element)
if (targetSelector) {
target = $(targetSelector)[0]
}
if (target && (target.offsetWidth || target.offsetHeight)) {
// todo (fat): remove sketch reliance on jQuery position/offset
return [$(target)[offsetMethod]().top + offsetBase, targetSelector]
}
})
.filter(function (item) { return item })
.sort(function (a, b) { return a[0] - b[0] })
.forEach(function (item, index) {
this._offsets.push(item[0])
this._targets.push(item[1])
}.bind(this))
}
/**
* @private
*/
ScrollSpy.prototype._getScrollTop = function () {
return this._scrollElement === window ?
this._scrollElement.scrollY : this._scrollElement.scrollTop
}
/**
* @private
*/
ScrollSpy.prototype._getScrollHeight = function () {
return this._scrollElement.scrollHeight
|| Math.max(document.body.scrollHeight, document.documentElement.scrollHeight)
}
/**
* @private
*/
ScrollSpy.prototype._process = function () {
var scrollTop = this._getScrollTop() + this._config.offset
var scrollHeight = this._getScrollHeight()
var maxScroll = this._config.offset + scrollHeight - this._scrollElement.offsetHeight
if (this._scrollHeight != scrollHeight) {
this['refresh']()
}
if (scrollTop >= maxScroll) {
var target = this._targets[this._targets.length - 1]
if (this._activeTarget != target) {
this._activate(target)
}
}
if (this._activeTarget && scrollTop < this._offsets[0]) {
this._activeTarget = null
this._clear()
return
}
for (var i = this._offsets.length; i--;) {
var isActiveTarget = this._activeTarget != this._targets[i]
&& scrollTop >= this._offsets[i]
&& (!this._offsets[i + 1] || scrollTop < this._offsets[i + 1])
if (isActiveTarget) {
this._activate(this._targets[i])
}
}
}
/**
* @param {Element} target
* @private
*/
ScrollSpy.prototype._activate = function (target) {
this._activeTarget = target
this._clear()
var selector = this._selector
+ '[data-target="' + target + '"],'
+ this._selector + '[href="' + target + '"]'
// todo (fat): this seems horribly wrong… getting all raw li elements up the tree ,_,
var parentListItems = $(selector).parents(ScrollSpy._Selector.LI)
for (var i = parentListItems.length; i--;) {
$(parentListItems[i]).addClass(ScrollSpy._ClassName.ACTIVE)
var itemParent = parentListItems[i].parentNode
if (itemParent && $(itemParent).hasClass(ScrollSpy._ClassName.DROPDOWN_MENU)) {
var closestDropdown = $(itemParent).closest(ScrollSpy._Selector.LI_DROPDOWN)[0]
$(closestDropdown).addClass(ScrollSpy._ClassName.ACTIVE)
}
}
$(this._scrollElement).trigger(ScrollSpy._Event.ACTIVATE, {
relatedTarget: target
})
}
/**
* @private
*/
ScrollSpy.prototype._clear = function () {
var activeParents = $(this._selector).parentsUntil(this._config.target, ScrollSpy._Selector.ACTIVE)
for (var i = activeParents.length; i--;) {
$(activeParents[i]).removeClass(ScrollSpy._ClassName.ACTIVE)
}
}
/**
* ------------------------------------------------------------------------
* jQuery Interface + noConflict implementaiton
* ------------------------------------------------------------------------
*/
/**
* @const
* @type {Function}
*/
$.fn[ScrollSpy._NAME] = ScrollSpy._jQueryInterface
/**
* @const
* @type {Function}
*/
$.fn[ScrollSpy._NAME]['Constructor'] = ScrollSpy
/**
* @const
* @type {Function}
*/
$.fn[ScrollSpy._NAME]['noConflict'] = function () {
$.fn[ScrollSpy._NAME] = ScrollSpy._JQUERY_NO_CONFLICT
return this
}
/**
* ------------------------------------------------------------------------
* Data Api implementation
* ------------------------------------------------------------------------
*/
$(window).on('load.bs.scrollspy.data-api', function () {
var scrollSpys = /** @type {Array.<Element>} */ ($.makeArray($(ScrollSpy._Selector.DATA_SPY)))
for (var i = scrollSpys.length; i--;) {
var $spy = $(scrollSpys[i])
ScrollSpy._jQueryInterface.call($spy, /** @type {Object|null} */ ($spy.data()))
}
})
/** =======================================================================
* Bootstrap: tooltip.js v4.0.0
* http://getbootstrap.com/javascript/#tooltip
* ========================================================================
* Copyright 2011-2015 Twitter, Inc.
* Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
* ========================================================================
* @fileoverview - Bootstrap's tooltip plugin.
* (Inspired by jQuery.tipsy by Jason Frame)
*
* Public Methods & Properties:
*
* + $.tooltip
* + $.tooltip.noConflict
* + $.tooltip.Constructor
* + $.tooltip.Constructor.VERSION
* + $.tooltip.Constructor.Defaults
* + $.tooltip.Constructor.Defaults.container
* + $.tooltip.Constructor.Defaults.animation
* + $.tooltip.Constructor.Defaults.placement
* + $.tooltip.Constructor.Defaults.selector
* + $.tooltip.Constructor.Defaults.template
* + $.tooltip.Constructor.Defaults.trigger
* + $.tooltip.Constructor.Defaults.title
* + $.tooltip.Constructor.Defaults.delay
* + $.tooltip.Constructor.Defaults.html
* + $.tooltip.Constructor.Defaults.viewport
* + $.tooltip.Constructor.Defaults.viewport.selector
* + $.tooltip.Constructor.Defaults.viewport.padding
* + $.tooltip.Constructor.prototype.enable
* + $.tooltip.Constructor.prototype.disable
* + $.tooltip.Constructor.prototype.destroy
* + $.tooltip.Constructor.prototype.toggleEnabled
* + $.tooltip.Constructor.prototype.toggle
* + $.tooltip.Constructor.prototype.show
* + $.tooltip.Constructor.prototype.hide
*
* ========================================================================
*/
'use strict';
/**
* Our tooltip class.
* @param {Element!} element
* @param {Object=} opt_config
* @constructor
*/
var Tooltip = function (element, opt_config) {
/** @private {boolean} */
this._isEnabled = true
/** @private {number} */
this._timeout = 0
/** @private {string} */
this._hoverState = ''
/** @protected {Element} */
this.element = element
/** @protected {Object} */
this.config = this._getConfig(opt_config)
/** @protected {Element} */
this.tip = null
/** @protected {Element} */
this.arrow = null
if (this.config['viewport']) {
/** @private {Element} */
this._viewport = $(this.config['viewport']['selector'] || this.config['viewport'])[0]
}
this._setListeners()
}
/**
* @const
* @type {string}
*/
Tooltip['VERSION'] = '4.0.0'
/**
* @const
* @type {Object}
*/
Tooltip['Defaults'] = {
'container' : false,
'animation' : true,
'placement' : 'top',
'selector' : false,
'template' : '<div class="tooltip" role="tooltip"><div class="tooltip-arrow"></div><div class="tooltip-inner"></div></div>',
'trigger' : 'hover focus',
'title' : '',
'delay' : 0,
'html' : false,
'viewport': {
'selector': 'body',
'padding' : 0
}
}
/**
* @const
* @enum {string}
* @protected
*/
Tooltip.Direction = {
TOP: 'top',
LEFT: 'left',
RIGHT: 'right',
BOTTOM: 'bottom'
}
/**
* @const
* @type {string}
* @private
*/
Tooltip._NAME = 'tooltip'
/**
* @const
* @type {string}
* @private
*/
Tooltip._DATA_KEY = 'bs.tooltip'
/**
* @const
* @type {number}
* @private
*/
Tooltip._TRANSITION_DURATION = 150
/**
* @const
* @enum {string}
* @private
*/
Tooltip._HoverState = {
IN: 'in',
OUT: 'out'
}
/**
* @const
* @enum {string}
* @private
*/
Tooltip._Event = {
HIDE : 'hide.bs.tooltip',
HIDDEN : 'hidden.bs.tooltip',
SHOW : 'show.bs.tooltip',
SHOWN : 'shown.bs.tooltip'
}
/**
* @const
* @enum {string}
* @private
*/
Tooltip._ClassName = {
FADE : 'fade',
IN : 'in'
}
/**
* @const
* @enum {string}
* @private
*/
Tooltip._Selector = {
TOOLTIP : '.tooltip',
TOOLTIP_INNER : '.tooltip-inner',
TOOLTIP_ARROW : '.tooltip-arrow'
}
/**
* @const
* @type {Function}
* @private
*/
Tooltip._JQUERY_NO_CONFLICT = $.fn[Tooltip._NAME]
/**
* @param {Object=} opt_config
* @this {jQuery}
* @return {jQuery}
* @private
*/
Tooltip._jQueryInterface = function (opt_config) {
return this.each(function () {
var data = $(this).data(Tooltip._DATA_KEY)
var config = typeof opt_config == 'object' ? opt_config : null
if (!data && opt_config == 'destroy') {
return
}
if (!data) {
data = new Tooltip(this, config)
$(this).data(Tooltip._DATA_KEY, data)
}
if (typeof opt_config === 'string') {
data[opt_config]()
}
})
}
/**
* Enable tooltip
*/
Tooltip.prototype['enable'] = function () {
this._isEnabled = true
}
/**
* Disable tooltip
*/
Tooltip.prototype['disable'] = function () {
this._isEnabled = false
}
/**
* Toggle the tooltip enable state
*/
Tooltip.prototype['toggleEnabled'] = function () {
this._isEnabled = !this._isEnabled
}
/**
* Toggle the tooltips display
* @param {Event} opt_event
*/
Tooltip.prototype['toggle'] = function (opt_event) {
var context = this
var dataKey = this.getDataKey()
if (opt_event) {
context = $(opt_event.currentTarget).data(dataKey)
if (!context) {
context = new this.constructor(opt_event.currentTarget, this._getDelegateConfig())
$(opt_event.currentTarget).data(dataKey, context)
}
}
$(context.getTipElement()).hasClass(Tooltip._ClassName.IN) ?
context._leave(null, context) :
context._enter(null, context)
}
/**
* Remove tooltip functionality
*/
Tooltip.prototype['destroy'] = function () {
clearTimeout(this._timeout)
this['hide'](function () {
$(this.element)
.off(Tooltip._Selector.TOOLTIP)
.removeData(this.getDataKey())
}.bind(this))
}
/**
* Show the tooltip
* todo (fat): ~fuck~ this is a big function - refactor out all of positioning logic
* and replace with external lib
*/
Tooltip.prototype['show'] = function () {
var showEvent = $.Event(this.getEventObject().SHOW)
if (this.isWithContent() && this._isEnabled) {
$(this.element).trigger(showEvent)
var isInTheDom = $.contains(this.element.ownerDocument.documentElement, this.element)
if (showEvent.isDefaultPrevented() || !isInTheDom) {
return
}
var tip = this.getTipElement()
var tipId = Bootstrap.getUID(this.getName())
tip.setAttribute('id', tipId)
this.element.setAttribute('aria-describedby', tipId)
this.setContent()
if (this.config['animation']) {
$(tip).addClass(Tooltip._ClassName.FADE)
}
var placement = typeof this.config['placement'] == 'function' ?
this.config['placement'].call(this, tip, this.element) :
this.config['placement']
var autoToken = /\s?auto?\s?/i
var isWithAutoPlacement = autoToken.test(placement)
if (isWithAutoPlacement) {
placement = placement.replace(autoToken, '') || Tooltip.Direction.TOP
}
if (tip.parentNode && tip.parentNode.nodeType == Node.ELEMENT_NODE) {
tip.parentNode.removeChild(tip)
}
tip.style.top = 0
tip.style.left = 0
tip.style.display = 'block'
$(tip).addClass(Tooltip._NAME + '-' + placement)
$(tip).data(this.getDataKey(), this)
if (this.config['container']) {
$(this.config['container'])[0].appendChild(tip)
} else {
this.element.parentNode.insertBefore(tip, this.element.nextSibling)
}
var position = this._getPosition()
var actualWidth = tip.offsetWidth
var actualHeight = tip.offsetHeight
var calculatedPlacement = this._getCalculatedAutoPlacement(isWithAutoPlacement, placement, position, actualWidth, actualHeight)
var calculatedOffset = this._getCalculatedOffset(calculatedPlacement, position, actualWidth, actualHeight)
this._applyCalculatedPlacement(calculatedOffset, calculatedPlacement)
var complete = function () {
var prevHoverState = this.hoverState
$(this.element).trigger(this.getEventObject().SHOWN)
this.hoverState = null
if (prevHoverState == 'out') this._leave(null, this)
}.bind(this)
Bootstrap.transition && $(this._tip).hasClass(Tooltip._ClassName.FADE) ?
$(this._tip)
.one(Bootstrap.TRANSITION_END, complete)
.emulateTransitionEnd(Tooltip._TRANSITION_DURATION) :
complete()
}
}
/**
* Hide the tooltip breh
*/
Tooltip.prototype['hide'] = function (callback) {
var tip = this.getTipElement()
var hideEvent = $.Event(this.getEventObject().HIDE)
var complete = function () {
if (this._hoverState != Tooltip._HoverState.IN) {
tip.parentNode.removeChild(tip)
}
this.element.removeAttribute('aria-describedby')
$(this.element).trigger(this.getEventObject().HIDDEN)
if (callback) {
callback()
}
}.bind(this)
$(this.element).trigger(hideEvent)
if (hideEvent.isDefaultPrevented()) return
$(tip).removeClass(Tooltip._ClassName.IN)
if (Bootstrap.transition && $(this._tip).hasClass(Tooltip._ClassName.FADE)) {
$(tip)
.one(Bootstrap.TRANSITION_END, complete)
.emulateTransitionEnd(Tooltip._TRANSITION_DURATION)
} else {
complete()
}
this._hoverState = ''
}
/**
* @return {string}
*/
Tooltip.prototype['getHoverState'] = function (callback) {
return this._hoverState
}
/**
* @return {string}
* @protected
*/
Tooltip.prototype.getName = function () {
return Tooltip._NAME
}
/**
* @return {string}
* @protected
*/
Tooltip.prototype.getDataKey = function () {
return Tooltip._DATA_KEY
}
/**
* @return {Object}
* @protected
*/
Tooltip.prototype.getEventObject = function () {
return Tooltip._Event
}
/**
* @return {string}
* @protected
*/
Tooltip.prototype.getTitle = function () {
var title = this.element.getAttribute('data-original-title')
if (!title) {
title = typeof this.config['title'] === 'function' ?
this.config['title'].call(this.element) :
this.config['title']
}
return /** @type {string} */ (title)
}
/**
* @return {Element}
* @protected
*/
Tooltip.prototype.getTipElement = function () {
return (this._tip = this._tip || $(this.config['template'])[0])
}
/**
* @return {Element}
* @protected
*/
Tooltip.prototype.getArrowElement = function () {
return (this.arrow = this.arrow || $(this.getTipElement()).find(Tooltip._Selector.TOOLTIP_ARROW)[0])
}
/**
* @return {boolean}
* @protected
*/
Tooltip.prototype.isWithContent = function () {
return !!this.getTitle()
}
/**
* @protected
*/
Tooltip.prototype.setContent = function () {
var tip = this.getTipElement()
var title = this.getTitle()
$(tip).find(Tooltip._Selector.TOOLTIP_INNER)[0][this.config['html'] ? 'innerHTML' : 'innerText'] = title
$(tip)
.removeClass(Tooltip._ClassName.FADE)
.removeClass(Tooltip._ClassName.IN)
for (var direction in Tooltip.Direction) {
$(tip).removeClass(Tooltip._NAME + '-' + direction)
}
}
/**
* @private
*/
Tooltip.prototype._setListeners = function () {
var triggers = this.config['trigger'].split(' ')
triggers.forEach(function (trigger) {
if (trigger == 'click') {
$(this.element).on('click.bs.tooltip', this.config['selector'], this['toggle'].bind(this))
} else if (trigger != 'manual') {
var eventIn = trigger == 'hover' ? 'mouseenter' : 'focusin'
var eventOut = trigger == 'hover' ? 'mouseleave' : 'focusout'
$(this.element)
.on(eventIn + '.bs.tooltip', this.config['selector'], this._enter.bind(this))
.on(eventOut + '.bs.tooltip', this.config['selector'], this._leave.bind(this))
}
}.bind(this))
if (this.config['selector']) {
this.config = $.extend({}, this.config, { 'trigger': 'manual', 'selector': '' })
} else {
this._fixTitle()
}
}
/**
* @param {Object=} opt_config
* @return {Object}
* @private
*/
Tooltip.prototype._getConfig = function (opt_config) {
var config = $.extend({}, this.constructor['Defaults'], $(this.element).data(), opt_config)
if (config['delay'] && typeof config['delay'] == 'number') {
config['delay'] = {
'show': config['delay'],
'hide': config['delay']
}
}
return config
}
/**
* @return {Object}
* @private
*/
Tooltip.prototype._getDelegateConfig = function () {
var config = {}
var defaults = this.constructor['Defaults']
if (this.config) {
for (var key in this.config) {
var value = this.config[key]
if (defaults[key] != value) config[key] = value
}
}
return config
}
/**
* @param {boolean} isWithAutoPlacement
* @param {string} placement
* @param {Object} position
* @param {number} actualWidth
* @param {number} actualHeight
* @return {string}
* @private
*/
Tooltip.prototype._getCalculatedAutoPlacement = function (isWithAutoPlacement, placement, position, actualWidth, actualHeight) {
if (isWithAutoPlacement) {
var originalPlacement = placement
var container = this.config['container'] ? $(this.config['container'])[0] : this.element.parentNode
var containerDim = this._getPosition(/** @type {Element} */ (container))
placement = placement == Tooltip.Direction.BOTTOM && position.bottom + actualHeight > containerDim.bottom ? Tooltip.Direction.TOP :
placement == Tooltip.Direction.TOP && position.top - actualHeight < containerDim.top ? Tooltip.Direction.BOTTOM :
placement == Tooltip.Direction.RIGHT && position.right + actualWidth > containerDim.width ? Tooltip.Direction.LEFT :
placement == Tooltip.Direction.LEFT && position.left - actualWidth < containerDim.left ? Tooltip.Direction.RIGHT :
placement
$(this._tip)
.removeClass(Tooltip._NAME + '-' + originalPlacement)
.addClass(Tooltip._NAME + '-' + placement)
}
return placement
}
/**
* @param {string} placement
* @param {Object} position
* @param {number} actualWidth
* @param {number} actualHeight
* @return {{left: number, top: number}}
* @private
*/
Tooltip.prototype._getCalculatedOffset = function (placement, position, actualWidth, actualHeight) {
return placement == Tooltip.Direction.BOTTOM ? { top: position.top + position.height, left: position.left + position.width / 2 - actualWidth / 2 } :
placement == Tooltip.Direction.TOP ? { top: position.top - actualHeight, left: position.left + position.width / 2 - actualWidth / 2 } :
placement == Tooltip.Direction.LEFT ? { top: position.top + position.height / 2 - actualHeight / 2, left: position.left - actualWidth } :
/* placement == Tooltip.Direction.RIGHT */ { top: position.top + position.height / 2 - actualHeight / 2, left: position.left + position.width }
}
/**
* @param {string} placement
* @param {Object} position
* @param {number} actualWidth
* @param {number} actualHeight
* @return {Object}
* @private
*/
Tooltip.prototype._getViewportAdjustedDelta = function (placement, position, actualWidth, actualHeight) {
var delta = { top: 0, left: 0 }
if (!this._viewport) {
return delta
}
var viewportPadding = this.config['viewport'] && this.config['viewport']['padding'] || 0
var viewportDimensions = this._getPosition(this._viewport)
if (placement === Tooltip.Direction.RIGHT || placement === Tooltip.Direction.LEFT) {
var topEdgeOffset = position.top - viewportPadding - viewportDimensions.scroll
var bottomEdgeOffset = position.top + viewportPadding - viewportDimensions.scroll + actualHeight
if (topEdgeOffset < viewportDimensions.top) { // top overflow
delta.top = viewportDimensions.top - topEdgeOffset
} else if (bottomEdgeOffset > viewportDimensions.top + viewportDimensions.height) { // bottom overflow
delta.top = viewportDimensions.top + viewportDimensions.height - bottomEdgeOffset
}
} else {
var leftEdgeOffset = position.left - viewportPadding
var rightEdgeOffset = position.left + viewportPadding + actualWidth
if (leftEdgeOffset < viewportDimensions.left) { // left overflow
delta.left = viewportDimensions.left - leftEdgeOffset
} else if (rightEdgeOffset > viewportDimensions.width) { // right overflow
delta.left = viewportDimensions.left + viewportDimensions.width - rightEdgeOffset
}
}
return delta
}
/**
* @param {Element=} opt_element
* @return {Object}
* @private
*/
Tooltip.prototype._getPosition = function (opt_element) {
var element = opt_element || this.element
var isBody = element.tagName == 'BODY'
var rect = element.getBoundingClientRect()
var offset = isBody ? { top: 0, left: 0 } : $(element).offset()
var scroll = { scroll: isBody ? document.documentElement.scrollTop || document.body.scrollTop : this.element.scrollTop }
var outerDims = isBody ? { width: window.innerWidth, height: window.innerHeight } : null
return $.extend({}, rect, scroll, outerDims, offset)
}
/**
* @param {{left: number, top: number}} offset
* @param {string} placement
* @private
*/
Tooltip.prototype._applyCalculatedPlacement = function (offset, placement) {
var tip = this.getTipElement()
var width = tip.offsetWidth
var height = tip.offsetHeight
// manually read margins because getBoundingClientRect includes difference
var marginTop = parseInt(tip.style.marginTop, 10)
var marginLeft = parseInt(tip.style.marginLeft, 10)
// we must check for NaN for ie 8/9
if (isNaN(marginTop)) {
marginTop = 0
}
if (isNaN(marginLeft)) {
marginLeft = 0
}
offset.top = offset.top + marginTop
offset.left = offset.left + marginLeft
// $.fn.offset doesn't round pixel values
// so we use setOffset directly with our own function B-0
$.offset.setOffset(tip, $.extend({
using: function (props) {
tip.style.top = Math.round(props.top) + 'px'
tip.style.left = Math.round(props.left) + 'px'
}
}, offset), 0)
$(tip).addClass(Tooltip._ClassName.IN)
// check to see if placing tip in new offset caused the tip to resize itself
var actualWidth = tip.offsetWidth
var actualHeight = tip.offsetHeight
if (placement == Tooltip.Direction.TOP && actualHeight != height) {
offset.top = offset.top + height - actualHeight
}
var delta = this._getViewportAdjustedDelta(placement, offset, actualWidth, actualHeight)
if (delta.left) {
offset.left += delta.left
} else {
offset.top += delta.top
}
var isVertical = placement === Tooltip.Direction.TOP || placement === Tooltip.Direction.BOTTOM
var arrowDelta = isVertical ? delta.left * 2 - width + actualWidth : delta.top * 2 - height + actualHeight
var arrowOffsetPosition = isVertical ? 'offsetWidth' : 'offsetHeight'
$(tip).offset(offset)
this._replaceArrow(arrowDelta, tip[arrowOffsetPosition], isVertical)
}
/**
* @param {number} delta
* @param {number} dimension
* @param {boolean} isHorizontal
* @private
*/
Tooltip.prototype._replaceArrow = function (delta, dimension, isHorizontal) {
var arrow = this.getArrowElement()
arrow.style[isHorizontal ? 'left' : 'top'] = 50 * (1 - delta / dimension) + '%'
arrow.style[isHorizontal ? 'top' : 'left'] = ''
}
/**
* @private
*/
Tooltip.prototype._fixTitle = function () {
if (this.element.getAttribute('title') || typeof this.element.getAttribute('data-original-title') != 'string') {
this.element.setAttribute('data-original-title', this.element.getAttribute('title') || '')
this.element.setAttribute('title', '')
}
}
/**
* @param {Event=} opt_event
* @param {Object=} opt_context
* @private
*/
Tooltip.prototype._enter = function (opt_event, opt_context) {
var dataKey = this.getDataKey()
var context = opt_context || $(opt_event.currentTarget).data(dataKey)
if (context && context._tip && context._tip.offsetWidth) {
context._hoverState = Tooltip._HoverState.IN
return
}
if (!context) {
context = new this.constructor(opt_event.currentTarget, this._getDelegateConfig())
$(opt_event.currentTarget).data(dataKey, context)
}
clearTimeout(context._timeout)
context._hoverState = Tooltip._HoverState.IN
if (!context.config['delay'] || !context.config['delay']['show']) {
context['show']()
return
}
context._timeout = setTimeout(function () {
if (context._hoverState == Tooltip._HoverState.IN) {
context['show']()
}
}, context.config['delay']['show'])
}
/**
* @param {Event=} opt_event
* @param {Object=} opt_context
* @private
*/
Tooltip.prototype._leave = function (opt_event, opt_context) {
var dataKey = this.getDataKey()
var context = opt_context || $(opt_event.currentTarget).data(dataKey)
if (!context) {
context = new this.constructor(opt_event.currentTarget, this._getDelegateConfig())
$(opt_event.currentTarget).data(dataKey, context)
}
clearTimeout(context._timeout)
context._hoverState = Tooltip._HoverState.OUT
if (!context.config['delay'] || !context.config['delay']['hide']) {
context['hide']()
return
}
context._timeout = setTimeout(function () {
if (context._hoverState == Tooltip._HoverState.OUT) {
context['hide']()
}
}, context.config['delay']['hide'])
}
/**
* ------------------------------------------------------------------------
* jQuery Interface + noConflict implementaiton
* ------------------------------------------------------------------------
*/
/**
* @const
* @type {Function}
*/
$.fn[Tooltip._NAME] = Tooltip._jQueryInterface
/**
* @const
* @type {Function}
*/
$.fn[Tooltip._NAME]['Constructor'] = Tooltip
/**
* @const
* @type {Function}
*/
$.fn[Tooltip._NAME]['noConflict'] = function () {
$.fn[Tooltip._NAME] = Tooltip._JQUERY_NO_CONFLICT
return this
}
/** =======================================================================
* Bootstrap: popover.js v4.0.0
* http://getbootstrap.com/javascript/#popovers
* ========================================================================
* Copyright 2011-2015 Twitter, Inc.
* Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
* ========================================================================
* @fileoverview - Bootstrap's popover plugin - extends tooltip.
*
* Public Methods & Properties:
*
* + $.popover
* + $.popover.noConflict
* + $.popover.Constructor
* + $.popover.Constructor.VERSION
* + $.popover.Constructor.Defaults
* + $.popover.Constructor.Defaults.container
* + $.popover.Constructor.Defaults.animation
* + $.popover.Constructor.Defaults.placement
* + $.popover.Constructor.Defaults.selector
* + $.popover.Constructor.Defaults.template
* + $.popover.Constructor.Defaults.trigger
* + $.popover.Constructor.Defaults.title
* + $.popover.Constructor.Defaults.content
* + $.popover.Constructor.Defaults.delay
* + $.popover.Constructor.Defaults.html
* + $.popover.Constructor.Defaults.viewport
* + $.popover.Constructor.Defaults.viewport.selector
* + $.popover.Constructor.Defaults.viewport.padding
* + $.popover.Constructor.prototype.enable
* + $.popover.Constructor.prototype.disable
* + $.popover.Constructor.prototype.destroy
* + $.popover.Constructor.prototype.toggleEnabled
* + $.popover.Constructor.prototype.toggle
* + $.popover.Constructor.prototype.show
* + $.popover.Constructor.prototype.hide
*
* ========================================================================
*/
'use strict';
if (!Tooltip) throw new Error('Popover requires tooltip.js')
/**
* Our tooltip class.
* @param {Element!} element
* @param {Object=} opt_config
* @constructor
* @extends {Tooltip}
*/
var Popover = function (element, opt_config) {
Tooltip.apply(this, arguments)
}
Bootstrap.inherits(Popover, Tooltip)
/**
* @const
* @type {string}
*/
Popover['VERSION'] = '4.0.0'
/**
* @const
* @type {Object}
*/
Popover['Defaults'] = $.extend({}, $.fn['tooltip']['Constructor']['Defaults'], {
'placement': 'right',
'trigger': 'click',
'content': '',
'template': '<div class="popover" role="tooltip"><div class="popover-arrow"></div><h3 class="popover-title"></h3><div class="popover-content"></div></div>'
})
/**
* @const
* @type {string}
* @private
*/
Popover._NAME = 'popover'
/**
* @const
* @type {string}
* @private
*/
Popover._DATA_KEY = 'bs.popover'
/**
* @const
* @enum {string}
* @private
*/
Popover._Event = {
HIDE : 'hide.bs.popover',
HIDDEN : 'hidden.bs.popover',
SHOW : 'show.bs.popover',
SHOWN : 'shown.bs.popover'
}
/**
* @const
* @enum {string}
* @private
*/
Popover._ClassName = {
FADE : 'fade',
IN : 'in'
}
/**
* @const
* @enum {string}
* @private
*/
Popover._Selector = {
TITLE : '.popover-title',
CONTENT : '.popover-content',
ARROW : '.popover-arrow'
}
/**
* @const
* @type {Function}
* @private
*/
Popover._JQUERY_NO_CONFLICT = $.fn[Popover._NAME]
/**
* @param {Object|string=} opt_config
* @this {jQuery}
* @return {jQuery}
* @private
*/
Popover._jQueryInterface = function (opt_config) {
return this.each(function () {
var data = $(this).data(Popover._DATA_KEY)
var config = typeof opt_config === 'object' ? opt_config : null
if (!data && opt_config === 'destroy') {
return
}
if (!data) {
data = new Popover(this, config)
$(this).data(Popover._DATA_KEY, data)
}
if (typeof opt_config === 'string') {
data[opt_config]()
}
})
}
/**
* @return {string}
* @protected
*/
Popover.prototype.getName = function () {
return Popover._NAME
}
/**
* @override
*/
Popover.prototype.getDataKey = function () {
return Popover._DATA_KEY
}
/**
* @override
*/
Popover.prototype.getEventObject = function () {
return Popover._Event
}
/**
* @override
*/
Popover.prototype.getArrowElement = function () {
return (this.arrow = this.arrow || $(this.getTipElement()).find(Popover._Selector.ARROW)[0])
}
/**
* @override
*/
Popover.prototype.setContent = function () {
var tip = this.getTipElement()
var title = this.getTitle()
var content = this._getContent()
var titleElement = $(tip).find(Popover._Selector.TITLE)[0]
if (titleElement) {
titleElement[this.config['html'] ? 'innerHTML' : 'innerText'] = title
}
// we use append for html objects to maintain js events
$(tip).find(Popover._Selector.CONTENT).children().detach().end()[
this.config['html'] ? (typeof content == 'string' ? 'html' : 'append') : 'text'
](content)
$(tip)
.removeClass(Popover._ClassName.FADE)
.removeClass(Popover._ClassName.IN)
for (var direction in Tooltip.Direction) {
$(tip).removeClass(Popover._NAME + '-' + Tooltip.Direction[direction])
}
}
/**
* @override
*/
Popover.prototype.isWithContent = function () {
return this.getTitle() || this._getContent()
}
/**
* @override
*/
Popover.prototype.getTipElement = function () {
return (this.tip = this.tip || $(this.config['template'])[0])
}
/**
* @private
*/
Popover.prototype._getContent = function () {
return this.element.getAttribute('data-content')
|| (typeof this.config['content'] == 'function' ?
this.config['content'].call(this.element) :
this.config['content'])
}
/**
* ------------------------------------------------------------------------
* jQuery Interface + noConflict implementaiton
* ------------------------------------------------------------------------
*/
/**
* @const
* @type {Function}
*/
$.fn[Popover._NAME] = Popover._jQueryInterface
/**
* @const
* @type {Function}
*/
$.fn[Popover._NAME]['Constructor'] = Popover
/**
* @const
* @type {Function}
*/
$.fn[Popover._NAME]['noConflict'] = function () {
$.fn[Popover._NAME] = Popover._JQUERY_NO_CONFLICT
return this
}
/** =======================================================================
* Bootstrap: tab.js v4.0.0
* http://getbootstrap.com/javascript/#tabs
* ========================================================================
* Copyright 2011-2015 Twitter, Inc.
* Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
* ======================================================================== */
+function ($) {
'use strict';
// TAB CLASS DEFINITION
// ====================
var Tab = function (element) {
this.element = $(element)
}
Tab.VERSION = '3.3.2'
Tab.TRANSITION_DURATION = 150
Tab.prototype.show = function () {
var $this = this.element
var $ul = $this.closest('ul:not(.dropdown-menu)')
var selector = $this.data('target')
if (!selector) {
selector = $this.attr('href')
selector = selector && selector.replace(/.*(?=#[^\s]*$)/, '') // strip for ie7
}
if ($this.parent('li').hasClass('active')) return
var $previous = $ul.find('.active:last a')
var hideEvent = $.Event('hide.bs.tab', {
relatedTarget: $this[0]
})
var showEvent = $.Event('show.bs.tab', {
relatedTarget: $previous[0]
})
$previous.trigger(hideEvent)
$this.trigger(showEvent)
if (showEvent.isDefaultPrevented() || hideEvent.isDefaultPrevented()) return
var $target = $(selector)
this.activate($this.closest('li'), $ul)
this.activate($target, $target.parent(), function () {
$previous.trigger({
type: 'hidden.bs.tab',
relatedTarget: $this[0]
})
$this.trigger({
type: 'shown.bs.tab',
relatedTarget: $previous[0]
})
})
}
Tab.prototype.activate = function (element, container, callback) {
var $active = container.find('> .active')
var transition = callback
&& $.support.transition
&& (($active.length && $active.hasClass('fade')) || !!container.find('> .fade').length)
function next() {
$active
.removeClass('active')
.find('> .dropdown-menu > .active')
.removeClass('active')
.end()
.find('[data-toggle="tab"]')
.attr('aria-expanded', false)
element
.addClass('active')
.find('[data-toggle="tab"]')
.attr('aria-expanded', true)
if (transition) {
element[0].offsetWidth // reflow for transition
element.addClass('in')
} else {
element.removeClass('fade')
}
if (element.parent('.dropdown-menu').length) {
element
.closest('li.dropdown')
.addClass('active')
.end()
.find('[data-toggle="tab"]')
.attr('aria-expanded', true)
}
callback && callback()
}
$active.length && transition ?
$active
.one('bsTransitionEnd', next)
.emulateTransitionEnd(Tab.TRANSITION_DURATION) :
next()
$active.removeClass('in')
}
// TAB PLUGIN DEFINITION
// =====================
function Plugin(option) {
return this.each(function () {
var $this = $(this)
var data = $this.data('bs.tab')
if (!data) $this.data('bs.tab', (data = new Tab(this)))
if (typeof option == 'string') data[option]()
})
}
var old = $.fn.tab
$.fn.tab = Plugin
$.fn.tab.Constructor = Tab
// TAB NO CONFLICT
// ===============
$.fn.tab.noConflict = function () {
$.fn.tab = old
return this
}
// TAB DATA-API
// ============
var clickHandler = function (e) {
e.preventDefault()
Plugin.call($(this), 'show')
}
$(document)
.on('click.bs.tab.data-api', '[data-toggle="tab"]', clickHandler)
.on('click.bs.tab.data-api', '[data-toggle="pill"]', clickHandler)
}(jQuery);
/* ========================================================================
* Bootstrap: affix.js v3.3.2
* http://getbootstrap.com/javascript/#affix
* ========================================================================
* Copyright 2011-2015 Twitter, Inc.
* Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
* ======================================================================== */
* @fileoverview - Bootstrap's tab plugin. Tab O_O
*
* Public Methods & Properties:
*
* + $.tab
* + $.tab.noConflict
* + $.tab.Constructor
* + $.tab.Constructor.VERSION
* + $.tab.Constructor.prototype.show
*
* ========================================================================
*/
+function ($) {
'use strict';
'use strict';
// AFFIX CLASS DEFINITION
// ======================
/**
* Our Tab class.
* @param {Element!} element
* @constructor
*/
var Tab = function (element) {
var Affix = function (element, options) {
this.options = $.extend({}, Affix.DEFAULTS, options)
/** @type {Element} */
this._element = element
this.$target = $(this.options.target)
.on('scroll.bs.affix.data-api', $.proxy(this.checkPosition, this))
.on('click.bs.affix.data-api', $.proxy(this.checkPositionWithEventLoop, this))
}
this.$element = $(element)
this.affixed = null
this.unpin = null
this.pinnedOffset = null
this.checkPosition()
}
/**
* @const
* @type {string}
*/
Tab['VERSION'] = '4.0.0'
Affix.VERSION = '3.3.2'
Affix.RESET = 'affix affix-top affix-bottom'
/**
* @const
* @type {string}
* @private
*/
Tab._NAME = 'tab'
Affix.DEFAULTS = {
offset: 0,
target: window
}
Affix.prototype.getState = function (scrollHeight, height, offsetTop, offsetBottom) {
var scrollTop = this.$target.scrollTop()
var position = this.$element.offset()
var targetHeight = this.$target.height()
/**
* @const
* @type {string}
* @private
*/
Tab._DATA_KEY = 'bs.tab'
if (offsetTop != null && this.affixed == 'top') return scrollTop < offsetTop ? 'top' : false
if (this.affixed == 'bottom') {
if (offsetTop != null) return (scrollTop + this.unpin <= position.top) ? false : 'bottom'
return (scrollTop + targetHeight <= scrollHeight - offsetBottom) ? false : 'bottom'
/**
* @const
* @type {number}
* @private
*/
Tab._TRANSITION_DURATION = 150
/**
* @const
* @enum {string}
* @private
*/
Tab._Event = {
HIDE : 'hide.bs.tab',
HIDDEN : 'hidden.bs.tab',
SHOW : 'show.bs.tab',
SHOWN : 'shown.bs.tab'
}
/**
* @const
* @enum {string}
* @private
*/
Tab._ClassName = {
DROPDOWN_MENU : 'dropdown-menu',
ACTIVE : 'active',
FADE : 'fade',
IN : 'in'
}
/**
* @const
* @enum {string}
* @private
*/
Tab._Selector = {
A : 'a',
LI : 'li',
LI_DROPDOWN : 'li.dropdown',
UL : 'ul:not(.dropdown-menu)',
FADE_CHILD : ':scope > .fade',
ACTIVE : '.active',
ACTIVE_CHILD : ':scope > .active',
DATA_TOGGLE : '[data-toggle="tab"], [data-toggle="pill"]',
DROPDOWN_ACTIVE_CHILD : ':scope > .dropdown-menu > .active'
}
/**
* @param {Object|string=} opt_config
* @this {jQuery}
* @return {jQuery}
* @private
*/
Tab._jQueryInterface = function (opt_config) {
return this.each(function () {
var $this = $(this)
var data = $this.data(Tab._DATA_KEY)
if (!data) {
data = data = new Tab(this)
$this.data(Tab._DATA_KEY, data)
}
var initializing = this.affixed == null
var colliderTop = initializing ? scrollTop : position.top
var colliderHeight = initializing ? targetHeight : height
if (offsetTop != null && scrollTop <= offsetTop) return 'top'
if (offsetBottom != null && (colliderTop + colliderHeight >= scrollHeight - offsetBottom)) return 'bottom'
return false
}
Affix.prototype.getPinnedOffset = function () {
if (this.pinnedOffset) return this.pinnedOffset
this.$element.removeClass(Affix.RESET).addClass('affix')
var scrollTop = this.$target.scrollTop()
var position = this.$element.offset()
return (this.pinnedOffset = position.top - scrollTop)
}
Affix.prototype.checkPositionWithEventLoop = function () {
setTimeout($.proxy(this.checkPosition, this), 1)
}
Affix.prototype.checkPosition = function () {
if (!this.$element.is(':visible')) return
var height = this.$element.height()
var offset = this.options.offset
var offsetTop = offset.top
var offsetBottom = offset.bottom
var scrollHeight = $('body').height()
if (typeof offset != 'object') offsetBottom = offsetTop = offset
if (typeof offsetTop == 'function') offsetTop = offset.top(this.$element)
if (typeof offsetBottom == 'function') offsetBottom = offset.bottom(this.$element)
var affix = this.getState(scrollHeight, height, offsetTop, offsetBottom)
if (this.affixed != affix) {
if (this.unpin != null) this.$element.css('top', '')
var affixType = 'affix' + (affix ? '-' + affix : '')
var e = $.Event(affixType + '.bs.affix')
this.$element.trigger(e)
if (e.isDefaultPrevented()) return
this.affixed = affix
this.unpin = affix == 'bottom' ? this.getPinnedOffset() : null
this.$element
.removeClass(Affix.RESET)
.addClass(affixType)
.trigger(affixType.replace('affix', 'affixed') + '.bs.affix')
if (typeof opt_config === 'string') {
data[opt_config]()
}
})
}
if (affix == 'bottom') {
this.$element.offset({
top: scrollHeight - height - offsetBottom
})
/**
* Show the tab
*/
Tab.prototype['show'] = function () {
if ( this._element.parentNode
&& this._element.parentNode.nodeType == Node.ELEMENT_NODE
&& $(this._element).parent().hasClass(Tab._ClassName.ACTIVE)) {
return
}
var ulElement = $(this._element).closest(Tab._Selector.UL)[0]
var selector = Bootstrap.getSelectorFromElement(this._element)
if (ulElement) {
var previous = /** @type {Array.<Element>} */ ($.makeArray($(ulElement).find(Tab._Selector.ACTIVE)))
previous = previous[previous.length - 1]
if (previous) {
previous = $(previous).find('a')[0]
}
}
// AFFIX PLUGIN DEFINITION
// =======================
function Plugin(option) {
return this.each(function () {
var $this = $(this)
var data = $this.data('bs.affix')
var options = typeof option == 'object' && option
if (!data) $this.data('bs.affix', (data = new Affix(this, options)))
if (typeof option == 'string') data[option]()
})
}
var old = $.fn.affix
$.fn.affix = Plugin
$.fn.affix.Constructor = Affix
// AFFIX NO CONFLICT
// =================
$.fn.affix.noConflict = function () {
$.fn.affix = old
return this
}
// AFFIX DATA-API
// ==============
$(window).on('load', function () {
$('[data-spy="affix"]').each(function () {
var $spy = $(this)
var data = $spy.data()
data.offset = data.offset || {}
if (data.offsetBottom != null) data.offset.bottom = data.offsetBottom
if (data.offsetTop != null) data.offset.top = data.offsetTop
Plugin.call($spy, data)
})
var hideEvent = $.Event(Tab._Event.HIDE, {
relatedTarget: this._element
})
}(jQuery);
var showEvent = $.Event(Tab._Event.SHOW, {
relatedTarget: previous
})
if (previous) {
$(previous).trigger(hideEvent)
}
$(this._element).trigger(showEvent)
if (showEvent.isDefaultPrevented() || hideEvent.isDefaultPrevented()) return
if (selector) {
var target = $(selector)[0]
}
this._activate($(this._element).closest(Tab._Selector.LI)[0], ulElement)
var complete = function () {
var hiddenEvent = $.Event(Tab._Event.HIDDEN, {
relatedTarget: this._element
})
var shownEvent = $.Event(Tab._Event.SHOWN, {
relatedTarget: previous
})
$(previous).trigger(hiddenEvent)
$(this._element).trigger(shownEvent)
}.bind(this)
if (target) {
this._activate(target, /** @type {Element} */ (target.parentNode), complete)
} else {
complete()
}
}
/**
* @param {Element} element
* @param {Element} container
* @param {Function=} opt_callback
* @private
*/
Tab.prototype._activate = function (element, container, opt_callback) {
var active = $(container).find(Tab._Selector.ACTIVE_CHILD)[0]
var isTransitioning = opt_callback
&& Bootstrap.transition
&& ((active && $(active).hasClass(Tab._ClassName.FADE))
|| !!$(container).find(Tab._Selector.FADE_CHILD)[0])
var complete = this._transitionComplete.bind(this, element, active, isTransitioning, opt_callback)
if (active && isTransitioning) {
$(active)
.one(Bootstrap.TRANSITION_END, complete)
.emulateTransitionEnd(Tab._TRANSITION_DURATION)
} else {
complete()
}
if (active) {
$(active).removeClass(Tab._ClassName.IN)
}
}
/**
* @param {Element} element
* @param {Element} active
* @param {boolean} isTransitioning
* @param {Function=} opt_callback
* @private
*/
Tab.prototype._transitionComplete = function (element, active, isTransitioning, opt_callback) {
if (active) {
$(active).removeClass(Tab._ClassName.ACTIVE)
var dropdownChild = $(active).find(Tab._Selector.DROPDOWN_ACTIVE_CHILD)[0]
if (dropdownChild) {
$(dropdownChild).removeClass(Tab._ClassName.ACTIVE)
}
var activeToggle = $(active).find(Tab._Selector.DATA_TOGGLE)[0]
if (activeToggle) {
activeToggle.setAttribute('aria-expanded', false)
}
}
$(element).addClass(Tab._ClassName.ACTIVE)
var elementToggle = $(element).find(Tab._Selector.DATA_TOGGLE)[0]
if (elementToggle) {
elementToggle.setAttribute('aria-expanded', true)
}
if (isTransitioning) {
Bootstrap.reflow(element)
$(element).addClass(Tab._ClassName.IN)
} else {
$(element).removeClass(Tab._ClassName.FADE)
}
if (element.parentNode && $(element.parentNode).hasClass(Tab._ClassName.DROPDOWN_MENU)) {
var dropdownElement = $(element).closest(Tab._Selector.LI_DROPDOWN)[0]
if (dropdownElement) {
$(dropdownElement).addClass(Tab._ClassName.ACTIVE)
}
elementToggle = $(element).find(Tab._Selector.DATA_TOGGLE)[0]
if (elementToggle) {
elementToggle.setAttribute('aria-expanded', true)
}
}
if (opt_callback) {
opt_callback()
}
}
/**
* ------------------------------------------------------------------------
* jQuery Interface + noConflict implementaiton
* ------------------------------------------------------------------------
*/
/**
* @const
* @type {Function}
*/
$.fn[Tab._NAME] = Tab._jQueryInterface
/**
* @const
* @type {Function}
*/
$.fn[Tab._NAME]['Constructor'] = Tab
/**
* @const
* @type {Function}
*/
$.fn[Tab._NAME]['noConflict'] = function () {
$.fn[Tab._NAME] = Tab._JQUERY_NO_CONFLICT
return this
}
// TAB DATA-API
// ============
var clickHandler = function (e) {
e.preventDefault()
Tab._jQueryInterface.call($(this), 'show')
}
$(document)
.on('click.bs.tab.data-api', Tab._Selector.DATA_TOGGLE, clickHandler)

File diff suppressed because one or more lines are too long

4
docs/dist/js/npm.js vendored
View File

@ -1,12 +1,12 @@
// This file is autogenerated via the `commonjs` Grunt task. You can require() this file in a CommonJS environment.
require('../../js/transition.js')
require('../../js/util.js')
require('../../js/alert.js')
require('../../js/button.js')
require('../../js/carousel.js')
require('../../js/collapse.js')
require('../../js/dropdown.js')
require('../../js/modal.js')
require('../../js/scrollspy.js')
require('../../js/tooltip.js')
require('../../js/popover.js')
require('../../js/scrollspy.js')
require('../../js/tab.js')