Caldera Forms – More Than Contact Forms - Version 1.5.0.7

Version Description

See: https://calderaforms.com/updates/caldera-forms-1.5.0.7

Download this release

Release Info

Developer Shelob9
Plugin Icon 128x128 Caldera Forms – More Than Contact Forms
Version 1.5.0.7
Comparing to
See all releases

Code changes from version 1.5.0.6 to 1.5.0.7

README.md CHANGED
@@ -13,7 +13,7 @@ Caldera-Forms
13
 
14
 
15
  ### Contributing/ Using This Repo, Etc.
16
- * The default branch is "master" that should be the same as WordPress.org
17
  * Development happens on the "develop" branch.
18
- * If you find a bug, or would like to make a feature request, [please open an issue]()https://github.com/CalderaWP/Caldera-Forms/issues/ .
19
  * If you fixed a bug, or made a new feature, please submit a pull request against the develop branch.
13
 
14
 
15
  ### Contributing/ Using This Repo, Etc.
16
+ * The default branch is "master" that should be the same as WordPress.org.
17
  * Development happens on the "develop" branch.
18
+ * If you find a bug, or would like to make a feature request, [please open an issue]()https://github.com/CalderaWP/Caldera-Forms/issues/.
19
  * If you fixed a bug, or made a new feature, please submit a pull request against the develop branch.
assets/build/css/caldera-forms-front.min.css CHANGED
@@ -1 +1 @@
1
- /*! GENERATED SOURCE FILE caldera-forms - v1.5.0.6 - 2017-03-14 */.caldera-grid html,.cf-toggle-switch html{-ms-text-size-adjust:100%;-webkit-text-size-adjust:100%}.caldera-grid .sr-only,.caldera-grid svg:not(:root),.cf-toggle-switch svg:not(:root){overflow:hidden}.caldera-grid .btn,.cfdatepicker table{-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none}.caldera-grid button,.caldera-grid select,.cf-toggle-switch button,.cf-toggle-switch select{text-transform:none}@media (min-width:768px){.caldera-grid .container{width:750px}}@media (min-width:992px){.caldera-grid .container{width:970px}}@media (min-width:1200px){.caldera-grid .container{width:1170px}}.caldera-grid article,.caldera-grid aside,.caldera-grid details,.caldera-grid figcaption,.caldera-grid figure,.caldera-grid footer,.caldera-grid header,.caldera-grid hgroup,.caldera-grid main,.caldera-grid nav,.caldera-grid section,.caldera-grid summary{display:block}.caldera-grid a{background:0 0;text-decoration:none}.caldera-grid img{vertical-align:middle}.caldera-grid *,.caldera-grid :after,.caldera-grid :before{-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box}.caldera-grid html{font-size:62.5%;-webkit-tap-highlight-color:transparent}.caldera-grid body{font-family:"Helvetica Neue",Helvetica,Arial,sans-serif;font-size:14px;line-height:1.42857143;color:#333;background-color:#fff}.caldera-grid button,.caldera-grid input,.caldera-grid select,.caldera-grid textarea{font-family:inherit;font-size:inherit;line-height:inherit}.caldera-grid a:focus,.caldera-grid a:hover{color:#2a6496;text-decoration:underline}.caldera-grid a:focus{outline:dotted thin;outline:-webkit-focus-ring-color auto 5px;outline-offset:-2px}.caldera-grid .img-responsive{display:block;max-width:100%;height:auto}.caldera-grid .img-rounded{border-radius:6px}.caldera-grid .img-thumbnail{padding:4px;line-height:1.42857143;background-color:#fff;border:1px solid #ddd;border-radius:4px;-webkit-transition:all .2s ease-in-out;transition:all .2s ease-in-out;display:inline-block;max-width:100%;height:auto}.caldera-grid .img-circle{border-radius:50%}.caldera-grid hr{margin-top:20px;margin-bottom:20px;border:0;border-top:1px solid #eee}.caldera-grid .sr-only{position:absolute;width:1px;height:1px;margin:-1px;padding:0;clip:rect(0,0,0,0);border:0}.caldera-grid .container,.caldera-grid .container-fluid{margin-right:auto;margin-left:auto;padding-left:7.5px;padding-right:7.5px}@media (min-width:768px){.caldera-grid .container{width:735px}}@media (min-width:992px){.caldera-grid .container{width:955px}}@media (min-width:1200px){.caldera-grid .container{width:1155px}}.caldera-grid .row{margin-left:-7.5px;margin-right:-7.5px}.caldera-grid .col-lg-1,.caldera-grid .col-lg-10,.caldera-grid .col-lg-11,.caldera-grid .col-lg-12,.caldera-grid .col-lg-2,.caldera-grid .col-lg-3,.caldera-grid .col-lg-4,.caldera-grid .col-lg-5,.caldera-grid .col-lg-6,.caldera-grid .col-lg-7,.caldera-grid .col-lg-8,.caldera-grid .col-lg-9,.caldera-grid .col-md-1,.caldera-grid .col-md-10,.caldera-grid .col-md-11,.caldera-grid .col-md-12,.caldera-grid .col-md-2,.caldera-grid .col-md-3,.caldera-grid .col-md-4,.caldera-grid .col-md-5,.caldera-grid .col-md-6,.caldera-grid .col-md-7,.caldera-grid .col-md-8,.caldera-grid .col-md-9,.caldera-grid .col-sm-1,.caldera-grid .col-sm-10,.caldera-grid .col-sm-11,.caldera-grid .col-sm-12,.caldera-grid .col-sm-2,.caldera-grid .col-sm-3,.caldera-grid .col-sm-4,.caldera-grid .col-sm-5,.caldera-grid .col-sm-6,.caldera-grid .col-sm-7,.caldera-grid .col-sm-8,.caldera-grid .col-sm-9,.caldera-grid .col-xs-1,.caldera-grid .col-xs-10,.caldera-grid .col-xs-11,.caldera-grid .col-xs-12,.caldera-grid .col-xs-2,.caldera-grid .col-xs-3,.caldera-grid .col-xs-4,.caldera-grid .col-xs-5,.caldera-grid .col-xs-6,.caldera-grid .col-xs-7,.caldera-grid .col-xs-8,.caldera-grid .col-xs-9{position:relative;padding-left:7.5px;padding-right:7.5px}.caldera-grid .col-xs-1,.caldera-grid .col-xs-10,.caldera-grid .col-xs-11,.caldera-grid .col-xs-12,.caldera-grid .col-xs-2,.caldera-grid .col-xs-3,.caldera-grid .col-xs-4,.caldera-grid .col-xs-5,.caldera-grid .col-xs-6,.caldera-grid .col-xs-7,.caldera-grid .col-xs-8,.caldera-grid .col-xs-9{float:left}.caldera-grid .col-xs-12{width:100%}.caldera-grid .col-xs-11{width:91.66666667%}.caldera-grid .col-xs-10{width:83.33333333%}.caldera-grid .col-xs-9{width:75%}.caldera-grid .col-xs-8{width:66.66666667%}.caldera-grid .col-xs-7{width:58.33333333%}.caldera-grid .col-xs-6{width:50%}.caldera-grid .col-xs-5{width:41.66666667%}.caldera-grid .col-xs-4{width:33.33333333%}.caldera-grid .col-xs-3{width:25%}.caldera-grid .col-xs-2{width:16.66666667%}.caldera-grid .col-xs-1{width:8.33333333%}.caldera-grid .col-xs-pull-12{right:100%}.caldera-grid .col-xs-pull-11{right:91.66666667%}.caldera-grid .col-xs-pull-10{right:83.33333333%}.caldera-grid .col-xs-pull-9{right:75%}.caldera-grid .col-xs-pull-8{right:66.66666667%}.caldera-grid .col-xs-pull-7{right:58.33333333%}.caldera-grid .col-xs-pull-6{right:50%}.caldera-grid .col-xs-pull-5{right:41.66666667%}.caldera-grid .col-xs-pull-4{right:33.33333333%}.caldera-grid .col-xs-pull-3{right:25%}.caldera-grid .col-xs-pull-2{right:16.66666667%}.caldera-grid .col-xs-pull-1{right:8.33333333%}.caldera-grid .col-xs-pull-0{right:0}.caldera-grid .col-xs-push-12{left:100%}.caldera-grid .col-xs-push-11{left:91.66666667%}.caldera-grid .col-xs-push-10{left:83.33333333%}.caldera-grid .col-xs-push-9{left:75%}.caldera-grid .col-xs-push-8{left:66.66666667%}.caldera-grid .col-xs-push-7{left:58.33333333%}.caldera-grid .col-xs-push-6{left:50%}.caldera-grid .col-xs-push-5{left:41.66666667%}.caldera-grid .col-xs-push-4{left:33.33333333%}.caldera-grid .col-xs-push-3{left:25%}.caldera-grid .col-xs-push-2{left:16.66666667%}.caldera-grid .col-xs-push-1{left:8.33333333%}.caldera-grid .col-xs-push-0{left:0}.caldera-grid .col-xs-offset-12{margin-left:100%}.caldera-grid .col-xs-offset-11{margin-left:91.66666667%}.caldera-grid .col-xs-offset-10{margin-left:83.33333333%}.caldera-grid .col-xs-offset-9{margin-left:75%}.caldera-grid .col-xs-offset-8{margin-left:66.66666667%}.caldera-grid .col-xs-offset-7{margin-left:58.33333333%}.caldera-grid .col-xs-offset-6{margin-left:50%}.caldera-grid .col-xs-offset-5{margin-left:41.66666667%}.caldera-grid .col-xs-offset-4{margin-left:33.33333333%}.caldera-grid .col-xs-offset-3{margin-left:25%}.caldera-grid .col-xs-offset-2{margin-left:16.66666667%}.caldera-grid .col-xs-offset-1{margin-left:8.33333333%}.caldera-grid .col-xs-offset-0{margin-left:0}@media (min-width:768px){.caldera-grid .col-sm-1,.caldera-grid .col-sm-10,.caldera-grid .col-sm-11,.caldera-grid .col-sm-12,.caldera-grid .col-sm-2,.caldera-grid .col-sm-3,.caldera-grid .col-sm-4,.caldera-grid .col-sm-5,.caldera-grid .col-sm-6,.caldera-grid .col-sm-7,.caldera-grid .col-sm-8,.caldera-grid .col-sm-9{float:left}.caldera-grid .col-sm-12{width:100%}.caldera-grid .col-sm-11{width:91.66666667%}.caldera-grid .col-sm-10{width:83.33333333%}.caldera-grid .col-sm-9{width:75%}.caldera-grid .col-sm-8{width:66.66666667%}.caldera-grid .col-sm-7{width:58.33333333%}.caldera-grid .col-sm-6{width:50%}.caldera-grid .col-sm-5{width:41.66666667%}.caldera-grid .col-sm-4{width:33.33333333%}.caldera-grid .col-sm-3{width:25%}.caldera-grid .col-sm-2{width:16.66666667%}.caldera-grid .col-sm-1{width:8.33333333%}.caldera-grid .col-sm-pull-12{right:100%}.caldera-grid .col-sm-pull-11{right:91.66666667%}.caldera-grid .col-sm-pull-10{right:83.33333333%}.caldera-grid .col-sm-pull-9{right:75%}.caldera-grid .col-sm-pull-8{right:66.66666667%}.caldera-grid .col-sm-pull-7{right:58.33333333%}.caldera-grid .col-sm-pull-6{right:50%}.caldera-grid .col-sm-pull-5{right:41.66666667%}.caldera-grid .col-sm-pull-4{right:33.33333333%}.caldera-grid .col-sm-pull-3{right:25%}.caldera-grid .col-sm-pull-2{right:16.66666667%}.caldera-grid .col-sm-pull-1{right:8.33333333%}.caldera-grid .col-sm-pull-0{right:0}.caldera-grid .col-sm-push-12{left:100%}.caldera-grid .col-sm-push-11{left:91.66666667%}.caldera-grid .col-sm-push-10{left:83.33333333%}.caldera-grid .col-sm-push-9{left:75%}.caldera-grid .col-sm-push-8{left:66.66666667%}.caldera-grid .col-sm-push-7{left:58.33333333%}.caldera-grid .col-sm-push-6{left:50%}.caldera-grid .col-sm-push-5{left:41.66666667%}.caldera-grid .col-sm-push-4{left:33.33333333%}.caldera-grid .col-sm-push-3{left:25%}.caldera-grid .col-sm-push-2{left:16.66666667%}.caldera-grid .col-sm-push-1{left:8.33333333%}.caldera-grid .col-sm-push-0{left:0}.caldera-grid .col-sm-offset-12{margin-left:100%}.caldera-grid .col-sm-offset-11{margin-left:91.66666667%}.caldera-grid .col-sm-offset-10{margin-left:83.33333333%}.caldera-grid .col-sm-offset-9{margin-left:75%}.caldera-grid .col-sm-offset-8{margin-left:66.66666667%}.caldera-grid .col-sm-offset-7{margin-left:58.33333333%}.caldera-grid .col-sm-offset-6{margin-left:50%}.caldera-grid .col-sm-offset-5{margin-left:41.66666667%}.caldera-grid .col-sm-offset-4{margin-left:33.33333333%}.caldera-grid .col-sm-offset-3{margin-left:25%}.caldera-grid .col-sm-offset-2{margin-left:16.66666667%}.caldera-grid .col-sm-offset-1{margin-left:8.33333333%}.caldera-grid .col-sm-offset-0{margin-left:0}}@media (min-width:992px){.caldera-grid .col-md-1,.caldera-grid .col-md-10,.caldera-grid .col-md-11,.caldera-grid .col-md-12,.caldera-grid .col-md-2,.caldera-grid .col-md-3,.caldera-grid .col-md-4,.caldera-grid .col-md-5,.caldera-grid .col-md-6,.caldera-grid .col-md-7,.caldera-grid .col-md-8,.caldera-grid .col-md-9{float:left}.caldera-grid .col-md-12{width:100%}.caldera-grid .col-md-11{width:91.66666667%}.caldera-grid .col-md-10{width:83.33333333%}.caldera-grid .col-md-9{width:75%}.caldera-grid .col-md-8{width:66.66666667%}.caldera-grid .col-md-7{width:58.33333333%}.caldera-grid .col-md-6{width:50%}.caldera-grid .col-md-5{width:41.66666667%}.caldera-grid .col-md-4{width:33.33333333%}.caldera-grid .col-md-3{width:25%}.caldera-grid .col-md-2{width:16.66666667%}.caldera-grid .col-md-1{width:8.33333333%}.caldera-grid .col-md-pull-12{right:100%}.caldera-grid .col-md-pull-11{right:91.66666667%}.caldera-grid .col-md-pull-10{right:83.33333333%}.caldera-grid .col-md-pull-9{right:75%}.caldera-grid .col-md-pull-8{right:66.66666667%}.caldera-grid .col-md-pull-7{right:58.33333333%}.caldera-grid .col-md-pull-6{right:50%}.caldera-grid .col-md-pull-5{right:41.66666667%}.caldera-grid .col-md-pull-4{right:33.33333333%}.caldera-grid .col-md-pull-3{right:25%}.caldera-grid .col-md-pull-2{right:16.66666667%}.caldera-grid .col-md-pull-1{right:8.33333333%}.caldera-grid .col-md-pull-0{right:0}.caldera-grid .col-md-push-12{left:100%}.caldera-grid .col-md-push-11{left:91.66666667%}.caldera-grid .col-md-push-10{left:83.33333333%}.caldera-grid .col-md-push-9{left:75%}.caldera-grid .col-md-push-8{left:66.66666667%}.caldera-grid .col-md-push-7{left:58.33333333%}.caldera-grid .col-md-push-6{left:50%}.caldera-grid .col-md-push-5{left:41.66666667%}.caldera-grid .col-md-push-4{left:33.33333333%}.caldera-grid .col-md-push-3{left:25%}.caldera-grid .col-md-push-2{left:16.66666667%}.caldera-grid .col-md-push-1{left:8.33333333%}.caldera-grid .col-md-push-0{left:0}.caldera-grid .col-md-offset-12{margin-left:100%}.caldera-grid .col-md-offset-11{margin-left:91.66666667%}.caldera-grid .col-md-offset-10{margin-left:83.33333333%}.caldera-grid .col-md-offset-9{margin-left:75%}.caldera-grid .col-md-offset-8{margin-left:66.66666667%}.caldera-grid .col-md-offset-7{margin-left:58.33333333%}.caldera-grid .col-md-offset-6{margin-left:50%}.caldera-grid .col-md-offset-5{margin-left:41.66666667%}.caldera-grid .col-md-offset-4{margin-left:33.33333333%}.caldera-grid .col-md-offset-3{margin-left:25%}.caldera-grid .col-md-offset-2{margin-left:16.66666667%}.caldera-grid .col-md-offset-1{margin-left:8.33333333%}.caldera-grid .col-md-offset-0{margin-left:0}}@-ms-viewport{width:device-width}@media (min-width:1200px){.caldera-grid .col-lg-1,.caldera-grid .col-lg-10,.caldera-grid .col-lg-11,.caldera-grid .col-lg-12,.caldera-grid .col-lg-2,.caldera-grid .col-lg-3,.caldera-grid .col-lg-4,.caldera-grid .col-lg-5,.caldera-grid .col-lg-6,.caldera-grid .col-lg-7,.caldera-grid .col-lg-8,.caldera-grid .col-lg-9{float:left}.caldera-grid .col-lg-12{width:100%}.caldera-grid .col-lg-11{width:91.66666667%}.caldera-grid .col-lg-10{width:83.33333333%}.caldera-grid .col-lg-9{width:75%}.caldera-grid .col-lg-8{width:66.66666667%}.caldera-grid .col-lg-7{width:58.33333333%}.caldera-grid .col-lg-6{width:50%}.caldera-grid .col-lg-5{width:41.66666667%}.caldera-grid .col-lg-4{width:33.33333333%}.caldera-grid .col-lg-3{width:25%}.caldera-grid .col-lg-2{width:16.66666667%}.caldera-grid .col-lg-1{width:8.33333333%}.caldera-grid .col-lg-pull-12{right:100%}.caldera-grid .col-lg-pull-11{right:91.66666667%}.caldera-grid .col-lg-pull-10{right:83.33333333%}.caldera-grid .col-lg-pull-9{right:75%}.caldera-grid .col-lg-pull-8{right:66.66666667%}.caldera-grid .col-lg-pull-7{right:58.33333333%}.caldera-grid .col-lg-pull-6{right:50%}.caldera-grid .col-lg-pull-5{right:41.66666667%}.caldera-grid .col-lg-pull-4{right:33.33333333%}.caldera-grid .col-lg-pull-3{right:25%}.caldera-grid .col-lg-pull-2{right:16.66666667%}.caldera-grid .col-lg-pull-1{right:8.33333333%}.caldera-grid .col-lg-pull-0{right:0}.caldera-grid .col-lg-push-12{left:100%}.caldera-grid .col-lg-push-11{left:91.66666667%}.caldera-grid .col-lg-push-10{left:83.33333333%}.caldera-grid .col-lg-push-9{left:75%}.caldera-grid .col-lg-push-8{left:66.66666667%}.caldera-grid .col-lg-push-7{left:58.33333333%}.caldera-grid .col-lg-push-6{left:50%}.caldera-grid .col-lg-push-5{left:41.66666667%}.caldera-grid .col-lg-push-4{left:33.33333333%}.caldera-grid .col-lg-push-3{left:25%}.caldera-grid .col-lg-push-2{left:16.66666667%}.caldera-grid .col-lg-push-1{left:8.33333333%}.caldera-grid .col-lg-push-0{left:0}.caldera-grid .col-lg-offset-12{margin-left:100%}.caldera-grid .col-lg-offset-11{margin-left:91.66666667%}.caldera-grid .col-lg-offset-10{margin-left:83.33333333%}.caldera-grid .col-lg-offset-9{margin-left:75%}.caldera-grid .col-lg-offset-8{margin-left:66.66666667%}.caldera-grid .col-lg-offset-7{margin-left:58.33333333%}.caldera-grid .col-lg-offset-6{margin-left:50%}.caldera-grid .col-lg-offset-5{margin-left:41.66666667%}.caldera-grid .col-lg-offset-4{margin-left:33.33333333%}.caldera-grid .col-lg-offset-3{margin-left:25%}.caldera-grid .col-lg-offset-2{margin-left:16.66666667%}.caldera-grid .col-lg-offset-1{margin-left:8.33333333%}.caldera-grid .col-lg-offset-0{margin-left:0}}.caldera-grid .clearfix:after,.caldera-grid .clearfix:before,.caldera-grid .container-fluid:after,.caldera-grid .container-fluid:before,.caldera-grid .container:after,.caldera-grid .container:before,.caldera-grid .row:after,.caldera-grid .row:before{content:" ";display:table}.caldera-grid .clearfix:after,.caldera-grid .container-fluid:after,.caldera-grid .container:after,.caldera-grid .row:after{clear:both}.caldera-grid .center-block{display:block;margin-left:auto;margin-right:auto}.caldera-grid .pull-right{float:right!important}.caldera-grid .pull-left{float:left!important}.caldera-grid .hide{display:none!important}.caldera-grid .show{display:block!important}.caldera-grid .hidden,.caldera-grid .visible-lg,.caldera-grid .visible-md,.caldera-grid .visible-sm,.caldera-grid .visible-xs{display:none!important}.caldera-grid .invisible{visibility:hidden}.caldera-grid .text-hide{font:0/0 a;color:transparent;text-shadow:none;background-color:transparent;border:0}.caldera-grid .alert .alert-link,.caldera-grid b,.caldera-grid strong{font-weight:700}.caldera-grid .hidden{visibility:hidden!important}.caldera-grid .affix{position:fixed}@-ms-viewport{width:device-width}@media (max-width:767px){.caldera-grid .visible-xs{display:block!important}.caldera-grid table.visible-xs{display:table}.caldera-grid tr.visible-xs{display:table-row!important}.caldera-grid td.visible-xs,.caldera-grid th.visible-xs{display:table-cell!important}}@media (min-width:768px) and (max-width:991px){.caldera-grid .visible-sm{display:block!important}.caldera-grid table.visible-sm{display:table}.caldera-grid tr.visible-sm{display:table-row!important}.caldera-grid td.visible-sm,.caldera-grid th.visible-sm{display:table-cell!important}}@media (min-width:992px) and (max-width:1199px){.caldera-grid .visible-md{display:block!important}.caldera-grid table.visible-md{display:table}.caldera-grid tr.visible-md{display:table-row!important}.caldera-grid td.visible-md,.caldera-grid th.visible-md{display:table-cell!important}}@media (min-width:1200px){.caldera-grid .visible-lg{display:block!important}.caldera-grid table.visible-lg{display:table}.caldera-grid tr.visible-lg{display:table-row!important}.caldera-grid td.visible-lg,.caldera-grid th.visible-lg{display:table-cell!important}.caldera-grid .hidden-lg{display:none!important}}@media (max-width:767px){.caldera-grid .hidden-xs{display:none!important}}@media (min-width:768px) and (max-width:991px){.caldera-grid .hidden-sm{display:none!important}}@media (min-width:992px) and (max-width:1199px){.caldera-grid .hidden-md{display:none!important}}.caldera-grid .visible-print{display:none!important}@media print{.caldera-grid .visible-print{display:block!important}.caldera-grid table.visible-print{display:table}.caldera-grid tr.visible-print{display:table-row!important}.caldera-grid td.visible-print,.caldera-grid th.visible-print{display:table-cell!important}.caldera-grid .hidden-print{display:none!important}}input.parsley-success,select.parsley-success,textarea.parsley-success{color:#468847;background-color:#DFF0D8;border:1px solid #D6E9C6}input.parsley-error,select.parsley-error,textarea.parsley-error{color:#B94A48;background-color:#F2DEDE;border:1px solid #EED3D7}.parsley-errors-list{margin:2px 0 3px;padding:0;list-style-type:none;font-size:.9em;line-height:.9em;opacity:0;transition:all .3s ease-in;-o-transition:all .3s ease-in;-moz-transition:all .3s ease-in;-webkit-transition:all .3s ease-in}.parsley-errors-list.filled{opacity:1}.caldera-grid .alert{padding:8px;margin-bottom:18px;border-radius:2px}.caldera-grid .alert-dismissable{padding-right:28px}.caldera-grid .alert-success{background-color:#dff0d8;border-color:#a3d48e;color:#3c763d}.caldera-grid .alert-success hr{border-top-color:#93cd7c}.caldera-grid .alert-success .alert-link{color:#2b542c}.caldera-grid .alert-info{background-color:#d9edf7;border-color:#85c5e5;color:#31708f}.caldera-grid .alert-info hr{border-top-color:#70bbe1}.caldera-grid .alert-info .alert-link{color:#245269}.caldera-grid .alert-warning{background-color:#f9edbe;border-color:#f0c36d;color:#333}.caldera-grid .alert-warning hr{border-top-color:#eeb956}.caldera-grid .alert-warning .alert-link{color:#1a1a1a}.caldera-grid .alert-danger,.caldera-grid .alert-error{background-color:#f2dede;border-color:#d59595;color:#a94442}.caldera-grid .alert-danger hr,.caldera-grid .alert-error hr{border-top-color:#ce8383}.caldera-grid .alert-danger .alert-link,.caldera-grid .alert-error .alert-link{color:#843534}.caldera-grid .alert-danger,.caldera-grid .alert-error,.caldera-grid .alert-info,.caldera-grid .alert-success,.caldera-grid .alert-warning{text-shadow:0 1px 0 rgba(255,255,255,.5)}.caldera-grid .has-error .form-control:focus,.caldera-grid .has-error .form-control:hover{border-color:#dd4b39}.caldera-grid.cf_processing{background:url(../images/loading.gif) center center/30px auto no-repeat rgba(0,0,0,0)}.caldera-grid.cf_processing>*{opacity:.5}.caldera-grid html{font-family:sans-serif}.caldera-grid body{margin:0}.caldera-grid article,.caldera-grid aside,.caldera-grid details,.caldera-grid figcaption,.caldera-grid figure,.caldera-grid footer,.caldera-grid header,.caldera-grid hgroup,.caldera-grid main,.caldera-grid menu,.caldera-grid nav,.caldera-grid section,.caldera-grid summary{display:block}.caldera-grid audio,.caldera-grid canvas,.caldera-grid progress,.caldera-grid video{display:inline-block;vertical-align:baseline}.caldera-grid audio:not([controls]){display:none;height:0}.caldera-grid [hidden],.caldera-grid template{display:none}.caldera-grid a{background-color:transparent}.caldera-grid a:active,.caldera-grid a:hover{outline:0}.caldera-grid abbr[title]{border-bottom:1px dotted}.caldera-grid dfn{font-style:italic}.caldera-grid h1{font-size:2em;margin:.67em 0}.caldera-grid mark{background:#ff0;color:#000}.caldera-grid small{font-size:80%}.caldera-grid sub,.caldera-grid sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}.caldera-grid sup{top:-.5em}.caldera-grid sub{bottom:-.25em}.caldera-grid img{border:0}.caldera-grid figure{margin:1em 40px}.caldera-grid hr{-moz-box-sizing:content-box;box-sizing:content-box;height:0}.caldera-grid pre{overflow:auto}.caldera-grid code,.caldera-grid kbd,.caldera-grid pre,.caldera-grid samp{font-family:monospace,monospace;font-size:1em}.caldera-grid button,.caldera-grid input,.caldera-grid optgroup,.caldera-grid select,.caldera-grid textarea{font:inherit;margin:0}.caldera-grid button{overflow:visible}.caldera-grid button,.caldera-grid html input[type=button],.caldera-grid input[type=reset],.caldera-grid input[type=submit]{-webkit-appearance:button;cursor:pointer}.caldera-grid button[disabled],.caldera-grid html input[disabled]{cursor:default}.caldera-grid button::-moz-focus-inner,.caldera-grid input::-moz-focus-inner{border:0;padding:0}.caldera-grid input{line-height:normal}.caldera-grid input[type=checkbox],.caldera-grid input[type=radio]{box-sizing:border-box;padding:0}.caldera-grid input[type=number]::-webkit-inner-spin-button,.caldera-grid input[type=number]::-webkit-outer-spin-button{height:auto}.caldera-grid input[type=search]{-webkit-appearance:textfield;-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box}.caldera-grid input[type=search]::-webkit-search-cancel-button,.caldera-grid input[type=search]::-webkit-search-decoration{-webkit-appearance:none}.caldera-grid textarea{overflow:auto}.caldera-grid optgroup{font-weight:700}.caldera-grid table{border-collapse:collapse;border-spacing:0}.caldera-grid td,.caldera-grid th{padding:0}@media print{.caldera-grid *,.caldera-grid :after,.caldera-grid :before{background:0 0!important;color:#000!important;box-shadow:none!important;text-shadow:none!important}.caldera-grid a,.caldera-grid a:visited{text-decoration:underline}.caldera-grid a[href]:after{content:" (" attr(href) ")"}.caldera-grid abbr[title]:after{content:" (" attr(title) ")"}.caldera-grid a[href^="#"]:after,.caldera-grid a[href^="javascript:"]:after{content:""}.caldera-grid blockquote,.caldera-grid pre{border:1px solid #999;page-break-inside:avoid}.caldera-grid thead{display:table-header-group}.caldera-grid img,.caldera-grid tr{page-break-inside:avoid}.caldera-grid img{max-width:100%!important}.caldera-grid h2,.caldera-grid h3,.caldera-grid p{orphans:3;widows:3}.caldera-grid h2,.caldera-grid h3{page-break-after:avoid}.caldera-grid select{background:#fff!important}.caldera-grid .navbar{display:none}.caldera-grid .btn>.caret,.caldera-grid .dropup>.btn>.caret{border-top-color:#000!important}.caldera-grid .label{border:1px solid #000}.caldera-grid .table{border-collapse:collapse!important}.caldera-grid .table td,.caldera-grid .table th{background-color:#fff!important}.caldera-grid .table-bordered td,.caldera-grid .table-bordered th{border:1px solid #ddd!important}}.caldera-grid .btn,.caldera-grid .btn-danger.active,.caldera-grid .btn-danger:active,.caldera-grid .btn-default.active,.caldera-grid .btn-default:active,.caldera-grid .btn-info.active,.caldera-grid .btn-info:active,.caldera-grid .btn-primary.active,.caldera-grid .btn-primary:active,.caldera-grid .btn-success.active,.caldera-grid .btn-success:active,.caldera-grid .btn-warning.active,.caldera-grid .btn-warning:active,.caldera-grid .form-control,.open>.dropdown-toggle.caldera-grid .btn-danger,.open>.dropdown-toggle.caldera-grid .btn-default,.open>.dropdown-toggle.caldera-grid .btn-info,.open>.dropdown-toggle.caldera-grid .btn-primary,.open>.dropdown-toggle.caldera-grid .btn-success,.open>.dropdown-toggle.caldera-grid .btn-warning{background-image:none}.caldera-grid fieldset{padding:0;margin:0;border:0;min-width:0}.caldera-grid legend{display:block;width:100%;padding:0;margin-bottom:20px;font-size:21px;line-height:inherit;color:#333;border:0;border-bottom:1px solid #e5e5e5}.caldera-grid label{display:inline-block;max-width:100%;margin-bottom:5px;font-weight:700}.caldera-grid input[type=checkbox],.caldera-grid input[type=radio]{margin:0;line-height:normal}.caldera-grid .form-control,.caldera-grid output{font-size:14px;line-height:1.42857143;color:#555;display:block}.caldera-grid input[type=file]{display:block}.caldera-grid input[type=range]{display:block;width:100%}.caldera-grid select[multiple],.caldera-grid select[size]{height:auto}.caldera-grid input[type=checkbox]:focus,.caldera-grid input[type=file]:focus,.caldera-grid input[type=radio]:focus{outline:dotted thin;outline:-webkit-focus-ring-color auto 5px;outline-offset:-2px}.caldera-grid input[type=checkbox]{-webkit-appearance:checkbox}.caldera-grid input[type=radio]{-webkit-appearance:radio}.caldera-grid output{padding-top:7px}.caldera-grid .form-control{width:100%;height:34px;padding:6px 12px;background-color:#fff;border:1px solid #ccc;border-radius:2px;-webkit-box-shadow:inset 0 1px 1px rgba(0,0,0,.075);box-shadow:inset 0 1px 1px rgba(0,0,0,.075);-webkit-transition:border-color ease-in-out .15s,box-shadow ease-in-out .15s;-o-transition:border-color ease-in-out .15s,box-shadow ease-in-out .15s;transition:border-color ease-in-out .15s,box-shadow ease-in-out .15s}.caldera-grid .form-control:focus{border-color:#66afe9;outline:0;-webkit-box-shadow:inset 0 1px 1px rgba(0,0,0,.075),0 0 8px rgba(102,175,233,.6);box-shadow:inset 0 1px 1px rgba(0,0,0,.075),0 0 8px rgba(102,175,233,.6)}.caldera-grid .form-control::-moz-placeholder{color:#999;opacity:1}.caldera-grid .form-control:-ms-input-placeholder{color:#999}.caldera-grid .form-control::-webkit-input-placeholder{color:#999}.caldera-grid .has-success .checkbox,.caldera-grid .has-success .checkbox-inline,.caldera-grid .has-success .control-label,.caldera-grid .has-success .form-control-feedback,.caldera-grid .has-success .help-block,.caldera-grid .has-success .radio,.caldera-grid .has-success .radio-inline,.caldera-grid .has-success.checkbox label,.caldera-grid .has-success.checkbox-inline label,.caldera-grid .has-success.radio label,.caldera-grid .has-success.radio-inline label{color:#3c763d}.caldera-grid .form-control[disabled],.caldera-grid .form-control[readonly],fieldset[disabled] .caldera-grid .form-control{background-color:#eee;opacity:1}.caldera-grid .form-control[disabled],fieldset[disabled] .caldera-grid .form-control{cursor:not-allowed}textarea .caldera-grid .form-control{height:auto}@media screen and (-webkit-min-device-pixel-ratio:0){.caldera-grid input[type=date],.caldera-grid input[type=datetime-local],.caldera-grid input[type=month],.caldera-grid input[type=time]{line-height:34px}.caldera-grid input[type=date].input-sm,.caldera-grid input[type=datetime-local].input-sm,.caldera-grid input[type=month].input-sm,.caldera-grid input[type=time].input-sm,.input-group-sm .caldera-grid input[type=date],.input-group-sm .caldera-grid input[type=datetime-local],.input-group-sm .caldera-grid input[type=month],.input-group-sm .caldera-grid input[type=time]{line-height:30px}.caldera-grid input[type=date].input-lg,.caldera-grid input[type=datetime-local].input-lg,.caldera-grid input[type=month].input-lg,.caldera-grid input[type=time].input-lg,.input-group-lg .caldera-grid input[type=date],.input-group-lg .caldera-grid input[type=datetime-local],.input-group-lg .caldera-grid input[type=month],.input-group-lg .caldera-grid input[type=time]{line-height:46px}}.caldera-grid .form-group{margin-bottom:15px}.caldera-grid .checkbox,.caldera-grid .radio{position:relative;display:block;margin-top:10px;margin-bottom:10px}.caldera-grid .checkbox label,.caldera-grid .radio label{min-height:20px;padding-left:20px;margin-bottom:0;font-weight:400;cursor:pointer}.caldera-grid .checkbox input[type=checkbox],.caldera-grid .checkbox-inline input[type=checkbox],.caldera-grid .radio input[type=radio],.caldera-grid .radio-inline input[type=radio]{margin-left:-20px}.caldera-grid .checkbox+.checkbox,.caldera-grid .radio+.radio{margin-top:-5px}.caldera-grid .checkbox-inline,.caldera-grid .radio-inline{position:relative;display:inline-block;padding-left:20px;margin-bottom:0;vertical-align:middle;font-weight:400;cursor:pointer}.caldera-grid .checkbox-inline+.checkbox-inline,.caldera-grid .radio-inline+.radio-inline{margin-top:0;margin-left:10px}.caldera-grid .checkbox-inline.disabled,.caldera-grid .checkbox.disabled label,.caldera-grid .radio-inline.disabled,.caldera-grid .radio.disabled label,.caldera-grid input[type=checkbox].disabled,.caldera-grid input[type=checkbox][disabled],.caldera-grid input[type=radio].disabled,.caldera-grid input[type=radio][disabled],fieldset[disabled] .caldera-grid .checkbox label,fieldset[disabled] .caldera-grid .checkbox-inline,fieldset[disabled] .caldera-grid .radio label,fieldset[disabled] .caldera-grid .radio-inline,fieldset[disabled] .caldera-grid input[type=checkbox],fieldset[disabled] .caldera-grid input[type=radio]{cursor:not-allowed}.caldera-grid .form-control-static{padding-top:7px;padding-bottom:7px;margin-bottom:0;min-height:34px}.caldera-grid .form-control-static.input-lg,.caldera-grid .form-control-static.input-sm{padding-left:0;padding-right:0}.caldera-grid .input-sm{height:30px;padding:5px 10px;font-size:12px;line-height:1.5;border-radius:1px}select.caldera-grid .input-sm{height:30px;line-height:30px}select[multiple].caldera-grid .input-sm,textarea.caldera-grid .input-sm{height:auto}.caldera-grid .form-group-sm .form-control{height:30px;padding:5px 10px;font-size:12px;line-height:1.5;border-radius:1px}select.caldera-grid .form-group-sm .form-control{height:30px;line-height:30px}select[multiple].caldera-grid .form-group-sm .form-control,textarea.caldera-grid .form-group-sm .form-control{height:auto}.caldera-grid .form-group-sm .form-control-static{height:30px;padding:5px 10px;font-size:12px;line-height:1.5;min-height:32px}.caldera-grid .input-lg{height:46px;padding:10px 16px;font-size:18px;line-height:1.3333333;border-radius:4px}select.caldera-grid .input-lg{height:46px;line-height:46px}select[multiple].caldera-grid .input-lg,textarea.caldera-grid .input-lg{height:auto}.caldera-grid .form-group-lg .form-control{height:46px;padding:10px 16px;font-size:18px;line-height:1.3333333;border-radius:4px}select.caldera-grid .form-group-lg .form-control{height:46px;line-height:46px}select[multiple].caldera-grid .form-group-lg .form-control,textarea.caldera-grid .form-group-lg .form-control{height:auto}.caldera-grid .form-group-lg .form-control-static{height:46px;padding:10px 16px;font-size:18px;line-height:1.3333333;min-height:38px}.caldera-grid .has-feedback{position:relative}.caldera-grid .has-feedback .form-control{padding-right:42.5px}.caldera-grid .form-control-feedback{position:absolute;top:0;right:0;z-index:2;display:block;width:34px;height:34px;line-height:34px;text-align:center;pointer-events:none}.caldera-grid .input-lg+.form-control-feedback{width:46px;height:46px;line-height:46px}.caldera-grid .input-sm+.form-control-feedback{width:30px;height:30px;line-height:30px}.caldera-grid .has-success .form-control{border-color:#3c763d;-webkit-box-shadow:inset 0 1px 1px rgba(0,0,0,.075);box-shadow:inset 0 1px 1px rgba(0,0,0,.075)}.caldera-grid .has-success .form-control:focus{border-color:#2b542c;-webkit-box-shadow:inset 0 1px 1px rgba(0,0,0,.075),0 0 6px #67b168;box-shadow:inset 0 1px 1px rgba(0,0,0,.075),0 0 6px #67b168}.caldera-grid .has-success .input-group-addon{color:#3c763d;border-color:#3c763d;background-color:#dff0d8}.caldera-grid .has-warning .checkbox,.caldera-grid .has-warning .checkbox-inline,.caldera-grid .has-warning .control-label,.caldera-grid .has-warning .form-control-feedback,.caldera-grid .has-warning .help-block,.caldera-grid .has-warning .radio,.caldera-grid .has-warning .radio-inline,.caldera-grid .has-warning.checkbox label,.caldera-grid .has-warning.checkbox-inline label,.caldera-grid .has-warning.radio label,.caldera-grid .has-warning.radio-inline label{color:#8a6d3b}.caldera-grid .has-warning .form-control{border-color:#8a6d3b;-webkit-box-shadow:inset 0 1px 1px rgba(0,0,0,.075);box-shadow:inset 0 1px 1px rgba(0,0,0,.075)}.caldera-grid .has-warning .form-control:focus{border-color:#66512c;-webkit-box-shadow:inset 0 1px 1px rgba(0,0,0,.075),0 0 6px #c0a16b;box-shadow:inset 0 1px 1px rgba(0,0,0,.075),0 0 6px #c0a16b}.caldera-grid .has-warning .input-group-addon{color:#8a6d3b;border-color:#8a6d3b;background-color:#fcf8e3}.caldera-grid .has-error .checkbox,.caldera-grid .has-error .checkbox-inline,.caldera-grid .has-error .control-label,.caldera-grid .has-error .form-control-feedback,.caldera-grid .has-error .help-block,.caldera-grid .has-error .radio,.caldera-grid .has-error .radio-inline,.caldera-grid .has-error.checkbox label,.caldera-grid .has-error.checkbox-inline label,.caldera-grid .has-error.radio label,.caldera-grid .has-error.radio-inline label{color:#a94442}.caldera-grid .has-error .form-control{border-color:#a94442;-webkit-box-shadow:inset 0 1px 1px rgba(0,0,0,.075);box-shadow:inset 0 1px 1px rgba(0,0,0,.075)}.caldera-grid .has-error .form-control:focus{border-color:#843534;-webkit-box-shadow:inset 0 1px 1px rgba(0,0,0,.075),0 0 6px #ce8483;box-shadow:inset 0 1px 1px rgba(0,0,0,.075),0 0 6px #ce8483}.caldera-grid .has-error .input-group-addon{color:#a94442;border-color:#a94442;background-color:#f2dede}.caldera-grid .has-feedback label~.form-control-feedback{top:25px}.caldera-grid .has-feedback label.sr-only~.form-control-feedback{top:0}.caldera-grid .help-block{display:block;margin-top:5px;margin-bottom:10px;color:#737373}@media (min-width:768px){.caldera-grid .form-inline .form-group{display:inline-block;margin-bottom:0;vertical-align:middle}.caldera-grid .form-inline .form-control{display:inline-block;width:auto;vertical-align:middle}.caldera-grid .form-inline .form-control-static{display:inline-block}.caldera-grid .form-inline .input-group{display:inline-table;vertical-align:middle}.caldera-grid .form-inline .input-group .form-control,.caldera-grid .form-inline .input-group .input-group-addon,.caldera-grid .form-inline .input-group .input-group-btn{width:auto}.caldera-grid .form-inline .input-group>.form-control{width:100%}.caldera-grid .form-inline .control-label{margin-bottom:0;vertical-align:middle}.caldera-grid .form-inline .checkbox,.caldera-grid .form-inline .radio{display:inline-block;margin-top:0;margin-bottom:0;vertical-align:middle}.caldera-grid .form-inline .checkbox label,.caldera-grid .form-inline .radio label{padding-left:0}.caldera-grid .form-inline .checkbox input[type=checkbox],.caldera-grid .form-inline .radio input[type=radio]{position:relative;margin-left:0}.caldera-grid .form-inline .has-feedback .form-control-feedback{top:0}.caldera-grid .form-horizontal .control-label{text-align:right;margin-bottom:0;padding-top:7px}}.caldera-grid .form-horizontal .checkbox,.caldera-grid .form-horizontal .checkbox-inline,.caldera-grid .form-horizontal .radio,.caldera-grid .form-horizontal .radio-inline{margin-top:0;margin-bottom:0;padding-top:7px}.caldera-grid .form-horizontal .checkbox,.caldera-grid .form-horizontal .radio{min-height:27px}.caldera-grid .form-horizontal .form-group{margin-left:-15px;margin-right:-15px}.caldera-grid .form-horizontal .has-feedback .form-control-feedback{right:15px}@media (min-width:768px){.caldera-grid .form-horizontal .form-group-lg .control-label{padding-top:14.33px}.caldera-grid .form-horizontal .form-group-sm .control-label{padding-top:6px}}.caldera-grid .btn{display:inline-block;margin-bottom:0;font-weight:400;text-align:center;vertical-align:middle;touch-action:manipulation;cursor:pointer;border:1px solid transparent;white-space:nowrap;padding:6px 12px;font-size:14px;line-height:1.42857143;border-radius:2px;user-select:none}.caldera-grid .btn.active.focus,.caldera-grid .btn.active:focus,.caldera-grid .btn.focus,.caldera-grid .btn:active.focus,.caldera-grid .btn:active:focus,.caldera-grid .btn:focus{outline:dotted thin;outline:-webkit-focus-ring-color auto 5px;outline-offset:-2px}.caldera-grid .btn.focus,.caldera-grid .btn:focus,.caldera-grid .btn:hover{color:#333;text-decoration:none}.caldera-grid .btn.active,.caldera-grid .btn:active{outline:0;background-image:none;-webkit-box-shadow:inset 0 3px 5px rgba(0,0,0,.125);box-shadow:inset 0 3px 5px rgba(0,0,0,.125)}.caldera-grid .btn.disabled,.caldera-grid .btn[disabled],fieldset[disabled] .caldera-grid .btn{cursor:not-allowed;pointer-events:none;opacity:.65;filter:alpha(opacity=65);-webkit-box-shadow:none;box-shadow:none}.caldera-grid .btn-default{color:#333;background-color:#fff;border-color:#ccc}.caldera-grid .btn-default.active,.caldera-grid .btn-default.focus,.caldera-grid .btn-default:active,.caldera-grid .btn-default:focus,.caldera-grid .btn-default:hover,.open>.dropdown-toggle.caldera-grid .btn-default{color:#333;background-color:#e6e6e6;border-color:#adadad}.caldera-grid .btn-default.disabled,.caldera-grid .btn-default.disabled.active,.caldera-grid .btn-default.disabled.focus,.caldera-grid .btn-default.disabled:active,.caldera-grid .btn-default.disabled:focus,.caldera-grid .btn-default.disabled:hover,.caldera-grid .btn-default[disabled],.caldera-grid .btn-default[disabled].active,.caldera-grid .btn-default[disabled].focus,.caldera-grid .btn-default[disabled]:active,.caldera-grid .btn-default[disabled]:focus,.caldera-grid .btn-default[disabled]:hover,fieldset[disabled] .caldera-grid .btn-default,fieldset[disabled] .caldera-grid .btn-default.active,fieldset[disabled] .caldera-grid .btn-default.focus,fieldset[disabled] .caldera-grid .btn-default:active,fieldset[disabled] .caldera-grid .btn-default:focus,fieldset[disabled] .caldera-grid .btn-default:hover{background-color:#fff;border-color:#ccc}.caldera-grid .btn-default .badge{color:#fff;background-color:#333}.caldera-grid .btn-primary{color:#fff;background-color:#337ab7;border-color:#2e6da4}.caldera-grid .btn-primary.active,.caldera-grid .btn-primary.focus,.caldera-grid .btn-primary:active,.caldera-grid .btn-primary:focus,.caldera-grid .btn-primary:hover,.open>.dropdown-toggle.caldera-grid .btn-primary{color:#fff;background-color:#286090;border-color:#204d74}.caldera-grid .btn-primary.disabled,.caldera-grid .btn-primary.disabled.active,.caldera-grid .btn-primary.disabled.focus,.caldera-grid .btn-primary.disabled:active,.caldera-grid .btn-primary.disabled:focus,.caldera-grid .btn-primary.disabled:hover,.caldera-grid .btn-primary[disabled],.caldera-grid .btn-primary[disabled].active,.caldera-grid .btn-primary[disabled].focus,.caldera-grid .btn-primary[disabled]:active,.caldera-grid .btn-primary[disabled]:focus,.caldera-grid .btn-primary[disabled]:hover,fieldset[disabled] .caldera-grid .btn-primary,fieldset[disabled] .caldera-grid .btn-primary.active,fieldset[disabled] .caldera-grid .btn-primary.focus,fieldset[disabled] .caldera-grid .btn-primary:active,fieldset[disabled] .caldera-grid .btn-primary:focus,fieldset[disabled] .caldera-grid .btn-primary:hover{background-color:#337ab7;border-color:#2e6da4}.caldera-grid .btn-primary .badge{color:#337ab7;background-color:#fff}.caldera-grid .btn-success{color:#fff;background-color:#5cb85c;border-color:#4cae4c}.caldera-grid .btn-success.active,.caldera-grid .btn-success.focus,.caldera-grid .btn-success:active,.caldera-grid .btn-success:focus,.caldera-grid .btn-success:hover,.open>.dropdown-toggle.caldera-grid .btn-success{color:#fff;background-color:#449d44;border-color:#398439}.caldera-grid .btn-success.disabled,.caldera-grid .btn-success.disabled.active,.caldera-grid .btn-success.disabled.focus,.caldera-grid .btn-success.disabled:active,.caldera-grid .btn-success.disabled:focus,.caldera-grid .btn-success.disabled:hover,.caldera-grid .btn-success[disabled],.caldera-grid .btn-success[disabled].active,.caldera-grid .btn-success[disabled].focus,.caldera-grid .btn-success[disabled]:active,.caldera-grid .btn-success[disabled]:focus,.caldera-grid .btn-success[disabled]:hover,fieldset[disabled] .caldera-grid .btn-success,fieldset[disabled] .caldera-grid .btn-success.active,fieldset[disabled] .caldera-grid .btn-success.focus,fieldset[disabled] .caldera-grid .btn-success:active,fieldset[disabled] .caldera-grid .btn-success:focus,fieldset[disabled] .caldera-grid .btn-success:hover{background-color:#5cb85c;border-color:#4cae4c}.caldera-grid .btn-success .badge{color:#5cb85c;background-color:#fff}.caldera-grid .btn-info{color:#fff;background-color:#5bc0de;border-color:#46b8da}.caldera-grid .btn-info.active,.caldera-grid .btn-info.focus,.caldera-grid .btn-info:active,.caldera-grid .btn-info:focus,.caldera-grid .btn-info:hover,.open>.dropdown-toggle.caldera-grid .btn-info{color:#fff;background-color:#31b0d5;border-color:#269abc}.caldera-grid .btn-info.disabled,.caldera-grid .btn-info.disabled.active,.caldera-grid .btn-info.disabled.focus,.caldera-grid .btn-info.disabled:active,.caldera-grid .btn-info.disabled:focus,.caldera-grid .btn-info.disabled:hover,.caldera-grid .btn-info[disabled],.caldera-grid .btn-info[disabled].active,.caldera-grid .btn-info[disabled].focus,.caldera-grid .btn-info[disabled]:active,.caldera-grid .btn-info[disabled]:focus,.caldera-grid .btn-info[disabled]:hover,fieldset[disabled] .caldera-grid .btn-info,fieldset[disabled] .caldera-grid .btn-info.active,fieldset[disabled] .caldera-grid .btn-info.focus,fieldset[disabled] .caldera-grid .btn-info:active,fieldset[disabled] .caldera-grid .btn-info:focus,fieldset[disabled] .caldera-grid .btn-info:hover{background-color:#5bc0de;border-color:#46b8da}.caldera-grid .btn-info .badge{color:#5bc0de;background-color:#fff}.caldera-grid .btn-warning{color:#fff;background-color:#f0ad4e;border-color:#eea236}.caldera-grid .btn-warning.active,.caldera-grid .btn-warning.focus,.caldera-grid .btn-warning:active,.caldera-grid .btn-warning:focus,.caldera-grid .btn-warning:hover,.open>.dropdown-toggle.caldera-grid .btn-warning{color:#fff;background-color:#ec971f;border-color:#d58512}.caldera-grid .btn-warning.disabled,.caldera-grid .btn-warning.disabled.active,.caldera-grid .btn-warning.disabled.focus,.caldera-grid .btn-warning.disabled:active,.caldera-grid .btn-warning.disabled:focus,.caldera-grid .btn-warning.disabled:hover,.caldera-grid .btn-warning[disabled],.caldera-grid .btn-warning[disabled].active,.caldera-grid .btn-warning[disabled].focus,.caldera-grid .btn-warning[disabled]:active,.caldera-grid .btn-warning[disabled]:focus,.caldera-grid .btn-warning[disabled]:hover,fieldset[disabled] .caldera-grid .btn-warning,fieldset[disabled] .caldera-grid .btn-warning.active,fieldset[disabled] .caldera-grid .btn-warning.focus,fieldset[disabled] .caldera-grid .btn-warning:active,fieldset[disabled] .caldera-grid .btn-warning:focus,fieldset[disabled] .caldera-grid .btn-warning:hover{background-color:#f0ad4e;border-color:#eea236}.caldera-grid .btn-warning .badge{color:#f0ad4e;background-color:#fff}.caldera-grid .btn-danger{color:#fff;background-color:#d9534f;border-color:#d43f3a}.caldera-grid .btn-danger.active,.caldera-grid .btn-danger.focus,.caldera-grid .btn-danger:active,.caldera-grid .btn-danger:focus,.caldera-grid .btn-danger:hover,.open>.dropdown-toggle.caldera-grid .btn-danger{color:#fff;background-color:#c9302c;border-color:#ac2925}.caldera-grid .btn-danger.disabled,.caldera-grid .btn-danger.disabled.active,.caldera-grid .btn-danger.disabled.focus,.caldera-grid .btn-danger.disabled:active,.caldera-grid .btn-danger.disabled:focus,.caldera-grid .btn-danger.disabled:hover,.caldera-grid .btn-danger[disabled],.caldera-grid .btn-danger[disabled].active,.caldera-grid .btn-danger[disabled].focus,.caldera-grid .btn-danger[disabled]:active,.caldera-grid .btn-danger[disabled]:focus,.caldera-grid .btn-danger[disabled]:hover,fieldset[disabled] .caldera-grid .btn-danger,fieldset[disabled] .caldera-grid .btn-danger.active,fieldset[disabled] .caldera-grid .btn-danger.focus,fieldset[disabled] .caldera-grid .btn-danger:active,fieldset[disabled] .caldera-grid .btn-danger:focus,fieldset[disabled] .caldera-grid .btn-danger:hover{background-color:#d9534f;border-color:#d43f3a}.caldera-grid .btn-danger .badge{color:#d9534f;background-color:#fff}.caldera-grid .btn-link{color:#337ab7;font-weight:400;border-radius:0}.caldera-grid .btn-link,.caldera-grid .btn-link.active,.caldera-grid .btn-link:active,.caldera-grid .btn-link[disabled],fieldset[disabled] .caldera-grid .btn-link{background-color:transparent;-webkit-box-shadow:none;box-shadow:none}.caldera-grid .btn-link,.caldera-grid .btn-link:active,.caldera-grid .btn-link:focus,.caldera-grid .btn-link:hover{border-color:transparent}.caldera-grid .btn-link:focus,.caldera-grid .btn-link:hover{color:#23527c;text-decoration:underline;background-color:transparent}.caldera-grid .btn-link[disabled]:focus,.caldera-grid .btn-link[disabled]:hover,fieldset[disabled] .caldera-grid .btn-link:focus,fieldset[disabled] .caldera-grid .btn-link:hover{color:#777;text-decoration:none}.caldera-grid .btn-lg{padding:10px 16px;font-size:18px;line-height:1.3333333;border-radius:4px}.caldera-grid .btn-sm,.caldera-grid .btn-xs{font-size:12px;line-height:1.5;border-radius:1px}.caldera-grid .btn-sm{padding:5px 10px}.caldera-grid .btn-xs{padding:1px 5px}.caldera-grid .btn-block{display:block;width:100%}.caldera-grid .btn-block+.btn-block{margin-top:5px}.caldera-grid input[type=button].btn-block,.caldera-grid input[type=reset].btn-block,.caldera-grid input[type=submit].btn-block{width:100%}.caldera-grid textarea.form-control{padding-right:4px;height:auto}.caldera-grid .breadcrumb{padding:6px 12px;margin:0 0 20px;list-style:none;background-color:#f5f5f5;border-radius:4px}.caldera-grid .breadcrumb>li{display:inline-block;margin:0}.caldera-grid .breadcrumb>li+li:before{content:"/\00a0";padding:0 5px;color:#ccc}.caldera-grid .breadcrumb>.active,.caldera-grid .breadcrumb>.active>a{color:#777}.breadcrumb>li.active.error>a,.breadcrumb>li.error>a{color:red}.caldera-grid .cf-credit-card{padding-left:42px;background-image:url(../images/credit-card.svg);background-repeat:no-repeat!important;background-position-x:4px!important;background-position-y:3px!important}.caldera-grid .screen-reader-text{clip:rect(1px,1px,1px,1px);height:1px;overflow:hidden;position:absolute!important;width:1px;word-wrap:normal!important}@font-face{font-family:cf-raty;src:url(fonts/cf-raty.eot?40481674);src:url(fonts/cf-raty.eot?40481674#iefix) format('embedded-opentype'),url(fonts/cf-raty.woff?40481674) format('woff'),url(fonts/cf-raty.ttf?40481674) format('truetype'),url(fonts/cf-raty.svg?40481674#cf-raty) format('svg');font-weight:400;font-style:normal}[class*=" raty-"]:before,[class^=raty-]:before{font-family:cf-raty;font-style:normal;font-weight:400;speak:none;font-size:2em;display:inline-block;text-decoration:inherit;width:1em;text-align:center;font-variant:normal;text-transform:none;line-height:1em}.raty-heart-on:before{content:'\e800'}.raty-heart-off:before{content:'\e801'}.raty-star-on:before{content:'\e802'}.raty-star-off:before{content:'\e803'}.raty-circle-on:before{content:'\e804'}.raty-circle-off:before{content:'\e805'}.raty-dot-off:before{content:'\e806'}.raty-dot-on:before{content:'\e807'}.raty-face-off:before{content:'\e808'}.raty-face-on:before{content:'\e809'}.raty-cancel-off:before{content:'\e80a'}.raty-cancel-on:before{content:'\e80b'}.calculation-group{background:#FFF;box-shadow:0 1px 2px rgba(0,0,0,.05);padding:6px;margin:6px 0}.preview-color-selector{background:#F0F0F0;border:1px solid #E2E2E2;display:inline;margin-left:-1px;padding:3px 12px;box-shadow:0 0 0 2px #fff inset}.miniColors-trigger{border:1px solid #999;-mz-border-radius:0 1px 1px 0;-webkit-border-radius:0 1px 1px 0;display:inline-block;height:24px;margin:0 0 -8px -1px;width:30px}.cf-color-picker .input-group-btn:last-child>.btn,.cf-color-picker .input-group-btn:last-child>.btn-group,.cf-color-picker .input-group-btn>.btn+.btn{margin-left:-1px}.miniColors-selector{background:#FFF;border:1px solid #999;-moz-box-shadow:0 3px 0 -1px rgba(0,0,0,.05);-webkit-box-shadow:0 3px 0 -1px rgba(0,0,0,.05);box-shadow:0 3px 0 -1px rgba(0,0,0,.05);height:162px;padding:5px;position:absolute;width:187px;z-index:999999;margin-top:-1px}.miniColors-colors,.miniColors-hues{top:5px;height:150px;cursor:crosshair;position:absolute}.miniColors-selector.black{background:#000;border-color:#000}.miniColors-colors{left:5px;width:150px;background:url(minicolor-colors.png) right no-repeat}.miniColors-hues{left:160px;width:20px;background:url(minicolor-colors.png) left no-repeat}.miniColors-colorPicker{position:absolute;width:9px;height:9px;border:1px solid #fff;-moz-border-radius:11px;-webkit-border-radius:11px;border-radius:11px}.miniColors-colorPicker-inner{position:absolute;top:0;left:0;width:7px;height:7px;border:1px solid #000;-moz-border-radius:9px;-webkit-border-radius:9px;border-radius:9px}.miniColors-huePicker{position:absolute;left:-3px;width:24px;height:1px;border:1px solid #fff;border-radius:2px;background:#000}.cf-color-picker .form-control::-moz-placeholder{color:#999;opacity:1}.cf-color-picker .form-control:-ms-input-placeholder{color:#999}.cf-color-picker .form-control::-webkit-input-placeholder{color:#999}.cf-color-picker .form-control[disabled],.cf-color-picker .form-control[readonly],.cf-color-picker fieldset[disabled] .form-control{cursor:not-allowed;background-color:#eee;opacity:1}.cf-color-picker .form-group{margin-bottom:15px}.cf-color-picker .input-group{position:relative;display:table;border-collapse:separate;max-width:120px}.cf-color-picker .input-group[class*=col-]{float:none;padding-left:0;padding-right:0}.cf-color-picker .input-group .form-control{position:relative;z-index:2;float:left;width:100%;margin-bottom:0}.cf-color-picker .input-group-lg>.form-control,.cf-color-picker .input-group-lg>.input-group-addon,.cf-color-picker .input-group-lg>.input-group-btn>.btn{height:46px;padding:10px 16px;font-size:18px;line-height:1.33;border-radius:6px}.cf-color-picker .input-group-sm>.form-control,.cf-color-picker .input-group-sm>.input-group-addon,.cf-color-picker .input-group-sm>.input-group-btn>.btn{height:30px;padding:5px 10px;font-size:12px;line-height:1.5;border-radius:3px}.cf-color-picker .input-group .form-control,.cf-color-picker .input-group-addon,.cf-color-picker .input-group-btn{display:table-cell}.cf-color-picker .input-group .form-control:not(:first-child):not(:last-child),.cf-color-picker .input-group-addon:not(:first-child):not(:last-child),.cf-color-picker .input-group-btn:not(:first-child):not(:last-child){border-radius:0}.cf-color-picker .input-group-addon,.cf-color-picker .input-group-btn{width:1%;white-space:nowrap;vertical-align:middle}.cf-color-picker .input-group-addon{padding:6px 12px;font-size:14px;font-weight:400;line-height:1;color:#555;text-align:center;background-color:#eee;border:1px solid #ccc;border-radius:4px}.cf-color-picker .text-hide,.table-striped .cfdatepicker table tr td,.table-striped .cfdatepicker table tr th{background-color:transparent}.cf-color-picker .input-group-addon.input-sm{padding:5px 10px;font-size:12px;border-radius:3px}.cf-color-picker .input-group-addon.input-lg{padding:10px 16px;font-size:18px;border-radius:6px}.cf-color-picker .input-group .form-control:first-child,.cf-color-picker .input-group-addon:first-child,.cf-color-picker .input-group-btn:first-child>.btn,.cf-color-picker .input-group-btn:first-child>.btn-group>.btn,.cf-color-picker .input-group-btn:first-child>.dropdown-toggle,.cf-color-picker .input-group-btn:last-child>.btn-group:not(:last-child)>.btn,.cf-color-picker .input-group-btn:last-child>.btn:not(:last-child):not(.dropdown-toggle){border-bottom-right-radius:0;border-top-right-radius:0}.cf-color-picker .input-group-addon:first-child{border-right:0}.cf-color-picker .input-group .form-control:last-child,.cf-color-picker .input-group-addon:last-child,.cf-color-picker .input-group-btn:first-child>.btn-group:not(:first-child)>.btn,.cf-color-picker .input-group-btn:first-child>.btn:not(:first-child),.cf-color-picker .input-group-btn:last-child>.btn,.cf-color-picker .input-group-btn:last-child>.btn-group>.btn,.cf-color-picker .input-group-btn:last-child>.dropdown-toggle{border-bottom-left-radius:0;border-top-left-radius:0}.cf-color-picker .input-group-addon:last-child{border-left:0}.cf-color-picker .input-group-btn{position:relative;font-size:0;white-space:nowrap}.cf-color-picker .input-group-btn>.btn{position:relative}.cf-color-picker .input-group-btn>.btn:active,.cf-color-picker .input-group-btn>.btn:focus,.cf-color-picker .input-group-btn>.btn:hover{z-index:2}.cf-color-picker .input-group-btn:first-child>.btn,.cf-color-picker .input-group-btn:first-child>.btn-group{margin-right:-1px}.cf-color-picker .clearfix:after,.cf-color-picker .clearfix:before,.cf-color-picker .form-horizontal .form-group:after,.cf-color-picker .form-horizontal .form-group:before{content:" ";display:table}.cf-color-picker .clearfix:after,.cf-color-picker .form-horizontal .form-group:after{clear:both}.cf-color-picker .center-block{display:block;margin-left:auto;margin-right:auto}.cf-color-picker .pull-right{float:right!important}.cf-color-picker .pull-left{float:left!important}.cf-color-picker .hide{display:none!important}.cf-color-picker .show{display:block!important}.cf-color-picker .invisible{visibility:hidden}.cf-color-picker .text-hide{font:0/0 a;color:transparent;text-shadow:none;border:0}.cf-color-picker .hidden{display:none!important;visibility:hidden!important}.cf-color-picker .affix{position:fixed}@-ms-viewport{width:device-width}.cf-color-picker .visible-lg,.cf-color-picker .visible-md,.cf-color-picker .visible-print,.cf-color-picker .visible-sm,.cf-color-picker .visible-xs{display:none!important}@media (max-width:767px){.cf-color-picker .visible-xs{display:block!important}.cf-color-picker table.visible-xs{display:table}.cf-color-picker tr.visible-xs{display:table-row!important}.cf-color-picker td.visible-xs,.cf-color-picker th.visible-xs{display:table-cell!important}}@media (min-width:768px) and (max-width:991px){.cf-color-picker .visible-sm{display:block!important}.cf-color-picker table.visible-sm{display:table}.cf-color-picker tr.visible-sm{display:table-row!important}.cf-color-picker td.visible-sm,.cf-color-picker th.visible-sm{display:table-cell!important}}@media (min-width:992px) and (max-width:1199px){.cf-color-picker .visible-md{display:block!important}.cf-color-picker table.visible-md{display:table}.cf-color-picker tr.visible-md{display:table-row!important}.cf-color-picker td.visible-md,.cf-color-picker th.visible-md{display:table-cell!important}}@media (min-width:1200px){.cf-color-picker .visible-lg{display:block!important}.cf-color-picker table.visible-lg{display:table}.cf-color-picker tr.visible-lg{display:table-row!important}.cf-color-picker td.visible-lg,.cf-color-picker th.visible-lg{display:table-cell!important}.cf-color-picker .hidden-lg{display:none!important}}@media (max-width:767px){.cf-color-picker .hidden-xs{display:none!important}}@media (min-width:768px) and (max-width:991px){.cf-color-picker .hidden-sm{display:none!important}}@media (min-width:992px) and (max-width:1199px){.cf-color-picker .hidden-md{display:none!important}}@media print{.cf-color-picker .visible-print{display:block!important}.cf-color-picker table.visible-print{display:table}.cf-color-picker tr.visible-print{display:table-row!important}.cf-color-picker td.visible-print,.cf-color-picker th.visible-print{display:table-cell!important}.cf-color-picker .hidden-print{display:none!important}}.cfdatepicker-dropdown:after,.cfdatepicker-dropdown:before{content:'';display:inline-block;border-top:0;position:absolute}.cfdatepicker{padding:4px;border-radius:4px;direction:ltr}.cfdatepicker-inline{width:220px}.cfdatepicker.cfdatepicker-rtl{direction:rtl}.cfdatepicker.cfdatepicker-rtl table tr td span{float:right}.cfdatepicker-dropdown{top:0;left:0}.cfdatepicker-dropdown:before{border-left:7px solid transparent;border-right:7px solid transparent;border-bottom:7px solid #ccc;border-bottom-color:rgba(0,0,0,.2)}.cfdatepicker-dropdown:after{border-left:6px solid transparent;border-right:6px solid transparent;border-bottom:6px solid #fff}.cfdatepicker-dropdown.cfdatepicker-orient-left:before{left:6px}.cfdatepicker-dropdown.cfdatepicker-orient-left:after{left:7px}.cfdatepicker-dropdown.cfdatepicker-orient-right:before{right:6px}.cfdatepicker-dropdown.cfdatepicker-orient-right:after{right:7px}.cfdatepicker-dropdown.cfdatepicker-orient-top:before{top:-7px}.cfdatepicker-dropdown.cfdatepicker-orient-top:after{top:-6px}.cfdatepicker-dropdown.cfdatepicker-orient-bottom:before{bottom:-7px;border-bottom:0;border-top:7px solid #999}.cfdatepicker-dropdown.cfdatepicker-orient-bottom:after{bottom:-6px;border-bottom:0;border-top:6px solid #fff}.cfdatepicker>div{display:none}.cfdatepicker.days div.cfdatepicker-days,.cfdatepicker.months div.cfdatepicker-months,.cfdatepicker.years div.cfdatepicker-years{display:block}.cfdatepicker table{border:0;width:auto;margin:0;-webkit-touch-callout:none;-khtml-user-select:none;user-select:none}.cfdatepicker table tr td,.cfdatepicker table tr th{text-align:center;width:10px;height:10px;border-radius:4px;border:none}.cfdatepicker table tr td.day.focused,.cfdatepicker table tr td.day:hover{background:#eee;cursor:pointer}.cfdatepicker table tr td.new,.cfdatepicker table tr td.old{color:#999}.cfdatepicker table tr td.disabled,.cfdatepicker table tr td.disabled:hover{background:0 0;color:#999;cursor:default}.cfdatepicker table tr td.today,.cfdatepicker table tr td.today.disabled,.cfdatepicker table tr td.today.disabled:hover,.cfdatepicker table tr td.today:hover{color:#000;background-color:#ffdb99;border-color:#ffb733}.cfdatepicker table tr td.today.active,.cfdatepicker table tr td.today.disabled.active,.cfdatepicker table tr td.today.disabled:active,.cfdatepicker table tr td.today.disabled:focus,.cfdatepicker table tr td.today.disabled:hover,.cfdatepicker table tr td.today.disabled:hover.active,.cfdatepicker table tr td.today.disabled:hover:active,.cfdatepicker table tr td.today.disabled:hover:focus,.cfdatepicker table tr td.today.disabled:hover:hover,.cfdatepicker table tr td.today:active,.cfdatepicker table tr td.today:focus,.cfdatepicker table tr td.today:hover,.cfdatepicker table tr td.today:hover.active,.cfdatepicker table tr td.today:hover:active,.cfdatepicker table tr td.today:hover:focus,.cfdatepicker table tr td.today:hover:hover,.open .dropdown-toggle.cfdatepicker table tr td.today,.open .dropdown-toggle.cfdatepicker table tr td.today.disabled,.open .dropdown-toggle.cfdatepicker table tr td.today.disabled:hover,.open .dropdown-toggle.cfdatepicker table tr td.today:hover{color:#000;background-color:#ffcd70;border-color:#f59e00}.cfdatepicker table tr td.today.active,.cfdatepicker table tr td.today.disabled.active,.cfdatepicker table tr td.today.disabled:active,.cfdatepicker table tr td.today.disabled:hover.active,.cfdatepicker table tr td.today.disabled:hover:active,.cfdatepicker table tr td.today:active,.cfdatepicker table tr td.today:hover.active,.cfdatepicker table tr td.today:hover:active,.open .dropdown-toggle.cfdatepicker table tr td.today,.open .dropdown-toggle.cfdatepicker table tr td.today.disabled,.open .dropdown-toggle.cfdatepicker table tr td.today.disabled:hover,.open .dropdown-toggle.cfdatepicker table tr td.today:hover{background-image:none}.cfdatepicker table tr td.today.disabled,.cfdatepicker table tr td.today.disabled.active,.cfdatepicker table tr td.today.disabled.disabled,.cfdatepicker table tr td.today.disabled.disabled.active,.cfdatepicker table tr td.today.disabled.disabled:active,.cfdatepicker table tr td.today.disabled.disabled:focus,.cfdatepicker table tr td.today.disabled.disabled:hover,.cfdatepicker table tr td.today.disabled:active,.cfdatepicker table tr td.today.disabled:focus,.cfdatepicker table tr td.today.disabled:hover,.cfdatepicker table tr td.today.disabled:hover.disabled,.cfdatepicker table tr td.today.disabled:hover.disabled.active,.cfdatepicker table tr td.today.disabled:hover.disabled:active,.cfdatepicker table tr td.today.disabled:hover.disabled:focus,.cfdatepicker table tr td.today.disabled:hover.disabled:hover,.cfdatepicker table tr td.today.disabled:hover[disabled],.cfdatepicker table tr td.today.disabled:hover[disabled].active,.cfdatepicker table tr td.today.disabled:hover[disabled]:active,.cfdatepicker table tr td.today.disabled:hover[disabled]:focus,.cfdatepicker table tr td.today.disabled:hover[disabled]:hover,.cfdatepicker table tr td.today.disabled[disabled],.cfdatepicker table tr td.today.disabled[disabled].active,.cfdatepicker table tr td.today.disabled[disabled]:active,.cfdatepicker table tr td.today.disabled[disabled]:focus,.cfdatepicker table tr td.today.disabled[disabled]:hover,.cfdatepicker table tr td.today:hover.disabled,.cfdatepicker table tr td.today:hover.disabled.active,.cfdatepicker table tr td.today:hover.disabled:active,.cfdatepicker table tr td.today:hover.disabled:focus,.cfdatepicker table tr td.today:hover.disabled:hover,.cfdatepicker table tr td.today:hover[disabled],.cfdatepicker table tr td.today:hover[disabled].active,.cfdatepicker table tr td.today:hover[disabled]:active,.cfdatepicker table tr td.today:hover[disabled]:focus,.cfdatepicker table tr td.today:hover[disabled]:hover,.cfdatepicker table tr td.today[disabled],.cfdatepicker table tr td.today[disabled].active,.cfdatepicker table tr td.today[disabled]:active,.cfdatepicker table tr td.today[disabled]:focus,.cfdatepicker table tr td.today[disabled]:hover,fieldset[disabled] .cfdatepicker table tr td.today,fieldset[disabled] .cfdatepicker table tr td.today.active,fieldset[disabled] .cfdatepicker table tr td.today.disabled,fieldset[disabled] .cfdatepicker table tr td.today.disabled.active,fieldset[disabled] .cfdatepicker table tr td.today.disabled:active,fieldset[disabled] .cfdatepicker table tr td.today.disabled:focus,fieldset[disabled] .cfdatepicker table tr td.today.disabled:hover,fieldset[disabled] .cfdatepicker table tr td.today.disabled:hover.active,fieldset[disabled] .cfdatepicker table tr td.today.disabled:hover:active,fieldset[disabled] .cfdatepicker table tr td.today.disabled:hover:focus,fieldset[disabled] .cfdatepicker table tr td.today.disabled:hover:hover,fieldset[disabled] .cfdatepicker table tr td.today:active,fieldset[disabled] .cfdatepicker table tr td.today:focus,fieldset[disabled] .cfdatepicker table tr td.today:hover,fieldset[disabled] .cfdatepicker table tr td.today:hover.active,fieldset[disabled] .cfdatepicker table tr td.today:hover:active,fieldset[disabled] .cfdatepicker table tr td.today:hover:focus,fieldset[disabled] .cfdatepicker table tr td.today:hover:hover{background-color:#ffdb99;border-color:#ffb733}.cfdatepicker table tr td.today:hover:hover{color:#000}.cfdatepicker table tr td.today.active:hover{color:#fff}.cfdatepicker table tr td.range,.cfdatepicker table tr td.range.disabled,.cfdatepicker table tr td.range.disabled:hover,.cfdatepicker table tr td.range:hover{background:#eee;border-radius:0}.cfdatepicker table tr td.active.active,.cfdatepicker table tr td.active.disabled.active,.cfdatepicker table tr td.active.disabled:active,.cfdatepicker table tr td.active.disabled:hover.active,.cfdatepicker table tr td.active.disabled:hover:active,.cfdatepicker table tr td.active:active,.cfdatepicker table tr td.active:hover.active,.cfdatepicker table tr td.active:hover:active,.cfdatepicker table tr td.range.today.active,.cfdatepicker table tr td.range.today.disabled.active,.cfdatepicker table tr td.range.today.disabled:active,.cfdatepicker table tr td.range.today.disabled:hover.active,.cfdatepicker table tr td.range.today.disabled:hover:active,.cfdatepicker table tr td.range.today:active,.cfdatepicker table tr td.range.today:hover.active,.cfdatepicker table tr td.range.today:hover:active,.cfdatepicker table tr td.selected.active,.cfdatepicker table tr td.selected.disabled.active,.cfdatepicker table tr td.selected.disabled:active,.cfdatepicker table tr td.selected.disabled:hover.active,.cfdatepicker table tr td.selected.disabled:hover:active,.cfdatepicker table tr td.selected:active,.cfdatepicker table tr td.selected:hover.active,.cfdatepicker table tr td.selected:hover:active,.open .dropdown-toggle.cfdatepicker table tr td.active,.open .dropdown-toggle.cfdatepicker table tr td.active.disabled,.open .dropdown-toggle.cfdatepicker table tr td.active.disabled:hover,.open .dropdown-toggle.cfdatepicker table tr td.active:hover,.open .dropdown-toggle.cfdatepicker table tr td.range.today,.open .dropdown-toggle.cfdatepicker table tr td.range.today.disabled,.open .dropdown-toggle.cfdatepicker table tr td.range.today.disabled:hover,.open .dropdown-toggle.cfdatepicker table tr td.range.today:hover,.open .dropdown-toggle.cfdatepicker table tr td.selected,.open .dropdown-toggle.cfdatepicker table tr td.selected.disabled,.open .dropdown-toggle.cfdatepicker table tr td.selected.disabled:hover,.open .dropdown-toggle.cfdatepicker table tr td.selected:hover{background-image:none}.cfdatepicker table tr td.range.today,.cfdatepicker table tr td.range.today.disabled,.cfdatepicker table tr td.range.today.disabled:hover,.cfdatepicker table tr td.range.today:hover{color:#000;background-color:#f7ca77;border-color:#f1a417;border-radius:0}.cfdatepicker table tr td.range.today.active,.cfdatepicker table tr td.range.today.disabled.active,.cfdatepicker table tr td.range.today.disabled:active,.cfdatepicker table tr td.range.today.disabled:focus,.cfdatepicker table tr td.range.today.disabled:hover,.cfdatepicker table tr td.range.today.disabled:hover.active,.cfdatepicker table tr td.range.today.disabled:hover:active,.cfdatepicker table tr td.range.today.disabled:hover:focus,.cfdatepicker table tr td.range.today.disabled:hover:hover,.cfdatepicker table tr td.range.today:active,.cfdatepicker table tr td.range.today:focus,.cfdatepicker table tr td.range.today:hover,.cfdatepicker table tr td.range.today:hover.active,.cfdatepicker table tr td.range.today:hover:active,.cfdatepicker table tr td.range.today:hover:focus,.cfdatepicker table tr td.range.today:hover:hover,.open .dropdown-toggle.cfdatepicker table tr td.range.today,.open .dropdown-toggle.cfdatepicker table tr td.range.today.disabled,.open .dropdown-toggle.cfdatepicker table tr td.range.today.disabled:hover,.open .dropdown-toggle.cfdatepicker table tr td.range.today:hover{color:#000;background-color:#f4bb51;border-color:#bf800c}.cfdatepicker table tr td.range.today.disabled,.cfdatepicker table tr td.range.today.disabled.active,.cfdatepicker table tr td.range.today.disabled.disabled,.cfdatepicker table tr td.range.today.disabled.disabled.active,.cfdatepicker table tr td.range.today.disabled.disabled:active,.cfdatepicker table tr td.range.today.disabled.disabled:focus,.cfdatepicker table tr td.range.today.disabled.disabled:hover,.cfdatepicker table tr td.range.today.disabled:active,.cfdatepicker table tr td.range.today.disabled:focus,.cfdatepicker table tr td.range.today.disabled:hover,.cfdatepicker table tr td.range.today.disabled:hover.disabled,.cfdatepicker table tr td.range.today.disabled:hover.disabled.active,.cfdatepicker table tr td.range.today.disabled:hover.disabled:active,.cfdatepicker table tr td.range.today.disabled:hover.disabled:focus,.cfdatepicker table tr td.range.today.disabled:hover.disabled:hover,.cfdatepicker table tr td.range.today.disabled:hover[disabled],.cfdatepicker table tr td.range.today.disabled:hover[disabled].active,.cfdatepicker table tr td.range.today.disabled:hover[disabled]:active,.cfdatepicker table tr td.range.today.disabled:hover[disabled]:focus,.cfdatepicker table tr td.range.today.disabled:hover[disabled]:hover,.cfdatepicker table tr td.range.today.disabled[disabled],.cfdatepicker table tr td.range.today.disabled[disabled].active,.cfdatepicker table tr td.range.today.disabled[disabled]:active,.cfdatepicker table tr td.range.today.disabled[disabled]:focus,.cfdatepicker table tr td.range.today.disabled[disabled]:hover,.cfdatepicker table tr td.range.today:hover.disabled,.cfdatepicker table tr td.range.today:hover.disabled.active,.cfdatepicker table tr td.range.today:hover.disabled:active,.cfdatepicker table tr td.range.today:hover.disabled:focus,.cfdatepicker table tr td.range.today:hover.disabled:hover,.cfdatepicker table tr td.range.today:hover[disabled],.cfdatepicker table tr td.range.today:hover[disabled].active,.cfdatepicker table tr td.range.today:hover[disabled]:active,.cfdatepicker table tr td.range.today:hover[disabled]:focus,.cfdatepicker table tr td.range.today:hover[disabled]:hover,.cfdatepicker table tr td.range.today[disabled],.cfdatepicker table tr td.range.today[disabled].active,.cfdatepicker table tr td.range.today[disabled]:active,.cfdatepicker table tr td.range.today[disabled]:focus,.cfdatepicker table tr td.range.today[disabled]:hover,fieldset[disabled] .cfdatepicker table tr td.range.today,fieldset[disabled] .cfdatepicker table tr td.range.today.active,fieldset[disabled] .cfdatepicker table tr td.range.today.disabled,fieldset[disabled] .cfdatepicker table tr td.range.today.disabled.active,fieldset[disabled] .cfdatepicker table tr td.range.today.disabled:active,fieldset[disabled] .cfdatepicker table tr td.range.today.disabled:focus,fieldset[disabled] .cfdatepicker table tr td.range.today.disabled:hover,fieldset[disabled] .cfdatepicker table tr td.range.today.disabled:hover.active,fieldset[disabled] .cfdatepicker table tr td.range.today.disabled:hover:active,fieldset[disabled] .cfdatepicker table tr td.range.today.disabled:hover:focus,fieldset[disabled] .cfdatepicker table tr td.range.today.disabled:hover:hover,fieldset[disabled] .cfdatepicker table tr td.range.today:active,fieldset[disabled] .cfdatepicker table tr td.range.today:focus,fieldset[disabled] .cfdatepicker table tr td.range.today:hover,fieldset[disabled] .cfdatepicker table tr td.range.today:hover.active,fieldset[disabled] .cfdatepicker table tr td.range.today:hover:active,fieldset[disabled] .cfdatepicker table tr td.range.today:hover:focus,fieldset[disabled] .cfdatepicker table tr td.range.today:hover:hover{background-color:#f7ca77;border-color:#f1a417}.cfdatepicker table tr td.selected,.cfdatepicker table tr td.selected.disabled,.cfdatepicker table tr td.selected.disabled:hover,.cfdatepicker table tr td.selected:hover{color:#fff;background-color:#999;border-color:#555;text-shadow:0 -1px 0 rgba(0,0,0,.25)}.cfdatepicker table tr td.selected.active,.cfdatepicker table tr td.selected.disabled.active,.cfdatepicker table tr td.selected.disabled:active,.cfdatepicker table tr td.selected.disabled:focus,.cfdatepicker table tr td.selected.disabled:hover,.cfdatepicker table tr td.selected.disabled:hover.active,.cfdatepicker table tr td.selected.disabled:hover:active,.cfdatepicker table tr td.selected.disabled:hover:focus,.cfdatepicker table tr td.selected.disabled:hover:hover,.cfdatepicker table tr td.selected:active,.cfdatepicker table tr td.selected:focus,.cfdatepicker table tr td.selected:hover,.cfdatepicker table tr td.selected:hover.active,.cfdatepicker table tr td.selected:hover:active,.cfdatepicker table tr td.selected:hover:focus,.cfdatepicker table tr td.selected:hover:hover,.open .dropdown-toggle.cfdatepicker table tr td.selected,.open .dropdown-toggle.cfdatepicker table tr td.selected.disabled,.open .dropdown-toggle.cfdatepicker table tr td.selected.disabled:hover,.open .dropdown-toggle.cfdatepicker table tr td.selected:hover{color:#fff;background-color:#858585;border-color:#373737}.cfdatepicker table tr td.selected.disabled,.cfdatepicker table tr td.selected.disabled.active,.cfdatepicker table tr td.selected.disabled.disabled,.cfdatepicker table tr td.selected.disabled.disabled.active,.cfdatepicker table tr td.selected.disabled.disabled:active,.cfdatepicker table tr td.selected.disabled.disabled:focus,.cfdatepicker table tr td.selected.disabled.disabled:hover,.cfdatepicker table tr td.selected.disabled:active,.cfdatepicker table tr td.selected.disabled:focus,.cfdatepicker table tr td.selected.disabled:hover,.cfdatepicker table tr td.selected.disabled:hover.disabled,.cfdatepicker table tr td.selected.disabled:hover.disabled.active,.cfdatepicker table tr td.selected.disabled:hover.disabled:active,.cfdatepicker table tr td.selected.disabled:hover.disabled:focus,.cfdatepicker table tr td.selected.disabled:hover.disabled:hover,.cfdatepicker table tr td.selected.disabled:hover[disabled],.cfdatepicker table tr td.selected.disabled:hover[disabled].active,.cfdatepicker table tr td.selected.disabled:hover[disabled]:active,.cfdatepicker table tr td.selected.disabled:hover[disabled]:focus,.cfdatepicker table tr td.selected.disabled:hover[disabled]:hover,.cfdatepicker table tr td.selected.disabled[disabled],.cfdatepicker table tr td.selected.disabled[disabled].active,.cfdatepicker table tr td.selected.disabled[disabled]:active,.cfdatepicker table tr td.selected.disabled[disabled]:focus,.cfdatepicker table tr td.selected.disabled[disabled]:hover,.cfdatepicker table tr td.selected:hover.disabled,.cfdatepicker table tr td.selected:hover.disabled.active,.cfdatepicker table tr td.selected:hover.disabled:active,.cfdatepicker table tr td.selected:hover.disabled:focus,.cfdatepicker table tr td.selected:hover.disabled:hover,.cfdatepicker table tr td.selected:hover[disabled],.cfdatepicker table tr td.selected:hover[disabled].active,.cfdatepicker table tr td.selected:hover[disabled]:active,.cfdatepicker table tr td.selected:hover[disabled]:focus,.cfdatepicker table tr td.selected:hover[disabled]:hover,.cfdatepicker table tr td.selected[disabled],.cfdatepicker table tr td.selected[disabled].active,.cfdatepicker table tr td.selected[disabled]:active,.cfdatepicker table tr td.selected[disabled]:focus,.cfdatepicker table tr td.selected[disabled]:hover,fieldset[disabled] .cfdatepicker table tr td.selected,fieldset[disabled] .cfdatepicker table tr td.selected.active,fieldset[disabled] .cfdatepicker table tr td.selected.disabled,fieldset[disabled] .cfdatepicker table tr td.selected.disabled.active,fieldset[disabled] .cfdatepicker table tr td.selected.disabled:active,fieldset[disabled] .cfdatepicker table tr td.selected.disabled:focus,fieldset[disabled] .cfdatepicker table tr td.selected.disabled:hover,fieldset[disabled] .cfdatepicker table tr td.selected.disabled:hover.active,fieldset[disabled] .cfdatepicker table tr td.selected.disabled:hover:active,fieldset[disabled] .cfdatepicker table tr td.selected.disabled:hover:focus,fieldset[disabled] .cfdatepicker table tr td.selected.disabled:hover:hover,fieldset[disabled] .cfdatepicker table tr td.selected:active,fieldset[disabled] .cfdatepicker table tr td.selected:focus,fieldset[disabled] .cfdatepicker table tr td.selected:hover,fieldset[disabled] .cfdatepicker table tr td.selected:hover.active,fieldset[disabled] .cfdatepicker table tr td.selected:hover:active,fieldset[disabled] .cfdatepicker table tr td.selected:hover:focus,fieldset[disabled] .cfdatepicker table tr td.selected:hover:hover{background-color:#999;border-color:#555}.cfdatepicker table tr td.active,.cfdatepicker table tr td.active.disabled,.cfdatepicker table tr td.active.disabled:hover,.cfdatepicker table tr td.active:hover{color:#fff;background-color:#428bca;border-color:#357ebd;text-shadow:0 -1px 0 rgba(0,0,0,.25)}.cfdatepicker table tr td.active.active,.cfdatepicker table tr td.active.disabled.active,.cfdatepicker table tr td.active.disabled:active,.cfdatepicker table tr td.active.disabled:focus,.cfdatepicker table tr td.active.disabled:hover,.cfdatepicker table tr td.active.disabled:hover.active,.cfdatepicker table tr td.active.disabled:hover:active,.cfdatepicker table tr td.active.disabled:hover:focus,.cfdatepicker table tr td.active.disabled:hover:hover,.cfdatepicker table tr td.active:active,.cfdatepicker table tr td.active:focus,.cfdatepicker table tr td.active:hover,.cfdatepicker table tr td.active:hover.active,.cfdatepicker table tr td.active:hover:active,.cfdatepicker table tr td.active:hover:focus,.cfdatepicker table tr td.active:hover:hover,.open .dropdown-toggle.cfdatepicker table tr td.active,.open .dropdown-toggle.cfdatepicker table tr td.active.disabled,.open .dropdown-toggle.cfdatepicker table tr td.active.disabled:hover,.open .dropdown-toggle.cfdatepicker table tr td.active:hover{color:#fff;background-color:#3276b1;border-color:#285e8e}.cfdatepicker table tr td.active.disabled,.cfdatepicker table tr td.active.disabled.active,.cfdatepicker table tr td.active.disabled.disabled,.cfdatepicker table tr td.active.disabled.disabled.active,.cfdatepicker table tr td.active.disabled.disabled:active,.cfdatepicker table tr td.active.disabled.disabled:focus,.cfdatepicker table tr td.active.disabled.disabled:hover,.cfdatepicker table tr td.active.disabled:active,.cfdatepicker table tr td.active.disabled:focus,.cfdatepicker table tr td.active.disabled:hover,.cfdatepicker table tr td.active.disabled:hover.disabled,.cfdatepicker table tr td.active.disabled:hover.disabled.active,.cfdatepicker table tr td.active.disabled:hover.disabled:active,.cfdatepicker table tr td.active.disabled:hover.disabled:focus,.cfdatepicker table tr td.active.disabled:hover.disabled:hover,.cfdatepicker table tr td.active.disabled:hover[disabled],.cfdatepicker table tr td.active.disabled:hover[disabled].active,.cfdatepicker table tr td.active.disabled:hover[disabled]:active,.cfdatepicker table tr td.active.disabled:hover[disabled]:focus,.cfdatepicker table tr td.active.disabled:hover[disabled]:hover,.cfdatepicker table tr td.active.disabled[disabled],.cfdatepicker table tr td.active.disabled[disabled].active,.cfdatepicker table tr td.active.disabled[disabled]:active,.cfdatepicker table tr td.active.disabled[disabled]:focus,.cfdatepicker table tr td.active.disabled[disabled]:hover,.cfdatepicker table tr td.active:hover.disabled,.cfdatepicker table tr td.active:hover.disabled.active,.cfdatepicker table tr td.active:hover.disabled:active,.cfdatepicker table tr td.active:hover.disabled:focus,.cfdatepicker table tr td.active:hover.disabled:hover,.cfdatepicker table tr td.active:hover[disabled],.cfdatepicker table tr td.active:hover[disabled].active,.cfdatepicker table tr td.active:hover[disabled]:active,.cfdatepicker table tr td.active:hover[disabled]:focus,.cfdatepicker table tr td.active:hover[disabled]:hover,.cfdatepicker table tr td.active[disabled],.cfdatepicker table tr td.active[disabled].active,.cfdatepicker table tr td.active[disabled]:active,.cfdatepicker table tr td.active[disabled]:focus,.cfdatepicker table tr td.active[disabled]:hover,fieldset[disabled] .cfdatepicker table tr td.active,fieldset[disabled] .cfdatepicker table tr td.active.active,fieldset[disabled] .cfdatepicker table tr td.active.disabled,fieldset[disabled] .cfdatepicker table tr td.active.disabled.active,fieldset[disabled] .cfdatepicker table tr td.active.disabled:active,fieldset[disabled] .cfdatepicker table tr td.active.disabled:focus,fieldset[disabled] .cfdatepicker table tr td.active.disabled:hover,fieldset[disabled] .cfdatepicker table tr td.active.disabled:hover.active,fieldset[disabled] .cfdatepicker table tr td.active.disabled:hover:active,fieldset[disabled] .cfdatepicker table tr td.active.disabled:hover:focus,fieldset[disabled] .cfdatepicker table tr td.active.disabled:hover:hover,fieldset[disabled] .cfdatepicker table tr td.active:active,fieldset[disabled] .cfdatepicker table tr td.active:focus,fieldset[disabled] .cfdatepicker table tr td.active:hover,fieldset[disabled] .cfdatepicker table tr td.active:hover.active,fieldset[disabled] .cfdatepicker table tr td.active:hover:active,fieldset[disabled] .cfdatepicker table tr td.active:hover:focus,fieldset[disabled] .cfdatepicker table tr td.active:hover:hover{background-color:#428bca;border-color:#357ebd}.cfdatepicker table tr td span{display:block;width:23%;height:54px;line-height:54px;float:left;margin:1%;cursor:pointer;border-radius:4px}.cfdatepicker table tr td span:hover{background:#eee}.cfdatepicker table tr td span.disabled,.cfdatepicker table tr td span.disabled:hover{background:0 0;color:#999;cursor:default}.cfdatepicker table tr td span.active,.cfdatepicker table tr td span.active.disabled,.cfdatepicker table tr td span.active.disabled:hover,.cfdatepicker table tr td span.active:hover{color:#fff;background-color:#428bca;border-color:#357ebd;text-shadow:0 -1px 0 rgba(0,0,0,.25)}.cfdatepicker table tr td span.active.active,.cfdatepicker table tr td span.active.disabled.active,.cfdatepicker table tr td span.active.disabled:active,.cfdatepicker table tr td span.active.disabled:focus,.cfdatepicker table tr td span.active.disabled:hover,.cfdatepicker table tr td span.active.disabled:hover.active,.cfdatepicker table tr td span.active.disabled:hover:active,.cfdatepicker table tr td span.active.disabled:hover:focus,.cfdatepicker table tr td span.active.disabled:hover:hover,.cfdatepicker table tr td span.active:active,.cfdatepicker table tr td span.active:focus,.cfdatepicker table tr td span.active:hover,.cfdatepicker table tr td span.active:hover.active,.cfdatepicker table tr td span.active:hover:active,.cfdatepicker table tr td span.active:hover:focus,.cfdatepicker table tr td span.active:hover:hover,.open .dropdown-toggle.cfdatepicker table tr td span.active,.open .dropdown-toggle.cfdatepicker table tr td span.active.disabled,.open .dropdown-toggle.cfdatepicker table tr td span.active.disabled:hover,.open .dropdown-toggle.cfdatepicker table tr td span.active:hover{color:#fff;background-color:#3276b1;border-color:#285e8e}.cfdatepicker table tr td span.active.active,.cfdatepicker table tr td span.active.disabled.active,.cfdatepicker table tr td span.active.disabled:active,.cfdatepicker table tr td span.active.disabled:hover.active,.cfdatepicker table tr td span.active.disabled:hover:active,.cfdatepicker table tr td span.active:active,.cfdatepicker table tr td span.active:hover.active,.cfdatepicker table tr td span.active:hover:active,.open .dropdown-toggle.cfdatepicker table tr td span.active,.open .dropdown-toggle.cfdatepicker table tr td span.active.disabled,.open .dropdown-toggle.cfdatepicker table tr td span.active.disabled:hover,.open .dropdown-toggle.cfdatepicker table tr td span.active:hover{background-image:none}.cfdatepicker table tr td span.active.disabled,.cfdatepicker table tr td span.active.disabled.active,.cfdatepicker table tr td span.active.disabled.disabled,.cfdatepicker table tr td span.active.disabled.disabled.active,.cfdatepicker table tr td span.active.disabled.disabled:active,.cfdatepicker table tr td span.active.disabled.disabled:focus,.cfdatepicker table tr td span.active.disabled.disabled:hover,.cfdatepicker table tr td span.active.disabled:active,.cfdatepicker table tr td span.active.disabled:focus,.cfdatepicker table tr td span.active.disabled:hover,.cfdatepicker table tr td span.active.disabled:hover.disabled,.cfdatepicker table tr td span.active.disabled:hover.disabled.active,.cfdatepicker table tr td span.active.disabled:hover.disabled:active,.cfdatepicker table tr td span.active.disabled:hover.disabled:focus,.cfdatepicker table tr td span.active.disabled:hover.disabled:hover,.cfdatepicker table tr td span.active.disabled:hover[disabled],.cfdatepicker table tr td span.active.disabled:hover[disabled].active,.cfdatepicker table tr td span.active.disabled:hover[disabled]:active,.cfdatepicker table tr td span.active.disabled:hover[disabled]:focus,.cfdatepicker table tr td span.active.disabled:hover[disabled]:hover,.cfdatepicker table tr td span.active.disabled[disabled],.cfdatepicker table tr td span.active.disabled[disabled].active,.cfdatepicker table tr td span.active.disabled[disabled]:active,.cfdatepicker table tr td span.active.disabled[disabled]:focus,.cfdatepicker table tr td span.active.disabled[disabled]:hover,.cfdatepicker table tr td span.active:hover.disabled,.cfdatepicker table tr td span.active:hover.disabled.active,.cfdatepicker table tr td span.active:hover.disabled:active,.cfdatepicker table tr td span.active:hover.disabled:focus,.cfdatepicker table tr td span.active:hover.disabled:hover,.cfdatepicker table tr td span.active:hover[disabled],.cfdatepicker table tr td span.active:hover[disabled].active,.cfdatepicker table tr td span.active:hover[disabled]:active,.cfdatepicker table tr td span.active:hover[disabled]:focus,.cfdatepicker table tr td span.active:hover[disabled]:hover,.cfdatepicker table tr td span.active[disabled],.cfdatepicker table tr td span.active[disabled].active,.cfdatepicker table tr td span.active[disabled]:active,.cfdatepicker table tr td span.active[disabled]:focus,.cfdatepicker table tr td span.active[disabled]:hover,fieldset[disabled] .cfdatepicker table tr td span.active,fieldset[disabled] .cfdatepicker table tr td span.active.active,fieldset[disabled] .cfdatepicker table tr td span.active.disabled,fieldset[disabled] .cfdatepicker table tr td span.active.disabled.active,fieldset[disabled] .cfdatepicker table tr td span.active.disabled:active,fieldset[disabled] .cfdatepicker table tr td span.active.disabled:focus,fieldset[disabled] .cfdatepicker table tr td span.active.disabled:hover,fieldset[disabled] .cfdatepicker table tr td span.active.disabled:hover.active,fieldset[disabled] .cfdatepicker table tr td span.active.disabled:hover:active,fieldset[disabled] .cfdatepicker table tr td span.active.disabled:hover:focus,fieldset[disabled] .cfdatepicker table tr td span.active.disabled:hover:hover,fieldset[disabled] .cfdatepicker table tr td span.active:active,fieldset[disabled] .cfdatepicker table tr td span.active:focus,fieldset[disabled] .cfdatepicker table tr td span.active:hover,fieldset[disabled] .cfdatepicker table tr td span.active:hover.active,fieldset[disabled] .cfdatepicker table tr td span.active:hover:active,fieldset[disabled] .cfdatepicker table tr td span.active:hover:focus,fieldset[disabled] .cfdatepicker table tr td span.active:hover:hover{background-color:#428bca;border-color:#357ebd}.cfdatepicker table tr td span.new,.cfdatepicker table tr td span.old{color:#999}.cfdatepicker th.cfdatepicker-switch{width:145px}.cfdatepicker tfoot tr th,.cfdatepicker thead tr:first-child th{cursor:pointer}.cfdatepicker tfoot tr th:hover,.cfdatepicker thead tr:first-child th:hover{background:#eee}.cfdatepicker .cw{font-size:10px;width:12px;padding:0 2px 0 5px;vertical-align:middle}.cfdatepicker thead tr:first-child th.cw{cursor:default;background-color:transparent}.input-group.date .input-group-addon i{cursor:pointer;width:16px;height:16px}.input-daterange input{text-align:center}.input-daterange input:first-child{border-radius:3px 0 0 3px}.input-daterange input:last-child{border-radius:0 3px 3px 0}.input-daterange .input-group-addon{width:auto;min-width:16px;padding:4px 5px;font-weight:400;line-height:1.42857143;text-align:center;text-shadow:0 1px 0 #fff;vertical-align:middle;background-color:#eee;border:solid #ccc;border-width:1px 0;margin-left:-5px;margin-right:-5px}.cfdatepicker.dropdown-menu{position:absolute;top:100%;left:0;z-index:1000;float:left;display:none;min-width:160px;list-style:none;background-color:#fff;border:1px solid #ccc;border:1px solid rgba(0,0,0,.2);border-radius:5px;-webkit-box-shadow:0 5px 10px rgba(0,0,0,.2);-moz-box-shadow:0 5px 10px rgba(0,0,0,.2);box-shadow:0 5px 10px rgba(0,0,0,.2);-webkit-background-clip:padding-box;-moz-background-clip:padding;background-clip:padding-box;color:#333;font-family:"Helvetica Neue",Helvetica,Arial,sans-serif;font-size:13px;line-height:1.42857143}.cfdatepicker.dropdown-menu td,.cfdatepicker.dropdown-menu th{padding:4px 5px}.image-thumb{margin-left:63px;padding:6px 0 6px 6px}.image-picker-content.image-thumb-lrg{margin-bottom:6px}.image-picker-side-bar{float:left;margin-left:-68px;width:62px;max-width:100%}.image-thumb-lrg .image-picker-side-bar{background:#F6F6F6;border:1px solid #DFDFDF;float:none;margin:0 0 6px;padding:6px 6px 2px;text-align:center;width:auto}.image-picker-side-bar>img{border:1px solid #DFDFDF;width:62px}.image-thumb-lrg .image-picker-side-bar>img{-moz-box-sizing:border-box;box-sizing:border-box;max-width:100%;text-align:center;width:auto}.image-thumb .image-picker-main-content{margin-right:6px}.button.image-picker-button{margin:7px 0 0;width:110px;display:inline-block}.button.button-primary.image-picker-button{float:right;margin-left:6px;width:80px}.image-picker-main-content select{width:100%}.image-picker-sizer:disabled{opacity:.7;box-shadow:none;color:#A1A1A1}.button-primary.image-picker-button.image-picker-button-solo,.button.image-picker-button.image-picker-button-solo{width:170px;margin-top:0}.button-primary.image-picker-button.image-picker-button-solo{margin-top:7px;margin-left:0;float:none}.image-thumb-lrg .button.image-picker-button.cu-image-picker.image-picker-button-solo{width:120px}.image-thumb-lrg .button.button-primary.image-picker-button.cu-image-remover.image-picker-button-solo{float:right;margin:0 0 0 6px;width:auto}.cf-toggle-switch .btn-group>.btn-group,.cf-toggle-switch .btn-toolbar .btn-group,.cf-toggle-switch .btn-toolbar .input-group{float:left}.image-thumb-lrg .button.button-primary.image-picker-button.cu-image-remover{width:45%}input.cu-image-picker-file-select[type=file]{display:none}.rangeslider,.rangeslider__fill{background:#e6e6e6;display:block;height:8px;width:100%;-webkit-border-radius:10px;-moz-border-radius:10px;-ms-border-radius:10px;-o-border-radius:10px;border-radius:10px}.rangeslider__handle,.toggle_option_row input{display:inline-block}.rangeslider{position:relative}.rangeslider--disabled{filter:alpha(Opacity=40);opacity:.4}.rangeslider__fill{background:#0f0;position:absolute;top:0}.rangeslider__handle{background:#fff;border:1px solid #ccc;cursor:pointer;width:18px;height:18px;position:absolute;top:-5px;-webkit-border-radius:50%;-moz-border-radius:50%;-ms-border-radius:50%;-o-border-radius:50%;border-radius:50%}input[type=range]:focus+.rangeslider .rangeslider__handle{-webkit-box-shadow:0 0 3px rgba(100,100,100,.9);-moz-box-shadow:0 0 3px rgba(100,100,100,.9);box-shadow:0 0 3px rgba(100,100,100,.9)}.recaptchatable #recaptcha_response_field{height:21px!important}.toggle_option_row{margin:4px 0}.toggle_option_row .dashicons-sort{cursor:move}.toggle_option_row .toggle_label_field,.toggle_option_row .toggle_value_field{width:136px;line-height:20px}.toggle_option_preview .button{border-radius:0;margin-right:-5px}.toggle_option_preview .button:first-child{border-radius:3px 0 0 3px}.toggle_option_preview .button:last-child{border-radius:0 3px 3px 0}.toggle_option_preview.toggle_vertical .button{width:100%}.toggle_option_preview.toggle_vertical .button:first-child{border-radius:3px 3px 0 0}.toggle_option_preview.toggle_vertical .button:last-child{border-radius:0 0 3px 3px}.cf-toggle-switch html{font-family:sans-serif}.cf-toggle-switch body{margin:0}.cf-toggle-switch article,.cf-toggle-switch aside,.cf-toggle-switch details,.cf-toggle-switch figcaption,.cf-toggle-switch figure,.cf-toggle-switch footer,.cf-toggle-switch header,.cf-toggle-switch hgroup,.cf-toggle-switch main,.cf-toggle-switch nav,.cf-toggle-switch section,.cf-toggle-switch summary{display:block}.cf-toggle-switch audio,.cf-toggle-switch canvas,.cf-toggle-switch progress,.cf-toggle-switch video{display:inline-block;vertical-align:baseline}.cf-toggle-switch audio:not([controls]){display:none;height:0}.cf-toggle-switch [hidden],.cf-toggle-switch template{display:none}.cf-toggle-switch a{background:0 0}.cf-toggle-switch a:active,.cf-toggle-switch a:hover{outline:0}.cf-toggle-switch abbr[title]{border-bottom:1px dotted}.cf-toggle-switch b,.cf-toggle-switch strong{font-weight:700}.cf-toggle-switch dfn{font-style:italic}.cf-toggle-switch h1{font-size:2em;margin:.67em 0}.cf-toggle-switch mark{background:#ff0;color:#000}.cf-toggle-switch .btn,.cf-toggle-switch .btn-danger.active,.cf-toggle-switch .btn-danger:active,.cf-toggle-switch .btn-default.active,.cf-toggle-switch .btn-default:active,.cf-toggle-switch .btn-info.active,.cf-toggle-switch .btn-info:active,.cf-toggle-switch .btn-primary.active,.cf-toggle-switch .btn-primary:active,.cf-toggle-switch .btn-success.active,.cf-toggle-switch .btn-success:active,.cf-toggle-switch .btn-warning.active,.cf-toggle-switch .btn-warning:active,.cf-toggle-switch .open .dropdown-toggle.btn-danger,.cf-toggle-switch .open .dropdown-toggle.btn-default,.cf-toggle-switch .open .dropdown-toggle.btn-info,.cf-toggle-switch .open .dropdown-toggle.btn-primary,.cf-toggle-switch .open .dropdown-toggle.btn-success,.cf-toggle-switch .open .dropdown-toggle.btn-warning{background-image:none}.cf-toggle-switch small{font-size:80%}.cf-toggle-switch sub,.cf-toggle-switch sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}.cf-toggle-switch sup{top:-.5em}.cf-toggle-switch sub{bottom:-.25em}.cf-toggle-switch img{border:0}.cf-toggle-switch figure{margin:1em 40px}.cf-toggle-switch hr{-moz-box-sizing:content-box;box-sizing:content-box;height:0}.cf-toggle-switch pre{overflow:auto}.cf-toggle-switch code,.cf-toggle-switch kbd,.cf-toggle-switch pre,.cf-toggle-switch samp{font-family:monospace,monospace;font-size:1em}.cf-toggle-switch button,.cf-toggle-switch input,.cf-toggle-switch optgroup,.cf-toggle-switch select,.cf-toggle-switch textarea{color:inherit;font:inherit;margin:0}.cf-toggle-switch button{overflow:visible}.cf-toggle-switch button,.cf-toggle-switch html input[type=button],.cf-toggle-switch input[type=reset],.cf-toggle-switch input[type=submit]{-webkit-appearance:button;cursor:pointer}.cf-toggle-switch button[disabled],.cf-toggle-switch html input[disabled]{cursor:default}.cf-toggle-switch button::-moz-focus-inner,.cf-toggle-switch input::-moz-focus-inner{border:0;padding:0}.cf-toggle-switch input{line-height:normal}.cf-toggle-switch input[type=checkbox],.cf-toggle-switch input[type=radio]{box-sizing:border-box;padding:0}.cf-toggle-switch input[type=number]::-webkit-inner-spin-button,.cf-toggle-switch input[type=number]::-webkit-outer-spin-button{height:auto}.cf-toggle-switch input[type=search]{-webkit-appearance:textfield;-moz-box-sizing:content-box;-webkit-box-sizing:content-box;box-sizing:content-box}.cf-toggle-switch input[type=search]::-webkit-search-cancel-button,.cf-toggle-switch input[type=search]::-webkit-search-decoration{-webkit-appearance:none}.cf-toggle-switch fieldset{border:1px solid silver;margin:0 2px;padding:.35em .625em .75em}.cf-toggle-switch legend{border:0;padding:0}.cf-toggle-switch textarea{overflow:auto}.cf-toggle-switch optgroup{font-weight:700}.cf-toggle-switch table{border-collapse:collapse;border-spacing:0}.cf-toggle-switch td,.cf-toggle-switch th{padding:0}.cf-toggle-switch .btn{display:inline-block;margin-bottom:0;font-weight:400;text-align:center;vertical-align:middle;cursor:pointer;border:1px solid transparent;white-space:nowrap;padding:6px 12px;font-size:14px;line-height:1.42857143;border-radius:4px;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}.cf-toggle-switch .btn.active:focus,.cf-toggle-switch .btn:active:focus,.cf-toggle-switch .btn:focus{outline:dotted thin;outline:-webkit-focus-ring-color auto 5px;outline-offset:-2px}.cf-toggle-switch .btn-group .dropdown-toggle:active,.cf-toggle-switch .btn-group-vertical>.btn:focus,.cf-toggle-switch .btn-group.open .dropdown-toggle,.cf-toggle-switch .btn-group>.btn:focus{outline:0}.cf-toggle-switch .btn:focus,.cf-toggle-switch .btn:hover{color:#333;text-decoration:none}.cf-toggle-switch .btn.active,.cf-toggle-switch .btn:active{outline:0;background-image:none;-webkit-box-shadow:inset 0 3px 5px rgba(0,0,0,.125);box-shadow:inset 0 3px 5px rgba(0,0,0,.125)}.cf-toggle-switch .btn.disabled,.cf-toggle-switch .btn[disabled],.cf-toggle-switch fieldset[disabled] .btn{cursor:not-allowed;pointer-events:none;opacity:.65;filter:alpha(opacity=65);-webkit-box-shadow:none;box-shadow:none}.cf-toggle-switch .btn-default{color:#333;background-color:#fff;border-color:#ccc}.cf-toggle-switch .btn-default.active,.cf-toggle-switch .btn-default:active,.cf-toggle-switch .btn-default:focus,.cf-toggle-switch .btn-default:hover,.cf-toggle-switch .open .dropdown-toggle.btn-default{color:#333;background-color:#ebebeb;border-color:#adadad}.cf-toggle-switch .btn-default.disabled,.cf-toggle-switch .btn-default.disabled.active,.cf-toggle-switch .btn-default.disabled:active,.cf-toggle-switch .btn-default.disabled:focus,.cf-toggle-switch .btn-default.disabled:hover,.cf-toggle-switch .btn-default[disabled],.cf-toggle-switch .btn-default[disabled].active,.cf-toggle-switch .btn-default[disabled]:active,.cf-toggle-switch .btn-default[disabled]:focus,.cf-toggle-switch .btn-default[disabled]:hover,.cf-toggle-switch fieldset[disabled] .btn-default,.cf-toggle-switch fieldset[disabled] .btn-default.active,.cf-toggle-switch fieldset[disabled] .btn-default:active,.cf-toggle-switch fieldset[disabled] .btn-default:focus,.cf-toggle-switch fieldset[disabled] .btn-default:hover{background-color:#fff;border-color:#ccc}.cf-toggle-switch .btn-default .badge{color:#fff;background-color:#333}.cf-toggle-switch .btn-primary{color:#fff;background-color:#428bca;border-color:#357ebd}.cf-toggle-switch .btn-primary.active,.cf-toggle-switch .btn-primary:active,.cf-toggle-switch .btn-primary:focus,.cf-toggle-switch .btn-primary:hover,.cf-toggle-switch .open .dropdown-toggle.btn-primary{color:#fff;background-color:#3276b1;border-color:#285e8e}.cf-toggle-switch .btn-primary.disabled,.cf-toggle-switch .btn-primary.disabled.active,.cf-toggle-switch .btn-primary.disabled:active,.cf-toggle-switch .btn-primary.disabled:focus,.cf-toggle-switch .btn-primary.disabled:hover,.cf-toggle-switch .btn-primary[disabled],.cf-toggle-switch .btn-primary[disabled].active,.cf-toggle-switch .btn-primary[disabled]:active,.cf-toggle-switch .btn-primary[disabled]:focus,.cf-toggle-switch .btn-primary[disabled]:hover,.cf-toggle-switch fieldset[disabled] .btn-primary,.cf-toggle-switch fieldset[disabled] .btn-primary.active,.cf-toggle-switch fieldset[disabled] .btn-primary:active,.cf-toggle-switch fieldset[disabled] .btn-primary:focus,.cf-toggle-switch fieldset[disabled] .btn-primary:hover{background-color:#428bca;border-color:#357ebd}.cf-toggle-switch .btn-primary .badge{color:#428bca;background-color:#fff}.cf-toggle-switch .btn-success{color:#fff;background-color:#5cb85c;border-color:#4cae4c}.cf-toggle-switch .btn-success.active,.cf-toggle-switch .btn-success:active,.cf-toggle-switch .btn-success:focus,.cf-toggle-switch .btn-success:hover,.cf-toggle-switch .open .dropdown-toggle.btn-success{color:#fff;background-color:#47a447;border-color:#398439}.cf-toggle-switch .btn-success.disabled,.cf-toggle-switch .btn-success.disabled.active,.cf-toggle-switch .btn-success.disabled:active,.cf-toggle-switch .btn-success.disabled:focus,.cf-toggle-switch .btn-success.disabled:hover,.cf-toggle-switch .btn-success[disabled],.cf-toggle-switch .btn-success[disabled].active,.cf-toggle-switch .btn-success[disabled]:active,.cf-toggle-switch .btn-success[disabled]:focus,.cf-toggle-switch .btn-success[disabled]:hover,.cf-toggle-switch fieldset[disabled] .btn-success,.cf-toggle-switch fieldset[disabled] .btn-success.active,.cf-toggle-switch fieldset[disabled] .btn-success:active,.cf-toggle-switch fieldset[disabled] .btn-success:focus,.cf-toggle-switch fieldset[disabled] .btn-success:hover{background-color:#5cb85c;border-color:#4cae4c}.cf-toggle-switch .btn-success .badge{color:#5cb85c;background-color:#fff}.cf-toggle-switch .btn-info{color:#fff;background-color:#5bc0de;border-color:#46b8da}.cf-toggle-switch .btn-info.active,.cf-toggle-switch .btn-info:active,.cf-toggle-switch .btn-info:focus,.cf-toggle-switch .btn-info:hover,.cf-toggle-switch .open .dropdown-toggle.btn-info{color:#fff;background-color:#39b3d7;border-color:#269abc}.cf-toggle-switch .btn-info.disabled,.cf-toggle-switch .btn-info.disabled.active,.cf-toggle-switch .btn-info.disabled:active,.cf-toggle-switch .btn-info.disabled:focus,.cf-toggle-switch .btn-info.disabled:hover,.cf-toggle-switch .btn-info[disabled],.cf-toggle-switch .btn-info[disabled].active,.cf-toggle-switch .btn-info[disabled]:active,.cf-toggle-switch .btn-info[disabled]:focus,.cf-toggle-switch .btn-info[disabled]:hover,.cf-toggle-switch fieldset[disabled] .btn-info,.cf-toggle-switch fieldset[disabled] .btn-info.active,.cf-toggle-switch fieldset[disabled] .btn-info:active,.cf-toggle-switch fieldset[disabled] .btn-info:focus,.cf-toggle-switch fieldset[disabled] .btn-info:hover{background-color:#5bc0de;border-color:#46b8da}.cf-toggle-switch .btn-info .badge{color:#5bc0de;background-color:#fff}.cf-toggle-switch .btn-warning{color:#fff;background-color:#f0ad4e;border-color:#eea236}.cf-toggle-switch .btn-warning.active,.cf-toggle-switch .btn-warning:active,.cf-toggle-switch .btn-warning:focus,.cf-toggle-switch .btn-warning:hover,.cf-toggle-switch .open .dropdown-toggle.btn-warning{color:#fff;background-color:#ed9c28;border-color:#d58512}.cf-toggle-switch .btn-warning.disabled,.cf-toggle-switch .btn-warning.disabled.active,.cf-toggle-switch .btn-warning.disabled:active,.cf-toggle-switch .btn-warning.disabled:focus,.cf-toggle-switch .btn-warning.disabled:hover,.cf-toggle-switch .btn-warning[disabled],.cf-toggle-switch .btn-warning[disabled].active,.cf-toggle-switch .btn-warning[disabled]:active,.cf-toggle-switch .btn-warning[disabled]:focus,.cf-toggle-switch .btn-warning[disabled]:hover,.cf-toggle-switch fieldset[disabled] .btn-warning,.cf-toggle-switch fieldset[disabled] .btn-warning.active,.cf-toggle-switch fieldset[disabled] .btn-warning:active,.cf-toggle-switch fieldset[disabled] .btn-warning:focus,.cf-toggle-switch fieldset[disabled] .btn-warning:hover{background-color:#f0ad4e;border-color:#eea236}.cf-toggle-switch .btn-warning .badge{color:#f0ad4e;background-color:#fff}.cf-toggle-switch .btn-danger{color:#fff;background-color:#d9534f;border-color:#d43f3a}.cf-toggle-switch .btn-danger.active,.cf-toggle-switch .btn-danger:active,.cf-toggle-switch .btn-danger:focus,.cf-toggle-switch .btn-danger:hover,.cf-toggle-switch .open .dropdown-toggle.btn-danger{color:#fff;background-color:#d2322d;border-color:#ac2925}.cf-toggle-switch .btn-danger.disabled,.cf-toggle-switch .btn-danger.disabled.active,.cf-toggle-switch .btn-danger.disabled:active,.cf-toggle-switch .btn-danger.disabled:focus,.cf-toggle-switch .btn-danger.disabled:hover,.cf-toggle-switch .btn-danger[disabled],.cf-toggle-switch .btn-danger[disabled].active,.cf-toggle-switch .btn-danger[disabled]:active,.cf-toggle-switch .btn-danger[disabled]:focus,.cf-toggle-switch .btn-danger[disabled]:hover,.cf-toggle-switch fieldset[disabled] .btn-danger,.cf-toggle-switch fieldset[disabled] .btn-danger.active,.cf-toggle-switch fieldset[disabled] .btn-danger:active,.cf-toggle-switch fieldset[disabled] .btn-danger:focus,.cf-toggle-switch fieldset[disabled] .btn-danger:hover{background-color:#d9534f;border-color:#d43f3a}.cf-toggle-switch .btn-danger .badge{color:#d9534f;background-color:#fff}.cf-toggle-switch .btn-link{color:#428bca;font-weight:400;cursor:pointer;border-radius:0}.cf-toggle-switch .btn-link,.cf-toggle-switch .btn-link:active,.cf-toggle-switch .btn-link[disabled],.cf-toggle-switch fieldset[disabled] .btn-link{background-color:transparent;-webkit-box-shadow:none;box-shadow:none}.cf-toggle-switch .btn-link,.cf-toggle-switch .btn-link:active,.cf-toggle-switch .btn-link:focus,.cf-toggle-switch .btn-link:hover{border-color:transparent}.cf-toggle-switch .btn-link:focus,.cf-toggle-switch .btn-link:hover{color:#2a6496;text-decoration:underline;background-color:transparent}.cf-toggle-switch .btn-link[disabled]:focus,.cf-toggle-switch .btn-link[disabled]:hover,.cf-toggle-switch fieldset[disabled] .btn-link:focus,.cf-toggle-switch fieldset[disabled] .btn-link:hover{color:#999;text-decoration:none}.cf-toggle-switch .btn-group-lg>.btn,.cf-toggle-switch .btn-lg{padding:10px 16px;font-size:18px;line-height:1.33;border-radius:6px}.cf-toggle-switch .btn-group-sm>.btn,.cf-toggle-switch .btn-sm{padding:5px 10px;font-size:12px;line-height:1.5;border-radius:3px}.cf-toggle-switch .btn-group-xs>.btn,.cf-toggle-switch .btn-xs{padding:1px 5px;font-size:12px;line-height:1.5;border-radius:3px}.cf-toggle-switch .btn-group-vertical>.btn:not(:first-child):not(:last-child),.cf-toggle-switch .btn-group>.btn-group:not(:first-child):not(:last-child)>.btn,.cf-toggle-switch .btn-group>.btn:not(:first-child):not(:last-child):not(.dropdown-toggle){border-radius:0}.cf-toggle-switch .btn-block{display:block;width:100%;padding-left:0;padding-right:0}.cf-toggle-switch .btn-block+.btn-block{margin-top:5px}.cf-toggle-switch input[type=button].btn-block,.cf-toggle-switch input[type=reset].btn-block,.cf-toggle-switch input[type=submit].btn-block{width:100%}.cf-toggle-switch .btn-group,.cf-toggle-switch .btn-group-vertical{position:relative;display:inline-block;vertical-align:middle}.cf-toggle-switch .btn-group-vertical>.btn,.cf-toggle-switch .btn-group>.btn{position:relative;float:left}.cf-toggle-switch .btn-group-vertical>.btn.active,.cf-toggle-switch .btn-group-vertical>.btn:active,.cf-toggle-switch .btn-group-vertical>.btn:focus,.cf-toggle-switch .btn-group-vertical>.btn:hover,.cf-toggle-switch .btn-group>.btn.active,.cf-toggle-switch .btn-group>.btn:active,.cf-toggle-switch .btn-group>.btn:focus,.cf-toggle-switch .btn-group>.btn:hover{z-index:2}.cf-toggle-switch .btn-group .btn+.btn,.cf-toggle-switch .btn-group .btn+.btn-group,.cf-toggle-switch .btn-group .btn-group+.btn,.cf-toggle-switch .btn-group .btn-group+.btn-group{margin-left:-1px}.cf-toggle-switch .btn-toolbar{margin-left:-5px}.cf-toggle-switch .btn-toolbar>.btn,.cf-toggle-switch .btn-toolbar>.btn-group,.cf-toggle-switch .btn-toolbar>.input-group{margin-left:5px}.cf-toggle-switch .btn .caret,.cf-toggle-switch .btn-group>.btn:first-child{margin-left:0}.cf-toggle-switch .btn-group>.btn:first-child:not(:last-child):not(.dropdown-toggle){border-bottom-right-radius:0;border-top-right-radius:0}.cf-toggle-switch .btn-group>.btn:last-child:not(:first-child),.cf-toggle-switch .btn-group>.dropdown-toggle:not(:first-child){border-bottom-left-radius:0;border-top-left-radius:0}.cf-toggle-switch .btn-group>.btn-group:first-child>.btn:last-child,.cf-toggle-switch .btn-group>.btn-group:first-child>.dropdown-toggle{border-bottom-right-radius:0;border-top-right-radius:0}.cf-toggle-switch .btn-group>.btn-group:last-child>.btn:first-child{border-bottom-left-radius:0;border-top-left-radius:0}.cf-toggle-switch .btn-group>.btn+.dropdown-toggle{padding-left:8px;padding-right:8px}.cf-toggle-switch .btn-group>.btn-lg+.dropdown-toggle{padding-left:12px;padding-right:12px}.cf-toggle-switch .btn-group.open .dropdown-toggle{-webkit-box-shadow:inset 0 3px 5px rgba(0,0,0,.125);box-shadow:inset 0 3px 5px rgba(0,0,0,.125)}.cf-toggle-switch .btn-group.open .dropdown-toggle.btn-link{-webkit-box-shadow:none;box-shadow:none}.cf-toggle-switch .btn-lg .caret{border-width:5px 5px 0}.cf-toggle-switch .dropup .btn-lg .caret{border-width:0 5px 5px}.cf-toggle-switch .btn-group-vertical>.btn,.cf-toggle-switch .btn-group-vertical>.btn-group,.cf-toggle-switch .btn-group-vertical>.btn-group>.btn{display:block;float:none;width:100%;max-width:100%}.cf-toggle-switch .btn-group-vertical>.btn-group>.btn{float:none}.cf-toggle-switch .btn-group-vertical>.btn+.btn,.cf-toggle-switch .btn-group-vertical>.btn+.btn-group,.cf-toggle-switch .btn-group-vertical>.btn-group+.btn,.cf-toggle-switch .btn-group-vertical>.btn-group+.btn-group{margin-top:-1px;margin-left:0}.cf-toggle-switch .btn-group-vertical>.btn:first-child:not(:last-child){border-top-right-radius:4px;border-bottom-right-radius:0;border-bottom-left-radius:0}.cf-toggle-switch .btn-group-vertical>.btn:last-child:not(:first-child){border-bottom-left-radius:4px;border-top-right-radius:0;border-top-left-radius:0}.cf-toggle-switch .btn-group-vertical>.btn-group:not(:first-child):not(:last-child)>.btn{border-radius:0}.cf-toggle-switch .btn-group-vertical>.btn-group:first-child:not(:last-child)>.btn:last-child,.cf-toggle-switch .btn-group-vertical>.btn-group:first-child:not(:last-child)>.dropdown-toggle{border-bottom-right-radius:0;border-bottom-left-radius:0}.cf-toggle-switch .btn-group-vertical>.btn-group:last-child:not(:first-child)>.btn:first-child{border-top-right-radius:0;border-top-left-radius:0}.cf-toggle-switch .btn-group-justified{display:table;width:100%;table-layout:fixed;border-collapse:separate}.cf-toggle-switch .btn-group-justified>.btn,.cf-toggle-switch .btn-group-justified>.btn-group{float:none;display:table-cell;width:1%}.cf-toggle-switch .btn-group-justified>.btn-group .btn{width:100%}.cf-toggle-switch [data-toggle=buttons]>.btn>input[type=checkbox],.cf-toggle-switch [data-toggle=buttons]>.btn>input[type=radio]{display:none}.cf-toggle-switch .btn-group-vertical>.btn-group:after,.cf-toggle-switch .btn-group-vertical>.btn-group:before,.cf-toggle-switch .btn-toolbar:after,.cf-toggle-switch .btn-toolbar:before,.cf-toggle-switch .clearfix:after,.cf-toggle-switch .clearfix:before{content:" ";display:table}.cf-toggle-switch .btn-group-vertical>.btn-group:after,.cf-toggle-switch .btn-toolbar:after,.cf-toggle-switch .clearfix:after{clear:both}.cf-toggle-switch .center-block{display:block;margin-left:auto;margin-right:auto}.cf-toggle-switch .pull-right{float:right!important}.cf-toggle-switch .pull-left{float:left!important}.cf-toggle-switch .hide{display:none!important}.cf-toggle-switch .show{display:block!important}.cf-toggle-switch .invisible{visibility:hidden}.cf-toggle-switch .text-hide{font:0/0 a;color:transparent;text-shadow:none;background-color:transparent;border:0}.cf-toggle-switch .hidden{display:none!important;visibility:hidden!important}.cf-toggle-switch .affix{position:fixed}@-ms-viewport{width:device-width}.cf-toggle-switch .visible-lg,.cf-toggle-switch .visible-md,.cf-toggle-switch .visible-print,.cf-toggle-switch .visible-sm,.cf-toggle-switch .visible-xs{display:none!important}@media (max-width:767px){.cf-toggle-switch .visible-xs{display:block!important}.cf-toggle-switch table.visible-xs{display:table}.cf-toggle-switch tr.visible-xs{display:table-row!important}.cf-toggle-switch td.visible-xs,.cf-toggle-switch th.visible-xs{display:table-cell!important}}@media (min-width:768px) and (max-width:991px){.cf-toggle-switch .visible-sm{display:block!important}.cf-toggle-switch table.visible-sm{display:table}.cf-toggle-switch tr.visible-sm{display:table-row!important}.cf-toggle-switch td.visible-sm,.cf-toggle-switch th.visible-sm{display:table-cell!important}}@media (min-width:992px) and (max-width:1199px){.cf-toggle-switch .visible-md{display:block!important}.cf-toggle-switch table.visible-md{display:table}.cf-toggle-switch tr.visible-md{display:table-row!important}.cf-toggle-switch td.visible-md,.cf-toggle-switch th.visible-md{display:table-cell!important}}@media (min-width:1200px){.cf-toggle-switch .visible-lg{display:block!important}.cf-toggle-switch table.visible-lg{display:table}.cf-toggle-switch tr.visible-lg{display:table-row!important}.cf-toggle-switch td.visible-lg,.cf-toggle-switch th.visible-lg{display:table-cell!important}.cf-toggle-switch .hidden-lg{display:none!important}}@media (max-width:767px){.cf-toggle-switch .hidden-xs{display:none!important}}@media (min-width:768px) and (max-width:991px){.cf-toggle-switch .hidden-sm{display:none!important}}@media (min-width:992px) and (max-width:1199px){.cf-toggle-switch .hidden-md{display:none!important}}@media print{.cf-toggle-switch .visible-print{display:block!important}.cf-toggle-switch table.visible-print{display:table}.cf-toggle-switch tr.visible-print{display:table-row!important}.cf-toggle-switch td.visible-print,.cf-toggle-switch th.visible-print{display:table-cell!important}.cf-toggle-switch .hidden-print{display:none!important}}.cf-toggle-group-buttons{width:100%;clear:both}input.form-control.parsley-success,select.form-control.parsley-success,textarea.form-control.parsley-success{color:#468847;background-color:#DFF0D8;border-color:#D6E9C6}input.form-control.parsley-error,select.form-control.parsley-error,textarea.form-control.parsley-error{color:#B94A48;background-color:#F2DEDE;border-color:#EED3D7}.form-control.parsley-errors-list{margin:2px 0 3px;padding:0;list-style-type:none;font-size:.9em;line-height:.9em;opacity:0;color:#468847;transition:all .3s ease-in;-o-transition:all .3s ease-in;-moz-transition:all .3s ease-in;-webkit-transition:all .3s ease-in}.form-control.parsley-errors-list.filled{opacity:1}.breadcrumb a.has-error{color:red}.form-group .parsley-errors-list.filled,.form-group .parsley-errors-list.filled .parsley-type{list-style:none}.caldera-grid .cf-multi-uploader-list>ul{list-style:none;margin:0 0 12px;padding:0}.caldera-grid .cf-multi-uploader-list>ul>li{margin:0;padding:0 0 22px;position:relative;clear:both}.caldera-grid .cf-multi-uploader-list>ul>li .file-name{display:inline-block;font-weight:700;left:16px;right:0;overflow:hidden;position:absolute;text-overflow:ellipsis;white-space:nowrap}.caldera-grid .cf-multi-uploader-list>ul>li .file-name.file-uploaded{left:0}.caldera-grid .cf-multi-uploader-list>ul>li .file-size{float:right}.caldera-grid .cf-multi-uploader-list>ul>li .file-type{float:left}.caldera-grid .cf-multi-uploader-list>ul>li .file-error{clear:both;display:block}.caldera-grid .cf-multi-uploader-list>ul>li .cf-file-remove{color:#cf0000;text-decoration:none;border:0}.caldera-grid .cf-multi-uploader-list>ul>li.has-error .bar{background-color:#cf0000!important}.caldera-grid .cf-multi-uploader-list>ul>li.has-error{color:#cf0000}.has-error.cf-toggle-switch .cf-toggle-group-buttons>a{background-color:#f2dede;border-color:#dd4b39}
1
+ /*! GENERATED SOURCE FILE caldera-forms - v1.5.0.7 - 2017-04-04 */.caldera-grid html,.cf-toggle-switch html{-ms-text-size-adjust:100%;-webkit-text-size-adjust:100%}.caldera-grid .sr-only,.caldera-grid svg:not(:root),.cf-toggle-switch svg:not(:root){overflow:hidden}.caldera-grid .btn,.cfdatepicker table{-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none}.caldera-grid button,.caldera-grid select,.cf-toggle-switch button,.cf-toggle-switch select{text-transform:none}@media (min-width:768px){.caldera-grid .container{width:750px}}@media (min-width:992px){.caldera-grid .container{width:970px}}@media (min-width:1200px){.caldera-grid .container{width:1170px}}.caldera-grid article,.caldera-grid aside,.caldera-grid details,.caldera-grid figcaption,.caldera-grid figure,.caldera-grid footer,.caldera-grid header,.caldera-grid hgroup,.caldera-grid main,.caldera-grid nav,.caldera-grid section,.caldera-grid summary{display:block}.caldera-grid a{background:0 0;text-decoration:none}.caldera-grid img{vertical-align:middle}.caldera-grid *,.caldera-grid :after,.caldera-grid :before{-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box}.caldera-grid html{font-size:62.5%;-webkit-tap-highlight-color:transparent}.caldera-grid body{font-family:"Helvetica Neue",Helvetica,Arial,sans-serif;font-size:14px;line-height:1.42857143;color:#333;background-color:#fff}.caldera-grid button,.caldera-grid input,.caldera-grid select,.caldera-grid textarea{font-family:inherit;font-size:inherit;line-height:inherit}.caldera-grid a:focus,.caldera-grid a:hover{color:#2a6496;text-decoration:underline}.caldera-grid a:focus{outline:dotted thin;outline:-webkit-focus-ring-color auto 5px;outline-offset:-2px}.caldera-grid .img-responsive{display:block;max-width:100%;height:auto}.caldera-grid .img-rounded{border-radius:6px}.caldera-grid .img-thumbnail{padding:4px;line-height:1.42857143;background-color:#fff;border:1px solid #ddd;border-radius:4px;-webkit-transition:all .2s ease-in-out;transition:all .2s ease-in-out;display:inline-block;max-width:100%;height:auto}.caldera-grid .img-circle{border-radius:50%}.caldera-grid hr{margin-top:20px;margin-bottom:20px;border:0;border-top:1px solid #eee}.caldera-grid .sr-only{position:absolute;width:1px;height:1px;margin:-1px;padding:0;clip:rect(0,0,0,0);border:0}.caldera-grid .container,.caldera-grid .container-fluid{margin-right:auto;margin-left:auto;padding-left:7.5px;padding-right:7.5px}@media (min-width:768px){.caldera-grid .container{width:735px}}@media (min-width:992px){.caldera-grid .container{width:955px}}@media (min-width:1200px){.caldera-grid .container{width:1155px}}.caldera-grid .row{margin-left:-7.5px;margin-right:-7.5px}.caldera-grid .col-lg-1,.caldera-grid .col-lg-10,.caldera-grid .col-lg-11,.caldera-grid .col-lg-12,.caldera-grid .col-lg-2,.caldera-grid .col-lg-3,.caldera-grid .col-lg-4,.caldera-grid .col-lg-5,.caldera-grid .col-lg-6,.caldera-grid .col-lg-7,.caldera-grid .col-lg-8,.caldera-grid .col-lg-9,.caldera-grid .col-md-1,.caldera-grid .col-md-10,.caldera-grid .col-md-11,.caldera-grid .col-md-12,.caldera-grid .col-md-2,.caldera-grid .col-md-3,.caldera-grid .col-md-4,.caldera-grid .col-md-5,.caldera-grid .col-md-6,.caldera-grid .col-md-7,.caldera-grid .col-md-8,.caldera-grid .col-md-9,.caldera-grid .col-sm-1,.caldera-grid .col-sm-10,.caldera-grid .col-sm-11,.caldera-grid .col-sm-12,.caldera-grid .col-sm-2,.caldera-grid .col-sm-3,.caldera-grid .col-sm-4,.caldera-grid .col-sm-5,.caldera-grid .col-sm-6,.caldera-grid .col-sm-7,.caldera-grid .col-sm-8,.caldera-grid .col-sm-9,.caldera-grid .col-xs-1,.caldera-grid .col-xs-10,.caldera-grid .col-xs-11,.caldera-grid .col-xs-12,.caldera-grid .col-xs-2,.caldera-grid .col-xs-3,.caldera-grid .col-xs-4,.caldera-grid .col-xs-5,.caldera-grid .col-xs-6,.caldera-grid .col-xs-7,.caldera-grid .col-xs-8,.caldera-grid .col-xs-9{position:relative;padding-left:7.5px;padding-right:7.5px}.caldera-grid .col-xs-1,.caldera-grid .col-xs-10,.caldera-grid .col-xs-11,.caldera-grid .col-xs-12,.caldera-grid .col-xs-2,.caldera-grid .col-xs-3,.caldera-grid .col-xs-4,.caldera-grid .col-xs-5,.caldera-grid .col-xs-6,.caldera-grid .col-xs-7,.caldera-grid .col-xs-8,.caldera-grid .col-xs-9{float:left}.caldera-grid .col-xs-12{width:100%}.caldera-grid .col-xs-11{width:91.66666667%}.caldera-grid .col-xs-10{width:83.33333333%}.caldera-grid .col-xs-9{width:75%}.caldera-grid .col-xs-8{width:66.66666667%}.caldera-grid .col-xs-7{width:58.33333333%}.caldera-grid .col-xs-6{width:50%}.caldera-grid .col-xs-5{width:41.66666667%}.caldera-grid .col-xs-4{width:33.33333333%}.caldera-grid .col-xs-3{width:25%}.caldera-grid .col-xs-2{width:16.66666667%}.caldera-grid .col-xs-1{width:8.33333333%}.caldera-grid .col-xs-pull-12{right:100%}.caldera-grid .col-xs-pull-11{right:91.66666667%}.caldera-grid .col-xs-pull-10{right:83.33333333%}.caldera-grid .col-xs-pull-9{right:75%}.caldera-grid .col-xs-pull-8{right:66.66666667%}.caldera-grid .col-xs-pull-7{right:58.33333333%}.caldera-grid .col-xs-pull-6{right:50%}.caldera-grid .col-xs-pull-5{right:41.66666667%}.caldera-grid .col-xs-pull-4{right:33.33333333%}.caldera-grid .col-xs-pull-3{right:25%}.caldera-grid .col-xs-pull-2{right:16.66666667%}.caldera-grid .col-xs-pull-1{right:8.33333333%}.caldera-grid .col-xs-pull-0{right:0}.caldera-grid .col-xs-push-12{left:100%}.caldera-grid .col-xs-push-11{left:91.66666667%}.caldera-grid .col-xs-push-10{left:83.33333333%}.caldera-grid .col-xs-push-9{left:75%}.caldera-grid .col-xs-push-8{left:66.66666667%}.caldera-grid .col-xs-push-7{left:58.33333333%}.caldera-grid .col-xs-push-6{left:50%}.caldera-grid .col-xs-push-5{left:41.66666667%}.caldera-grid .col-xs-push-4{left:33.33333333%}.caldera-grid .col-xs-push-3{left:25%}.caldera-grid .col-xs-push-2{left:16.66666667%}.caldera-grid .col-xs-push-1{left:8.33333333%}.caldera-grid .col-xs-push-0{left:0}.caldera-grid .col-xs-offset-12{margin-left:100%}.caldera-grid .col-xs-offset-11{margin-left:91.66666667%}.caldera-grid .col-xs-offset-10{margin-left:83.33333333%}.caldera-grid .col-xs-offset-9{margin-left:75%}.caldera-grid .col-xs-offset-8{margin-left:66.66666667%}.caldera-grid .col-xs-offset-7{margin-left:58.33333333%}.caldera-grid .col-xs-offset-6{margin-left:50%}.caldera-grid .col-xs-offset-5{margin-left:41.66666667%}.caldera-grid .col-xs-offset-4{margin-left:33.33333333%}.caldera-grid .col-xs-offset-3{margin-left:25%}.caldera-grid .col-xs-offset-2{margin-left:16.66666667%}.caldera-grid .col-xs-offset-1{margin-left:8.33333333%}.caldera-grid .col-xs-offset-0{margin-left:0}@media (min-width:768px){.caldera-grid .col-sm-1,.caldera-grid .col-sm-10,.caldera-grid .col-sm-11,.caldera-grid .col-sm-12,.caldera-grid .col-sm-2,.caldera-grid .col-sm-3,.caldera-grid .col-sm-4,.caldera-grid .col-sm-5,.caldera-grid .col-sm-6,.caldera-grid .col-sm-7,.caldera-grid .col-sm-8,.caldera-grid .col-sm-9{float:left}.caldera-grid .col-sm-12{width:100%}.caldera-grid .col-sm-11{width:91.66666667%}.caldera-grid .col-sm-10{width:83.33333333%}.caldera-grid .col-sm-9{width:75%}.caldera-grid .col-sm-8{width:66.66666667%}.caldera-grid .col-sm-7{width:58.33333333%}.caldera-grid .col-sm-6{width:50%}.caldera-grid .col-sm-5{width:41.66666667%}.caldera-grid .col-sm-4{width:33.33333333%}.caldera-grid .col-sm-3{width:25%}.caldera-grid .col-sm-2{width:16.66666667%}.caldera-grid .col-sm-1{width:8.33333333%}.caldera-grid .col-sm-pull-12{right:100%}.caldera-grid .col-sm-pull-11{right:91.66666667%}.caldera-grid .col-sm-pull-10{right:83.33333333%}.caldera-grid .col-sm-pull-9{right:75%}.caldera-grid .col-sm-pull-8{right:66.66666667%}.caldera-grid .col-sm-pull-7{right:58.33333333%}.caldera-grid .col-sm-pull-6{right:50%}.caldera-grid .col-sm-pull-5{right:41.66666667%}.caldera-grid .col-sm-pull-4{right:33.33333333%}.caldera-grid .col-sm-pull-3{right:25%}.caldera-grid .col-sm-pull-2{right:16.66666667%}.caldera-grid .col-sm-pull-1{right:8.33333333%}.caldera-grid .col-sm-pull-0{right:0}.caldera-grid .col-sm-push-12{left:100%}.caldera-grid .col-sm-push-11{left:91.66666667%}.caldera-grid .col-sm-push-10{left:83.33333333%}.caldera-grid .col-sm-push-9{left:75%}.caldera-grid .col-sm-push-8{left:66.66666667%}.caldera-grid .col-sm-push-7{left:58.33333333%}.caldera-grid .col-sm-push-6{left:50%}.caldera-grid .col-sm-push-5{left:41.66666667%}.caldera-grid .col-sm-push-4{left:33.33333333%}.caldera-grid .col-sm-push-3{left:25%}.caldera-grid .col-sm-push-2{left:16.66666667%}.caldera-grid .col-sm-push-1{left:8.33333333%}.caldera-grid .col-sm-push-0{left:0}.caldera-grid .col-sm-offset-12{margin-left:100%}.caldera-grid .col-sm-offset-11{margin-left:91.66666667%}.caldera-grid .col-sm-offset-10{margin-left:83.33333333%}.caldera-grid .col-sm-offset-9{margin-left:75%}.caldera-grid .col-sm-offset-8{margin-left:66.66666667%}.caldera-grid .col-sm-offset-7{margin-left:58.33333333%}.caldera-grid .col-sm-offset-6{margin-left:50%}.caldera-grid .col-sm-offset-5{margin-left:41.66666667%}.caldera-grid .col-sm-offset-4{margin-left:33.33333333%}.caldera-grid .col-sm-offset-3{margin-left:25%}.caldera-grid .col-sm-offset-2{margin-left:16.66666667%}.caldera-grid .col-sm-offset-1{margin-left:8.33333333%}.caldera-grid .col-sm-offset-0{margin-left:0}}@media (min-width:992px){.caldera-grid .col-md-1,.caldera-grid .col-md-10,.caldera-grid .col-md-11,.caldera-grid .col-md-12,.caldera-grid .col-md-2,.caldera-grid .col-md-3,.caldera-grid .col-md-4,.caldera-grid .col-md-5,.caldera-grid .col-md-6,.caldera-grid .col-md-7,.caldera-grid .col-md-8,.caldera-grid .col-md-9{float:left}.caldera-grid .col-md-12{width:100%}.caldera-grid .col-md-11{width:91.66666667%}.caldera-grid .col-md-10{width:83.33333333%}.caldera-grid .col-md-9{width:75%}.caldera-grid .col-md-8{width:66.66666667%}.caldera-grid .col-md-7{width:58.33333333%}.caldera-grid .col-md-6{width:50%}.caldera-grid .col-md-5{width:41.66666667%}.caldera-grid .col-md-4{width:33.33333333%}.caldera-grid .col-md-3{width:25%}.caldera-grid .col-md-2{width:16.66666667%}.caldera-grid .col-md-1{width:8.33333333%}.caldera-grid .col-md-pull-12{right:100%}.caldera-grid .col-md-pull-11{right:91.66666667%}.caldera-grid .col-md-pull-10{right:83.33333333%}.caldera-grid .col-md-pull-9{right:75%}.caldera-grid .col-md-pull-8{right:66.66666667%}.caldera-grid .col-md-pull-7{right:58.33333333%}.caldera-grid .col-md-pull-6{right:50%}.caldera-grid .col-md-pull-5{right:41.66666667%}.caldera-grid .col-md-pull-4{right:33.33333333%}.caldera-grid .col-md-pull-3{right:25%}.caldera-grid .col-md-pull-2{right:16.66666667%}.caldera-grid .col-md-pull-1{right:8.33333333%}.caldera-grid .col-md-pull-0{right:0}.caldera-grid .col-md-push-12{left:100%}.caldera-grid .col-md-push-11{left:91.66666667%}.caldera-grid .col-md-push-10{left:83.33333333%}.caldera-grid .col-md-push-9{left:75%}.caldera-grid .col-md-push-8{left:66.66666667%}.caldera-grid .col-md-push-7{left:58.33333333%}.caldera-grid .col-md-push-6{left:50%}.caldera-grid .col-md-push-5{left:41.66666667%}.caldera-grid .col-md-push-4{left:33.33333333%}.caldera-grid .col-md-push-3{left:25%}.caldera-grid .col-md-push-2{left:16.66666667%}.caldera-grid .col-md-push-1{left:8.33333333%}.caldera-grid .col-md-push-0{left:0}.caldera-grid .col-md-offset-12{margin-left:100%}.caldera-grid .col-md-offset-11{margin-left:91.66666667%}.caldera-grid .col-md-offset-10{margin-left:83.33333333%}.caldera-grid .col-md-offset-9{margin-left:75%}.caldera-grid .col-md-offset-8{margin-left:66.66666667%}.caldera-grid .col-md-offset-7{margin-left:58.33333333%}.caldera-grid .col-md-offset-6{margin-left:50%}.caldera-grid .col-md-offset-5{margin-left:41.66666667%}.caldera-grid .col-md-offset-4{margin-left:33.33333333%}.caldera-grid .col-md-offset-3{margin-left:25%}.caldera-grid .col-md-offset-2{margin-left:16.66666667%}.caldera-grid .col-md-offset-1{margin-left:8.33333333%}.caldera-grid .col-md-offset-0{margin-left:0}}@-ms-viewport{width:device-width}@media (min-width:1200px){.caldera-grid .col-lg-1,.caldera-grid .col-lg-10,.caldera-grid .col-lg-11,.caldera-grid .col-lg-12,.caldera-grid .col-lg-2,.caldera-grid .col-lg-3,.caldera-grid .col-lg-4,.caldera-grid .col-lg-5,.caldera-grid .col-lg-6,.caldera-grid .col-lg-7,.caldera-grid .col-lg-8,.caldera-grid .col-lg-9{float:left}.caldera-grid .col-lg-12{width:100%}.caldera-grid .col-lg-11{width:91.66666667%}.caldera-grid .col-lg-10{width:83.33333333%}.caldera-grid .col-lg-9{width:75%}.caldera-grid .col-lg-8{width:66.66666667%}.caldera-grid .col-lg-7{width:58.33333333%}.caldera-grid .col-lg-6{width:50%}.caldera-grid .col-lg-5{width:41.66666667%}.caldera-grid .col-lg-4{width:33.33333333%}.caldera-grid .col-lg-3{width:25%}.caldera-grid .col-lg-2{width:16.66666667%}.caldera-grid .col-lg-1{width:8.33333333%}.caldera-grid .col-lg-pull-12{right:100%}.caldera-grid .col-lg-pull-11{right:91.66666667%}.caldera-grid .col-lg-pull-10{right:83.33333333%}.caldera-grid .col-lg-pull-9{right:75%}.caldera-grid .col-lg-pull-8{right:66.66666667%}.caldera-grid .col-lg-pull-7{right:58.33333333%}.caldera-grid .col-lg-pull-6{right:50%}.caldera-grid .col-lg-pull-5{right:41.66666667%}.caldera-grid .col-lg-pull-4{right:33.33333333%}.caldera-grid .col-lg-pull-3{right:25%}.caldera-grid .col-lg-pull-2{right:16.66666667%}.caldera-grid .col-lg-pull-1{right:8.33333333%}.caldera-grid .col-lg-pull-0{right:0}.caldera-grid .col-lg-push-12{left:100%}.caldera-grid .col-lg-push-11{left:91.66666667%}.caldera-grid .col-lg-push-10{left:83.33333333%}.caldera-grid .col-lg-push-9{left:75%}.caldera-grid .col-lg-push-8{left:66.66666667%}.caldera-grid .col-lg-push-7{left:58.33333333%}.caldera-grid .col-lg-push-6{left:50%}.caldera-grid .col-lg-push-5{left:41.66666667%}.caldera-grid .col-lg-push-4{left:33.33333333%}.caldera-grid .col-lg-push-3{left:25%}.caldera-grid .col-lg-push-2{left:16.66666667%}.caldera-grid .col-lg-push-1{left:8.33333333%}.caldera-grid .col-lg-push-0{left:0}.caldera-grid .col-lg-offset-12{margin-left:100%}.caldera-grid .col-lg-offset-11{margin-left:91.66666667%}.caldera-grid .col-lg-offset-10{margin-left:83.33333333%}.caldera-grid .col-lg-offset-9{margin-left:75%}.caldera-grid .col-lg-offset-8{margin-left:66.66666667%}.caldera-grid .col-lg-offset-7{margin-left:58.33333333%}.caldera-grid .col-lg-offset-6{margin-left:50%}.caldera-grid .col-lg-offset-5{margin-left:41.66666667%}.caldera-grid .col-lg-offset-4{margin-left:33.33333333%}.caldera-grid .col-lg-offset-3{margin-left:25%}.caldera-grid .col-lg-offset-2{margin-left:16.66666667%}.caldera-grid .col-lg-offset-1{margin-left:8.33333333%}.caldera-grid .col-lg-offset-0{margin-left:0}}.caldera-grid .clearfix:after,.caldera-grid .clearfix:before,.caldera-grid .container-fluid:after,.caldera-grid .container-fluid:before,.caldera-grid .container:after,.caldera-grid .container:before,.caldera-grid .row:after,.caldera-grid .row:before{content:" ";display:table}.caldera-grid .clearfix:after,.caldera-grid .container-fluid:after,.caldera-grid .container:after,.caldera-grid .row:after{clear:both}.caldera-grid .center-block{display:block;margin-left:auto;margin-right:auto}.caldera-grid .pull-right{float:right!important}.caldera-grid .pull-left{float:left!important}.caldera-grid .hide{display:none!important}.caldera-grid .show{display:block!important}.caldera-grid .hidden,.caldera-grid .visible-lg,.caldera-grid .visible-md,.caldera-grid .visible-sm,.caldera-grid .visible-xs{display:none!important}.caldera-grid .invisible{visibility:hidden}.caldera-grid .text-hide{font:0/0 a;color:transparent;text-shadow:none;background-color:transparent;border:0}.caldera-grid .alert .alert-link,.caldera-grid b,.caldera-grid strong{font-weight:700}.caldera-grid .hidden{visibility:hidden!important}.caldera-grid .affix{position:fixed}@-ms-viewport{width:device-width}@media (max-width:767px){.caldera-grid .visible-xs{display:block!important}.caldera-grid table.visible-xs{display:table}.caldera-grid tr.visible-xs{display:table-row!important}.caldera-grid td.visible-xs,.caldera-grid th.visible-xs{display:table-cell!important}}@media (min-width:768px) and (max-width:991px){.caldera-grid .visible-sm{display:block!important}.caldera-grid table.visible-sm{display:table}.caldera-grid tr.visible-sm{display:table-row!important}.caldera-grid td.visible-sm,.caldera-grid th.visible-sm{display:table-cell!important}}@media (min-width:992px) and (max-width:1199px){.caldera-grid .visible-md{display:block!important}.caldera-grid table.visible-md{display:table}.caldera-grid tr.visible-md{display:table-row!important}.caldera-grid td.visible-md,.caldera-grid th.visible-md{display:table-cell!important}}@media (min-width:1200px){.caldera-grid .visible-lg{display:block!important}.caldera-grid table.visible-lg{display:table}.caldera-grid tr.visible-lg{display:table-row!important}.caldera-grid td.visible-lg,.caldera-grid th.visible-lg{display:table-cell!important}.caldera-grid .hidden-lg{display:none!important}}@media (max-width:767px){.caldera-grid .hidden-xs{display:none!important}}@media (min-width:768px) and (max-width:991px){.caldera-grid .hidden-sm{display:none!important}}@media (min-width:992px) and (max-width:1199px){.caldera-grid .hidden-md{display:none!important}}.caldera-grid .visible-print{display:none!important}@media print{.caldera-grid .visible-print{display:block!important}.caldera-grid table.visible-print{display:table}.caldera-grid tr.visible-print{display:table-row!important}.caldera-grid td.visible-print,.caldera-grid th.visible-print{display:table-cell!important}.caldera-grid .hidden-print{display:none!important}}input.parsley-success,select.parsley-success,textarea.parsley-success{color:#468847;background-color:#DFF0D8;border:1px solid #D6E9C6}input.parsley-error,select.parsley-error,textarea.parsley-error{color:#B94A48;background-color:#F2DEDE;border:1px solid #EED3D7}.parsley-errors-list{margin:2px 0 3px;padding:0;list-style-type:none;font-size:.9em;line-height:.9em;opacity:0;transition:all .3s ease-in;-o-transition:all .3s ease-in;-moz-transition:all .3s ease-in;-webkit-transition:all .3s ease-in}.parsley-errors-list.filled{opacity:1}.caldera-grid .alert{padding:8px;margin-bottom:18px;border-radius:2px}.caldera-grid .alert-dismissable{padding-right:28px}.caldera-grid .alert-success{background-color:#dff0d8;border-color:#a3d48e;color:#3c763d}.caldera-grid .alert-success hr{border-top-color:#93cd7c}.caldera-grid .alert-success .alert-link{color:#2b542c}.caldera-grid .alert-info{background-color:#d9edf7;border-color:#85c5e5;color:#31708f}.caldera-grid .alert-info hr{border-top-color:#70bbe1}.caldera-grid .alert-info .alert-link{color:#245269}.caldera-grid .alert-warning{background-color:#f9edbe;border-color:#f0c36d;color:#333}.caldera-grid .alert-warning hr{border-top-color:#eeb956}.caldera-grid .alert-warning .alert-link{color:#1a1a1a}.caldera-grid .alert-danger,.caldera-grid .alert-error{background-color:#f2dede;border-color:#d59595;color:#a94442}.caldera-grid .alert-danger hr,.caldera-grid .alert-error hr{border-top-color:#ce8383}.caldera-grid .alert-danger .alert-link,.caldera-grid .alert-error .alert-link{color:#843534}.caldera-grid .alert-danger,.caldera-grid .alert-error,.caldera-grid .alert-info,.caldera-grid .alert-success,.caldera-grid .alert-warning{text-shadow:0 1px 0 rgba(255,255,255,.5)}.caldera-grid .has-error .form-control:focus,.caldera-grid .has-error .form-control:hover{border-color:#dd4b39}.caldera-grid.cf_processing{background:url(../images/loading.gif) center center/30px auto no-repeat rgba(0,0,0,0)}.caldera-grid.cf_processing>*{opacity:.5}.caldera-grid html{font-family:sans-serif}.caldera-grid body{margin:0}.caldera-grid article,.caldera-grid aside,.caldera-grid details,.caldera-grid figcaption,.caldera-grid figure,.caldera-grid footer,.caldera-grid header,.caldera-grid hgroup,.caldera-grid main,.caldera-grid menu,.caldera-grid nav,.caldera-grid section,.caldera-grid summary{display:block}.caldera-grid audio,.caldera-grid canvas,.caldera-grid progress,.caldera-grid video{display:inline-block;vertical-align:baseline}.caldera-grid audio:not([controls]){display:none;height:0}.caldera-grid [hidden],.caldera-grid template{display:none}.caldera-grid a{background-color:transparent}.caldera-grid a:active,.caldera-grid a:hover{outline:0}.caldera-grid abbr[title]{border-bottom:1px dotted}.caldera-grid dfn{font-style:italic}.caldera-grid h1{font-size:2em;margin:.67em 0}.caldera-grid mark{background:#ff0;color:#000}.caldera-grid small{font-size:80%}.caldera-grid sub,.caldera-grid sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}.caldera-grid sup{top:-.5em}.caldera-grid sub{bottom:-.25em}.caldera-grid img{border:0}.caldera-grid figure{margin:1em 40px}.caldera-grid hr{-moz-box-sizing:content-box;box-sizing:content-box;height:0}.caldera-grid pre{overflow:auto}.caldera-grid code,.caldera-grid kbd,.caldera-grid pre,.caldera-grid samp{font-family:monospace,monospace;font-size:1em}.caldera-grid button,.caldera-grid input,.caldera-grid optgroup,.caldera-grid select,.caldera-grid textarea{font:inherit;margin:0}.caldera-grid button{overflow:visible}.caldera-grid button,.caldera-grid html input[type=button],.caldera-grid input[type=reset],.caldera-grid input[type=submit]{-webkit-appearance:button;cursor:pointer}.caldera-grid button[disabled],.caldera-grid html input[disabled]{cursor:default}.caldera-grid button::-moz-focus-inner,.caldera-grid input::-moz-focus-inner{border:0;padding:0}.caldera-grid input{line-height:normal}.caldera-grid input[type=checkbox],.caldera-grid input[type=radio]{box-sizing:border-box;padding:0}.caldera-grid input[type=number]::-webkit-inner-spin-button,.caldera-grid input[type=number]::-webkit-outer-spin-button{height:auto}.caldera-grid input[type=search]{-webkit-appearance:textfield;-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box}.caldera-grid input[type=search]::-webkit-search-cancel-button,.caldera-grid input[type=search]::-webkit-search-decoration{-webkit-appearance:none}.caldera-grid textarea{overflow:auto}.caldera-grid optgroup{font-weight:700}.caldera-grid table{border-collapse:collapse;border-spacing:0}.caldera-grid td,.caldera-grid th{padding:0}@media print{.caldera-grid *,.caldera-grid :after,.caldera-grid :before{background:0 0!important;color:#000!important;box-shadow:none!important;text-shadow:none!important}.caldera-grid a,.caldera-grid a:visited{text-decoration:underline}.caldera-grid a[href]:after{content:" (" attr(href) ")"}.caldera-grid abbr[title]:after{content:" (" attr(title) ")"}.caldera-grid a[href^="#"]:after,.caldera-grid a[href^="javascript:"]:after{content:""}.caldera-grid blockquote,.caldera-grid pre{border:1px solid #999;page-break-inside:avoid}.caldera-grid thead{display:table-header-group}.caldera-grid img,.caldera-grid tr{page-break-inside:avoid}.caldera-grid img{max-width:100%!important}.caldera-grid h2,.caldera-grid h3,.caldera-grid p{orphans:3;widows:3}.caldera-grid h2,.caldera-grid h3{page-break-after:avoid}.caldera-grid select{background:#fff!important}.caldera-grid .navbar{display:none}.caldera-grid .btn>.caret,.caldera-grid .dropup>.btn>.caret{border-top-color:#000!important}.caldera-grid .label{border:1px solid #000}.caldera-grid .table{border-collapse:collapse!important}.caldera-grid .table td,.caldera-grid .table th{background-color:#fff!important}.caldera-grid .table-bordered td,.caldera-grid .table-bordered th{border:1px solid #ddd!important}}.caldera-grid .btn,.caldera-grid .btn-danger.active,.caldera-grid .btn-danger:active,.caldera-grid .btn-default.active,.caldera-grid .btn-default:active,.caldera-grid .btn-info.active,.caldera-grid .btn-info:active,.caldera-grid .btn-primary.active,.caldera-grid .btn-primary:active,.caldera-grid .btn-success.active,.caldera-grid .btn-success:active,.caldera-grid .btn-warning.active,.caldera-grid .btn-warning:active,.caldera-grid .form-control,.open>.dropdown-toggle.caldera-grid .btn-danger,.open>.dropdown-toggle.caldera-grid .btn-default,.open>.dropdown-toggle.caldera-grid .btn-info,.open>.dropdown-toggle.caldera-grid .btn-primary,.open>.dropdown-toggle.caldera-grid .btn-success,.open>.dropdown-toggle.caldera-grid .btn-warning{background-image:none}.caldera-grid fieldset{padding:0;margin:0;border:0;min-width:0}.caldera-grid legend{display:block;width:100%;padding:0;margin-bottom:20px;font-size:21px;line-height:inherit;color:#333;border:0;border-bottom:1px solid #e5e5e5}.caldera-grid label{display:inline-block;max-width:100%;margin-bottom:5px;font-weight:700}.caldera-grid input[type=checkbox],.caldera-grid input[type=radio]{margin:0;line-height:normal}.caldera-grid .form-control,.caldera-grid output{font-size:14px;line-height:1.42857143;color:#555;display:block}.caldera-grid input[type=file]{display:block}.caldera-grid input[type=range]{display:block;width:100%}.caldera-grid select[multiple],.caldera-grid select[size]{height:auto}.caldera-grid input[type=checkbox]:focus,.caldera-grid input[type=file]:focus,.caldera-grid input[type=radio]:focus{outline:dotted thin;outline:-webkit-focus-ring-color auto 5px;outline-offset:-2px}.caldera-grid input[type=checkbox]{-webkit-appearance:checkbox}.caldera-grid input[type=radio]{-webkit-appearance:radio}.caldera-grid output{padding-top:7px}.caldera-grid .form-control{width:100%;height:34px;padding:6px 12px;background-color:#fff;border:1px solid #ccc;border-radius:2px;-webkit-box-shadow:inset 0 1px 1px rgba(0,0,0,.075);box-shadow:inset 0 1px 1px rgba(0,0,0,.075);-webkit-transition:border-color ease-in-out .15s,box-shadow ease-in-out .15s;-o-transition:border-color ease-in-out .15s,box-shadow ease-in-out .15s;transition:border-color ease-in-out .15s,box-shadow ease-in-out .15s}.caldera-grid .form-control:focus{border-color:#66afe9;outline:0;-webkit-box-shadow:inset 0 1px 1px rgba(0,0,0,.075),0 0 8px rgba(102,175,233,.6);box-shadow:inset 0 1px 1px rgba(0,0,0,.075),0 0 8px rgba(102,175,233,.6)}.caldera-grid .form-control::-moz-placeholder{color:#999;opacity:1}.caldera-grid .form-control:-ms-input-placeholder{color:#999}.caldera-grid .form-control::-webkit-input-placeholder{color:#999}.caldera-grid .has-success .checkbox,.caldera-grid .has-success .checkbox-inline,.caldera-grid .has-success .control-label,.caldera-grid .has-success .form-control-feedback,.caldera-grid .has-success .help-block,.caldera-grid .has-success .radio,.caldera-grid .has-success .radio-inline,.caldera-grid .has-success.checkbox label,.caldera-grid .has-success.checkbox-inline label,.caldera-grid .has-success.radio label,.caldera-grid .has-success.radio-inline label{color:#3c763d}.caldera-grid .form-control[disabled],.caldera-grid .form-control[readonly],fieldset[disabled] .caldera-grid .form-control{background-color:#eee;opacity:1}.caldera-grid .form-control[disabled],fieldset[disabled] .caldera-grid .form-control{cursor:not-allowed}textarea .caldera-grid .form-control{height:auto}@media screen and (-webkit-min-device-pixel-ratio:0){.caldera-grid input[type=date],.caldera-grid input[type=datetime-local],.caldera-grid input[type=month],.caldera-grid input[type=time]{line-height:34px}.caldera-grid input[type=date].input-sm,.caldera-grid input[type=datetime-local].input-sm,.caldera-grid input[type=month].input-sm,.caldera-grid input[type=time].input-sm,.input-group-sm .caldera-grid input[type=date],.input-group-sm .caldera-grid input[type=datetime-local],.input-group-sm .caldera-grid input[type=month],.input-group-sm .caldera-grid input[type=time]{line-height:30px}.caldera-grid input[type=date].input-lg,.caldera-grid input[type=datetime-local].input-lg,.caldera-grid input[type=month].input-lg,.caldera-grid input[type=time].input-lg,.input-group-lg .caldera-grid input[type=date],.input-group-lg .caldera-grid input[type=datetime-local],.input-group-lg .caldera-grid input[type=month],.input-group-lg .caldera-grid input[type=time]{line-height:46px}}.caldera-grid .form-group{margin-bottom:15px}.caldera-grid .checkbox,.caldera-grid .radio{position:relative;display:block;margin-top:10px;margin-bottom:10px}.caldera-grid .checkbox label,.caldera-grid .radio label{min-height:20px;padding-left:20px;margin-bottom:0;font-weight:400;cursor:pointer}.caldera-grid .checkbox input[type=checkbox],.caldera-grid .checkbox-inline input[type=checkbox],.caldera-grid .radio input[type=radio],.caldera-grid .radio-inline input[type=radio]{margin-left:-20px}.caldera-grid .checkbox+.checkbox,.caldera-grid .radio+.radio{margin-top:-5px}.caldera-grid .checkbox-inline,.caldera-grid .radio-inline{position:relative;display:inline-block;padding-left:20px;margin-bottom:0;vertical-align:middle;font-weight:400;cursor:pointer}.caldera-grid .checkbox-inline+.checkbox-inline,.caldera-grid .radio-inline+.radio-inline{margin-top:0;margin-left:10px}.caldera-grid .checkbox-inline.disabled,.caldera-grid .checkbox.disabled label,.caldera-grid .radio-inline.disabled,.caldera-grid .radio.disabled label,.caldera-grid input[type=checkbox].disabled,.caldera-grid input[type=checkbox][disabled],.caldera-grid input[type=radio].disabled,.caldera-grid input[type=radio][disabled],fieldset[disabled] .caldera-grid .checkbox label,fieldset[disabled] .caldera-grid .checkbox-inline,fieldset[disabled] .caldera-grid .radio label,fieldset[disabled] .caldera-grid .radio-inline,fieldset[disabled] .caldera-grid input[type=checkbox],fieldset[disabled] .caldera-grid input[type=radio]{cursor:not-allowed}.caldera-grid .form-control-static{padding-top:7px;padding-bottom:7px;margin-bottom:0;min-height:34px}.caldera-grid .form-control-static.input-lg,.caldera-grid .form-control-static.input-sm{padding-left:0;padding-right:0}.caldera-grid .input-sm{height:30px;padding:5px 10px;font-size:12px;line-height:1.5;border-radius:1px}select.caldera-grid .input-sm{height:30px;line-height:30px}select[multiple].caldera-grid .input-sm,textarea.caldera-grid .input-sm{height:auto}.caldera-grid .form-group-sm .form-control{height:30px;padding:5px 10px;font-size:12px;line-height:1.5;border-radius:1px}select.caldera-grid .form-group-sm .form-control{height:30px;line-height:30px}select[multiple].caldera-grid .form-group-sm .form-control,textarea.caldera-grid .form-group-sm .form-control{height:auto}.caldera-grid .form-group-sm .form-control-static{height:30px;padding:5px 10px;font-size:12px;line-height:1.5;min-height:32px}.caldera-grid .input-lg{height:46px;padding:10px 16px;font-size:18px;line-height:1.3333333;border-radius:4px}select.caldera-grid .input-lg{height:46px;line-height:46px}select[multiple].caldera-grid .input-lg,textarea.caldera-grid .input-lg{height:auto}.caldera-grid .form-group-lg .form-control{height:46px;padding:10px 16px;font-size:18px;line-height:1.3333333;border-radius:4px}select.caldera-grid .form-group-lg .form-control{height:46px;line-height:46px}select[multiple].caldera-grid .form-group-lg .form-control,textarea.caldera-grid .form-group-lg .form-control{height:auto}.caldera-grid .form-group-lg .form-control-static{height:46px;padding:10px 16px;font-size:18px;line-height:1.3333333;min-height:38px}.caldera-grid .has-feedback{position:relative}.caldera-grid .has-feedback .form-control{padding-right:42.5px}.caldera-grid .form-control-feedback{position:absolute;top:0;right:0;z-index:2;display:block;width:34px;height:34px;line-height:34px;text-align:center;pointer-events:none}.caldera-grid .input-lg+.form-control-feedback{width:46px;height:46px;line-height:46px}.caldera-grid .input-sm+.form-control-feedback{width:30px;height:30px;line-height:30px}.caldera-grid .has-success .form-control{border-color:#3c763d;-webkit-box-shadow:inset 0 1px 1px rgba(0,0,0,.075);box-shadow:inset 0 1px 1px rgba(0,0,0,.075)}.caldera-grid .has-success .form-control:focus{border-color:#2b542c;-webkit-box-shadow:inset 0 1px 1px rgba(0,0,0,.075),0 0 6px #67b168;box-shadow:inset 0 1px 1px rgba(0,0,0,.075),0 0 6px #67b168}.caldera-grid .has-success .input-group-addon{color:#3c763d;border-color:#3c763d;background-color:#dff0d8}.caldera-grid .has-warning .checkbox,.caldera-grid .has-warning .checkbox-inline,.caldera-grid .has-warning .control-label,.caldera-grid .has-warning .form-control-feedback,.caldera-grid .has-warning .help-block,.caldera-grid .has-warning .radio,.caldera-grid .has-warning .radio-inline,.caldera-grid .has-warning.checkbox label,.caldera-grid .has-warning.checkbox-inline label,.caldera-grid .has-warning.radio label,.caldera-grid .has-warning.radio-inline label{color:#8a6d3b}.caldera-grid .has-warning .form-control{border-color:#8a6d3b;-webkit-box-shadow:inset 0 1px 1px rgba(0,0,0,.075);box-shadow:inset 0 1px 1px rgba(0,0,0,.075)}.caldera-grid .has-warning .form-control:focus{border-color:#66512c;-webkit-box-shadow:inset 0 1px 1px rgba(0,0,0,.075),0 0 6px #c0a16b;box-shadow:inset 0 1px 1px rgba(0,0,0,.075),0 0 6px #c0a16b}.caldera-grid .has-warning .input-group-addon{color:#8a6d3b;border-color:#8a6d3b;background-color:#fcf8e3}.caldera-grid .has-error .checkbox,.caldera-grid .has-error .checkbox-inline,.caldera-grid .has-error .control-label,.caldera-grid .has-error .form-control-feedback,.caldera-grid .has-error .help-block,.caldera-grid .has-error .radio,.caldera-grid .has-error .radio-inline,.caldera-grid .has-error.checkbox label,.caldera-grid .has-error.checkbox-inline label,.caldera-grid .has-error.radio label,.caldera-grid .has-error.radio-inline label{color:#a94442}.caldera-grid .has-error .form-control{border-color:#a94442;-webkit-box-shadow:inset 0 1px 1px rgba(0,0,0,.075);box-shadow:inset 0 1px 1px rgba(0,0,0,.075)}.caldera-grid .has-error .form-control:focus{border-color:#843534;-webkit-box-shadow:inset 0 1px 1px rgba(0,0,0,.075),0 0 6px #ce8483;box-shadow:inset 0 1px 1px rgba(0,0,0,.075),0 0 6px #ce8483}.caldera-grid .has-error .input-group-addon{color:#a94442;border-color:#a94442;background-color:#f2dede}.caldera-grid .has-feedback label~.form-control-feedback{top:25px}.caldera-grid .has-feedback label.sr-only~.form-control-feedback{top:0}.caldera-grid .help-block{display:block;margin-top:5px;margin-bottom:10px;color:#737373}@media (min-width:768px){.caldera-grid .form-inline .form-group{display:inline-block;margin-bottom:0;vertical-align:middle}.caldera-grid .form-inline .form-control{display:inline-block;width:auto;vertical-align:middle}.caldera-grid .form-inline .form-control-static{display:inline-block}.caldera-grid .form-inline .input-group{display:inline-table;vertical-align:middle}.caldera-grid .form-inline .input-group .form-control,.caldera-grid .form-inline .input-group .input-group-addon,.caldera-grid .form-inline .input-group .input-group-btn{width:auto}.caldera-grid .form-inline .input-group>.form-control{width:100%}.caldera-grid .form-inline .control-label{margin-bottom:0;vertical-align:middle}.caldera-grid .form-inline .checkbox,.caldera-grid .form-inline .radio{display:inline-block;margin-top:0;margin-bottom:0;vertical-align:middle}.caldera-grid .form-inline .checkbox label,.caldera-grid .form-inline .radio label{padding-left:0}.caldera-grid .form-inline .checkbox input[type=checkbox],.caldera-grid .form-inline .radio input[type=radio]{position:relative;margin-left:0}.caldera-grid .form-inline .has-feedback .form-control-feedback{top:0}.caldera-grid .form-horizontal .control-label{text-align:right;margin-bottom:0;padding-top:7px}}.caldera-grid .form-horizontal .checkbox,.caldera-grid .form-horizontal .checkbox-inline,.caldera-grid .form-horizontal .radio,.caldera-grid .form-horizontal .radio-inline{margin-top:0;margin-bottom:0;padding-top:7px}.caldera-grid .form-horizontal .checkbox,.caldera-grid .form-horizontal .radio{min-height:27px}.caldera-grid .form-horizontal .form-group{margin-left:-15px;margin-right:-15px}.caldera-grid .form-horizontal .has-feedback .form-control-feedback{right:15px}@media (min-width:768px){.caldera-grid .form-horizontal .form-group-lg .control-label{padding-top:14.33px}.caldera-grid .form-horizontal .form-group-sm .control-label{padding-top:6px}}.caldera-grid .btn{display:inline-block;margin-bottom:0;font-weight:400;text-align:center;vertical-align:middle;touch-action:manipulation;cursor:pointer;border:1px solid transparent;white-space:nowrap;padding:6px 12px;font-size:14px;line-height:1.42857143;border-radius:2px;user-select:none}.caldera-grid .btn.active.focus,.caldera-grid .btn.active:focus,.caldera-grid .btn.focus,.caldera-grid .btn:active.focus,.caldera-grid .btn:active:focus,.caldera-grid .btn:focus{outline:dotted thin;outline:-webkit-focus-ring-color auto 5px;outline-offset:-2px}.caldera-grid .btn.focus,.caldera-grid .btn:focus,.caldera-grid .btn:hover{color:#333;text-decoration:none}.caldera-grid .btn.active,.caldera-grid .btn:active{outline:0;background-image:none;-webkit-box-shadow:inset 0 3px 5px rgba(0,0,0,.125);box-shadow:inset 0 3px 5px rgba(0,0,0,.125)}.caldera-grid .btn.disabled,.caldera-grid .btn[disabled],fieldset[disabled] .caldera-grid .btn{cursor:not-allowed;pointer-events:none;opacity:.65;filter:alpha(opacity=65);-webkit-box-shadow:none;box-shadow:none}.caldera-grid .btn-default{color:#333;background-color:#fff;border-color:#ccc}.caldera-grid .btn-default.active,.caldera-grid .btn-default.focus,.caldera-grid .btn-default:active,.caldera-grid .btn-default:focus,.caldera-grid .btn-default:hover,.open>.dropdown-toggle.caldera-grid .btn-default{color:#333;background-color:#e6e6e6;border-color:#adadad}.caldera-grid .btn-default.disabled,.caldera-grid .btn-default.disabled.active,.caldera-grid .btn-default.disabled.focus,.caldera-grid .btn-default.disabled:active,.caldera-grid .btn-default.disabled:focus,.caldera-grid .btn-default.disabled:hover,.caldera-grid .btn-default[disabled],.caldera-grid .btn-default[disabled].active,.caldera-grid .btn-default[disabled].focus,.caldera-grid .btn-default[disabled]:active,.caldera-grid .btn-default[disabled]:focus,.caldera-grid .btn-default[disabled]:hover,fieldset[disabled] .caldera-grid .btn-default,fieldset[disabled] .caldera-grid .btn-default.active,fieldset[disabled] .caldera-grid .btn-default.focus,fieldset[disabled] .caldera-grid .btn-default:active,fieldset[disabled] .caldera-grid .btn-default:focus,fieldset[disabled] .caldera-grid .btn-default:hover{background-color:#fff;border-color:#ccc}.caldera-grid .btn-default .badge{color:#fff;background-color:#333}.caldera-grid .btn-primary{color:#fff;background-color:#337ab7;border-color:#2e6da4}.caldera-grid .btn-primary.active,.caldera-grid .btn-primary.focus,.caldera-grid .btn-primary:active,.caldera-grid .btn-primary:focus,.caldera-grid .btn-primary:hover,.open>.dropdown-toggle.caldera-grid .btn-primary{color:#fff;background-color:#286090;border-color:#204d74}.caldera-grid .btn-primary.disabled,.caldera-grid .btn-primary.disabled.active,.caldera-grid .btn-primary.disabled.focus,.caldera-grid .btn-primary.disabled:active,.caldera-grid .btn-primary.disabled:focus,.caldera-grid .btn-primary.disabled:hover,.caldera-grid .btn-primary[disabled],.caldera-grid .btn-primary[disabled].active,.caldera-grid .btn-primary[disabled].focus,.caldera-grid .btn-primary[disabled]:active,.caldera-grid .btn-primary[disabled]:focus,.caldera-grid .btn-primary[disabled]:hover,fieldset[disabled] .caldera-grid .btn-primary,fieldset[disabled] .caldera-grid .btn-primary.active,fieldset[disabled] .caldera-grid .btn-primary.focus,fieldset[disabled] .caldera-grid .btn-primary:active,fieldset[disabled] .caldera-grid .btn-primary:focus,fieldset[disabled] .caldera-grid .btn-primary:hover{background-color:#337ab7;border-color:#2e6da4}.caldera-grid .btn-primary .badge{color:#337ab7;background-color:#fff}.caldera-grid .btn-success{color:#fff;background-color:#5cb85c;border-color:#4cae4c}.caldera-grid .btn-success.active,.caldera-grid .btn-success.focus,.caldera-grid .btn-success:active,.caldera-grid .btn-success:focus,.caldera-grid .btn-success:hover,.open>.dropdown-toggle.caldera-grid .btn-success{color:#fff;background-color:#449d44;border-color:#398439}.caldera-grid .btn-success.disabled,.caldera-grid .btn-success.disabled.active,.caldera-grid .btn-success.disabled.focus,.caldera-grid .btn-success.disabled:active,.caldera-grid .btn-success.disabled:focus,.caldera-grid .btn-success.disabled:hover,.caldera-grid .btn-success[disabled],.caldera-grid .btn-success[disabled].active,.caldera-grid .btn-success[disabled].focus,.caldera-grid .btn-success[disabled]:active,.caldera-grid .btn-success[disabled]:focus,.caldera-grid .btn-success[disabled]:hover,fieldset[disabled] .caldera-grid .btn-success,fieldset[disabled] .caldera-grid .btn-success.active,fieldset[disabled] .caldera-grid .btn-success.focus,fieldset[disabled] .caldera-grid .btn-success:active,fieldset[disabled] .caldera-grid .btn-success:focus,fieldset[disabled] .caldera-grid .btn-success:hover{background-color:#5cb85c;border-color:#4cae4c}.caldera-grid .btn-success .badge{color:#5cb85c;background-color:#fff}.caldera-grid .btn-info{color:#fff;background-color:#5bc0de;border-color:#46b8da}.caldera-grid .btn-info.active,.caldera-grid .btn-info.focus,.caldera-grid .btn-info:active,.caldera-grid .btn-info:focus,.caldera-grid .btn-info:hover,.open>.dropdown-toggle.caldera-grid .btn-info{color:#fff;background-color:#31b0d5;border-color:#269abc}.caldera-grid .btn-info.disabled,.caldera-grid .btn-info.disabled.active,.caldera-grid .btn-info.disabled.focus,.caldera-grid .btn-info.disabled:active,.caldera-grid .btn-info.disabled:focus,.caldera-grid .btn-info.disabled:hover,.caldera-grid .btn-info[disabled],.caldera-grid .btn-info[disabled].active,.caldera-grid .btn-info[disabled].focus,.caldera-grid .btn-info[disabled]:active,.caldera-grid .btn-info[disabled]:focus,.caldera-grid .btn-info[disabled]:hover,fieldset[disabled] .caldera-grid .btn-info,fieldset[disabled] .caldera-grid .btn-info.active,fieldset[disabled] .caldera-grid .btn-info.focus,fieldset[disabled] .caldera-grid .btn-info:active,fieldset[disabled] .caldera-grid .btn-info:focus,fieldset[disabled] .caldera-grid .btn-info:hover{background-color:#5bc0de;border-color:#46b8da}.caldera-grid .btn-info .badge{color:#5bc0de;background-color:#fff}.caldera-grid .btn-warning{color:#fff;background-color:#f0ad4e;border-color:#eea236}.caldera-grid .btn-warning.active,.caldera-grid .btn-warning.focus,.caldera-grid .btn-warning:active,.caldera-grid .btn-warning:focus,.caldera-grid .btn-warning:hover,.open>.dropdown-toggle.caldera-grid .btn-warning{color:#fff;background-color:#ec971f;border-color:#d58512}.caldera-grid .btn-warning.disabled,.caldera-grid .btn-warning.disabled.active,.caldera-grid .btn-warning.disabled.focus,.caldera-grid .btn-warning.disabled:active,.caldera-grid .btn-warning.disabled:focus,.caldera-grid .btn-warning.disabled:hover,.caldera-grid .btn-warning[disabled],.caldera-grid .btn-warning[disabled].active,.caldera-grid .btn-warning[disabled].focus,.caldera-grid .btn-warning[disabled]:active,.caldera-grid .btn-warning[disabled]:focus,.caldera-grid .btn-warning[disabled]:hover,fieldset[disabled] .caldera-grid .btn-warning,fieldset[disabled] .caldera-grid .btn-warning.active,fieldset[disabled] .caldera-grid .btn-warning.focus,fieldset[disabled] .caldera-grid .btn-warning:active,fieldset[disabled] .caldera-grid .btn-warning:focus,fieldset[disabled] .caldera-grid .btn-warning:hover{background-color:#f0ad4e;border-color:#eea236}.caldera-grid .btn-warning .badge{color:#f0ad4e;background-color:#fff}.caldera-grid .btn-danger{color:#fff;background-color:#d9534f;border-color:#d43f3a}.caldera-grid .btn-danger.active,.caldera-grid .btn-danger.focus,.caldera-grid .btn-danger:active,.caldera-grid .btn-danger:focus,.caldera-grid .btn-danger:hover,.open>.dropdown-toggle.caldera-grid .btn-danger{color:#fff;background-color:#c9302c;border-color:#ac2925}.caldera-grid .btn-danger.disabled,.caldera-grid .btn-danger.disabled.active,.caldera-grid .btn-danger.disabled.focus,.caldera-grid .btn-danger.disabled:active,.caldera-grid .btn-danger.disabled:focus,.caldera-grid .btn-danger.disabled:hover,.caldera-grid .btn-danger[disabled],.caldera-grid .btn-danger[disabled].active,.caldera-grid .btn-danger[disabled].focus,.caldera-grid .btn-danger[disabled]:active,.caldera-grid .btn-danger[disabled]:focus,.caldera-grid .btn-danger[disabled]:hover,fieldset[disabled] .caldera-grid .btn-danger,fieldset[disabled] .caldera-grid .btn-danger.active,fieldset[disabled] .caldera-grid .btn-danger.focus,fieldset[disabled] .caldera-grid .btn-danger:active,fieldset[disabled] .caldera-grid .btn-danger:focus,fieldset[disabled] .caldera-grid .btn-danger:hover{background-color:#d9534f;border-color:#d43f3a}.caldera-grid .btn-danger .badge{color:#d9534f;background-color:#fff}.caldera-grid .btn-link{color:#337ab7;font-weight:400;border-radius:0}.caldera-grid .btn-link,.caldera-grid .btn-link.active,.caldera-grid .btn-link:active,.caldera-grid .btn-link[disabled],fieldset[disabled] .caldera-grid .btn-link{background-color:transparent;-webkit-box-shadow:none;box-shadow:none}.caldera-grid .btn-link,.caldera-grid .btn-link:active,.caldera-grid .btn-link:focus,.caldera-grid .btn-link:hover{border-color:transparent}.caldera-grid .btn-link:focus,.caldera-grid .btn-link:hover{color:#23527c;text-decoration:underline;background-color:transparent}.caldera-grid .btn-link[disabled]:focus,.caldera-grid .btn-link[disabled]:hover,fieldset[disabled] .caldera-grid .btn-link:focus,fieldset[disabled] .caldera-grid .btn-link:hover{color:#777;text-decoration:none}.caldera-grid .btn-lg{padding:10px 16px;font-size:18px;line-height:1.3333333;border-radius:4px}.caldera-grid .btn-sm,.caldera-grid .btn-xs{font-size:12px;line-height:1.5;border-radius:1px}.caldera-grid .btn-sm{padding:5px 10px}.caldera-grid .btn-xs{padding:1px 5px}.caldera-grid .btn-block{display:block;width:100%}.caldera-grid .btn-block+.btn-block{margin-top:5px}.caldera-grid input[type=button].btn-block,.caldera-grid input[type=reset].btn-block,.caldera-grid input[type=submit].btn-block{width:100%}.caldera-grid textarea.form-control{padding-right:4px;height:auto}.caldera-grid .breadcrumb{padding:6px 12px;margin:0 0 20px;list-style:none;background-color:#f5f5f5;border-radius:4px}.caldera-grid .breadcrumb>li{display:inline-block;margin:0}.caldera-grid .breadcrumb>li+li:before{content:"/\00a0";padding:0 5px;color:#ccc}.caldera-grid .breadcrumb>.active,.caldera-grid .breadcrumb>.active>a{color:#777}.breadcrumb>li.active.error>a,.breadcrumb>li.error>a{color:red}.caldera-grid .cf-credit-card{padding-left:42px;background-image:url(../images/credit-card.svg);background-repeat:no-repeat!important;background-position-x:4px!important;background-position-y:3px!important}.caldera-grid .screen-reader-text{clip:rect(1px,1px,1px,1px);height:1px;overflow:hidden;position:absolute!important;width:1px;word-wrap:normal!important}@font-face{font-family:cf-raty;src:url(fonts/cf-raty.eot?40481674);src:url(fonts/cf-raty.eot?40481674#iefix) format('embedded-opentype'),url(fonts/cf-raty.woff?40481674) format('woff'),url(fonts/cf-raty.ttf?40481674) format('truetype'),url(fonts/cf-raty.svg?40481674#cf-raty) format('svg');font-weight:400;font-style:normal}[class*=" raty-"]:before,[class^=raty-]:before{font-family:cf-raty;font-style:normal;font-weight:400;speak:none;font-size:2em;display:inline-block;text-decoration:inherit;width:1em;text-align:center;font-variant:normal;text-transform:none;line-height:1em}.raty-heart-on:before{content:'\e800'}.raty-heart-off:before{content:'\e801'}.raty-star-on:before{content:'\e802'}.raty-star-off:before{content:'\e803'}.raty-circle-on:before{content:'\e804'}.raty-circle-off:before{content:'\e805'}.raty-dot-off:before{content:'\e806'}.raty-dot-on:before{content:'\e807'}.raty-face-off:before{content:'\e808'}.raty-face-on:before{content:'\e809'}.raty-cancel-off:before{content:'\e80a'}.raty-cancel-on:before{content:'\e80b'}.calculation-group{background:#FFF;box-shadow:0 1px 2px rgba(0,0,0,.05);padding:6px;margin:6px 0}.preview-color-selector{background:#F0F0F0;border:1px solid #E2E2E2;display:inline;margin-left:-1px;padding:3px 12px;box-shadow:0 0 0 2px #fff inset}.miniColors-trigger{border:1px solid #999;-mz-border-radius:0 1px 1px 0;-webkit-border-radius:0 1px 1px 0;display:inline-block;height:24px;margin:0 0 -8px -1px;width:30px}.cf-color-picker .input-group-btn:last-child>.btn,.cf-color-picker .input-group-btn:last-child>.btn-group,.cf-color-picker .input-group-btn>.btn+.btn{margin-left:-1px}.miniColors-selector{background:#FFF;border:1px solid #999;-moz-box-shadow:0 3px 0 -1px rgba(0,0,0,.05);-webkit-box-shadow:0 3px 0 -1px rgba(0,0,0,.05);box-shadow:0 3px 0 -1px rgba(0,0,0,.05);height:162px;padding:5px;position:absolute;width:187px;z-index:999999;margin-top:-1px}.miniColors-colors,.miniColors-hues{top:5px;height:150px;cursor:crosshair;position:absolute}.miniColors-selector.black{background:#000;border-color:#000}.miniColors-colors{left:5px;width:150px;background:url(minicolor-colors.png) right no-repeat}.miniColors-hues{left:160px;width:20px;background:url(minicolor-colors.png) left no-repeat}.miniColors-colorPicker{position:absolute;width:9px;height:9px;border:1px solid #fff;-moz-border-radius:11px;-webkit-border-radius:11px;border-radius:11px}.miniColors-colorPicker-inner{position:absolute;top:0;left:0;width:7px;height:7px;border:1px solid #000;-moz-border-radius:9px;-webkit-border-radius:9px;border-radius:9px}.miniColors-huePicker{position:absolute;left:-3px;width:24px;height:1px;border:1px solid #fff;border-radius:2px;background:#000}.cf-color-picker .form-control::-moz-placeholder{color:#999;opacity:1}.cf-color-picker .form-control:-ms-input-placeholder{color:#999}.cf-color-picker .form-control::-webkit-input-placeholder{color:#999}.cf-color-picker .form-control[disabled],.cf-color-picker .form-control[readonly],.cf-color-picker fieldset[disabled] .form-control{cursor:not-allowed;background-color:#eee;opacity:1}.cf-color-picker .form-group{margin-bottom:15px}.cf-color-picker .input-group{position:relative;display:table;border-collapse:separate;max-width:120px}.cf-color-picker .input-group[class*=col-]{float:none;padding-left:0;padding-right:0}.cf-color-picker .input-group .form-control{position:relative;z-index:2;float:left;width:100%;margin-bottom:0}.cf-color-picker .input-group-lg>.form-control,.cf-color-picker .input-group-lg>.input-group-addon,.cf-color-picker .input-group-lg>.input-group-btn>.btn{height:46px;padding:10px 16px;font-size:18px;line-height:1.33;border-radius:6px}.cf-color-picker .input-group-sm>.form-control,.cf-color-picker .input-group-sm>.input-group-addon,.cf-color-picker .input-group-sm>.input-group-btn>.btn{height:30px;padding:5px 10px;font-size:12px;line-height:1.5;border-radius:3px}.cf-color-picker .input-group .form-control,.cf-color-picker .input-group-addon,.cf-color-picker .input-group-btn{display:table-cell}.cf-color-picker .input-group .form-control:not(:first-child):not(:last-child),.cf-color-picker .input-group-addon:not(:first-child):not(:last-child),.cf-color-picker .input-group-btn:not(:first-child):not(:last-child){border-radius:0}.cf-color-picker .input-group-addon,.cf-color-picker .input-group-btn{width:1%;white-space:nowrap;vertical-align:middle}.cf-color-picker .input-group-addon{padding:6px 12px;font-size:14px;font-weight:400;line-height:1;color:#555;text-align:center;background-color:#eee;border:1px solid #ccc;border-radius:4px}.cf-color-picker .text-hide,.table-striped .cfdatepicker table tr td,.table-striped .cfdatepicker table tr th{background-color:transparent}.cf-color-picker .input-group-addon.input-sm{padding:5px 10px;font-size:12px;border-radius:3px}.cf-color-picker .input-group-addon.input-lg{padding:10px 16px;font-size:18px;border-radius:6px}.cf-color-picker .input-group .form-control:first-child,.cf-color-picker .input-group-addon:first-child,.cf-color-picker .input-group-btn:first-child>.btn,.cf-color-picker .input-group-btn:first-child>.btn-group>.btn,.cf-color-picker .input-group-btn:first-child>.dropdown-toggle,.cf-color-picker .input-group-btn:last-child>.btn-group:not(:last-child)>.btn,.cf-color-picker .input-group-btn:last-child>.btn:not(:last-child):not(.dropdown-toggle){border-bottom-right-radius:0;border-top-right-radius:0}.cf-color-picker .input-group-addon:first-child{border-right:0}.cf-color-picker .input-group .form-control:last-child,.cf-color-picker .input-group-addon:last-child,.cf-color-picker .input-group-btn:first-child>.btn-group:not(:first-child)>.btn,.cf-color-picker .input-group-btn:first-child>.btn:not(:first-child),.cf-color-picker .input-group-btn:last-child>.btn,.cf-color-picker .input-group-btn:last-child>.btn-group>.btn,.cf-color-picker .input-group-btn:last-child>.dropdown-toggle{border-bottom-left-radius:0;border-top-left-radius:0}.cf-color-picker .input-group-addon:last-child{border-left:0}.cf-color-picker .input-group-btn{position:relative;font-size:0;white-space:nowrap}.cf-color-picker .input-group-btn>.btn{position:relative}.cf-color-picker .input-group-btn>.btn:active,.cf-color-picker .input-group-btn>.btn:focus,.cf-color-picker .input-group-btn>.btn:hover{z-index:2}.cf-color-picker .input-group-btn:first-child>.btn,.cf-color-picker .input-group-btn:first-child>.btn-group{margin-right:-1px}.cf-color-picker .clearfix:after,.cf-color-picker .clearfix:before,.cf-color-picker .form-horizontal .form-group:after,.cf-color-picker .form-horizontal .form-group:before{content:" ";display:table}.cf-color-picker .clearfix:after,.cf-color-picker .form-horizontal .form-group:after{clear:both}.cf-color-picker .center-block{display:block;margin-left:auto;margin-right:auto}.cf-color-picker .pull-right{float:right!important}.cf-color-picker .pull-left{float:left!important}.cf-color-picker .hide{display:none!important}.cf-color-picker .show{display:block!important}.cf-color-picker .invisible{visibility:hidden}.cf-color-picker .text-hide{font:0/0 a;color:transparent;text-shadow:none;border:0}.cf-color-picker .hidden{display:none!important;visibility:hidden!important}.cf-color-picker .affix{position:fixed}@-ms-viewport{width:device-width}.cf-color-picker .visible-lg,.cf-color-picker .visible-md,.cf-color-picker .visible-print,.cf-color-picker .visible-sm,.cf-color-picker .visible-xs{display:none!important}@media (max-width:767px){.cf-color-picker .visible-xs{display:block!important}.cf-color-picker table.visible-xs{display:table}.cf-color-picker tr.visible-xs{display:table-row!important}.cf-color-picker td.visible-xs,.cf-color-picker th.visible-xs{display:table-cell!important}}@media (min-width:768px) and (max-width:991px){.cf-color-picker .visible-sm{display:block!important}.cf-color-picker table.visible-sm{display:table}.cf-color-picker tr.visible-sm{display:table-row!important}.cf-color-picker td.visible-sm,.cf-color-picker th.visible-sm{display:table-cell!important}}@media (min-width:992px) and (max-width:1199px){.cf-color-picker .visible-md{display:block!important}.cf-color-picker table.visible-md{display:table}.cf-color-picker tr.visible-md{display:table-row!important}.cf-color-picker td.visible-md,.cf-color-picker th.visible-md{display:table-cell!important}}@media (min-width:1200px){.cf-color-picker .visible-lg{display:block!important}.cf-color-picker table.visible-lg{display:table}.cf-color-picker tr.visible-lg{display:table-row!important}.cf-color-picker td.visible-lg,.cf-color-picker th.visible-lg{display:table-cell!important}.cf-color-picker .hidden-lg{display:none!important}}@media (max-width:767px){.cf-color-picker .hidden-xs{display:none!important}}@media (min-width:768px) and (max-width:991px){.cf-color-picker .hidden-sm{display:none!important}}@media (min-width:992px) and (max-width:1199px){.cf-color-picker .hidden-md{display:none!important}}@media print{.cf-color-picker .visible-print{display:block!important}.cf-color-picker table.visible-print{display:table}.cf-color-picker tr.visible-print{display:table-row!important}.cf-color-picker td.visible-print,.cf-color-picker th.visible-print{display:table-cell!important}.cf-color-picker .hidden-print{display:none!important}}.cfdatepicker-dropdown:after,.cfdatepicker-dropdown:before{content:'';display:inline-block;border-top:0;position:absolute}.cfdatepicker{padding:4px;border-radius:4px;direction:ltr}.cfdatepicker-inline{width:220px}.cfdatepicker.cfdatepicker-rtl{direction:rtl}.cfdatepicker.cfdatepicker-rtl table tr td span{float:right}.cfdatepicker-dropdown{top:0;left:0}.cfdatepicker-dropdown:before{border-left:7px solid transparent;border-right:7px solid transparent;border-bottom:7px solid #ccc;border-bottom-color:rgba(0,0,0,.2)}.cfdatepicker-dropdown:after{border-left:6px solid transparent;border-right:6px solid transparent;border-bottom:6px solid #fff}.cfdatepicker-dropdown.cfdatepicker-orient-left:before{left:6px}.cfdatepicker-dropdown.cfdatepicker-orient-left:after{left:7px}.cfdatepicker-dropdown.cfdatepicker-orient-right:before{right:6px}.cfdatepicker-dropdown.cfdatepicker-orient-right:after{right:7px}.cfdatepicker-dropdown.cfdatepicker-orient-top:before{top:-7px}.cfdatepicker-dropdown.cfdatepicker-orient-top:after{top:-6px}.cfdatepicker-dropdown.cfdatepicker-orient-bottom:before{bottom:-7px;border-bottom:0;border-top:7px solid #999}.cfdatepicker-dropdown.cfdatepicker-orient-bottom:after{bottom:-6px;border-bottom:0;border-top:6px solid #fff}.cfdatepicker>div{display:none}.cfdatepicker.days div.cfdatepicker-days,.cfdatepicker.months div.cfdatepicker-months,.cfdatepicker.years div.cfdatepicker-years{display:block}.cfdatepicker table{border:0;width:auto;margin:0;-webkit-touch-callout:none;-khtml-user-select:none;user-select:none}.cfdatepicker table tr td,.cfdatepicker table tr th{text-align:center;width:10px;height:10px;border-radius:4px;border:none}.cfdatepicker table tr td.day.focused,.cfdatepicker table tr td.day:hover{background:#eee;cursor:pointer}.cfdatepicker table tr td.new,.cfdatepicker table tr td.old{color:#999}.cfdatepicker table tr td.disabled,.cfdatepicker table tr td.disabled:hover{background:0 0;color:#999;cursor:default}.cfdatepicker table tr td.today,.cfdatepicker table tr td.today.disabled,.cfdatepicker table tr td.today.disabled:hover,.cfdatepicker table tr td.today:hover{color:#000;background-color:#ffdb99;border-color:#ffb733}.cfdatepicker table tr td.today.active,.cfdatepicker table tr td.today.disabled.active,.cfdatepicker table tr td.today.disabled:active,.cfdatepicker table tr td.today.disabled:focus,.cfdatepicker table tr td.today.disabled:hover,.cfdatepicker table tr td.today.disabled:hover.active,.cfdatepicker table tr td.today.disabled:hover:active,.cfdatepicker table tr td.today.disabled:hover:focus,.cfdatepicker table tr td.today.disabled:hover:hover,.cfdatepicker table tr td.today:active,.cfdatepicker table tr td.today:focus,.cfdatepicker table tr td.today:hover,.cfdatepicker table tr td.today:hover.active,.cfdatepicker table tr td.today:hover:active,.cfdatepicker table tr td.today:hover:focus,.cfdatepicker table tr td.today:hover:hover,.open .dropdown-toggle.cfdatepicker table tr td.today,.open .dropdown-toggle.cfdatepicker table tr td.today.disabled,.open .dropdown-toggle.cfdatepicker table tr td.today.disabled:hover,.open .dropdown-toggle.cfdatepicker table tr td.today:hover{color:#000;background-color:#ffcd70;border-color:#f59e00}.cfdatepicker table tr td.today.active,.cfdatepicker table tr td.today.disabled.active,.cfdatepicker table tr td.today.disabled:active,.cfdatepicker table tr td.today.disabled:hover.active,.cfdatepicker table tr td.today.disabled:hover:active,.cfdatepicker table tr td.today:active,.cfdatepicker table tr td.today:hover.active,.cfdatepicker table tr td.today:hover:active,.open .dropdown-toggle.cfdatepicker table tr td.today,.open .dropdown-toggle.cfdatepicker table tr td.today.disabled,.open .dropdown-toggle.cfdatepicker table tr td.today.disabled:hover,.open .dropdown-toggle.cfdatepicker table tr td.today:hover{background-image:none}.cfdatepicker table tr td.today.disabled,.cfdatepicker table tr td.today.disabled.active,.cfdatepicker table tr td.today.disabled.disabled,.cfdatepicker table tr td.today.disabled.disabled.active,.cfdatepicker table tr td.today.disabled.disabled:active,.cfdatepicker table tr td.today.disabled.disabled:focus,.cfdatepicker table tr td.today.disabled.disabled:hover,.cfdatepicker table tr td.today.disabled:active,.cfdatepicker table tr td.today.disabled:focus,.cfdatepicker table tr td.today.disabled:hover,.cfdatepicker table tr td.today.disabled:hover.disabled,.cfdatepicker table tr td.today.disabled:hover.disabled.active,.cfdatepicker table tr td.today.disabled:hover.disabled:active,.cfdatepicker table tr td.today.disabled:hover.disabled:focus,.cfdatepicker table tr td.today.disabled:hover.disabled:hover,.cfdatepicker table tr td.today.disabled:hover[disabled],.cfdatepicker table tr td.today.disabled:hover[disabled].active,.cfdatepicker table tr td.today.disabled:hover[disabled]:active,.cfdatepicker table tr td.today.disabled:hover[disabled]:focus,.cfdatepicker table tr td.today.disabled:hover[disabled]:hover,.cfdatepicker table tr td.today.disabled[disabled],.cfdatepicker table tr td.today.disabled[disabled].active,.cfdatepicker table tr td.today.disabled[disabled]:active,.cfdatepicker table tr td.today.disabled[disabled]:focus,.cfdatepicker table tr td.today.disabled[disabled]:hover,.cfdatepicker table tr td.today:hover.disabled,.cfdatepicker table tr td.today:hover.disabled.active,.cfdatepicker table tr td.today:hover.disabled:active,.cfdatepicker table tr td.today:hover.disabled:focus,.cfdatepicker table tr td.today:hover.disabled:hover,.cfdatepicker table tr td.today:hover[disabled],.cfdatepicker table tr td.today:hover[disabled].active,.cfdatepicker table tr td.today:hover[disabled]:active,.cfdatepicker table tr td.today:hover[disabled]:focus,.cfdatepicker table tr td.today:hover[disabled]:hover,.cfdatepicker table tr td.today[disabled],.cfdatepicker table tr td.today[disabled].active,.cfdatepicker table tr td.today[disabled]:active,.cfdatepicker table tr td.today[disabled]:focus,.cfdatepicker table tr td.today[disabled]:hover,fieldset[disabled] .cfdatepicker table tr td.today,fieldset[disabled] .cfdatepicker table tr td.today.active,fieldset[disabled] .cfdatepicker table tr td.today.disabled,fieldset[disabled] .cfdatepicker table tr td.today.disabled.active,fieldset[disabled] .cfdatepicker table tr td.today.disabled:active,fieldset[disabled] .cfdatepicker table tr td.today.disabled:focus,fieldset[disabled] .cfdatepicker table tr td.today.disabled:hover,fieldset[disabled] .cfdatepicker table tr td.today.disabled:hover.active,fieldset[disabled] .cfdatepicker table tr td.today.disabled:hover:active,fieldset[disabled] .cfdatepicker table tr td.today.disabled:hover:focus,fieldset[disabled] .cfdatepicker table tr td.today.disabled:hover:hover,fieldset[disabled] .cfdatepicker table tr td.today:active,fieldset[disabled] .cfdatepicker table tr td.today:focus,fieldset[disabled] .cfdatepicker table tr td.today:hover,fieldset[disabled] .cfdatepicker table tr td.today:hover.active,fieldset[disabled] .cfdatepicker table tr td.today:hover:active,fieldset[disabled] .cfdatepicker table tr td.today:hover:focus,fieldset[disabled] .cfdatepicker table tr td.today:hover:hover{background-color:#ffdb99;border-color:#ffb733}.cfdatepicker table tr td.today:hover:hover{color:#000}.cfdatepicker table tr td.today.active:hover{color:#fff}.cfdatepicker table tr td.range,.cfdatepicker table tr td.range.disabled,.cfdatepicker table tr td.range.disabled:hover,.cfdatepicker table tr td.range:hover{background:#eee;border-radius:0}.cfdatepicker table tr td.active.active,.cfdatepicker table tr td.active.disabled.active,.cfdatepicker table tr td.active.disabled:active,.cfdatepicker table tr td.active.disabled:hover.active,.cfdatepicker table tr td.active.disabled:hover:active,.cfdatepicker table tr td.active:active,.cfdatepicker table tr td.active:hover.active,.cfdatepicker table tr td.active:hover:active,.cfdatepicker table tr td.range.today.active,.cfdatepicker table tr td.range.today.disabled.active,.cfdatepicker table tr td.range.today.disabled:active,.cfdatepicker table tr td.range.today.disabled:hover.active,.cfdatepicker table tr td.range.today.disabled:hover:active,.cfdatepicker table tr td.range.today:active,.cfdatepicker table tr td.range.today:hover.active,.cfdatepicker table tr td.range.today:hover:active,.cfdatepicker table tr td.selected.active,.cfdatepicker table tr td.selected.disabled.active,.cfdatepicker table tr td.selected.disabled:active,.cfdatepicker table tr td.selected.disabled:hover.active,.cfdatepicker table tr td.selected.disabled:hover:active,.cfdatepicker table tr td.selected:active,.cfdatepicker table tr td.selected:hover.active,.cfdatepicker table tr td.selected:hover:active,.open .dropdown-toggle.cfdatepicker table tr td.active,.open .dropdown-toggle.cfdatepicker table tr td.active.disabled,.open .dropdown-toggle.cfdatepicker table tr td.active.disabled:hover,.open .dropdown-toggle.cfdatepicker table tr td.active:hover,.open .dropdown-toggle.cfdatepicker table tr td.range.today,.open .dropdown-toggle.cfdatepicker table tr td.range.today.disabled,.open .dropdown-toggle.cfdatepicker table tr td.range.today.disabled:hover,.open .dropdown-toggle.cfdatepicker table tr td.range.today:hover,.open .dropdown-toggle.cfdatepicker table tr td.selected,.open .dropdown-toggle.cfdatepicker table tr td.selected.disabled,.open .dropdown-toggle.cfdatepicker table tr td.selected.disabled:hover,.open .dropdown-toggle.cfdatepicker table tr td.selected:hover{background-image:none}.cfdatepicker table tr td.range.today,.cfdatepicker table tr td.range.today.disabled,.cfdatepicker table tr td.range.today.disabled:hover,.cfdatepicker table tr td.range.today:hover{color:#000;background-color:#f7ca77;border-color:#f1a417;border-radius:0}.cfdatepicker table tr td.range.today.active,.cfdatepicker table tr td.range.today.disabled.active,.cfdatepicker table tr td.range.today.disabled:active,.cfdatepicker table tr td.range.today.disabled:focus,.cfdatepicker table tr td.range.today.disabled:hover,.cfdatepicker table tr td.range.today.disabled:hover.active,.cfdatepicker table tr td.range.today.disabled:hover:active,.cfdatepicker table tr td.range.today.disabled:hover:focus,.cfdatepicker table tr td.range.today.disabled:hover:hover,.cfdatepicker table tr td.range.today:active,.cfdatepicker table tr td.range.today:focus,.cfdatepicker table tr td.range.today:hover,.cfdatepicker table tr td.range.today:hover.active,.cfdatepicker table tr td.range.today:hover:active,.cfdatepicker table tr td.range.today:hover:focus,.cfdatepicker table tr td.range.today:hover:hover,.open .dropdown-toggle.cfdatepicker table tr td.range.today,.open .dropdown-toggle.cfdatepicker table tr td.range.today.disabled,.open .dropdown-toggle.cfdatepicker table tr td.range.today.disabled:hover,.open .dropdown-toggle.cfdatepicker table tr td.range.today:hover{color:#000;background-color:#f4bb51;border-color:#bf800c}.cfdatepicker table tr td.range.today.disabled,.cfdatepicker table tr td.range.today.disabled.active,.cfdatepicker table tr td.range.today.disabled.disabled,.cfdatepicker table tr td.range.today.disabled.disabled.active,.cfdatepicker table tr td.range.today.disabled.disabled:active,.cfdatepicker table tr td.range.today.disabled.disabled:focus,.cfdatepicker table tr td.range.today.disabled.disabled:hover,.cfdatepicker table tr td.range.today.disabled:active,.cfdatepicker table tr td.range.today.disabled:focus,.cfdatepicker table tr td.range.today.disabled:hover,.cfdatepicker table tr td.range.today.disabled:hover.disabled,.cfdatepicker table tr td.range.today.disabled:hover.disabled.active,.cfdatepicker table tr td.range.today.disabled:hover.disabled:active,.cfdatepicker table tr td.range.today.disabled:hover.disabled:focus,.cfdatepicker table tr td.range.today.disabled:hover.disabled:hover,.cfdatepicker table tr td.range.today.disabled:hover[disabled],.cfdatepicker table tr td.range.today.disabled:hover[disabled].active,.cfdatepicker table tr td.range.today.disabled:hover[disabled]:active,.cfdatepicker table tr td.range.today.disabled:hover[disabled]:focus,.cfdatepicker table tr td.range.today.disabled:hover[disabled]:hover,.cfdatepicker table tr td.range.today.disabled[disabled],.cfdatepicker table tr td.range.today.disabled[disabled].active,.cfdatepicker table tr td.range.today.disabled[disabled]:active,.cfdatepicker table tr td.range.today.disabled[disabled]:focus,.cfdatepicker table tr td.range.today.disabled[disabled]:hover,.cfdatepicker table tr td.range.today:hover.disabled,.cfdatepicker table tr td.range.today:hover.disabled.active,.cfdatepicker table tr td.range.today:hover.disabled:active,.cfdatepicker table tr td.range.today:hover.disabled:focus,.cfdatepicker table tr td.range.today:hover.disabled:hover,.cfdatepicker table tr td.range.today:hover[disabled],.cfdatepicker table tr td.range.today:hover[disabled].active,.cfdatepicker table tr td.range.today:hover[disabled]:active,.cfdatepicker table tr td.range.today:hover[disabled]:focus,.cfdatepicker table tr td.range.today:hover[disabled]:hover,.cfdatepicker table tr td.range.today[disabled],.cfdatepicker table tr td.range.today[disabled].active,.cfdatepicker table tr td.range.today[disabled]:active,.cfdatepicker table tr td.range.today[disabled]:focus,.cfdatepicker table tr td.range.today[disabled]:hover,fieldset[disabled] .cfdatepicker table tr td.range.today,fieldset[disabled] .cfdatepicker table tr td.range.today.active,fieldset[disabled] .cfdatepicker table tr td.range.today.disabled,fieldset[disabled] .cfdatepicker table tr td.range.today.disabled.active,fieldset[disabled] .cfdatepicker table tr td.range.today.disabled:active,fieldset[disabled] .cfdatepicker table tr td.range.today.disabled:focus,fieldset[disabled] .cfdatepicker table tr td.range.today.disabled:hover,fieldset[disabled] .cfdatepicker table tr td.range.today.disabled:hover.active,fieldset[disabled] .cfdatepicker table tr td.range.today.disabled:hover:active,fieldset[disabled] .cfdatepicker table tr td.range.today.disabled:hover:focus,fieldset[disabled] .cfdatepicker table tr td.range.today.disabled:hover:hover,fieldset[disabled] .cfdatepicker table tr td.range.today:active,fieldset[disabled] .cfdatepicker table tr td.range.today:focus,fieldset[disabled] .cfdatepicker table tr td.range.today:hover,fieldset[disabled] .cfdatepicker table tr td.range.today:hover.active,fieldset[disabled] .cfdatepicker table tr td.range.today:hover:active,fieldset[disabled] .cfdatepicker table tr td.range.today:hover:focus,fieldset[disabled] .cfdatepicker table tr td.range.today:hover:hover{background-color:#f7ca77;border-color:#f1a417}.cfdatepicker table tr td.selected,.cfdatepicker table tr td.selected.disabled,.cfdatepicker table tr td.selected.disabled:hover,.cfdatepicker table tr td.selected:hover{color:#fff;background-color:#999;border-color:#555;text-shadow:0 -1px 0 rgba(0,0,0,.25)}.cfdatepicker table tr td.selected.active,.cfdatepicker table tr td.selected.disabled.active,.cfdatepicker table tr td.selected.disabled:active,.cfdatepicker table tr td.selected.disabled:focus,.cfdatepicker table tr td.selected.disabled:hover,.cfdatepicker table tr td.selected.disabled:hover.active,.cfdatepicker table tr td.selected.disabled:hover:active,.cfdatepicker table tr td.selected.disabled:hover:focus,.cfdatepicker table tr td.selected.disabled:hover:hover,.cfdatepicker table tr td.selected:active,.cfdatepicker table tr td.selected:focus,.cfdatepicker table tr td.selected:hover,.cfdatepicker table tr td.selected:hover.active,.cfdatepicker table tr td.selected:hover:active,.cfdatepicker table tr td.selected:hover:focus,.cfdatepicker table tr td.selected:hover:hover,.open .dropdown-toggle.cfdatepicker table tr td.selected,.open .dropdown-toggle.cfdatepicker table tr td.selected.disabled,.open .dropdown-toggle.cfdatepicker table tr td.selected.disabled:hover,.open .dropdown-toggle.cfdatepicker table tr td.selected:hover{color:#fff;background-color:#858585;border-color:#373737}.cfdatepicker table tr td.selected.disabled,.cfdatepicker table tr td.selected.disabled.active,.cfdatepicker table tr td.selected.disabled.disabled,.cfdatepicker table tr td.selected.disabled.disabled.active,.cfdatepicker table tr td.selected.disabled.disabled:active,.cfdatepicker table tr td.selected.disabled.disabled:focus,.cfdatepicker table tr td.selected.disabled.disabled:hover,.cfdatepicker table tr td.selected.disabled:active,.cfdatepicker table tr td.selected.disabled:focus,.cfdatepicker table tr td.selected.disabled:hover,.cfdatepicker table tr td.selected.disabled:hover.disabled,.cfdatepicker table tr td.selected.disabled:hover.disabled.active,.cfdatepicker table tr td.selected.disabled:hover.disabled:active,.cfdatepicker table tr td.selected.disabled:hover.disabled:focus,.cfdatepicker table tr td.selected.disabled:hover.disabled:hover,.cfdatepicker table tr td.selected.disabled:hover[disabled],.cfdatepicker table tr td.selected.disabled:hover[disabled].active,.cfdatepicker table tr td.selected.disabled:hover[disabled]:active,.cfdatepicker table tr td.selected.disabled:hover[disabled]:focus,.cfdatepicker table tr td.selected.disabled:hover[disabled]:hover,.cfdatepicker table tr td.selected.disabled[disabled],.cfdatepicker table tr td.selected.disabled[disabled].active,.cfdatepicker table tr td.selected.disabled[disabled]:active,.cfdatepicker table tr td.selected.disabled[disabled]:focus,.cfdatepicker table tr td.selected.disabled[disabled]:hover,.cfdatepicker table tr td.selected:hover.disabled,.cfdatepicker table tr td.selected:hover.disabled.active,.cfdatepicker table tr td.selected:hover.disabled:active,.cfdatepicker table tr td.selected:hover.disabled:focus,.cfdatepicker table tr td.selected:hover.disabled:hover,.cfdatepicker table tr td.selected:hover[disabled],.cfdatepicker table tr td.selected:hover[disabled].active,.cfdatepicker table tr td.selected:hover[disabled]:active,.cfdatepicker table tr td.selected:hover[disabled]:focus,.cfdatepicker table tr td.selected:hover[disabled]:hover,.cfdatepicker table tr td.selected[disabled],.cfdatepicker table tr td.selected[disabled].active,.cfdatepicker table tr td.selected[disabled]:active,.cfdatepicker table tr td.selected[disabled]:focus,.cfdatepicker table tr td.selected[disabled]:hover,fieldset[disabled] .cfdatepicker table tr td.selected,fieldset[disabled] .cfdatepicker table tr td.selected.active,fieldset[disabled] .cfdatepicker table tr td.selected.disabled,fieldset[disabled] .cfdatepicker table tr td.selected.disabled.active,fieldset[disabled] .cfdatepicker table tr td.selected.disabled:active,fieldset[disabled] .cfdatepicker table tr td.selected.disabled:focus,fieldset[disabled] .cfdatepicker table tr td.selected.disabled:hover,fieldset[disabled] .cfdatepicker table tr td.selected.disabled:hover.active,fieldset[disabled] .cfdatepicker table tr td.selected.disabled:hover:active,fieldset[disabled] .cfdatepicker table tr td.selected.disabled:hover:focus,fieldset[disabled] .cfdatepicker table tr td.selected.disabled:hover:hover,fieldset[disabled] .cfdatepicker table tr td.selected:active,fieldset[disabled] .cfdatepicker table tr td.selected:focus,fieldset[disabled] .cfdatepicker table tr td.selected:hover,fieldset[disabled] .cfdatepicker table tr td.selected:hover.active,fieldset[disabled] .cfdatepicker table tr td.selected:hover:active,fieldset[disabled] .cfdatepicker table tr td.selected:hover:focus,fieldset[disabled] .cfdatepicker table tr td.selected:hover:hover{background-color:#999;border-color:#555}.cfdatepicker table tr td.active,.cfdatepicker table tr td.active.disabled,.cfdatepicker table tr td.active.disabled:hover,.cfdatepicker table tr td.active:hover{color:#fff;background-color:#428bca;border-color:#357ebd;text-shadow:0 -1px 0 rgba(0,0,0,.25)}.cfdatepicker table tr td.active.active,.cfdatepicker table tr td.active.disabled.active,.cfdatepicker table tr td.active.disabled:active,.cfdatepicker table tr td.active.disabled:focus,.cfdatepicker table tr td.active.disabled:hover,.cfdatepicker table tr td.active.disabled:hover.active,.cfdatepicker table tr td.active.disabled:hover:active,.cfdatepicker table tr td.active.disabled:hover:focus,.cfdatepicker table tr td.active.disabled:hover:hover,.cfdatepicker table tr td.active:active,.cfdatepicker table tr td.active:focus,.cfdatepicker table tr td.active:hover,.cfdatepicker table tr td.active:hover.active,.cfdatepicker table tr td.active:hover:active,.cfdatepicker table tr td.active:hover:focus,.cfdatepicker table tr td.active:hover:hover,.open .dropdown-toggle.cfdatepicker table tr td.active,.open .dropdown-toggle.cfdatepicker table tr td.active.disabled,.open .dropdown-toggle.cfdatepicker table tr td.active.disabled:hover,.open .dropdown-toggle.cfdatepicker table tr td.active:hover{color:#fff;background-color:#3276b1;border-color:#285e8e}.cfdatepicker table tr td.active.disabled,.cfdatepicker table tr td.active.disabled.active,.cfdatepicker table tr td.active.disabled.disabled,.cfdatepicker table tr td.active.disabled.disabled.active,.cfdatepicker table tr td.active.disabled.disabled:active,.cfdatepicker table tr td.active.disabled.disabled:focus,.cfdatepicker table tr td.active.disabled.disabled:hover,.cfdatepicker table tr td.active.disabled:active,.cfdatepicker table tr td.active.disabled:focus,.cfdatepicker table tr td.active.disabled:hover,.cfdatepicker table tr td.active.disabled:hover.disabled,.cfdatepicker table tr td.active.disabled:hover.disabled.active,.cfdatepicker table tr td.active.disabled:hover.disabled:active,.cfdatepicker table tr td.active.disabled:hover.disabled:focus,.cfdatepicker table tr td.active.disabled:hover.disabled:hover,.cfdatepicker table tr td.active.disabled:hover[disabled],.cfdatepicker table tr td.active.disabled:hover[disabled].active,.cfdatepicker table tr td.active.disabled:hover[disabled]:active,.cfdatepicker table tr td.active.disabled:hover[disabled]:focus,.cfdatepicker table tr td.active.disabled:hover[disabled]:hover,.cfdatepicker table tr td.active.disabled[disabled],.cfdatepicker table tr td.active.disabled[disabled].active,.cfdatepicker table tr td.active.disabled[disabled]:active,.cfdatepicker table tr td.active.disabled[disabled]:focus,.cfdatepicker table tr td.active.disabled[disabled]:hover,.cfdatepicker table tr td.active:hover.disabled,.cfdatepicker table tr td.active:hover.disabled.active,.cfdatepicker table tr td.active:hover.disabled:active,.cfdatepicker table tr td.active:hover.disabled:focus,.cfdatepicker table tr td.active:hover.disabled:hover,.cfdatepicker table tr td.active:hover[disabled],.cfdatepicker table tr td.active:hover[disabled].active,.cfdatepicker table tr td.active:hover[disabled]:active,.cfdatepicker table tr td.active:hover[disabled]:focus,.cfdatepicker table tr td.active:hover[disabled]:hover,.cfdatepicker table tr td.active[disabled],.cfdatepicker table tr td.active[disabled].active,.cfdatepicker table tr td.active[disabled]:active,.cfdatepicker table tr td.active[disabled]:focus,.cfdatepicker table tr td.active[disabled]:hover,fieldset[disabled] .cfdatepicker table tr td.active,fieldset[disabled] .cfdatepicker table tr td.active.active,fieldset[disabled] .cfdatepicker table tr td.active.disabled,fieldset[disabled] .cfdatepicker table tr td.active.disabled.active,fieldset[disabled] .cfdatepicker table tr td.active.disabled:active,fieldset[disabled] .cfdatepicker table tr td.active.disabled:focus,fieldset[disabled] .cfdatepicker table tr td.active.disabled:hover,fieldset[disabled] .cfdatepicker table tr td.active.disabled:hover.active,fieldset[disabled] .cfdatepicker table tr td.active.disabled:hover:active,fieldset[disabled] .cfdatepicker table tr td.active.disabled:hover:focus,fieldset[disabled] .cfdatepicker table tr td.active.disabled:hover:hover,fieldset[disabled] .cfdatepicker table tr td.active:active,fieldset[disabled] .cfdatepicker table tr td.active:focus,fieldset[disabled] .cfdatepicker table tr td.active:hover,fieldset[disabled] .cfdatepicker table tr td.active:hover.active,fieldset[disabled] .cfdatepicker table tr td.active:hover:active,fieldset[disabled] .cfdatepicker table tr td.active:hover:focus,fieldset[disabled] .cfdatepicker table tr td.active:hover:hover{background-color:#428bca;border-color:#357ebd}.cfdatepicker table tr td span{display:block;width:23%;height:54px;line-height:54px;float:left;margin:1%;cursor:pointer;border-radius:4px}.cfdatepicker table tr td span:hover{background:#eee}.cfdatepicker table tr td span.disabled,.cfdatepicker table tr td span.disabled:hover{background:0 0;color:#999;cursor:default}.cfdatepicker table tr td span.active,.cfdatepicker table tr td span.active.disabled,.cfdatepicker table tr td span.active.disabled:hover,.cfdatepicker table tr td span.active:hover{color:#fff;background-color:#428bca;border-color:#357ebd;text-shadow:0 -1px 0 rgba(0,0,0,.25)}.cfdatepicker table tr td span.active.active,.cfdatepicker table tr td span.active.disabled.active,.cfdatepicker table tr td span.active.disabled:active,.cfdatepicker table tr td span.active.disabled:focus,.cfdatepicker table tr td span.active.disabled:hover,.cfdatepicker table tr td span.active.disabled:hover.active,.cfdatepicker table tr td span.active.disabled:hover:active,.cfdatepicker table tr td span.active.disabled:hover:focus,.cfdatepicker table tr td span.active.disabled:hover:hover,.cfdatepicker table tr td span.active:active,.cfdatepicker table tr td span.active:focus,.cfdatepicker table tr td span.active:hover,.cfdatepicker table tr td span.active:hover.active,.cfdatepicker table tr td span.active:hover:active,.cfdatepicker table tr td span.active:hover:focus,.cfdatepicker table tr td span.active:hover:hover,.open .dropdown-toggle.cfdatepicker table tr td span.active,.open .dropdown-toggle.cfdatepicker table tr td span.active.disabled,.open .dropdown-toggle.cfdatepicker table tr td span.active.disabled:hover,.open .dropdown-toggle.cfdatepicker table tr td span.active:hover{color:#fff;background-color:#3276b1;border-color:#285e8e}.cfdatepicker table tr td span.active.active,.cfdatepicker table tr td span.active.disabled.active,.cfdatepicker table tr td span.active.disabled:active,.cfdatepicker table tr td span.active.disabled:hover.active,.cfdatepicker table tr td span.active.disabled:hover:active,.cfdatepicker table tr td span.active:active,.cfdatepicker table tr td span.active:hover.active,.cfdatepicker table tr td span.active:hover:active,.open .dropdown-toggle.cfdatepicker table tr td span.active,.open .dropdown-toggle.cfdatepicker table tr td span.active.disabled,.open .dropdown-toggle.cfdatepicker table tr td span.active.disabled:hover,.open .dropdown-toggle.cfdatepicker table tr td span.active:hover{background-image:none}.cfdatepicker table tr td span.active.disabled,.cfdatepicker table tr td span.active.disabled.active,.cfdatepicker table tr td span.active.disabled.disabled,.cfdatepicker table tr td span.active.disabled.disabled.active,.cfdatepicker table tr td span.active.disabled.disabled:active,.cfdatepicker table tr td span.active.disabled.disabled:focus,.cfdatepicker table tr td span.active.disabled.disabled:hover,.cfdatepicker table tr td span.active.disabled:active,.cfdatepicker table tr td span.active.disabled:focus,.cfdatepicker table tr td span.active.disabled:hover,.cfdatepicker table tr td span.active.disabled:hover.disabled,.cfdatepicker table tr td span.active.disabled:hover.disabled.active,.cfdatepicker table tr td span.active.disabled:hover.disabled:active,.cfdatepicker table tr td span.active.disabled:hover.disabled:focus,.cfdatepicker table tr td span.active.disabled:hover.disabled:hover,.cfdatepicker table tr td span.active.disabled:hover[disabled],.cfdatepicker table tr td span.active.disabled:hover[disabled].active,.cfdatepicker table tr td span.active.disabled:hover[disabled]:active,.cfdatepicker table tr td span.active.disabled:hover[disabled]:focus,.cfdatepicker table tr td span.active.disabled:hover[disabled]:hover,.cfdatepicker table tr td span.active.disabled[disabled],.cfdatepicker table tr td span.active.disabled[disabled].active,.cfdatepicker table tr td span.active.disabled[disabled]:active,.cfdatepicker table tr td span.active.disabled[disabled]:focus,.cfdatepicker table tr td span.active.disabled[disabled]:hover,.cfdatepicker table tr td span.active:hover.disabled,.cfdatepicker table tr td span.active:hover.disabled.active,.cfdatepicker table tr td span.active:hover.disabled:active,.cfdatepicker table tr td span.active:hover.disabled:focus,.cfdatepicker table tr td span.active:hover.disabled:hover,.cfdatepicker table tr td span.active:hover[disabled],.cfdatepicker table tr td span.active:hover[disabled].active,.cfdatepicker table tr td span.active:hover[disabled]:active,.cfdatepicker table tr td span.active:hover[disabled]:focus,.cfdatepicker table tr td span.active:hover[disabled]:hover,.cfdatepicker table tr td span.active[disabled],.cfdatepicker table tr td span.active[disabled].active,.cfdatepicker table tr td span.active[disabled]:active,.cfdatepicker table tr td span.active[disabled]:focus,.cfdatepicker table tr td span.active[disabled]:hover,fieldset[disabled] .cfdatepicker table tr td span.active,fieldset[disabled] .cfdatepicker table tr td span.active.active,fieldset[disabled] .cfdatepicker table tr td span.active.disabled,fieldset[disabled] .cfdatepicker table tr td span.active.disabled.active,fieldset[disabled] .cfdatepicker table tr td span.active.disabled:active,fieldset[disabled] .cfdatepicker table tr td span.active.disabled:focus,fieldset[disabled] .cfdatepicker table tr td span.active.disabled:hover,fieldset[disabled] .cfdatepicker table tr td span.active.disabled:hover.active,fieldset[disabled] .cfdatepicker table tr td span.active.disabled:hover:active,fieldset[disabled] .cfdatepicker table tr td span.active.disabled:hover:focus,fieldset[disabled] .cfdatepicker table tr td span.active.disabled:hover:hover,fieldset[disabled] .cfdatepicker table tr td span.active:active,fieldset[disabled] .cfdatepicker table tr td span.active:focus,fieldset[disabled] .cfdatepicker table tr td span.active:hover,fieldset[disabled] .cfdatepicker table tr td span.active:hover.active,fieldset[disabled] .cfdatepicker table tr td span.active:hover:active,fieldset[disabled] .cfdatepicker table tr td span.active:hover:focus,fieldset[disabled] .cfdatepicker table tr td span.active:hover:hover{background-color:#428bca;border-color:#357ebd}.cfdatepicker table tr td span.new,.cfdatepicker table tr td span.old{color:#999}.cfdatepicker th.cfdatepicker-switch{width:145px}.cfdatepicker tfoot tr th,.cfdatepicker thead tr:first-child th{cursor:pointer}.cfdatepicker tfoot tr th:hover,.cfdatepicker thead tr:first-child th:hover{background:#eee}.cfdatepicker .cw{font-size:10px;width:12px;padding:0 2px 0 5px;vertical-align:middle}.cfdatepicker thead tr:first-child th.cw{cursor:default;background-color:transparent}.input-group.date .input-group-addon i{cursor:pointer;width:16px;height:16px}.input-daterange input{text-align:center}.input-daterange input:first-child{border-radius:3px 0 0 3px}.input-daterange input:last-child{border-radius:0 3px 3px 0}.input-daterange .input-group-addon{width:auto;min-width:16px;padding:4px 5px;font-weight:400;line-height:1.42857143;text-align:center;text-shadow:0 1px 0 #fff;vertical-align:middle;background-color:#eee;border:solid #ccc;border-width:1px 0;margin-left:-5px;margin-right:-5px}.cfdatepicker.dropdown-menu{position:absolute;top:100%;left:0;z-index:1000;float:left;display:none;min-width:160px;list-style:none;background-color:#fff;border:1px solid #ccc;border:1px solid rgba(0,0,0,.2);border-radius:5px;-webkit-box-shadow:0 5px 10px rgba(0,0,0,.2);-moz-box-shadow:0 5px 10px rgba(0,0,0,.2);box-shadow:0 5px 10px rgba(0,0,0,.2);-webkit-background-clip:padding-box;-moz-background-clip:padding;background-clip:padding-box;color:#333;font-family:"Helvetica Neue",Helvetica,Arial,sans-serif;font-size:13px;line-height:1.42857143}.cfdatepicker.dropdown-menu td,.cfdatepicker.dropdown-menu th{padding:4px 5px}.image-thumb{margin-left:63px;padding:6px 0 6px 6px}.image-picker-content.image-thumb-lrg{margin-bottom:6px}.image-picker-side-bar{float:left;margin-left:-68px;width:62px;max-width:100%}.image-thumb-lrg .image-picker-side-bar{background:#F6F6F6;border:1px solid #DFDFDF;float:none;margin:0 0 6px;padding:6px 6px 2px;text-align:center;width:auto}.image-picker-side-bar>img{border:1px solid #DFDFDF;width:62px}.image-thumb-lrg .image-picker-side-bar>img{-moz-box-sizing:border-box;box-sizing:border-box;max-width:100%;text-align:center;width:auto}.image-thumb .image-picker-main-content{margin-right:6px}.button.image-picker-button{margin:7px 0 0;width:110px;display:inline-block}.button.button-primary.image-picker-button{float:right;margin-left:6px;width:80px}.image-picker-main-content select{width:100%}.image-picker-sizer:disabled{opacity:.7;box-shadow:none;color:#A1A1A1}.button-primary.image-picker-button.image-picker-button-solo,.button.image-picker-button.image-picker-button-solo{width:170px;margin-top:0}.button-primary.image-picker-button.image-picker-button-solo{margin-top:7px;margin-left:0;float:none}.image-thumb-lrg .button.image-picker-button.cu-image-picker.image-picker-button-solo{width:120px}.image-thumb-lrg .button.button-primary.image-picker-button.cu-image-remover.image-picker-button-solo{float:right;margin:0 0 0 6px;width:auto}.cf-toggle-switch .btn-group>.btn-group,.cf-toggle-switch .btn-toolbar .btn-group,.cf-toggle-switch .btn-toolbar .input-group{float:left}.image-thumb-lrg .button.button-primary.image-picker-button.cu-image-remover{width:45%}input.cu-image-picker-file-select[type=file]{display:none}.rangeslider,.rangeslider__fill{background:#e6e6e6;display:block;height:8px;width:100%;-webkit-border-radius:10px;-moz-border-radius:10px;-ms-border-radius:10px;-o-border-radius:10px;border-radius:10px}.rangeslider__handle,.toggle_option_row input{display:inline-block}.rangeslider{position:relative}.rangeslider--disabled{filter:alpha(Opacity=40);opacity:.4}.rangeslider__fill{background:#0f0;position:absolute;top:0}.rangeslider__handle{background:#fff;border:1px solid #ccc;cursor:pointer;width:18px;height:18px;position:absolute;top:-5px;-webkit-border-radius:50%;-moz-border-radius:50%;-ms-border-radius:50%;-o-border-radius:50%;border-radius:50%}input[type=range]:focus+.rangeslider .rangeslider__handle{-webkit-box-shadow:0 0 3px rgba(100,100,100,.9);-moz-box-shadow:0 0 3px rgba(100,100,100,.9);box-shadow:0 0 3px rgba(100,100,100,.9)}.recaptchatable #recaptcha_response_field{height:21px!important}.toggle_option_row{margin:4px 0}.toggle_option_row .dashicons-sort{cursor:move}.toggle_option_row .toggle_label_field,.toggle_option_row .toggle_value_field{width:136px;line-height:20px}.toggle_option_preview .button{border-radius:0;margin-right:-5px}.toggle_option_preview .button:first-child{border-radius:3px 0 0 3px}.toggle_option_preview .button:last-child{border-radius:0 3px 3px 0}.toggle_option_preview.toggle_vertical .button{width:100%}.toggle_option_preview.toggle_vertical .button:first-child{border-radius:3px 3px 0 0}.toggle_option_preview.toggle_vertical .button:last-child{border-radius:0 0 3px 3px}.cf-toggle-switch html{font-family:sans-serif}.cf-toggle-switch body{margin:0}.cf-toggle-switch article,.cf-toggle-switch aside,.cf-toggle-switch details,.cf-toggle-switch figcaption,.cf-toggle-switch figure,.cf-toggle-switch footer,.cf-toggle-switch header,.cf-toggle-switch hgroup,.cf-toggle-switch main,.cf-toggle-switch nav,.cf-toggle-switch section,.cf-toggle-switch summary{display:block}.cf-toggle-switch audio,.cf-toggle-switch canvas,.cf-toggle-switch progress,.cf-toggle-switch video{display:inline-block;vertical-align:baseline}.cf-toggle-switch audio:not([controls]){display:none;height:0}.cf-toggle-switch [hidden],.cf-toggle-switch template{display:none}.cf-toggle-switch a{background:0 0}.cf-toggle-switch a:active,.cf-toggle-switch a:hover{outline:0}.cf-toggle-switch abbr[title]{border-bottom:1px dotted}.cf-toggle-switch b,.cf-toggle-switch strong{font-weight:700}.cf-toggle-switch dfn{font-style:italic}.cf-toggle-switch h1{font-size:2em;margin:.67em 0}.cf-toggle-switch mark{background:#ff0;color:#000}.cf-toggle-switch .btn,.cf-toggle-switch .btn-danger.active,.cf-toggle-switch .btn-danger:active,.cf-toggle-switch .btn-default.active,.cf-toggle-switch .btn-default:active,.cf-toggle-switch .btn-info.active,.cf-toggle-switch .btn-info:active,.cf-toggle-switch .btn-primary.active,.cf-toggle-switch .btn-primary:active,.cf-toggle-switch .btn-success.active,.cf-toggle-switch .btn-success:active,.cf-toggle-switch .btn-warning.active,.cf-toggle-switch .btn-warning:active,.cf-toggle-switch .open .dropdown-toggle.btn-danger,.cf-toggle-switch .open .dropdown-toggle.btn-default,.cf-toggle-switch .open .dropdown-toggle.btn-info,.cf-toggle-switch .open .dropdown-toggle.btn-primary,.cf-toggle-switch .open .dropdown-toggle.btn-success,.cf-toggle-switch .open .dropdown-toggle.btn-warning{background-image:none}.cf-toggle-switch small{font-size:80%}.cf-toggle-switch sub,.cf-toggle-switch sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}.cf-toggle-switch sup{top:-.5em}.cf-toggle-switch sub{bottom:-.25em}.cf-toggle-switch img{border:0}.cf-toggle-switch figure{margin:1em 40px}.cf-toggle-switch hr{-moz-box-sizing:content-box;box-sizing:content-box;height:0}.cf-toggle-switch pre{overflow:auto}.cf-toggle-switch code,.cf-toggle-switch kbd,.cf-toggle-switch pre,.cf-toggle-switch samp{font-family:monospace,monospace;font-size:1em}.cf-toggle-switch button,.cf-toggle-switch input,.cf-toggle-switch optgroup,.cf-toggle-switch select,.cf-toggle-switch textarea{color:inherit;font:inherit;margin:0}.cf-toggle-switch button{overflow:visible}.cf-toggle-switch button,.cf-toggle-switch html input[type=button],.cf-toggle-switch input[type=reset],.cf-toggle-switch input[type=submit]{-webkit-appearance:button;cursor:pointer}.cf-toggle-switch button[disabled],.cf-toggle-switch html input[disabled]{cursor:default}.cf-toggle-switch button::-moz-focus-inner,.cf-toggle-switch input::-moz-focus-inner{border:0;padding:0}.cf-toggle-switch input{line-height:normal}.cf-toggle-switch input[type=checkbox],.cf-toggle-switch input[type=radio]{box-sizing:border-box;padding:0}.cf-toggle-switch input[type=number]::-webkit-inner-spin-button,.cf-toggle-switch input[type=number]::-webkit-outer-spin-button{height:auto}.cf-toggle-switch input[type=search]{-webkit-appearance:textfield;-moz-box-sizing:content-box;-webkit-box-sizing:content-box;box-sizing:content-box}.cf-toggle-switch input[type=search]::-webkit-search-cancel-button,.cf-toggle-switch input[type=search]::-webkit-search-decoration{-webkit-appearance:none}.cf-toggle-switch fieldset{border:1px solid silver;margin:0 2px;padding:.35em .625em .75em}.cf-toggle-switch legend{border:0;padding:0}.cf-toggle-switch textarea{overflow:auto}.cf-toggle-switch optgroup{font-weight:700}.cf-toggle-switch table{border-collapse:collapse;border-spacing:0}.cf-toggle-switch td,.cf-toggle-switch th{padding:0}.cf-toggle-switch .btn{display:inline-block;margin-bottom:0;font-weight:400;text-align:center;vertical-align:middle;cursor:pointer;border:1px solid transparent;white-space:nowrap;padding:6px 12px;font-size:14px;line-height:1.42857143;border-radius:4px;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}.cf-toggle-switch .btn.active:focus,.cf-toggle-switch .btn:active:focus,.cf-toggle-switch .btn:focus{outline:dotted thin;outline:-webkit-focus-ring-color auto 5px;outline-offset:-2px}.cf-toggle-switch .btn-group .dropdown-toggle:active,.cf-toggle-switch .btn-group-vertical>.btn:focus,.cf-toggle-switch .btn-group.open .dropdown-toggle,.cf-toggle-switch .btn-group>.btn:focus{outline:0}.cf-toggle-switch .btn:focus,.cf-toggle-switch .btn:hover{color:#333;text-decoration:none}.cf-toggle-switch .btn.active,.cf-toggle-switch .btn:active{outline:0;background-image:none;-webkit-box-shadow:inset 0 3px 5px rgba(0,0,0,.125);box-shadow:inset 0 3px 5px rgba(0,0,0,.125)}.cf-toggle-switch .btn.disabled,.cf-toggle-switch .btn[disabled],.cf-toggle-switch fieldset[disabled] .btn{cursor:not-allowed;pointer-events:none;opacity:.65;filter:alpha(opacity=65);-webkit-box-shadow:none;box-shadow:none}.cf-toggle-switch .btn-default{color:#333;background-color:#fff;border-color:#ccc}.cf-toggle-switch .btn-default.active,.cf-toggle-switch .btn-default:active,.cf-toggle-switch .btn-default:focus,.cf-toggle-switch .btn-default:hover,.cf-toggle-switch .open .dropdown-toggle.btn-default{color:#333;background-color:#ebebeb;border-color:#adadad}.cf-toggle-switch .btn-default.disabled,.cf-toggle-switch .btn-default.disabled.active,.cf-toggle-switch .btn-default.disabled:active,.cf-toggle-switch .btn-default.disabled:focus,.cf-toggle-switch .btn-default.disabled:hover,.cf-toggle-switch .btn-default[disabled],.cf-toggle-switch .btn-default[disabled].active,.cf-toggle-switch .btn-default[disabled]:active,.cf-toggle-switch .btn-default[disabled]:focus,.cf-toggle-switch .btn-default[disabled]:hover,.cf-toggle-switch fieldset[disabled] .btn-default,.cf-toggle-switch fieldset[disabled] .btn-default.active,.cf-toggle-switch fieldset[disabled] .btn-default:active,.cf-toggle-switch fieldset[disabled] .btn-default:focus,.cf-toggle-switch fieldset[disabled] .btn-default:hover{background-color:#fff;border-color:#ccc}.cf-toggle-switch .btn-default .badge{color:#fff;background-color:#333}.cf-toggle-switch .btn-primary{color:#fff;background-color:#428bca;border-color:#357ebd}.cf-toggle-switch .btn-primary.active,.cf-toggle-switch .btn-primary:active,.cf-toggle-switch .btn-primary:focus,.cf-toggle-switch .btn-primary:hover,.cf-toggle-switch .open .dropdown-toggle.btn-primary{color:#fff;background-color:#3276b1;border-color:#285e8e}.cf-toggle-switch .btn-primary.disabled,.cf-toggle-switch .btn-primary.disabled.active,.cf-toggle-switch .btn-primary.disabled:active,.cf-toggle-switch .btn-primary.disabled:focus,.cf-toggle-switch .btn-primary.disabled:hover,.cf-toggle-switch .btn-primary[disabled],.cf-toggle-switch .btn-primary[disabled].active,.cf-toggle-switch .btn-primary[disabled]:active,.cf-toggle-switch .btn-primary[disabled]:focus,.cf-toggle-switch .btn-primary[disabled]:hover,.cf-toggle-switch fieldset[disabled] .btn-primary,.cf-toggle-switch fieldset[disabled] .btn-primary.active,.cf-toggle-switch fieldset[disabled] .btn-primary:active,.cf-toggle-switch fieldset[disabled] .btn-primary:focus,.cf-toggle-switch fieldset[disabled] .btn-primary:hover{background-color:#428bca;border-color:#357ebd}.cf-toggle-switch .btn-primary .badge{color:#428bca;background-color:#fff}.cf-toggle-switch .btn-success{color:#fff;background-color:#5cb85c;border-color:#4cae4c}.cf-toggle-switch .btn-success.active,.cf-toggle-switch .btn-success:active,.cf-toggle-switch .btn-success:focus,.cf-toggle-switch .btn-success:hover,.cf-toggle-switch .open .dropdown-toggle.btn-success{color:#fff;background-color:#47a447;border-color:#398439}.cf-toggle-switch .btn-success.disabled,.cf-toggle-switch .btn-success.disabled.active,.cf-toggle-switch .btn-success.disabled:active,.cf-toggle-switch .btn-success.disabled:focus,.cf-toggle-switch .btn-success.disabled:hover,.cf-toggle-switch .btn-success[disabled],.cf-toggle-switch .btn-success[disabled].active,.cf-toggle-switch .btn-success[disabled]:active,.cf-toggle-switch .btn-success[disabled]:focus,.cf-toggle-switch .btn-success[disabled]:hover,.cf-toggle-switch fieldset[disabled] .btn-success,.cf-toggle-switch fieldset[disabled] .btn-success.active,.cf-toggle-switch fieldset[disabled] .btn-success:active,.cf-toggle-switch fieldset[disabled] .btn-success:focus,.cf-toggle-switch fieldset[disabled] .btn-success:hover{background-color:#5cb85c;border-color:#4cae4c}.cf-toggle-switch .btn-success .badge{color:#5cb85c;background-color:#fff}.cf-toggle-switch .btn-info{color:#fff;background-color:#5bc0de;border-color:#46b8da}.cf-toggle-switch .btn-info.active,.cf-toggle-switch .btn-info:active,.cf-toggle-switch .btn-info:focus,.cf-toggle-switch .btn-info:hover,.cf-toggle-switch .open .dropdown-toggle.btn-info{color:#fff;background-color:#39b3d7;border-color:#269abc}.cf-toggle-switch .btn-info.disabled,.cf-toggle-switch .btn-info.disabled.active,.cf-toggle-switch .btn-info.disabled:active,.cf-toggle-switch .btn-info.disabled:focus,.cf-toggle-switch .btn-info.disabled:hover,.cf-toggle-switch .btn-info[disabled],.cf-toggle-switch .btn-info[disabled].active,.cf-toggle-switch .btn-info[disabled]:active,.cf-toggle-switch .btn-info[disabled]:focus,.cf-toggle-switch .btn-info[disabled]:hover,.cf-toggle-switch fieldset[disabled] .btn-info,.cf-toggle-switch fieldset[disabled] .btn-info.active,.cf-toggle-switch fieldset[disabled] .btn-info:active,.cf-toggle-switch fieldset[disabled] .btn-info:focus,.cf-toggle-switch fieldset[disabled] .btn-info:hover{background-color:#5bc0de;border-color:#46b8da}.cf-toggle-switch .btn-info .badge{color:#5bc0de;background-color:#fff}.cf-toggle-switch .btn-warning{color:#fff;background-color:#f0ad4e;border-color:#eea236}.cf-toggle-switch .btn-warning.active,.cf-toggle-switch .btn-warning:active,.cf-toggle-switch .btn-warning:focus,.cf-toggle-switch .btn-warning:hover,.cf-toggle-switch .open .dropdown-toggle.btn-warning{color:#fff;background-color:#ed9c28;border-color:#d58512}.cf-toggle-switch .btn-warning.disabled,.cf-toggle-switch .btn-warning.disabled.active,.cf-toggle-switch .btn-warning.disabled:active,.cf-toggle-switch .btn-warning.disabled:focus,.cf-toggle-switch .btn-warning.disabled:hover,.cf-toggle-switch .btn-warning[disabled],.cf-toggle-switch .btn-warning[disabled].active,.cf-toggle-switch .btn-warning[disabled]:active,.cf-toggle-switch .btn-warning[disabled]:focus,.cf-toggle-switch .btn-warning[disabled]:hover,.cf-toggle-switch fieldset[disabled] .btn-warning,.cf-toggle-switch fieldset[disabled] .btn-warning.active,.cf-toggle-switch fieldset[disabled] .btn-warning:active,.cf-toggle-switch fieldset[disabled] .btn-warning:focus,.cf-toggle-switch fieldset[disabled] .btn-warning:hover{background-color:#f0ad4e;border-color:#eea236}.cf-toggle-switch .btn-warning .badge{color:#f0ad4e;background-color:#fff}.cf-toggle-switch .btn-danger{color:#fff;background-color:#d9534f;border-color:#d43f3a}.cf-toggle-switch .btn-danger.active,.cf-toggle-switch .btn-danger:active,.cf-toggle-switch .btn-danger:focus,.cf-toggle-switch .btn-danger:hover,.cf-toggle-switch .open .dropdown-toggle.btn-danger{color:#fff;background-color:#d2322d;border-color:#ac2925}.cf-toggle-switch .btn-danger.disabled,.cf-toggle-switch .btn-danger.disabled.active,.cf-toggle-switch .btn-danger.disabled:active,.cf-toggle-switch .btn-danger.disabled:focus,.cf-toggle-switch .btn-danger.disabled:hover,.cf-toggle-switch .btn-danger[disabled],.cf-toggle-switch .btn-danger[disabled].active,.cf-toggle-switch .btn-danger[disabled]:active,.cf-toggle-switch .btn-danger[disabled]:focus,.cf-toggle-switch .btn-danger[disabled]:hover,.cf-toggle-switch fieldset[disabled] .btn-danger,.cf-toggle-switch fieldset[disabled] .btn-danger.active,.cf-toggle-switch fieldset[disabled] .btn-danger:active,.cf-toggle-switch fieldset[disabled] .btn-danger:focus,.cf-toggle-switch fieldset[disabled] .btn-danger:hover{background-color:#d9534f;border-color:#d43f3a}.cf-toggle-switch .btn-danger .badge{color:#d9534f;background-color:#fff}.cf-toggle-switch .btn-link{color:#428bca;font-weight:400;cursor:pointer;border-radius:0}.cf-toggle-switch .btn-link,.cf-toggle-switch .btn-link:active,.cf-toggle-switch .btn-link[disabled],.cf-toggle-switch fieldset[disabled] .btn-link{background-color:transparent;-webkit-box-shadow:none;box-shadow:none}.cf-toggle-switch .btn-link,.cf-toggle-switch .btn-link:active,.cf-toggle-switch .btn-link:focus,.cf-toggle-switch .btn-link:hover{border-color:transparent}.cf-toggle-switch .btn-link:focus,.cf-toggle-switch .btn-link:hover{color:#2a6496;text-decoration:underline;background-color:transparent}.cf-toggle-switch .btn-link[disabled]:focus,.cf-toggle-switch .btn-link[disabled]:hover,.cf-toggle-switch fieldset[disabled] .btn-link:focus,.cf-toggle-switch fieldset[disabled] .btn-link:hover{color:#999;text-decoration:none}.cf-toggle-switch .btn-group-lg>.btn,.cf-toggle-switch .btn-lg{padding:10px 16px;font-size:18px;line-height:1.33;border-radius:6px}.cf-toggle-switch .btn-group-sm>.btn,.cf-toggle-switch .btn-sm{padding:5px 10px;font-size:12px;line-height:1.5;border-radius:3px}.cf-toggle-switch .btn-group-xs>.btn,.cf-toggle-switch .btn-xs{padding:1px 5px;font-size:12px;line-height:1.5;border-radius:3px}.cf-toggle-switch .btn-group-vertical>.btn:not(:first-child):not(:last-child),.cf-toggle-switch .btn-group>.btn-group:not(:first-child):not(:last-child)>.btn,.cf-toggle-switch .btn-group>.btn:not(:first-child):not(:last-child):not(.dropdown-toggle){border-radius:0}.cf-toggle-switch .btn-block{display:block;width:100%;padding-left:0;padding-right:0}.cf-toggle-switch .btn-block+.btn-block{margin-top:5px}.cf-toggle-switch input[type=button].btn-block,.cf-toggle-switch input[type=reset].btn-block,.cf-toggle-switch input[type=submit].btn-block{width:100%}.cf-toggle-switch .btn-group,.cf-toggle-switch .btn-group-vertical{position:relative;display:inline-block;vertical-align:middle}.cf-toggle-switch .btn-group-vertical>.btn,.cf-toggle-switch .btn-group>.btn{position:relative;float:left}.cf-toggle-switch .btn-group-vertical>.btn.active,.cf-toggle-switch .btn-group-vertical>.btn:active,.cf-toggle-switch .btn-group-vertical>.btn:focus,.cf-toggle-switch .btn-group-vertical>.btn:hover,.cf-toggle-switch .btn-group>.btn.active,.cf-toggle-switch .btn-group>.btn:active,.cf-toggle-switch .btn-group>.btn:focus,.cf-toggle-switch .btn-group>.btn:hover{z-index:2}.cf-toggle-switch .btn-group .btn+.btn,.cf-toggle-switch .btn-group .btn+.btn-group,.cf-toggle-switch .btn-group .btn-group+.btn,.cf-toggle-switch .btn-group .btn-group+.btn-group{margin-left:-1px}.cf-toggle-switch .btn-toolbar{margin-left:-5px}.cf-toggle-switch .btn-toolbar>.btn,.cf-toggle-switch .btn-toolbar>.btn-group,.cf-toggle-switch .btn-toolbar>.input-group{margin-left:5px}.cf-toggle-switch .btn .caret,.cf-toggle-switch .btn-group>.btn:first-child{margin-left:0}.cf-toggle-switch .btn-group>.btn:first-child:not(:last-child):not(.dropdown-toggle){border-bottom-right-radius:0;border-top-right-radius:0}.cf-toggle-switch .btn-group>.btn:last-child:not(:first-child),.cf-toggle-switch .btn-group>.dropdown-toggle:not(:first-child){border-bottom-left-radius:0;border-top-left-radius:0}.cf-toggle-switch .btn-group>.btn-group:first-child>.btn:last-child,.cf-toggle-switch .btn-group>.btn-group:first-child>.dropdown-toggle{border-bottom-right-radius:0;border-top-right-radius:0}.cf-toggle-switch .btn-group>.btn-group:last-child>.btn:first-child{border-bottom-left-radius:0;border-top-left-radius:0}.cf-toggle-switch .btn-group>.btn+.dropdown-toggle{padding-left:8px;padding-right:8px}.cf-toggle-switch .btn-group>.btn-lg+.dropdown-toggle{padding-left:12px;padding-right:12px}.cf-toggle-switch .btn-group.open .dropdown-toggle{-webkit-box-shadow:inset 0 3px 5px rgba(0,0,0,.125);box-shadow:inset 0 3px 5px rgba(0,0,0,.125)}.cf-toggle-switch .btn-group.open .dropdown-toggle.btn-link{-webkit-box-shadow:none;box-shadow:none}.cf-toggle-switch .btn-lg .caret{border-width:5px 5px 0}.cf-toggle-switch .dropup .btn-lg .caret{border-width:0 5px 5px}.cf-toggle-switch .btn-group-vertical>.btn,.cf-toggle-switch .btn-group-vertical>.btn-group,.cf-toggle-switch .btn-group-vertical>.btn-group>.btn{display:block;float:none;width:100%;max-width:100%}.cf-toggle-switch .btn-group-vertical>.btn-group>.btn{float:none}.cf-toggle-switch .btn-group-vertical>.btn+.btn,.cf-toggle-switch .btn-group-vertical>.btn+.btn-group,.cf-toggle-switch .btn-group-vertical>.btn-group+.btn,.cf-toggle-switch .btn-group-vertical>.btn-group+.btn-group{margin-top:-1px;margin-left:0}.cf-toggle-switch .btn-group-vertical>.btn:first-child:not(:last-child){border-top-right-radius:4px;border-bottom-right-radius:0;border-bottom-left-radius:0}.cf-toggle-switch .btn-group-vertical>.btn:last-child:not(:first-child){border-bottom-left-radius:4px;border-top-right-radius:0;border-top-left-radius:0}.cf-toggle-switch .btn-group-vertical>.btn-group:not(:first-child):not(:last-child)>.btn{border-radius:0}.cf-toggle-switch .btn-group-vertical>.btn-group:first-child:not(:last-child)>.btn:last-child,.cf-toggle-switch .btn-group-vertical>.btn-group:first-child:not(:last-child)>.dropdown-toggle{border-bottom-right-radius:0;border-bottom-left-radius:0}.cf-toggle-switch .btn-group-vertical>.btn-group:last-child:not(:first-child)>.btn:first-child{border-top-right-radius:0;border-top-left-radius:0}.cf-toggle-switch .btn-group-justified{display:table;width:100%;table-layout:fixed;border-collapse:separate}.cf-toggle-switch .btn-group-justified>.btn,.cf-toggle-switch .btn-group-justified>.btn-group{float:none;display:table-cell;width:1%}.cf-toggle-switch .btn-group-justified>.btn-group .btn{width:100%}.cf-toggle-switch [data-toggle=buttons]>.btn>input[type=checkbox],.cf-toggle-switch [data-toggle=buttons]>.btn>input[type=radio]{display:none}.cf-toggle-switch .btn-group-vertical>.btn-group:after,.cf-toggle-switch .btn-group-vertical>.btn-group:before,.cf-toggle-switch .btn-toolbar:after,.cf-toggle-switch .btn-toolbar:before,.cf-toggle-switch .clearfix:after,.cf-toggle-switch .clearfix:before{content:" ";display:table}.cf-toggle-switch .btn-group-vertical>.btn-group:after,.cf-toggle-switch .btn-toolbar:after,.cf-toggle-switch .clearfix:after{clear:both}.cf-toggle-switch .center-block{display:block;margin-left:auto;margin-right:auto}.cf-toggle-switch .pull-right{float:right!important}.cf-toggle-switch .pull-left{float:left!important}.cf-toggle-switch .hide{display:none!important}.cf-toggle-switch .show{display:block!important}.cf-toggle-switch .invisible{visibility:hidden}.cf-toggle-switch .text-hide{font:0/0 a;color:transparent;text-shadow:none;background-color:transparent;border:0}.cf-toggle-switch .hidden{display:none!important;visibility:hidden!important}.cf-toggle-switch .affix{position:fixed}@-ms-viewport{width:device-width}.cf-toggle-switch .visible-lg,.cf-toggle-switch .visible-md,.cf-toggle-switch .visible-print,.cf-toggle-switch .visible-sm,.cf-toggle-switch .visible-xs{display:none!important}@media (max-width:767px){.cf-toggle-switch .visible-xs{display:block!important}.cf-toggle-switch table.visible-xs{display:table}.cf-toggle-switch tr.visible-xs{display:table-row!important}.cf-toggle-switch td.visible-xs,.cf-toggle-switch th.visible-xs{display:table-cell!important}}@media (min-width:768px) and (max-width:991px){.cf-toggle-switch .visible-sm{display:block!important}.cf-toggle-switch table.visible-sm{display:table}.cf-toggle-switch tr.visible-sm{display:table-row!important}.cf-toggle-switch td.visible-sm,.cf-toggle-switch th.visible-sm{display:table-cell!important}}@media (min-width:992px) and (max-width:1199px){.cf-toggle-switch .visible-md{display:block!important}.cf-toggle-switch table.visible-md{display:table}.cf-toggle-switch tr.visible-md{display:table-row!important}.cf-toggle-switch td.visible-md,.cf-toggle-switch th.visible-md{display:table-cell!important}}@media (min-width:1200px){.cf-toggle-switch .visible-lg{display:block!important}.cf-toggle-switch table.visible-lg{display:table}.cf-toggle-switch tr.visible-lg{display:table-row!important}.cf-toggle-switch td.visible-lg,.cf-toggle-switch th.visible-lg{display:table-cell!important}.cf-toggle-switch .hidden-lg{display:none!important}}@media (max-width:767px){.cf-toggle-switch .hidden-xs{display:none!important}}@media (min-width:768px) and (max-width:991px){.cf-toggle-switch .hidden-sm{display:none!important}}@media (min-width:992px) and (max-width:1199px){.cf-toggle-switch .hidden-md{display:none!important}}@media print{.cf-toggle-switch .visible-print{display:block!important}.cf-toggle-switch table.visible-print{display:table}.cf-toggle-switch tr.visible-print{display:table-row!important}.cf-toggle-switch td.visible-print,.cf-toggle-switch th.visible-print{display:table-cell!important}.cf-toggle-switch .hidden-print{display:none!important}}.cf-toggle-group-buttons{width:100%;clear:both}input.form-control.parsley-success,select.form-control.parsley-success,textarea.form-control.parsley-success{color:#468847;background-color:#DFF0D8;border-color:#D6E9C6}input.form-control.parsley-error,select.form-control.parsley-error,textarea.form-control.parsley-error{color:#B94A48;background-color:#F2DEDE;border-color:#EED3D7}.form-control.parsley-errors-list{margin:2px 0 3px;padding:0;list-style-type:none;font-size:.9em;line-height:.9em;opacity:0;color:#468847;transition:all .3s ease-in;-o-transition:all .3s ease-in;-moz-transition:all .3s ease-in;-webkit-transition:all .3s ease-in}.form-control.parsley-errors-list.filled{opacity:1}.breadcrumb a.has-error{color:red}.form-group .parsley-errors-list.filled,.form-group .parsley-errors-list.filled .parsley-type{list-style:none}.caldera-grid .cf-multi-uploader-list>ul{list-style:none;margin:0 0 12px;padding:0}.caldera-grid .cf-multi-uploader-list>ul>li{margin:0;padding:0 0 22px;position:relative;clear:both}.caldera-grid .cf-multi-uploader-list>ul>li .file-name{display:inline-block;font-weight:700;left:16px;right:0;overflow:hidden;position:absolute;text-overflow:ellipsis;white-space:nowrap}.caldera-grid .cf-multi-uploader-list>ul>li .file-name.file-uploaded{left:0}.caldera-grid .cf-multi-uploader-list>ul>li .file-size{float:right}.caldera-grid .cf-multi-uploader-list>ul>li .file-type{float:left}.caldera-grid .cf-multi-uploader-list>ul>li .file-error{clear:both;display:block}.caldera-grid .cf-multi-uploader-list>ul>li .cf-file-remove{color:#cf0000;text-decoration:none;border:0}.caldera-grid .cf-multi-uploader-list>ul>li.has-error .bar{background-color:#cf0000!important}.caldera-grid .cf-multi-uploader-list>ul>li.has-error{color:#cf0000}.has-error.cf-toggle-switch .cf-toggle-group-buttons>a{background-color:#f2dede;border-color:#dd4b39}
assets/build/js/admin.min.js CHANGED
@@ -1 +1 @@
1
- var baldrickTriggers,loop_loader;jQuery(document).ready(function(a){var b;b="object"==typeof CF_ADMIN?CF_ADMIN.adminAjax:ajaxurl,baldrickTriggers=function(){a(".ajax-trigger").baldrick({request:b,method:"POST",before:function(b,c){var d=a(b),e=a("#cf_toolbar_actions"),f=e.parent().find('[name="_wp_http_referer"]');if(e.length&&f.length&&(d.data("cf_toolbar_actions",e.val()),d.data("_wp_http_referer",f.val())),d.data("trigger")){c.preventDefault();var g=a(d.data("trigger"));return g.trigger(g.data("event")?g.data("event"):"click"),!1}},complete:function(){a(".init_field_type[data-type]").each(function(b,c){var d=a(c);"function"==typeof window[d.data("type")+"_init"]&&window[d.data("type")+"_init"](d.prop("id"),d[0])})}})},loop_loader=function(a,b){var c=Math.round(1e7*Math.random());return{__id__:c}},baldrickTriggers(),a("body").on("click",".modal-side-tab",function(b){b.preventDefault();var c=a(this),d=c.closest(".caldera-modal-body"),e=d.find(".tab-detail-panel"),f=a(c.attr("href"));d.find(".modal-side-tab.active").removeClass("active"),c.addClass("active"),e.hide(),f.show()}),a("body").on("click",".caldera-group-remover",function(b){b.preventDefault();var c=a(this),d=c.closest(".caldera-repeater-group");d.slideUp(200,function(){d.remove()})}),a("body").on("click",".form-delete a.form-control",function(b){var c=a(this);confirm(c.data("confirm"))||b.preventDefault()}),a("body").on("keyup change",'[data-format="key"]',function(a){this.value=this.value.replace(/[^a-z0-9]/gi,"-").toLowerCase()}),a("body").on("keyup change",'[data-format="slug"]',function(a){this.value=this.value.replace(/[^a-z0-9]/gi,"_").toLowerCase()}),a(window).on("resize",function(){var b=a("#cf_forms_toggle"),c=a(".form-panel-wrap");window.innerWidth<=1420&&b.is(":visible")&&c.is(":visible")&&b.trigger("click")});var c;void 0!=typeof CF_CLIPPY&&"object"==typeof CF_CLIPPY&&(c=new CalderaFormsAdminClippys(a(document.getElementById("caldera-forms-clippy")),CF_CLIPPY,a),c.init()),a(".cf-entry-viewer-link").on("click",function(){"object"==typeof c&&c.remove()})});var baldrickTriggers,loop_loader;jQuery(document).ready(function(a){baldrickTriggers=function(){a(".ajax-trigger").baldrick({request:ajaxurl,method:"POST",before:function(b,c){var d=a(b),e=a("#cf_toolbar_actions"),f=e.parent().find('[name="_wp_http_referer"]');if(e.length&&f.length&&(d.data("cf_toolbar_actions",e.val()),d.data("_wp_http_referer",f.val())),d.data("trigger")){c.preventDefault();var g=a(d.data("trigger"));return g.trigger(g.data("event")?g.data("event"):"click"),!1}},complete:function(){a(".init_field_type[data-type]").each(function(b,c){var d=a(c);"function"==typeof window[d.data("type")+"_init"]&&window[d.data("type")+"_init"](d.prop("id"),d[0])})}})},loop_loader=function(a,b){var c=Math.round(1e7*Math.random());return{__id__:c}},baldrickTriggers(),a("body").on("click",".modal-side-tab",function(b){b.preventDefault();var c=a(this),d=c.closest(".caldera-modal-body"),e=d.find(".tab-detail-panel"),f=a(c.attr("href"));d.find(".modal-side-tab.active").removeClass("active"),c.addClass("active"),e.hide(),f.show()}),a("body").on("click",".caldera-group-remover",function(b){b.preventDefault();var c=a(this),d=c.closest(".caldera-repeater-group");d.slideUp(200,function(){d.remove()})}),a("body").on("click",".form-delete a.form-control",function(b){var c=a(this);confirm(c.data("confirm"))||b.preventDefault()}),a("body").on("keyup change",'[data-format="key"]',function(a){this.value=this.value.replace(/[^a-z0-9]/gi,"-").toLowerCase()}),a("body").on("keyup change",'[data-format="slug"]',function(a){this.value=this.value.replace(/[^a-z0-9]/gi,"_").toLowerCase()}),a(window).on("resize",function(){var b=a("#cf_forms_toggle"),c=a(".form-panel-wrap");window.innerWidth<=1420&&b.is(":visible")&&c.is(":visible")&&b.trigger("click")});var b;void 0!=typeof CF_CLIPPY&&"object"==typeof CF_CLIPPY&&(b=new CalderaFormsAdminClippys(a(document.getElementById("caldera-forms-clippy")),CF_CLIPPY,a),b.init()),a(".cf-entry-viewer-link").on("click",function(){"object"==typeof b&&b.remove()})});
1
+ var baldrickTriggers,loop_loader;jQuery(document).ready(function(a){var b;b="object"==typeof CF_ADMIN?CF_ADMIN.adminAjax:ajaxurl,baldrickTriggers=function(){a(".ajax-trigger").baldrick({request:b,method:"POST",before:function(b,c){var d=a(b),e=a("#cf_toolbar_actions"),f=e.parent().find('[name="_wp_http_referer"]');if(e.length&&f.length&&(d.data("cf_toolbar_actions",e.val()),d.data("_wp_http_referer",f.val())),d.data("trigger")){c.preventDefault();var g=a(d.data("trigger"));return g.trigger(g.data("event")?g.data("event"):"click"),!1}},complete:function(){a(".init_field_type[data-type]").each(function(b,c){var d=a(c);"function"==typeof window[d.data("type")+"_init"]&&window[d.data("type")+"_init"](d.prop("id"),d[0])})}})},loop_loader=function(a,b){return{__id__:Math.round(1e7*Math.random())}},baldrickTriggers(),a("body").on("click",".modal-side-tab",function(b){b.preventDefault();var c=a(this),d=c.closest(".caldera-modal-body"),e=d.find(".tab-detail-panel"),f=a(c.attr("href"));d.find(".modal-side-tab.active").removeClass("active"),c.addClass("active"),e.hide(),f.show()}),a("body").on("click",".caldera-group-remover",function(b){b.preventDefault();var c=a(this),d=c.closest(".caldera-repeater-group");d.slideUp(200,function(){d.remove()})}),a("body").on("click",".form-delete a.form-control",function(b){var c=a(this);confirm(c.data("confirm"))||b.preventDefault()}),a("body").on("keyup change",'[data-format="key"]',function(a){this.value=this.value.replace(/[^a-z0-9]/gi,"-").toLowerCase()}),a("body").on("keyup change",'[data-format="slug"]',function(a){this.value=this.value.replace(/[^a-z0-9]/gi,"_").toLowerCase()}),a(window).on("resize",function(){var b=a("#cf_forms_toggle"),c=a(".form-panel-wrap");window.innerWidth<=1420&&b.is(":visible")&&c.is(":visible")&&b.trigger("click")});var c;void 0!=typeof CF_CLIPPY&&"object"==typeof CF_CLIPPY&&(c=new CalderaFormsAdminClippys(a(document.getElementById("caldera-forms-clippy")),CF_CLIPPY,a),c.init()),a(".cf-entry-viewer-link").on("click",function(){"object"==typeof c&&c.remove()})});var baldrickTriggers,loop_loader;jQuery(document).ready(function(a){baldrickTriggers=function(){a(".ajax-trigger").baldrick({request:ajaxurl,method:"POST",before:function(b,c){var d=a(b),e=a("#cf_toolbar_actions"),f=e.parent().find('[name="_wp_http_referer"]');if(e.length&&f.length&&(d.data("cf_toolbar_actions",e.val()),d.data("_wp_http_referer",f.val())),d.data("trigger")){c.preventDefault();var g=a(d.data("trigger"));return g.trigger(g.data("event")?g.data("event"):"click"),!1}},complete:function(){a(".init_field_type[data-type]").each(function(b,c){var d=a(c);"function"==typeof window[d.data("type")+"_init"]&&window[d.data("type")+"_init"](d.prop("id"),d[0])})}})},loop_loader=function(a,b){return{__id__:Math.round(1e7*Math.random())}},baldrickTriggers(),a("body").on("click",".modal-side-tab",function(b){b.preventDefault();var c=a(this),d=c.closest(".caldera-modal-body"),e=d.find(".tab-detail-panel"),f=a(c.attr("href"));d.find(".modal-side-tab.active").removeClass("active"),c.addClass("active"),e.hide(),f.show()}),a("body").on("click",".caldera-group-remover",function(b){b.preventDefault();var c=a(this),d=c.closest(".caldera-repeater-group");d.slideUp(200,function(){d.remove()})}),a("body").on("click",".form-delete a.form-control",function(b){var c=a(this);confirm(c.data("confirm"))||b.preventDefault()}),a("body").on("keyup change",'[data-format="key"]',function(a){this.value=this.value.replace(/[^a-z0-9]/gi,"-").toLowerCase()}),a("body").on("keyup change",'[data-format="slug"]',function(a){this.value=this.value.replace(/[^a-z0-9]/gi,"_").toLowerCase()}),a(window).on("resize",function(){var b=a("#cf_forms_toggle"),c=a(".form-panel-wrap");window.innerWidth<=1420&&b.is(":visible")&&c.is(":visible")&&b.trigger("click")});var b;void 0!=typeof CF_CLIPPY&&"object"==typeof CF_CLIPPY&&(b=new CalderaFormsAdminClippys(a(document.getElementById("caldera-forms-clippy")),CF_CLIPPY,a),b.init()),a(".cf-entry-viewer-link").on("click",function(){"object"==typeof b&&b.remove()})});
assets/build/js/ajax-core.min.js CHANGED
@@ -1 +1 @@
1
- var resBaldrickTriggers;jQuery(function(a){var b=[],c=function(c,d,e){var f=a("#progress-file-"+d),g=a("."+d+" .file-size");b.push(1),cf_uploader_filelist[d].state=2,a.ajax({xhr:function(){var a=new window.XMLHttpRequest;return a.upload.addEventListener("progress",function(a){if(a.lengthComputable){var b=a.loaded/a.total*100;f.width(b+"%"),g.html(size_format(a.loaded)+" / "+size_format(a.total))}},!1),a.addEventListener("progress",function(a){if(a.lengthComputable){a.loaded/a.total}},!1),a},url:c.data("request")+"/upload/",type:"POST",data:e,processData:!1,contentType:!1,success:function(e,f,g){if(e.success&&e.success===!0){b.pop();var h=a('[data-file="'+d+'"]');h.next().addClass("file-uploaded"),h.remove(),cf_uploader_filelist[d].state=3,c.submit()}else if(e.data&&!e.success)return a("."+d).addClass("has-error"),c.find(":submit").prop("disabled",!1),c.find(".cf-uploader-trigger").slideDown(),void a("."+d+" .file-error").html(e.data)},error:function(a,b,d){c.data("postDisable")||buttons.prop("disabled",!1)}})};(resBaldrickTriggers=function(){function d(b){return a("#caldera_notices_"+b.params.trigger.data("instance"))}a(".cfajax-trigger").baldrick({request:"./",method:"POST",init:function(d,e){e.preventDefault();var f=a(d),g=f.find(":submit");if(f.data("_cf_manual"))return f.find('[name="cfajax"]').remove(),!1;if(f.data("postDisable")||g.prop("disabled",!0),"object"==typeof cf_uploader_filelist){f.find(".cf-uploader-trigger").slideUp();var h=!1,i=b.length;for(var j in cf_uploader_filelist)if(!(cf_uploader_filelist[j].state>1||0===cf_uploader_filelist[j].state)){h=!0;var k=new FormData,l=j,m=a("#"+l.split("_file_")[0]);if(k.append(m.data("field"),cf_uploader_filelist[j].file),k.append("field",m.data("field")),k.append("control",m.data("controlid")),c(f,l,k),i++,1===i)break}if(!0===h||b.length)return!1}},error:function(b){if(404===b.jqxhr.status)this.trigger.data("_cf_manual",!0).trigger("submit");else{var c=d(b);b.jqxhr.responseJSON.data.html&&(c.html(b.jqxhr.responseJSON.data.html),a("html,body").animate({scrollTop:c.offset().top-c.outerHeight()},300))}},callback:function(b){b.params.trigger.find(":submit").prop("disabled",!1);var c=d(b);if(b.params.trigger.data("customCallback")&&"function"==typeof window[b.params.trigger.data("customCallback")]&&window[b.params.trigger.data("customCallback")](b.data),b.params.trigger.data("inhibitnotice")||(a(".caldera_ajax_error_wrap").removeClass("caldera_ajax_error_wrap").removeClass("has-error"),a(".caldera_ajax_error_block").remove(),"complete"===b.data.status||"success"===b.data.type?(b.data.html&&b.params.target.html(b.data.html),b.params.trigger.data("hiderows")&&b.params.trigger.find("div.row").remove()):"preprocess"===b.data.status?b.params.target.html(b.data.html):"error"===b.data.status&&b.params.target.html(b.data.html)),"complete"!==b.data.status&&"success"!==b.data.type||b.data.entry||b.params.trigger[0].reset(),b.data.url&&(b.params.trigger.hide(),window.location=b.data.url),b.params.trigger.find(".cf-uploader-trigger").slideDown(),b.data.fields)for(var e in b.data.fields){var f=b.params.trigger.find('[data-field="'+e+'"]'),g=f.parent();if(f.length){g.is("label")&&(g=g.parent(),(g.hasClass("checkbox")||g.hasClass("radio"))&&(g=g.parent()));var h=g.find(".help-block").not(".caldera_ajax_error_block");g.addClass("has-error").addClass("caldera_ajax_error_wrap"),h.length&&h.hide(),g.append('<span class="help-block caldera_ajax_error_block">'+b.data.fields[e]+"</span>")}else c.html('<p class="alert alert-danger ">'+b.data.fields[e]+"</p>")}if("undefined"!=b.data.scroll){var i=document.getElementById(b.data.scroll);if(null!=i){var j=a(i);a("html,body").animate({scrollTop:j.offset().top-j.outerHeight()-12},300)}}a(document).trigger("cf.submission",b),a(document).trigger("cf."+b.data.type)}})})()});
1
+ var resBaldrickTriggers;jQuery(function(a){var b=[],c=function(c,d,e){var f=a("#progress-file-"+d),g=a("."+d+" .file-size");b.push(1),cf_uploader_filelist[d].state=2,a.ajax({xhr:function(){var a=new window.XMLHttpRequest;return a.upload.addEventListener("progress",function(a){if(a.lengthComputable){var b=a.loaded/a.total*100;f.width(b+"%"),g.html(size_format(a.loaded)+" / "+size_format(a.total))}},!1),a.addEventListener("progress",function(a){if(a.lengthComputable){a.loaded,a.total}},!1),a},url:c.data("request")+"/upload/",type:"POST",data:e,processData:!1,contentType:!1,success:function(e,f,g){if(e.success&&!0===e.success){b.pop();var h=a('[data-file="'+d+'"]');h.next().addClass("file-uploaded"),h.remove(),cf_uploader_filelist[d].state=3,c.submit()}else if(e.data&&!e.success)return a("."+d).addClass("has-error"),c.find(":submit").prop("disabled",!1),c.find(".cf-uploader-trigger").slideDown(),void a("."+d+" .file-error").html(e.data)},error:function(a,b,d){c.data("postDisable")||buttons.prop("disabled",!1)}})};(resBaldrickTriggers=function(){function d(b){return a("#caldera_notices_"+b.params.trigger.data("instance"))}a(".cfajax-trigger").baldrick({request:"./",method:"POST",init:function(d,e){e.preventDefault();var f=a(d),g=f.find(":submit");if(f.data("_cf_manual"))return f.find('[name="cfajax"]').remove(),!1;if(f.data("postDisable")||g.prop("disabled",!0),"object"==typeof cf_uploader_filelist){f.find(".cf-uploader-trigger").slideUp();var h=!1,i=b.length;for(var j in cf_uploader_filelist)if(!(cf_uploader_filelist[j].state>1||0===cf_uploader_filelist[j].state)){h=!0;var k=new FormData,l=j,m=a("#"+l.split("_file_")[0]);if(k.append(m.data("field"),cf_uploader_filelist[j].file),k.append("field",m.data("field")),k.append("control",m.data("controlid")),c(f,l,k),1===++i)break}if(!0===h||b.length)return!1}},error:function(b){if(404===b.jqxhr.status)this.trigger.data("_cf_manual",!0).trigger("submit");else{var c=d(b);b.jqxhr.responseJSON.data.html&&(c.html(b.jqxhr.responseJSON.data.html),a("html,body").animate({scrollTop:c.offset().top-c.outerHeight()},300))}},callback:function(b){b.params.trigger.find(":submit").prop("disabled",!1);var c=d(b);if(b.params.trigger.data("customCallback")&&"function"==typeof window[b.params.trigger.data("customCallback")]&&window[b.params.trigger.data("customCallback")](b.data),b.params.trigger.data("inhibitnotice")||(a(".caldera_ajax_error_wrap").removeClass("caldera_ajax_error_wrap").removeClass("has-error"),a(".caldera_ajax_error_block").remove(),"complete"===b.data.status||"success"===b.data.type?(b.data.html&&b.params.target.html(b.data.html),b.params.trigger.data("hiderows")&&b.params.trigger.find("div.row").remove()):"preprocess"===b.data.status?b.params.target.html(b.data.html):"error"===b.data.status&&b.params.target.html(b.data.html)),"complete"!==b.data.status&&"success"!==b.data.type||b.data.entry||b.params.trigger[0].reset(),b.data.url&&(b.params.trigger.hide(),window.location=b.data.url),b.params.trigger.find(".cf-uploader-trigger").slideDown(),b.data.fields)for(var e in b.data.fields){var f=b.params.trigger.find('[data-field="'+e+'"]'),g=f.parent();if(f.length){g.is("label")&&(g=g.parent(),(g.hasClass("checkbox")||g.hasClass("radio"))&&(g=g.parent()));var h=g.find(".help-block").not(".caldera_ajax_error_block");g.addClass("has-error").addClass("caldera_ajax_error_wrap"),h.length&&h.hide(),g.append('<span class="help-block caldera_ajax_error_block">'+b.data.fields[e]+"</span>")}else c.html('<p class="alert alert-danger ">'+b.data.fields[e]+"</p>")}if("undefined"!=b.data.scroll){var i=document.getElementById(b.data.scroll);if(null!=i){var j=a(i);a("html,body").animate({scrollTop:j.offset().top-j.outerHeight()-12},300)}}a(document).trigger("cf.submission",b),a(document).trigger("cf."+b.data.type)}})})()});
assets/build/js/caldera-forms-front.min.js CHANGED
@@ -1,4 +1,4 @@
1
- function color_picker_init(){jQuery(".minicolor-picker").miniColors()}function toggle_button_init(a,b){var c=jQuery(b),d=c.find(".cf-toggle-group-radio:checked");d.length&&jQuery("#"+d.data("ref")).trigger("click")}function Caldera_Forms_Field_Config(a,b,c){function d(a,b,c,d){var g=b.parent().parent();return g.removeClass("has-error"),g.find(".help-block").remove(),a?(g.removeClass("has-error"),f(),!0):(g.addClass("has-error").append('<span id="cf-error-'+b.attr("id")+'" class="help-block '+d+'">'+c+"</span>"),b.prop("required")&&e(),b.addClass("parsely-error"),!1)}function e(){i.prop("disabled",!0).attr("aria-disabled",!0)}function f(){i.prop("disabled",!1).attr("aria-disabled",!1)}var g=this,h={},i=b.find(":submit, .cf-page-btn-next");this.init=function(){c.each(a,function(a,b){h[b.id]=g[b.type](b)})},this.button=function(a){var b=a.id;c(document).on("click dblclick","#"+b,function(a){c("#"+b+"_btn").val(a.type).trigger("change")})},this.html=function(a){function b(){for(var b=c(document.getElementById(a.tmplId)).html(),d=c(document.getElementById(a.contentId)),e=a.binds,f=0;f<e.length;f++){for(var g=c('[data-field="'+e[f]+'"]'),h=[],i=0;i<g.length;i++)if(!c(g[i]).is(":radio,:checkbox")||c(g[i]).prop("checked"))if(c(g[i]).is("input:file")){var j=g[i].value.split("\\");h.push(j[j.length-1])}else g[i].value&&h.push(g[i].value);b=b.replace(new RegExp("{{"+e[f]+"}}","g"),h.join(", "))}d.html(b).trigger("change")}0!=a.sync&&(c.each(a.bindFields,function(a,d){c(document.getElementById(d)).on("change keyup",b)}),b())},this.summary=this.html;var j={};this.range_slider=function(a){function b(){"object"!=j[a.id]&&(j[a.id]={value:a.default,init:{}});var b={onSlide:function(b,d){j[a.id].value=d,d=d.toFixed(a.value),c("#"+a.id+"_value").html(d)},onInit:function(){this.value=j[a.id].value,d.parent().find(".rangeslider").css("backgroundColor",a.trackcolor),d.parent().find(".rangeslider__fill").css("backgroundColor",a.color),d.parent().find(".rangeslider__handle").css("backgroundColor",a.handle).css("borderColor",a.handleborder)},polyfill:!1};d.rangeslider(b),j[a.id].init=b}var d=c(document.getElementById(a.id));d.on("change",function(){c("#"+a.id+"_value").html(this.value)}).css("width","100%"),c(document).on("cf.pagenav cf.add cf.disable cf.modal",function(){var b=document.getElementById(a.id);if(null!=b){var d=c(b);d.rangeslider("destroy"),d.rangeslider(j[a.id].init)}}),b()},this.star_rating=function(a){var b=a.options.score,d=c(document.getElementById(a.starFieldId)),e=(c(document.getElementById(a.id)),function(){var c=a.options;c.click=function(){b=d.raty("score"),d.trigger("change")},d.raty(c),d.raty("score",b)});e();var f=!1;jQuery(document).on("cf.add",function(){!1===f&&(f=!0,d.length&&(d.raty("destroy"),e()),setTimeout(function(){f=!1},500))})},this.toggle_switch=function(a){c(document).on("reset","#"+a.id,function(b){c.each(a.options,function(b,d){c(document.getElemenetById(d)).removeClass(a.selectedClassName).addClass(a.defaultClassName)}),c(document.getElementById(a.id)).prop("checked","")})},this.phone_better=function(a){var b=c(document.getElementById(a.id)),e=function(){var b=document.getElementById("cf-error-"+a.id);null!=b&&b.remove()},f=function(){e();var f;b.intlTelInput("isValidNumber");c.trim(b.val())&&(f=!!b.intlTelInput("isValidNumber"));var g,h=b.intlTelInput("getValidationError");0==h?(f=!0,g=""):g="undefined"!=a.messages[h]?a.messages[h]:a.messages.generic,d(f,b,g,"help-block-phone_better")};b.intlTelInput(a.options),b.on("keyup change",e),b.blur(function(){e(),f()}),b.on("change",f)},this.wysiwyg=function(a){var b=document.getElementById(a.id);if(null!=b){var d=c(b);d.trumbowyg(a.options);var e=d.parent().find(".trumbowyg-editor");e.html(d.html()),e.bind("input propertychange",function(){d.html(e.html())})}},this.credit_card_number=function(a){function b(){e();var b=c(document.getElementById(a.cvc)),d=c(document.getElementById(a.exp));b.blur(function(){g.creditCardUtil.validateCVC(h,b),g.creditCardUtil.validateExp(d)})}function f(b){var d={0:"amex",1:"discover",2:"visa",3:"discover",4:"mastercard"},e="credit-card.svg";c.each(d,function(a,c){if(0===b.indexOf(c))return e="cc-"+c+".svg",!1}),h.css("background",'url("'+a.imgPath+e+'")')}var h=c(document.getElementById(a.id));0==a.exp&&0==a.cvc||b(),h.length&&(h.payment("formatCardNumber"),h.blur(function(){var b=h.val(),e=c.payment.validateCardNumber(b),g=c.payment.cardType(b);d(e,h,a.invalid,"help-block-credit_card_number help-block-credit_card"),e&&f(g)}))},this.credit_card_exp=function(a){var b=c(document.getElementById(a.id));b.length&&(b.payment("formatCardExpiry"),b.blur(function(){var c=g.creditCardUtil.validateExp(b);d(c,b,a.invalid,"help-block-credit_card_exp help-block-credit_card")}))},this.credit_card_cvc=function(a){var b=c(document.getElementById(a.id));if(b.length&&(b.payment("formatCardCVC"),!1!==a.ccField)){var e=c(document.getElementById(a.ccField));b.blur(function(){var c=g.creditCardUtil.validateExp(e,b);d(c,b,a.invalid,"help-block-credit_card_cvc help-block-credit_card")})}},this.creditCardUtil={validateCVC:function(a,b){var d=b.val(),e=c.payment.validateCardNumber(a.val()),f=!1;if(e){var g=c.payment.cardType(a.val());f=c.payment.validateCardCVC(d,g)}return f},validateExp:function(a){var b=a.val().split("/");return c.payment.validateCardExpiry(b[0].trim(),b[1].trim())}},this.color_picker=function(a){c(document.getElementById(a.id)).miniColors(a.settings)}}function CalderaFormsFieldSync(a,b,c,d){for(var e=0;e<b.length;e++)d(document).on("keyup change blur mouseover","[data-field='"+b[e]+"']",function(){var b=a.data("sync");if(id=a.data("field"),reg=new RegExp("{{([^}]*?)}}","g"),template=b.match(reg),!a.data("unsync")&&void 0!=template&&template.length){for(var e=0;e<template.length;e++){for(var f=template[e].replace(/\}/g,"").replace(/\{/g,""),g=new RegExp(template[e],"g"),h=c.find("[data-field='"+f+"']"),i="",j=0;j<h.length;j++){var k=d(h[j]);(!k.is(":radio")&&!k.is(":checkbox")||k.is(":checked"))&&(i+=k.val())}b=b.replace(g,i)}a.val(b)}}),d("[data-field='"+b[e]+"']").trigger("change")}function CalderaFormsResetNonce(a,b,c){function d(a){var b=(new Date).getTime();return b-36e3>a}function e(){c.ajax({url:b.rest.tokens.nonce,method:"POST",beforeSend:function(a){a.setRequestHeader("X-WP-Nonce",b.rest.nonce)},data:{form_id:a}}).success(function(a){f.val(a.nonce),f.data("nonce-time",(new Date).getTime())})}var f;this.init=function(){f=c("#"+b.nonce.field+"_"+a),d(f.data("nonce-time"))&&e()}}jQuery&&function(a){a.extend(a.fn,{miniColors:function(b,c){var d=function(b,c,d){var e=s(b.val());e||(e="ffffff");var f=x(e),h=a('<span class="input-group-addon" style="background-color: #'+e+'" href="#"></span>');h.insertAfter(b),b.addClass("miniColors").data("original-maxlength",b.attr("maxlength")||null).data("original-autocomplete",b.attr("autocomplete")||null).data("letterCase",c.letterCase?c.letterCase:"uppercase").data("trigger",h).data("hsb",f).data("change",c.change?c.change:null).data("close",c.close?c.close:null).data("open",c.open?c.open:null).attr("maxlength",7).attr("autocomplete","off").val("#"+o(e,c.letterCase)).trigger("change"),c.readonly&&b.prop("readonly",!0),c.disabled&&g(b),h.on("click.miniColors",function(a){a.preventDefault(),""===b.val()&&b.val("#").trigger("change"),i(b)}),b.on("focus.miniColors",function(a){""===b.val()&&b.val("#").trigger("change"),i(b)}),b.on("blur.miniColors",function(a){var c=s(y(b.data("hsb")));b.val(c?"#"+o(c,b.data("letterCase")):"").trigger("change")}),b.on("keydown.miniColors",function(a){9===a.keyCode&&j(b)}),b.on("keyup.miniColors",function(a){n(b)}),b.on("paste.miniColors",function(a){setTimeout(function(){n(b)},5)})},e=function(b){j(),b=a(b),b.data("trigger").remove(),b.attr("autocomplete",b.data("original-autocomplete")).attr("maxlength",b.data("original-maxlength")).removeData().removeClass("miniColors").off(".miniColors"),a(document).off(".miniColors")},f=function(a){a.prop("disabled",!1).data("trigger").css("opacity",1)},g=function(a){j(a),a.prop("disabled",!0).data("trigger").css("opacity",.5)},i=function(b){if(b.prop("disabled"))return!1;j();var c=a('<div class="miniColors-selector"></div>');c.append('<div class="miniColors-colors" style="background-color: #FFF;"><div class="miniColors-colorPicker"><div class="miniColors-colorPicker-inner"></div></div>').append('<div class="miniColors-hues"><div class="miniColors-huePicker"></div></div>').css("display","none").addClass(b.attr("class")).removeClass("form-control");var d=b.data("hsb");c.find(".miniColors-colors").css("backgroundColor","#"+y({h:d.h,s:100,b:100}));var e=b.data("colorPosition");e||(e=p(d)),c.find(".miniColors-colorPicker").css("top",e.y+"px").css("left",e.x+"px");var f=b.data("huePosition");f||(f=q(d)),c.find(".miniColors-huePicker").css("top",f.y+"px"),b.data("selector",c).data("huePicker",c.find(".miniColors-huePicker")).data("colorPicker",c.find(".miniColors-colorPicker")).data("mousebutton",0),a("BODY").append(c);var g=b.data("trigger"),h=!b.is(":visible"),i=h?g.offset().top+g.outerHeight():b.offset().top+b.outerHeight(),m=h?g.offset().left:b.offset().left,n=c.outerWidth(),o=c.outerHeight(),r=g.outerWidth(),s=g.outerHeight(),u=a(window).height(),v=a(window).width(),w=a(window).scrollTop(),x=a(window).scrollLeft();i+o>u+w&&(i=i-o-s),m+n>v+x&&(m=m-n+r),c.css({top:i,left:m}).fadeIn(100),c.on("selectstart",function(){return!1}),(!a.browser.msie||a.browser.msie&&a.browser.version>=9)&&a(window).on("resize.miniColors",function(a){j(b)}),a(document).on("mousedown.miniColors touchstart.miniColors",function(c){b.data("mousebutton",1);var d=a(c.target).parents().andSelf();return d.hasClass("miniColors-colors")&&(c.preventDefault(),b.data("moving","colors"),k(b,c)),d.hasClass("miniColors-hues")&&(c.preventDefault(),b.data("moving","hues"),l(b,c)),d.hasClass("miniColors-selector")?void c.preventDefault():void(d.hasClass("miniColors")||j(b))}),a(document).on("mouseup.miniColors touchend.miniColors",function(a){a.preventDefault(),b.data("mousebutton",0).removeData("moving")}).on("mousemove.miniColors touchmove.miniColors",function(a){a.preventDefault(),1===b.data("mousebutton")&&("colors"===b.data("moving")&&k(b,a),"hues"===b.data("moving")&&l(b,a))}),b.data("open")&&b.data("open").call(b.get(0),"#"+y(d),t(d))},j=function(b){b||(b=a(".miniColors")),b.each(function(){var c=a(this).data("selector");a(this).removeData("selector"),a(c).fadeOut(100,function(){if(b.data("close")){var c=b.data("hsb"),d=y(c);b.data("close").call(b.get(0),"#"+d,t(c))}a(this).remove()})}),a(document).off(".miniColors")},k=function(a,b){var c=a.data("colorPicker");c.hide();var d={x:b.pageX,y:b.pageY};b.originalEvent.changedTouches&&(d.x=b.originalEvent.changedTouches[0].pageX,d.y=b.originalEvent.changedTouches[0].pageY),d.x=d.x-a.data("selector").find(".miniColors-colors").offset().left-5,d.y=d.y-a.data("selector").find(".miniColors-colors").offset().top-5,d.x<=-5&&(d.x=-5),d.x>=144&&(d.x=144),d.y<=-5&&(d.y=-5),d.y>=144&&(d.y=144),a.data("colorPosition",d),c.css("left",d.x).css("top",d.y).show();var e=Math.round(.67*(d.x+5));e<0&&(e=0),e>100&&(e=100);var f=100-Math.round(.67*(d.y+5));f<0&&(f=0),f>100&&(f=100);var g=a.data("hsb");g.s=e,g.b=f,m(a,g,!0)},l=function(a,b){var c=a.data("huePicker");c.hide();var d={y:b.pageY};b.originalEvent.changedTouches&&(d.y=b.originalEvent.changedTouches[0].pageY),d.y=d.y-a.data("selector").find(".miniColors-colors").offset().top-1,d.y<=-1&&(d.y=-1),d.y>=149&&(d.y=149),a.data("huePosition",d),c.css("top",d.y).show();var e=Math.round(2.4*(150-d.y-1));e<0&&(e=0),e>360&&(e=360);var f=a.data("hsb");f.h=e,m(a,f,!0)},m=function(a,b,c){a.data("hsb",b);var d=y(b);if(c&&a.val("#"+o(d,a.data("letterCase"))).trigger("change"),a.data("trigger").css("backgroundColor","#"+d),a.data("selector")&&a.data("selector").find(".miniColors-colors").css("backgroundColor","#"+y({h:b.h,s:100,b:100})),a.data("change")){if(d===a.data("lastChange"))return;a.data("change").call(a.get(0),"#"+d,t(b)),a.data("lastChange",d)}},n=function(b){b.val("#"+r(b.val())).trigger("change");var c=s(b.val());if(!c)return!1;var d=x(c),e=b.data("hsb");if(d.h===e.h&&d.s===e.s&&d.b===e.b)return!0;var f=p(d),g=a(b.data("colorPicker"));g.css("top",f.y+"px").css("left",f.x+"px"),b.data("colorPosition",f);var h=q(d),i=a(b.data("huePicker"));return i.css("top",h.y+"px"),b.data("huePosition",h),m(b,d),!0},o=function(a,b){return"lowercase"===b?a.toLowerCase():"uppercase"===b?a.toUpperCase():a},p=function(a){var b=Math.ceil(a.s/.67);b<0&&(b=0),b>150&&(b=150);var c=150-Math.ceil(a.b/.67);return c<0&&(c=0),c>150&&(c=150),{x:b-5,y:c-5}},q=function(a){var b=150-a.h/2.4;return b<0&&(h=0),b>150&&(h=150),{y:b-1}},r=function(a){return a.replace(/[^A-F0-9]/gi,"")},s=function(a){return(a=r(a))?(3===a.length&&(a=a[0]+a[0]+a[1]+a[1]+a[2]+a[2]),6===a.length?a:null):null},t=function(a){var b={},c=Math.round(a.h),d=Math.round(255*a.s/100),e=Math.round(255*a.b/100);if(0===d)b.r=b.g=b.b=e;else{var f=e,g=(255-d)*e/255,h=(f-g)*(c%60)/60;360===c&&(c=0),c<60?(b.r=f,b.b=g,b.g=g+h):c<120?(b.g=f,b.b=g,b.r=f-h):c<180?(b.g=f,b.r=g,b.b=g+h):c<240?(b.b=f,b.r=g,b.g=f-h):c<300?(b.b=f,b.g=g,b.r=g+h):c<360?(b.r=f,b.g=g,b.b=f-h):(b.r=0,b.g=0,b.b=0)}return{r:Math.round(b.r),g:Math.round(b.g),b:Math.round(b.b)}},u=function(b){var c=[b.r.toString(16),b.g.toString(16),b.b.toString(16)];return a.each(c,function(a,b){1===b.length&&(c[a]="0"+b)}),c.join("")},v=function(a){return a=parseInt(a.indexOf("#")>-1?a.substring(1):a,16),{r:a>>16,g:(65280&a)>>8,b:255&a}},w=function(a){var b={h:0,s:0,b:0},c=Math.min(a.r,a.g,a.b),d=Math.max(a.r,a.g,a.b),e=d-c;return b.b=d,b.s=0!==d?255*e/d:0,0!==b.s?a.r===d?b.h=(a.g-a.b)/e:a.g===d?b.h=2+(a.b-a.r)/e:b.h=4+(a.r-a.g)/e:b.h=-1,b.h*=60,b.h<0&&(b.h+=360),b.s*=100/255,b.b*=100/255,b},x=function(a){var b=w(v(a));return 0===b.s&&(b.h=360),b},y=function(a){return u(t(a))};switch(b){case"readonly":return a(this).each(function(){a(this).hasClass("miniColors")&&a(this).prop("readonly",c)}),a(this);case"disabled":return a(this).each(function(){a(this).hasClass("miniColors")&&(c?g(a(this)):f(a(this)))}),a(this);case"value":if(void 0===c){if(!a(this).hasClass("miniColors"))return;var z=a(this),A=s(z.val());return A?"#"+o(A,z.data("letterCase")):null}return a(this).each(function(){a(this).hasClass("miniColors")&&(a(this).val(c).trigger("change"),n(a(this)))}),a(this);case"destroy":return a(this).each(function(){a(this).hasClass("miniColors")&&e(a(this))}),a(this);default:return b||(b={}),a(this).each(function(){"input"===a(this)[0].tagName.toLowerCase()&&(a(this).data("trigger")||d(a(this),b,c))}),a(this)}}})}(jQuery),document.addEventListener("load",color_picker_init,!1),jQuery(document).ajaxComplete(function(){color_picker_init()}),function(a,b){function c(){return new Date(Date.UTC.apply(Date,arguments))}function d(){var a=new Date;return c(a.getFullYear(),a.getMonth(),a.getDate())}function e(a){return function(){return this[a].apply(this,arguments)}}function f(b,c){function d(a,b){return b.toLowerCase()}var e,f=a(b).data(),g={},h=new RegExp("^"+c.toLowerCase()+"([A-Z])");c=new RegExp("^"+c.toLowerCase());for(var i in f)c.test(i)&&(e=i.replace(h,d),g[e]=f[i]);return g}function g(b){var c={};if(o[b]||(b=b.split("-")[0],o[b])){var d=o[b];return a.each(n,function(a,b){b in d&&(c[b]=d[b])}),c}}var h=a(window),i=function(){var b={get:function(a){return this.slice(a)[0]},contains:function(a){for(var b=a&&a.valueOf(),c=0,d=this.length;c<d;c++)if(this[c].valueOf()===b)return c;return-1},remove:function(a){this.splice(a,1)},replace:function(b){b&&(a.isArray(b)||(b=[b]),this.clear(),this.push.apply(this,b))},clear:function(){this.splice(0)},copy:function(){var a=new i;return a.replace(this),a}};return function(){var c=[];return c.push.apply(c,arguments),a.extend(c,b),c}}(),j=function(b,c){this.dates=new i,this.viewDate=d(),this.focusDate=null,this._process_options(c),this.element=a(b),this.isInline=!1,this.isInput=this.element.is("input"),this.component=!!this.element.is(".date")&&this.element.find(".add-on, .input-group-addon, .btn"),this.hasInput=this.component&&this.element.find("input").length,this.component&&0===this.component.length&&(this.component=!1),this.picker=a(p.template),this._buildEvents(),this._attachEvents(),this.isInline?this.picker.addClass("cfdatepicker-inline").appendTo(this.element):this.picker.addClass("cfdatepicker-dropdown dropdown-menu"),this.o.rtl&&this.picker.addClass("cfdatepicker-rtl"),this.viewMode=this.o.startView,this.o.calendarWeeks&&this.picker.find("tfoot th.today").attr("colspan",function(a,b){return parseInt(b)+1}),this._allow_update=!1,this.setStartDate(this._o.startDate),this.setEndDate(this._o.endDate),this.setDaysOfWeekDisabled(this.o.daysOfWeekDisabled),this.fillDow(),this.fillMonths(),this._allow_update=!0,this.update(),this.showMode(),this.isInline&&this.show()};j.prototype={constructor:j,_process_options:function(b){this._o=a.extend({},this._o,b);var c=this.o=a.extend({},this._o),d=c.language;switch(o[d]||(d=d.split("-")[0],o[d]||(d=m.language)),c.language=d,c.startView){case 2:case"decade":c.startView=2;break;case 1:case"year":c.startView=1;break;default:c.startView=0}switch(c.minViewMode){case 1:case"months":c.minViewMode=1;break;case 2:case"years":c.minViewMode=2;break;default:c.minViewMode=0}c.startView=Math.max(c.startView,c.minViewMode),c.multidate!==!0&&(c.multidate=Number(c.multidate)||!1,c.multidate!==!1?c.multidate=Math.max(0,c.multidate):c.multidate=1),c.multidateSeparator=String(c.multidateSeparator),c.weekStart%=7,c.weekEnd=(c.weekStart+6)%7;var e=p.parseFormat(c.format);c.startDate!==-(1/0)&&(c.startDate?c.startDate instanceof Date?c.startDate=this._local_to_utc(this._zero_time(c.startDate)):c.startDate=p.parseDate(c.startDate,e,c.language):c.startDate=-(1/0)),c.endDate!==1/0&&(c.endDate?c.endDate instanceof Date?c.endDate=this._local_to_utc(this._zero_time(c.endDate)):c.endDate=p.parseDate(c.endDate,e,c.language):c.endDate=1/0),c.daysOfWeekDisabled=c.daysOfWeekDisabled||[],a.isArray(c.daysOfWeekDisabled)||(c.daysOfWeekDisabled=c.daysOfWeekDisabled.split(/[,\s]*/)),c.daysOfWeekDisabled=a.map(c.daysOfWeekDisabled,function(a){return parseInt(a,10)});var f=String(c.orientation).toLowerCase().split(/\s+/g),g=c.orientation.toLowerCase();if(f=a.grep(f,function(a){return/^auto|left|right|top|bottom$/.test(a)}),c.orientation={x:"auto",y:"auto"},g&&"auto"!==g)if(1===f.length)switch(f[0]){case"top":case"bottom":c.orientation.y=f[0];break;case"left":case"right":c.orientation.x=f[0]}else g=a.grep(f,function(a){return/^left|right$/.test(a)}),c.orientation.x=g[0]||"auto",g=a.grep(f,function(a){return/^top|bottom$/.test(a)}),c.orientation.y=g[0]||"auto";else;},_events:[],_secondaryEvents:[],_applyEvents:function(a){for(var c,d,e,f=0;f<a.length;f++)c=a[f][0],2===a[f].length?(d=b,e=a[f][1]):3===a[f].length&&(d=a[f][1],e=a[f][2]),c.on(e,d)},_unapplyEvents:function(a){for(var c,d,e,f=0;f<a.length;f++)c=a[f][0],2===a[f].length?(e=b,d=a[f][1]):3===a[f].length&&(e=a[f][1],d=a[f][2]),c.off(d,e)},_buildEvents:function(){this.isInput?this._events=[[this.element,{focus:a.proxy(this.show,this),keyup:a.proxy(function(b){a.inArray(b.keyCode,[27,37,39,38,40,32,13,9])===-1&&this.update()},this),keydown:a.proxy(this.keydown,this)}]]:this.component&&this.hasInput?this._events=[[this.element.find("input"),{focus:a.proxy(this.show,this),keyup:a.proxy(function(b){a.inArray(b.keyCode,[27,37,39,38,40,32,13,9])===-1&&this.update()},this),keydown:a.proxy(this.keydown,this)}],[this.component,{click:a.proxy(this.show,this)}]]:this.element.is("div")?this.isInline=!0:this._events=[[this.element,{click:a.proxy(this.show,this)}]],this._events.push([this.element,"*",{blur:a.proxy(function(a){this._focused_from=a.target},this)}],[this.element,{blur:a.proxy(function(a){this._focused_from=a.target},this)}]),this._secondaryEvents=[[this.picker,{click:a.proxy(this.click,this)}],[a(window),{resize:a.proxy(this.place,this)}],[a(document),{"mousedown touchstart":a.proxy(function(a){this.element.is(a.target)||this.element.find(a.target).length||this.picker.is(a.target)||this.picker.find(a.target).length||this.hide()},this)}]]},_attachEvents:function(){this._detachEvents(),this._applyEvents(this._events)},_detachEvents:function(){this._unapplyEvents(this._events)},_attachSecondaryEvents:function(){this._detachSecondaryEvents(),this._applyEvents(this._secondaryEvents)},_detachSecondaryEvents:function(){this._unapplyEvents(this._secondaryEvents)},_trigger:function(b,c){var d=c||this.dates.get(-1),e=this._utc_to_local(d);this.element.trigger({type:b,date:e,dates:a.map(this.dates,this._utc_to_local),format:a.proxy(function(a,b){0===arguments.length?(a=this.dates.length-1,b=this.o.format):"string"==typeof a&&(b=a,a=this.dates.length-1),b=b||this.o.format;var c=this.dates.get(a);return p.formatDate(c,b,this.o.language)},this)})},show:function(){this.isInline||this.picker.appendTo("body"),this.picker.show(),this.place(),this._attachSecondaryEvents(),this._trigger("show")},hide:function(){this.isInline||this.picker.is(":visible")&&(this.focusDate=null,this.picker.hide().detach(),this._detachSecondaryEvents(),this.viewMode=this.o.startView,this.showMode(),this.o.forceParse&&(this.isInput&&this.element.val()||this.hasInput&&this.element.find("input").val())&&this.setValue(),this._trigger("hide"))},remove:function(){this.hide(),this._detachEvents(),this._detachSecondaryEvents(),this.picker.remove(),delete this.element.data().cfdatepicker,this.isInput||delete this.element.data().date},_utc_to_local:function(a){return a&&new Date(a.getTime()+6e4*a.getTimezoneOffset())},_local_to_utc:function(a){return a&&new Date(a.getTime()-6e4*a.getTimezoneOffset())},_zero_time:function(a){return a&&new Date(a.getFullYear(),a.getMonth(),a.getDate())},_zero_utc_time:function(a){return a&&new Date(Date.UTC(a.getUTCFullYear(),a.getUTCMonth(),a.getUTCDate()))},getDates:function(){return a.map(this.dates,this._utc_to_local)},getUTCDates:function(){return a.map(this.dates,function(a){return new Date(a)})},getDate:function(){return this._utc_to_local(this.getUTCDate())},getUTCDate:function(){return new Date(this.dates.get(-1))},setDates:function(){var b=a.isArray(arguments[0])?arguments[0]:arguments;this.update.apply(this,b),this._trigger("changeDate"),this.setValue()},setUTCDates:function(){var b=a.isArray(arguments[0])?arguments[0]:arguments;this.update.apply(this,a.map(b,this._utc_to_local)),this._trigger("changeDate"),this.setValue()},setDate:e("setDates"),setUTCDate:e("setUTCDates"),setValue:function(){var a=this.getFormattedDate();this.isInput?this.element.val(a).change():this.component&&this.element.find("input").val(a).change()},getFormattedDate:function(c){c===b&&(c=this.o.format);var d=this.o.language;return a.map(this.dates,function(a){return p.formatDate(a,c,d)}).join(this.o.multidateSeparator)},setStartDate:function(a){this._process_options({startDate:a}),this.update(),this.updateNavArrows()},setEndDate:function(a){this._process_options({endDate:a}),this.update(),this.updateNavArrows()},setDaysOfWeekDisabled:function(a){this._process_options({daysOfWeekDisabled:a}),this.update(),this.updateNavArrows()},place:function(){if(!this.isInline){var b,c=this.picker.outerWidth(),d=this.picker.outerHeight(),e=10,f=h.width(),g=h.height(),i=h.scrollTop(),j=jQuery(this.element).data("form-id"),k=document.getElementById("modal-"+j+"-content");b=null!==k?1e4:parseInt(this.element.parents().filter(function(){return"auto"!==a(this).css("z-index")}).first().css("z-index"))+10;var l=this.component?this.component.parent().offset():this.element.offset(),m=this.component?this.component.outerHeight(!0):this.element.outerHeight(!1),n=this.component?this.component.outerWidth(!0):this.element.outerWidth(!1),o=l.left,p=l.top;this.picker.removeClass("cfdatepicker-orient-top cfdatepicker-orient-bottom cfdatepicker-orient-right cfdatepicker-orient-left"),"auto"!==this.o.orientation.x?(this.picker.addClass("cfdatepicker-orient-"+this.o.orientation.x),"right"===this.o.orientation.x&&(o-=c-n)):(this.picker.addClass("cfdatepicker-orient-left"),l.left<0?o-=l.left-e:l.left+c>f&&(o=f-c-e));var q,r,s=this.o.orientation.y;"auto"===s&&(q=-i+l.top-d,r=i+g-(l.top+m+d),s=Math.max(q,r)===r?"top":"bottom"),this.picker.addClass("cfdatepicker-orient-"+s),"top"===s?p+=m:p-=d+parseInt(this.picker.css("padding-top")),this.picker.css({top:p,left:o,zIndex:b})}},_allow_update:!0,update:function(){if(this._allow_update){var b=this.dates.copy(),c=[],d=!1;arguments.length?(a.each(arguments,a.proxy(function(a,b){b instanceof Date&&(b=this._local_to_utc(b)),c.push(b)},this)),d=!0):(c=this.isInput?this.element.val():this.element.data("date")||this.element.find("input").val(),c=c&&this.o.multidate?c.split(this.o.multidateSeparator):[c],delete this.element.data().date),c=a.map(c,a.proxy(function(a){return p.parseDate(a,this.o.format,this.o.language)},this)),c=a.grep(c,a.proxy(function(a){return a<this.o.startDate||a>this.o.endDate||!a},this),!0),this.dates.replace(c),this.dates.length?this.viewDate=new Date(this.dates.get(-1)):this.viewDate<this.o.startDate?this.viewDate=new Date(this.o.startDate):this.viewDate>this.o.endDate&&(this.viewDate=new Date(this.o.endDate)),d?this.setValue():c.length&&String(b)!==String(this.dates)&&this._trigger("changeDate"),!this.dates.length&&b.length&&this._trigger("clearDate"),this.fill()}},fillDow:function(){var a=this.o.weekStart,b="<tr>";if(this.o.calendarWeeks){var c='<th class="cw">&nbsp;</th>';b+=c,this.picker.find(".cfdatepicker-days thead tr:first-child").prepend(c)}for(;a<this.o.weekStart+7;)b+='<th class="dow">'+o[this.o.language].daysMin[a++%7]+"</th>";b+="</tr>",this.picker.find(".cfdatepicker-days thead").append(b)},fillMonths:function(){for(var a="",b=0;b<12;)a+='<span class="month">'+o[this.o.language].monthsShort[b++]+"</span>";this.picker.find(".cfdatepicker-months td").html(a)},setRange:function(b){b&&b.length?this.range=a.map(b,function(a){return a.valueOf()}):delete this.range,this.fill()},getClassNames:function(b){var c=[],d=this.viewDate.getUTCFullYear(),e=this.viewDate.getUTCMonth(),f=new Date;return b.getUTCFullYear()<d||b.getUTCFullYear()===d&&b.getUTCMonth()<e?c.push("old"):(b.getUTCFullYear()>d||b.getUTCFullYear()===d&&b.getUTCMonth()>e)&&c.push("new"),this.focusDate&&b.valueOf()===this.focusDate.valueOf()&&c.push("focused"),this.o.todayHighlight&&b.getUTCFullYear()===f.getFullYear()&&b.getUTCMonth()===f.getMonth()&&b.getUTCDate()===f.getDate()&&c.push("today"),this.dates.contains(b)!==-1&&c.push("active"),(b.valueOf()<this.o.startDate||b.valueOf()>this.o.endDate||a.inArray(b.getUTCDay(),this.o.daysOfWeekDisabled)!==-1)&&c.push("disabled"),this.range&&(b>this.range[0]&&b<this.range[this.range.length-1]&&c.push("range"),a.inArray(b.valueOf(),this.range)!==-1&&c.push("selected")),c},fill:function(){var d,e=new Date(this.viewDate),f=e.getUTCFullYear(),g=e.getUTCMonth(),h=this.o.startDate!==-(1/0)?this.o.startDate.getUTCFullYear():-(1/0),i=this.o.startDate!==-(1/0)?this.o.startDate.getUTCMonth():-(1/0),j=this.o.endDate!==1/0?this.o.endDate.getUTCFullYear():1/0,k=this.o.endDate!==1/0?this.o.endDate.getUTCMonth():1/0,l=o[this.o.language].today||o.en.today||"",m=o[this.o.language].clear||o.en.clear||"";this.picker.find(".cfdatepicker-days thead th.cfdatepicker-switch").text(o[this.o.language].months[g]+" "+f),this.picker.find("tfoot th.today").text(l).toggle(this.o.todayBtn!==!1),this.picker.find("tfoot th.clear").text(m).toggle(this.o.clearBtn!==!1),this.updateNavArrows(),this.fillMonths();var n=c(f,g-1,28),q=p.getDaysInMonth(n.getUTCFullYear(),n.getUTCMonth());n.setUTCDate(q),n.setUTCDate(q-(n.getUTCDay()-this.o.weekStart+7)%7);var r=new Date(n);r.setUTCDate(r.getUTCDate()+42),r=r.valueOf();for(var s,t=[];n.valueOf()<r;){if(n.getUTCDay()===this.o.weekStart&&(t.push("<tr>"),this.o.calendarWeeks)){var u=new Date(+n+(this.o.weekStart-n.getUTCDay()-7)%7*864e5),v=new Date(Number(u)+(11-u.getUTCDay())%7*864e5),w=new Date(Number(w=c(v.getUTCFullYear(),0,1))+(11-w.getUTCDay())%7*864e5),x=(v-w)/864e5/7+1;t.push('<td class="cw">'+x+"</td>")}if(s=this.getClassNames(n),s.push("day"),this.o.beforeShowDay!==a.noop){var y=this.o.beforeShowDay(this._utc_to_local(n));y===b?y={}:"boolean"==typeof y?y={enabled:y}:"string"==typeof y&&(y={classes:y}),y.enabled===!1&&s.push("disabled"),y.classes&&(s=s.concat(y.classes.split(/\s+/))),y.tooltip&&(d=y.tooltip)}s=a.unique(s),t.push('<td class="'+s.join(" ")+'"'+(d?' title="'+d+'"':"")+">"+n.getUTCDate()+"</td>"),n.getUTCDay()===this.o.weekEnd&&t.push("</tr>"),n.setUTCDate(n.getUTCDate()+1)}this.picker.find(".cfdatepicker-days tbody").empty().append(t.join(""));var z=this.picker.find(".cfdatepicker-months").find("th:eq(1)").text(f).end().find("span").removeClass("active");a.each(this.dates,function(a,b){b.getUTCFullYear()===f&&z.eq(b.getUTCMonth()).addClass("active")}),(f<h||f>j)&&z.addClass("disabled"),f===h&&z.slice(0,i).addClass("disabled"),f===j&&z.slice(k+1).addClass("disabled"),t="",f=10*parseInt(f/10,10);var A=this.picker.find(".cfdatepicker-years").find("th:eq(1)").text(f+"-"+(f+9)).end().find("td");f-=1;for(var B,C=a.map(this.dates,function(a){return a.getUTCFullYear()}),D=-1;D<11;D++)B=["year"],D===-1?B.push("old"):10===D&&B.push("new"),a.inArray(f,C)!==-1&&B.push("active"),(f<h||f>j)&&B.push("disabled"),t+='<span class="'+B.join(" ")+'">'+f+"</span>",f+=1;A.html(t)},updateNavArrows:function(){if(this._allow_update){var a=new Date(this.viewDate),b=a.getUTCFullYear(),c=a.getUTCMonth();switch(this.viewMode){case 0:this.o.startDate!==-(1/0)&&b<=this.o.startDate.getUTCFullYear()&&c<=this.o.startDate.getUTCMonth()?this.picker.find(".prev").css({visibility:"hidden"}):this.picker.find(".prev").css({visibility:"visible"}),this.o.endDate!==1/0&&b>=this.o.endDate.getUTCFullYear()&&c>=this.o.endDate.getUTCMonth()?this.picker.find(".next").css({visibility:"hidden"}):this.picker.find(".next").css({visibility:"visible"});break;case 1:case 2:this.o.startDate!==-(1/0)&&b<=this.o.startDate.getUTCFullYear()?this.picker.find(".prev").css({visibility:"hidden"}):this.picker.find(".prev").css({visibility:"visible"}),this.o.endDate!==1/0&&b>=this.o.endDate.getUTCFullYear()?this.picker.find(".next").css({visibility:"hidden"}):this.picker.find(".next").css({visibility:"visible"})}}},click:function(b){b.preventDefault();var d,e,f,g=a(b.target).closest("span, td, th");if(1===g.length)switch(g[0].nodeName.toLowerCase()){case"th":switch(g[0].className){case"cfdatepicker-switch":this.showMode(1);break;case"prev":case"next":var h=p.modes[this.viewMode].navStep*("prev"===g[0].className?-1:1);switch(this.viewMode){case 0:this.viewDate=this.moveMonth(this.viewDate,h),this._trigger("changeMonth",this.viewDate);break;case 1:case 2:this.viewDate=this.moveYear(this.viewDate,h),1===this.viewMode&&this._trigger("changeYear",this.viewDate)}this.fill();break;case"today":var i=new Date;i=c(i.getFullYear(),i.getMonth(),i.getDate(),0,0,0),this.showMode(-2);var j="linked"===this.o.todayBtn?null:"view";this._setDate(i,j);break;case"clear":var k;this.isInput?k=this.element:this.component&&(k=this.element.find("input")),k&&k.val("").change(),this.update(),this._trigger("changeDate"),this.o.autoclose&&this.hide()}break;case"span":g.is(".disabled")||(this.viewDate.setUTCDate(1),g.is(".month")?(f=1,e=g.parent().find("span").index(g),d=this.viewDate.getUTCFullYear(),this.viewDate.setUTCMonth(e),this._trigger("changeMonth",this.viewDate),1===this.o.minViewMode&&this._setDate(c(d,e,f))):(f=1,e=0,d=parseInt(g.text(),10)||0,this.viewDate.setUTCFullYear(d),this._trigger("changeYear",this.viewDate),2===this.o.minViewMode&&this._setDate(c(d,e,f))),this.showMode(-1),this.fill());break;case"td":g.is(".day")&&!g.is(".disabled")&&(f=parseInt(g.text(),10)||1,d=this.viewDate.getUTCFullYear(),e=this.viewDate.getUTCMonth(),g.is(".old")?0===e?(e=11,d-=1):e-=1:g.is(".new")&&(11===e?(e=0,d+=1):e+=1),this._setDate(c(d,e,f)))}this.picker.is(":visible")&&this._focused_from&&a(this._focused_from).focus(),delete this._focused_from},_toggle_multidate:function(a){
2
- var b=this.dates.contains(a);if(a?b!==-1?this.dates.remove(b):this.dates.push(a):this.dates.clear(),"number"==typeof this.o.multidate)for(;this.dates.length>this.o.multidate;)this.dates.remove(0)},_setDate:function(a,b){b&&"date"!==b||this._toggle_multidate(a&&new Date(a)),b&&"view"!==b||(this.viewDate=a&&new Date(a)),this.fill(),this.setValue(),this._trigger("changeDate");var c;this.isInput?c=this.element:this.component&&(c=this.element.find("input")),c&&c.change(),!this.o.autoclose||b&&"date"!==b||this.hide()},moveMonth:function(a,c){if(!a)return b;if(!c)return a;var d,e,f=new Date(a.valueOf()),g=f.getUTCDate(),h=f.getUTCMonth(),i=Math.abs(c);if(c=c>0?1:-1,1===i)e=c===-1?function(){return f.getUTCMonth()===h}:function(){return f.getUTCMonth()!==d},d=h+c,f.setUTCMonth(d),(d<0||d>11)&&(d=(d+12)%12);else{for(var j=0;j<i;j++)f=this.moveMonth(f,c);d=f.getUTCMonth(),f.setUTCDate(g),e=function(){return d!==f.getUTCMonth()}}for(;e();)f.setUTCDate(--g),f.setUTCMonth(d);return f},moveYear:function(a,b){return this.moveMonth(a,12*b)},dateWithinRange:function(a){return a>=this.o.startDate&&a<=this.o.endDate},keydown:function(a){if(this.picker.is(":not(:visible)"))return void(27===a.keyCode&&this.show());var b,c,e,f=!1,g=this.focusDate||this.viewDate;switch(a.keyCode){case 27:this.focusDate?(this.focusDate=null,this.viewDate=this.dates.get(-1)||this.viewDate,this.fill()):this.hide(),a.preventDefault();break;case 37:case 39:if(!this.o.keyboardNavigation)break;b=37===a.keyCode?-1:1,a.ctrlKey?(c=this.moveYear(this.dates.get(-1)||d(),b),e=this.moveYear(g,b),this._trigger("changeYear",this.viewDate)):a.shiftKey?(c=this.moveMonth(this.dates.get(-1)||d(),b),e=this.moveMonth(g,b),this._trigger("changeMonth",this.viewDate)):(c=new Date(this.dates.get(-1)||d()),c.setUTCDate(c.getUTCDate()+b),e=new Date(g),e.setUTCDate(g.getUTCDate()+b)),this.dateWithinRange(c)&&(this.focusDate=this.viewDate=e,this.setValue(),this.fill(),a.preventDefault());break;case 38:case 40:if(!this.o.keyboardNavigation)break;b=38===a.keyCode?-1:1,a.ctrlKey?(c=this.moveYear(this.dates.get(-1)||d(),b),e=this.moveYear(g,b),this._trigger("changeYear",this.viewDate)):a.shiftKey?(c=this.moveMonth(this.dates.get(-1)||d(),b),e=this.moveMonth(g,b),this._trigger("changeMonth",this.viewDate)):(c=new Date(this.dates.get(-1)||d()),c.setUTCDate(c.getUTCDate()+7*b),e=new Date(g),e.setUTCDate(g.getUTCDate()+7*b)),this.dateWithinRange(c)&&(this.focusDate=this.viewDate=e,this.setValue(),this.fill(),a.preventDefault());break;case 32:break;case 13:g=this.focusDate||this.dates.get(-1)||this.viewDate,this._toggle_multidate(g),f=!0,this.focusDate=null,this.viewDate=this.dates.get(-1)||this.viewDate,this.setValue(),this.fill(),this.picker.is(":visible")&&(a.preventDefault(),this.o.autoclose&&this.hide());break;case 9:this.focusDate=null,this.viewDate=this.dates.get(-1)||this.viewDate,this.fill(),this.hide()}if(f){this.dates.length?this._trigger("changeDate"):this._trigger("clearDate");var h;this.isInput?h=this.element:this.component&&(h=this.element.find("input")),h&&h.change()}},showMode:function(a){a&&(this.viewMode=Math.max(this.o.minViewMode,Math.min(2,this.viewMode+a))),this.picker.find(">div").hide().filter(".cfdatepicker-"+p.modes[this.viewMode].clsName).css("display","block"),this.updateNavArrows()}};var k=function(b,c){this.element=a(b),this.inputs=a.map(c.inputs,function(a){return a.jquery?a[0]:a}),delete c.inputs,a(this.inputs).cfdatepicker(c).bind("changeDate",a.proxy(this.dateUpdated,this)),this.pickers=a.map(this.inputs,function(b){return a(b).data("cfdatepicker")}),this.updateDates()};k.prototype={updateDates:function(){this.dates=a.map(this.pickers,function(a){return a.getUTCDate()}),this.updateRanges()},updateRanges:function(){var b=a.map(this.dates,function(a){return a.valueOf()});a.each(this.pickers,function(a,c){c.setRange(b)})},dateUpdated:function(b){if(!this.updating){this.updating=!0;var c=a(b.target).data("cfdatepicker"),d=c.getUTCDate(),e=a.inArray(b.target,this.inputs),f=this.inputs.length;if(e!==-1){if(a.each(this.pickers,function(a,b){b.getUTCDate()||b.setUTCDate(d)}),d<this.dates[e])for(;e>=0&&d<this.dates[e];)this.pickers[e--].setUTCDate(d);else if(d>this.dates[e])for(;e<f&&d>this.dates[e];)this.pickers[e++].setUTCDate(d);this.updateDates(),delete this.updating}}},remove:function(){a.map(this.pickers,function(a){a.remove()}),delete this.element.data().cfdatepicker}};var l=a.fn.cfdatepicker;a.fn.cfdatepicker=function(c){var d=Array.apply(null,arguments);d.shift();var e;return this.each(function(){var h=a(this),i=h.data("cfdatepicker"),l="object"==typeof c&&c;if(!i){var n=f(this,"date"),o=a.extend({},m,n,l),p=g(o.language),q=a.extend({},m,p,n,l);if(h.is(".input-daterange")||q.inputs){var r={inputs:q.inputs||h.find("input").toArray()};h.data("cfdatepicker",i=new k(this,a.extend(q,r)))}else h.data("cfdatepicker",i=new j(this,q))}if("string"==typeof c&&"function"==typeof i[c]&&(e=i[c].apply(i,d),e!==b))return!1}),e!==b?e:this};var m=a.fn.cfdatepicker.defaults={autoclose:!1,beforeShowDay:a.noop,calendarWeeks:!1,clearBtn:!1,daysOfWeekDisabled:[],endDate:1/0,forceParse:!0,format:"mm/dd/yyyy",keyboardNavigation:!0,language:"en",minViewMode:0,multidate:!1,multidateSeparator:",",orientation:"auto",rtl:!1,startDate:-(1/0),startView:0,todayBtn:!1,todayHighlight:!1,weekStart:0},n=a.fn.cfdatepicker.locale_opts=["format","rtl","weekStart"];a.fn.cfdatepicker.Constructor=j;var o=a.fn.cfdatepicker.dates={en:{days:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday","Sunday"],daysShort:["Sun","Mon","Tue","Wed","Thu","Fri","Sat","Sun"],daysMin:["Su","Mo","Tu","We","Th","Fr","Sa","Su"],months:["January","February","March","April","May","June","July","August","September","October","November","December"],monthsShort:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],today:"Today",clear:"Clear"}},p={modes:[{clsName:"days",navFnc:"Month",navStep:1},{clsName:"months",navFnc:"FullYear",navStep:1},{clsName:"years",navFnc:"FullYear",navStep:10}],isLeapYear:function(a){return a%4===0&&a%100!==0||a%400===0},getDaysInMonth:function(a,b){return[31,p.isLeapYear(a)?29:28,31,30,31,30,31,31,30,31,30,31][b]},validParts:/dd?|DD?|mm?|MM?|yy(?:yy)?/g,nonpunctuation:/[^ -\/:-@\[\u3400-\u9fff-`{-~\t\n\r]+/g,parseFormat:function(a){var b=a.replace(this.validParts,"\0").split("\0"),c=a.match(this.validParts);if(!b||!b.length||!c||0===c.length)throw new Error("Invalid date format.");return{separators:b,parts:c}},parseDate:function(d,e,f){function g(){var a=this.slice(0,m[k].length),b=m[k].slice(0,a.length);return a===b}if(!d)return b;if(d instanceof Date)return d;"string"==typeof e&&(e=p.parseFormat(e));var h,i,k,l=/([\-+]\d+)([dmwy])/,m=d.match(/([\-+]\d+)([dmwy])/g);if(/^[\-+]\d+[dmwy]([\s,]+[\-+]\d+[dmwy])*$/.test(d)){for(d=new Date,k=0;k<m.length;k++)switch(h=l.exec(m[k]),i=parseInt(h[1]),h[2]){case"d":d.setUTCDate(d.getUTCDate()+i);break;case"m":d=j.prototype.moveMonth.call(j.prototype,d,i);break;case"w":d.setUTCDate(d.getUTCDate()+7*i);break;case"y":d=j.prototype.moveYear.call(j.prototype,d,i)}return c(d.getUTCFullYear(),d.getUTCMonth(),d.getUTCDate(),0,0,0)}m=d&&d.match(this.nonpunctuation)||[],d=new Date;var n,q,r={},s=["yyyy","yy","M","MM","m","mm","d","dd"],t={yyyy:function(a,b){return a.setUTCFullYear(b)},yy:function(a,b){return a.setUTCFullYear(2e3+b)},m:function(a,b){if(isNaN(a))return a;for(b-=1;b<0;)b+=12;for(b%=12,a.setUTCMonth(b);a.getUTCMonth()!==b;)a.setUTCDate(a.getUTCDate()-1);return a},d:function(a,b){return a.setUTCDate(b)}};t.M=t.MM=t.mm=t.m,t.dd=t.d,d=c(d.getFullYear(),d.getMonth(),d.getDate(),0,0,0);var u=e.parts.slice();if(m.length!==u.length&&(u=a(u).filter(function(b,c){return a.inArray(c,s)!==-1}).toArray()),m.length===u.length){var v;for(k=0,v=u.length;k<v;k++){if(n=parseInt(m[k],10),h=u[k],isNaN(n))switch(h){case"MM":q=a(o[f].months).filter(g),n=a.inArray(q[0],o[f].months)+1;break;case"M":q=a(o[f].monthsShort).filter(g),n=a.inArray(q[0],o[f].monthsShort)+1}r[h]=n}var w,x;for(k=0;k<s.length;k++)x=s[k],x in r&&!isNaN(r[x])&&(w=new Date(d),t[x](w,r[x]),isNaN(w)||(d=w))}return d},formatDate:function(b,c,d){if(!b)return"";"string"==typeof c&&(c=p.parseFormat(c));var e={d:b.getUTCDate(),D:o[d].daysShort[b.getUTCDay()],DD:o[d].days[b.getUTCDay()],m:b.getUTCMonth()+1,M:o[d].monthsShort[b.getUTCMonth()],MM:o[d].months[b.getUTCMonth()],yy:b.getUTCFullYear().toString().substring(2),yyyy:b.getUTCFullYear()};e.dd=(e.d<10?"0":"")+e.d,e.mm=(e.m<10?"0":"")+e.m,b=[];for(var f=a.extend([],c.separators),g=0,h=c.parts.length;g<=h;g++)f.length&&b.push(f.shift()),b.push(e[c.parts[g]]);return b.join("")},headTemplate:'<thead><tr><th class="prev">&laquo;</th><th colspan="5" class="cfdatepicker-switch"></th><th class="next">&raquo;</th></tr></thead>',contTemplate:'<tbody><tr><td colspan="7"></td></tr></tbody>',footTemplate:'<tfoot><tr><th colspan="7" class="today"></th></tr><tr><th colspan="7" class="clear"></th></tr></tfoot>'};p.template='<div class="cfdatepicker"><div class="cfdatepicker-days"><table class=" table-condensed">'+p.headTemplate+"<tbody></tbody>"+p.footTemplate+'</table></div><div class="cfdatepicker-months"><table class="table-condensed">'+p.headTemplate+p.contTemplate+p.footTemplate+'</table></div><div class="cfdatepicker-years"><table class="table-condensed">'+p.headTemplate+p.contTemplate+p.footTemplate+"</table></div></div>",a.fn.cfdatepicker.DPGlobal=p,a.fn.cfdatepicker.noConflict=function(){return a.fn.cfdatepicker=l,this},a(document).on("focus.cfdatepicker.data-api click.cfdatepicker.data-api",'[data-provide="cfdatepicker"]',function(b){var c=a(this);c.data("cfdatepicker")||(b.preventDefault(),c.cfdatepicker("show").on("show",function(){a(this).trigger("blur")}).on("hide",function(){a(this).attr("disabled",!1)}))})}(window.jQuery),!function(a){function b(a){var b=document.createElement("input"),c="on"+a,d=c in b;return d||(b.setAttribute(c,"return;"),d="function"==typeof b[c]),b=null,d}function c(a){var b="text"==a||"tel"==a;if(!b){var c=document.createElement("input");c.setAttribute("type",a),b="text"===c.type,c=null}return b}function d(b,c,e){var f=e.aliases[b];return!!f&&(f.alias&&d(f.alias,void 0,e),a.extend(!0,e,f),a.extend(!0,e,c),!0)}function e(b,c){function d(a){function c(a,b,c,d){this.matches=[],this.isGroup=a||!1,this.isOptional=b||!1,this.isQuantifier=c||!1,this.isAlternator=d||!1,this.quantifier={min:1,max:1}}function d(a,c,d){var e=b.definitions[c],f=0==a.matches.length;if(d=void 0!=d?d:a.matches.length,e&&!l){for(var g=e.prevalidator,h=g?g.length:0,i=1;i<e.cardinality;i++){var j=h>=i?g[i-1]:[],k=j.validator,m=j.cardinality;a.matches.splice(d++,0,{fn:k?"string"==typeof k?new RegExp(k):new function(){this.test=k}:new RegExp("."),cardinality:m?m:1,optionality:a.isOptional,newBlockMarker:f,casing:e.casing,def:e.definitionSymbol||c,placeholder:e.placeholder,mask:c})}a.matches.splice(d++,0,{fn:e.validator?"string"==typeof e.validator?new RegExp(e.validator):new function(){this.test=e.validator}:new RegExp("."),cardinality:e.cardinality,optionality:a.isOptional,newBlockMarker:f,casing:e.casing,def:e.definitionSymbol||c,placeholder:e.placeholder,mask:c})}else a.matches.splice(d++,0,{fn:null,cardinality:0,optionality:a.isOptional,newBlockMarker:f,casing:null,def:c,placeholder:void 0,mask:c}),l=!1}for(var e,f,g,h,i,j,k=/(?:[?*+]|\{[0-9\+\*]+(?:,[0-9\+\*]*)?\})\??|[^.?*+^${[]()|\\]+|./g,l=!1,m=new c,n=[],o=[];e=k.exec(a);)switch(f=e[0],f.charAt(0)){case b.optionalmarker.end:case b.groupmarker.end:if(g=n.pop(),n.length>0){if(h=n[n.length-1],h.matches.push(g),h.isAlternator){i=n.pop();for(var p=0;p<i.matches.length;p++)i.matches[p].isGroup=!1;n.length>0?(h=n[n.length-1],h.matches.push(i)):m.matches.push(i)}}else m.matches.push(g);break;case b.optionalmarker.start:n.push(new c(!1,!0));break;case b.groupmarker.start:n.push(new c(!0));break;case b.quantifiermarker.start:var q=new c(!1,!1,!0);f=f.replace(/[{}]/g,"");var r=f.split(","),s=isNaN(r[0])?r[0]:parseInt(r[0]),t=1==r.length?s:isNaN(r[1])?r[1]:parseInt(r[1]);if(("*"==t||"+"==t)&&(s="*"==t?0:1),q.quantifier={min:s,max:t},n.length>0){var u=n[n.length-1].matches;if(e=u.pop(),!e.isGroup){var v=new c(!0);v.matches.push(e),e=v}u.push(e),u.push(q)}else{if(e=m.matches.pop(),!e.isGroup){var v=new c(!0);v.matches.push(e),e=v}m.matches.push(e),m.matches.push(q)}break;case b.escapeChar:l=!0;break;case b.alternatormarker:n.length>0?(h=n[n.length-1],j=h.matches.pop()):j=m.matches.pop(),j.isAlternator?n.push(j):(i=new c(!1,!1,!1,!0),i.matches.push(j),n.push(i));break;default:if(n.length>0){if(h=n[n.length-1],h.matches.length>0&&(j=h.matches[h.matches.length-1],j.isGroup&&(j.isGroup=!1,d(j,b.groupmarker.start,0),d(j,b.groupmarker.end))),d(h,f),h.isAlternator){i=n.pop();for(var p=0;p<i.matches.length;p++)i.matches[p].isGroup=!1;n.length>0?(h=n[n.length-1],h.matches.push(i)):m.matches.push(i)}}else m.matches.length>0&&(j=m.matches[m.matches.length-1],j.isGroup&&(j.isGroup=!1,d(j,b.groupmarker.start,0),d(j,b.groupmarker.end))),d(m,f)}return m.matches.length>0&&(j=m.matches[m.matches.length-1],j.isGroup&&(j.isGroup=!1,d(j,b.groupmarker.start,0),d(j,b.groupmarker.end)),o.push(m)),o}function e(c,e){if(b.numericInput&&b.multi!==!0){c=c.split("").reverse();for(var f=0;f<c.length;f++)c[f]==b.optionalmarker.start?c[f]=b.optionalmarker.end:c[f]==b.optionalmarker.end?c[f]=b.optionalmarker.start:c[f]==b.groupmarker.start?c[f]=b.groupmarker.end:c[f]==b.groupmarker.end&&(c[f]=b.groupmarker.start);c=c.join("")}if(void 0!=c&&""!=c){if(1==c.length&&0==b.greedy&&0!=b.repeat&&(b.placeholder=""),b.repeat>0||"*"==b.repeat||"+"==b.repeat){var g="*"==b.repeat?0:"+"==b.repeat?1:b.repeat;c=b.groupmarker.start+c+b.groupmarker.end+b.quantifiermarker.start+g+","+b.repeat+b.quantifiermarker.end}return void 0==a.inputmask.masksCache[c]&&(a.inputmask.masksCache[c]={mask:c,maskToken:d(c),validPositions:{},_buffer:void 0,buffer:void 0,tests:{},metadata:e}),a.extend(!0,{},a.inputmask.masksCache[c])}}var f=void 0;if(a.isFunction(b.mask)&&(b.mask=b.mask.call(this,b)),a.isArray(b.mask))if(c)f=[],a.each(b.mask,function(b,c){f.push(void 0==c.mask||a.isFunction(c.mask)?e(c.toString(),c):e(c.mask.toString(),c))});else{b.keepStatic=void 0==b.keepStatic||b.keepStatic;var g="(";a.each(b.mask,function(b,c){g.length>1&&(g+=")|("),g+=void 0==c.mask||a.isFunction(c.mask)?c.toString():c.mask.toString()}),g+=")",f=e(g,b.mask)}else b.mask&&(f=void 0==b.mask.mask||a.isFunction(b.mask.mask)?e(b.mask.toString(),b.mask):e(b.mask.mask.toString(),b.mask));return f}function f(d,e,f){function h(a,b,c){b=b||0;var d,e,f,g=[],h=0;do{if(a===!0&&o().validPositions[h]){var i=o().validPositions[h];e=i.match,d=i.locator.slice(),g.push(c===!0?i.input:I(h,e))}else{if(b>h){var j=w(h,d,h-1);f=j[0]}else f=t(h,d,h-1);e=f.match,d=f.locator.slice(),g.push(I(h,e))}h++}while((void 0==fa||fa>h-1)&&null!=e.fn||null==e.fn&&""!=e.def||b>=h);return g.pop(),g}function o(){return e}function p(a){var b=o();b.buffer=void 0,b.tests={},a!==!0&&(b._buffer=void 0,b.validPositions={},b.p=0)}function q(a){var b=o(),c=-1,d=b.validPositions;void 0==a&&(a=-1);var e=c,f=c;for(var g in d){var h=parseInt(g);(-1==a||null!=d[h].match.fn)&&(a>h&&(e=h),h>=a&&(f=h))}return c=a-e>1||a>f?e:f}function r(b,c,d){if(f.insertMode&&void 0!=o().validPositions[b]&&void 0==d){var e,g=a.extend(!0,{},o().validPositions),h=q();for(e=b;h>=e;e++)delete o().validPositions[e];o().validPositions[b]=c;var i,j=!0;for(e=b;h>=e;e++){var k=g[e];if(void 0!=k){var l=o().validPositions;i=!f.keepStatic&&(void 0!=l[e+1]&&w(e+1,l[e].locator.slice(),e).length>1||l[e]&&void 0!=l[e].alternation)?e+1:E(e),j=v(i,k.match.def)?j&&B(i,k.input,!0,!0)!==!1:null==k.match.fn}if(!j)break}if(!j)return o().validPositions=a.extend(!0,{},g),!1}else o().validPositions[b]=c;return!0}function s(a,b){var c,d=a;for(void 0!=o().validPositions[a]&&o().validPositions[a].input==f.radixPoint&&(b++,d++),c=d;b>c;c++)void 0==o().validPositions[c]||o().validPositions[c].input==f.radixPoint&&c!=q()||delete o().validPositions[c];for(c=b;c<=q();){var e=o().validPositions[c],g=o().validPositions[d];void 0!=e&&void 0==g?(v(d,e.match.def)&&B(d,e.input,!0)!==!1&&(delete o().validPositions[c],c++),d++):c++}var h=q();h>=a&&void 0!=o().validPositions[h]&&o().validPositions[h].input==f.radixPoint&&delete o().validPositions[h],p(!0)}function t(b,c,d){function e(b,c,d){for(var e=!1,f=b.locator[c].toString().split(","),g=0;g<f.length;g++)if(-1!=a.inArray(f[g],d)){e=!0;break}return e}for(var g,h=w(b,c,d),i=q(),j=o().validPositions[i]||w(0)[0],k=void 0!=j.alternation?j.locator[j.alternation].split(","):[],l=0;l<h.length&&(g=h[l],!(f.greedy||g.match&&(g.match.optionality===!1||g.match.newBlockMarker===!1)&&g.match.optionalQuantifier!==!0&&(void 0==j.alternation||void 0!=g.locator[j.alternation]&&e(g,j.alternation,k))));l++);return g}function u(a){return o().validPositions[a]?o().validPositions[a].match:w(a)[0].match}function v(a,b){for(var c=!1,d=w(a),e=0;e<d.length;e++)if(d[e].match&&d[e].match.def==b){c=!0;break}return c}function w(b,c,d){function e(c,d,g,i){function l(g,i,n){if(h>1e4)return alert("jquery.inputmask: There is probably an error in your mask definition or in the code. Create an issue on github with an example of the mask you are using. "+o().mask),!0;if(h==b&&void 0==g.matches)return j.push({match:g,locator:i.reverse()}),!0;if(void 0!=g.matches){if(g.isGroup&&n!==!0){if(g=l(c.matches[m+1],i))return!0}else if(g.isOptional){var p=g;if(g=e(g,d,i,n)){var q=j[j.length-1].match,r=0==a.inArray(q,p.matches);r&&(k=!0),h=b}}else if(g.isAlternator){var s,t=g,u=[],v=j.slice(),w=i.length,x=d.length>0?d.shift():-1;if(-1==x||"string"==typeof x){var y,z=h,A=d.slice();"string"==typeof x&&(y=x.split(","));for(var B=0;B<t.matches.length;B++){j=[],g=l(t.matches[B],[B].concat(i),n)||g,s=j.slice(),h=z,j=[];for(var C=0;C<A.length;C++)d[C]=A[C];for(var D=0;D<s.length;D++)for(var E=s[D],F=0;F<u.length;F++){var G=u[F];if(E.match.mask==G.match.mask&&("string"!=typeof x||-1!=a.inArray(E.locator[w].toString(),y))){s.splice(D,1),G.locator[w]=G.locator[w]+","+E.locator[w],G.alternation=w;break}}u=u.concat(s)}"string"==typeof x&&(u=a.map(u,function(b,c){if(isFinite(c)){var d,e=b.locator[w].toString().split(",");b.locator[w]=void 0,b.alternation=void 0;for(var f=0;f<e.length;f++)d=-1!=a.inArray(e[f],y),d&&(void 0!=b.locator[w]?(b.locator[w]+=",",b.alternation=w,b.locator[w]+=e[f]):b.locator[w]=parseInt(e[f]));if(void 0!=b.locator[w])return b}})),j=v.concat(u),k=!0}else g=l(t.matches[x],[x].concat(i),n);if(g)return!0}else if(g.isQuantifier&&n!==!0){var H=g;f.greedy=f.greedy&&isFinite(H.quantifier.max);for(var I=d.length>0&&n!==!0?d.shift():0;I<(isNaN(H.quantifier.max)?I+1:H.quantifier.max)&&b>=h;I++){var J=c.matches[a.inArray(H,c.matches)-1];if(g=l(J,[I].concat(i),!0)){var q=j[j.length-1].match;q.optionalQuantifier=I>H.quantifier.min-1;var r=0==a.inArray(q,J.matches);if(r){if(I>H.quantifier.min-1){k=!0,h=b;break}return!0}return!0}}}else if(g=e(g,d,i,n))return!0}else h++}for(var m=d.length>0?d.shift():0;m<c.matches.length;m++)if(c.matches[m].isQuantifier!==!0){var n=l(c.matches[m],[m].concat(g),i);if(n&&h==b)return n;if(h>b)break}}var g=o().maskToken,h=c?d:0,i=c||[0],j=[],k=!1;if(void 0==c){for(var l,m=b-1;void 0==(l=o().validPositions[m])&&m>-1;)m--;if(void 0!=l&&m>-1)h=m,i=l.locator.slice();else{for(m=b-1;void 0==(l=o().tests[m])&&m>-1;)m--;void 0!=l&&m>-1&&(h=m,i=l[0].locator.slice())}}for(var n=i.shift();n<g.length;n++){var p=e(g[n],i,[n]);if(p&&h==b||h>b)break}return(0==j.length||k)&&j.push({match:{fn:null,cardinality:0,optionality:!0,casing:null,def:""},locator:[]}),o().tests[b]=a.extend(!0,[],j),o().tests[b]}function x(){return void 0==o()._buffer&&(o()._buffer=h(!1,1)),o()._buffer}function y(){return void 0==o().buffer&&(o().buffer=h(!0,q(),!0)),o().buffer}function z(a,b){var c=y().slice();if(a===!0)p(),a=0,b=c.length;else for(var d=a;b>d;d++)delete o().validPositions[d],delete o().tests[d];for(var d=a;b>d;d++)c[d]!=f.skipOptionalPartCharacter&&B(d,c[d],!0,!0)}function A(a,b){switch(b.casing){case"upper":a=a.toUpperCase();break;case"lower":a=a.toLowerCase()}return a}function B(b,c,d,e){function g(b,c,d,e){var g=!1;return a.each(w(b),function(h,i){for(var j=i.match,k=c?1:0,l="",m=(y(),j.cardinality);m>k;m--)l+=G(b-(m-1));if(c&&(l+=c),g=null!=j.fn?j.fn.test(l,o(),b,d,f):(c==j.def||c==f.skipOptionalPartCharacter)&&""!=j.def&&{c:j.def,pos:b},g!==!1){var n=void 0!=g.c?g.c:c;n=n==f.skipOptionalPartCharacter&&null===j.fn?j.def:n;var t=b;if(void 0!=g.remove&&s(g.remove,g.remove+1),g.refreshFromBuffer){var u=g.refreshFromBuffer;if(d=!0,z(u===!0?u:u.start,u.end),void 0==g.pos&&void 0==g.c)return g.pos=q(),!1;if(t=void 0!=g.pos?g.pos:b,t!=b)return g=a.extend(g,B(t,n,!0)),!1}else if(g!==!0&&void 0!=g.pos&&g.pos!=b&&(t=g.pos,z(b,t),t!=b))return g=a.extend(g,B(t,n,!0)),!1;return(1==g||void 0!=g.pos||void 0!=g.c)&&(h>0&&p(!0),r(t,a.extend({},i,{input:A(n,j)}),e)||(g=!1),!1)}}),g}function h(b,c,d,e){var g,h,i=a.extend(!0,{},o().validPositions);for(g=q();g>=0;g--)if(o().validPositions[g]&&void 0!=o().validPositions[g].alternation){h=o().validPositions[g].alternation;break}if(void 0!=h)for(var j in o().validPositions)if(parseInt(j)>parseInt(g)&&void 0===o().validPositions[j].alternation){for(var k=o().validPositions[j],l=k.locator[h],m=o().validPositions[g].locator[h].split(","),n=0;n<m.length;n++)if(l<m[n]){for(var r,s,t=j-1;t>=0;t--)if(r=o().validPositions[t],void 0!=r){s=r.locator[h],r.locator[h]=m[n];break}if(l!=r.locator[h]){for(var u=y().slice(),v=j;v<q()+1;v++)delete o().validPositions[v],delete o().tests[v];p(!0),f.keepStatic=!f.keepStatic;for(var v=j;v<u.length;v++)u[v]!=f.skipOptionalPartCharacter&&B(q()+1,u[v],!1,!0);r.locator[h]=s;var w=B(b,c,d,e);if(f.keepStatic=!f.keepStatic,w)return w;p(),o().validPositions=a.extend(!0,{},i)}}break}return!1}d=d===!0;for(var i=y(),j=b-1;j>-1&&(!o().validPositions[j]||null!=o().validPositions[j].match.fn);j--)void 0==o().validPositions[j]&&(!C(j)||i[j]!=I(j))&&w(j).length>1&&g(j,i[j],!0);var k=b,l=!1;if(e&&k>=D()&&p(!0),k<D()&&(l=g(k,c,d,e),!d&&l===!1)){var m=o().validPositions[k];if(!m||null!=m.match.fn||m.match.def!=c&&c!=f.skipOptionalPartCharacter){if((f.insertMode||void 0==o().validPositions[E(k)])&&!C(k))for(var n=k+1,t=E(k);t>=n;n++)if(l=g(n,c,d,e),l!==!1){k=n;break}}else l={caret:E(k)}}return l===!1&&f.keepStatic&&R(i)&&(l=h(b,c,d,e)),l===!0&&(l={pos:k}),l}function C(a){var b=u(a);return null!=b.fn&&b.fn}function D(){var a;if(fa=ea.prop("maxLength"),-1==fa&&(fa=void 0),0==f.greedy){var b,c=q(),d=o().validPositions[c],e=void 0!=d?d.locator.slice():void 0;for(b=c+1;void 0==d||null!=d.match.fn||null==d.match.fn&&""!=d.match.def;b++)d=t(b,e,b-1),e=d.locator.slice();a=b}else a=y().length;return void 0==fa||fa>a?a:fa}function E(a){var b=D();if(a>=b)return b;for(var c=a;++c<b&&!C(c)&&(f.nojumps!==!0||f.nojumpsThreshold>c););return c}function F(a){var b=a;if(0>=b)return 0;for(;--b>0&&!C(b););return b}function G(a){return void 0==o().validPositions[a]?I(a):o().validPositions[a].input}function H(a,b,c){a._valueSet(b.join("")),void 0!=c&&O(a,c)}function I(b,c){c=c||u(b);var d=a.isFunction(c.placeholder)?c.placeholder.call(this,f):c.placeholder;return void 0!=d?d:null==c.fn?c.def:f.placeholder.charAt(b%f.placeholder.length)}function J(b,c,d,e,g){var h=void 0!=e?e.slice():L(b._valueGet()).split("");if(p(),c&&b._valueSet(""),a.each(h,function(c,e){if(g===!0){var f=q(),h=-1==f?c:E(f);-1==a.inArray(e,x().slice(f+1,h))&&Y.call(b,void 0,!0,e.charCodeAt(0),!1,d,d?c:o().p)}else Y.call(b,void 0,!0,e.charCodeAt(0),!1,d,d?c:o().p),d=d||c>0&&c>o().p}),c){var i=f.onKeyPress.call(this,void 0,y(),0,f);W(b,i),H(b,y(),a(b).is(":focus")?E(q(0)):void 0)}}function K(b){return a.inputmask.escapeRegex.call(this,b)}function L(a){return a.replace(new RegExp("("+K(x().join(""))+")*$"),"")}function M(b){if(b.data("_inputmask")&&!b.hasClass("hasDatepicker")){var c=[],d=o().validPositions;for(var e in d)d[e].match&&null!=d[e].match.fn&&c.push(d[e].input);var g=(ga?c.reverse():c).join(""),h=(ga?y().slice().reverse():y()).join("");return a.isFunction(f.onUnMask)&&(g=f.onUnMask.call(b,h,g,f)||g),g}return b[0]._valueGet()}function N(a){if(ga&&"number"==typeof a&&(!f.greedy||""!=f.placeholder)){var b=y().length;a=b-a}return a}function O(b,c,d){var e,g=b.jquery&&b.length>0?b[0]:b;if("number"!=typeof c){var h=a(g).data("_inputmask");return!a(g).is(":visible")&&h&&void 0!=h.caret?(c=h.caret.begin,d=h.caret.end):g.setSelectionRange?(c=g.selectionStart,d=g.selectionEnd):document.selection&&document.selection.createRange&&(e=document.selection.createRange(),c=0-e.duplicate().moveStart("character",-1e5),d=c+e.text.length),c=N(c),d=N(d),{begin:c,end:d}}c=N(c),d=N(d),d="number"==typeof d?d:c;var h=a(g).data("_inputmask")||{};h.caret={begin:c,end:d},a(g).data("_inputmask",h),a(g).is(":visible")&&(g.scrollLeft=g.scrollWidth,0==f.insertMode&&c==d&&d++,g.setSelectionRange?(g.selectionStart=c,g.selectionEnd=d):g.createTextRange&&(e=g.createTextRange(),e.collapse(!0),e.moveEnd("character",d),e.moveStart("character",c),e.select()))}function P(b){var c,d,e=y(),f=e.length,g=q(),h={},i=o().validPositions[g],j=void 0!=i?i.locator.slice():void 0;for(c=g+1;c<e.length;c++)d=t(c,j,c-1),j=d.locator.slice(),h[c]=a.extend(!0,{},d);var k=i&&void 0!=i.alternation?i.locator[i.alternation].split(","):[];for(c=f-1;c>g&&(d=h[c].match,(d.optionality||d.optionalQuantifier||i&&void 0!=i.alternation&&void 0!=h[c].locator[i.alternation]&&-1!=a.inArray(h[c].locator[i.alternation].toString(),k))&&e[c]==I(c,d));c--)f--;return b?{l:f,def:h[f]?h[f].match:void 0}:f}function Q(a){for(var b=y(),c=b.slice(),d=P(),e=c.length-1;e>d&&!C(e);e--);c.splice(d,e+1-d),H(a,c)}function R(b){if(a.isFunction(f.isComplete))return f.isComplete.call(ea,b,f);if("*"!=f.repeat){var c=!1,d=P(!0),e=F(d.l),g=q();if(g==e&&(void 0==d.def||d.def.newBlockMarker||d.def.optionalQuantifier)){c=!0;for(var h=0;e>=h;h++){var i=C(h);if(i&&(void 0==b[h]||b[h]==I(h))||!i&&b[h]!=I(h)){c=!1;break}}}return c}}function S(a,b){return ga?a-b>1||a-b==1&&f.insertMode:b-a>1||b-a==1&&f.insertMode}function T(b){var c=a._data(b).events;a.each(c,function(b,c){a.each(c,function(a,b){if("inputmask"==b.namespace&&"setvalue"!=b.type){var c=b.handler;b.handler=function(a){return this.readOnly||this.disabled?void a.preventDefault:c.apply(this,arguments)}}})})}function U(b){function c(b){if(void 0==a.valHooks[b]||1!=a.valHooks[b].inputmaskpatch){var c=a.valHooks[b]&&a.valHooks[b].get?a.valHooks[b].get:function(a){return a.value},d=a.valHooks[b]&&a.valHooks[b].set?a.valHooks[b].set:function(a,b){return a.value=b,a};a.valHooks[b]={get:function(b){var d=a(b);if(d.data("_inputmask")){if(d.data("_inputmask").opts.autoUnmask)return d.inputmask("unmaskedvalue");var e=c(b),f=d.data("_inputmask"),g=f.maskset,h=g._buffer;return h=h?h.join(""):"",e!=h?e:""}return c(b)},set:function(b,c){var e,f=a(b),g=f.data("_inputmask");return g?(e=d(b,a.isFunction(g.opts.onBeforeMask)?g.opts.onBeforeMask.call(oa,c,g.opts)||c:c),f.triggerHandler("setvalue.inputmask")):e=d(b,c),e},inputmaskpatch:!0}}}function d(){var b=a(this),c=a(this).data("_inputmask");return c?c.opts.autoUnmask?b.inputmask("unmaskedvalue"):g.call(this)!=x().join("")?g.call(this):"":g.call(this)}function e(b){var c=a(this).data("_inputmask");c?(h.call(this,a.isFunction(c.opts.onBeforeMask)?c.opts.onBeforeMask.call(oa,b,c.opts)||b:b),a(this).triggerHandler("setvalue.inputmask")):h.call(this,b)}function f(b){a(b).bind("mouseenter.inputmask",function(){var b=a(this),c=this,d=c._valueGet();""!=d&&d!=y().join("")&&b.trigger("setvalue")});var c=a._data(b).events,d=c.mouseover;if(d){for(var e=d[d.length-1],f=d.length-1;f>0;f--)d[f]=d[f-1];d[0]=e}}var g,h;b._valueGet||(Object.getOwnPropertyDescriptor&&Object.getOwnPropertyDescriptor(b,"value"),document.__lookupGetter__&&b.__lookupGetter__("value")?(g=b.__lookupGetter__("value"),h=b.__lookupSetter__("value"),b.__defineGetter__("value",d),b.__defineSetter__("value",e)):(g=function(){return b.value},h=function(a){b.value=a},c(b.type),f(b)),b._valueGet=function(){return ga?g.call(this).split("").reverse().join(""):g.call(this)},b._valueSet=function(a){h.call(this,ga?a.split("").reverse().join(""):a)})}function V(b,c,d){function e(){if(f.keepStatic){p(!0);var a,c=[];for(a=q();a>=0;a--)if(o().validPositions[a]){if(void 0!=o().validPositions[a].alternation)break;c.push(o().validPositions[a].input),delete o().validPositions[a]}if(a>0)for(;c.length>0;)o().p=E(q()),Y.call(b,void 0,!0,c.pop().charCodeAt(0),!1,!1,o().p)}}if((f.numericInput||ga)&&(c==a.inputmask.keyCode.BACKSPACE?c=a.inputmask.keyCode.DELETE:c==a.inputmask.keyCode.DELETE&&(c=a.inputmask.keyCode.BACKSPACE),ga)){var g=d.end;d.end=d.begin,d.begin=g}c==a.inputmask.keyCode.BACKSPACE&&d.end-d.begin<=1?d.begin=F(d.begin):c==a.inputmask.keyCode.DELETE&&d.begin==d.end&&d.end++,s(d.begin,d.end),e();var h=q(d.begin);h<d.begin?(-1==h&&p(),o().p=E(h)):o().p=d.begin}function W(a,b,c){if(b&&b.refreshFromBuffer){var d=b.refreshFromBuffer;z(d===!0?d:d.start,d.end),p(!0),void 0!=c&&(H(a,y()),O(a,b.caret||c.begin,b.caret||c.end))}}function X(c){ha=!1;var d=this,e=a(d),g=c.keyCode,h=O(d);g==a.inputmask.keyCode.BACKSPACE||g==a.inputmask.keyCode.DELETE||i&&127==g||c.ctrlKey&&88==g&&!b("cut")?(c.preventDefault(),88==g&&(da=y().join("")),V(d,g,h),H(d,y(),o().p),d._valueGet()==x().join("")&&e.trigger("cleared"),f.showTooltip&&e.prop("title",o().mask)):g==a.inputmask.keyCode.END||g==a.inputmask.keyCode.PAGE_DOWN?setTimeout(function(){var a=E(q());f.insertMode||a!=D()||c.shiftKey||a--,O(d,c.shiftKey?h.begin:a,a)},0):g==a.inputmask.keyCode.HOME&&!c.shiftKey||g==a.inputmask.keyCode.PAGE_UP?O(d,0,c.shiftKey?h.begin:0):g==a.inputmask.keyCode.ESCAPE||90==g&&c.ctrlKey?(J(d,!0,!1,da.split("")),e.click()):g!=a.inputmask.keyCode.INSERT||c.shiftKey||c.ctrlKey?0!=f.insertMode||c.shiftKey||(g==a.inputmask.keyCode.RIGHT?setTimeout(function(){var a=O(d);O(d,a.begin)},0):g==a.inputmask.keyCode.LEFT&&setTimeout(function(){var a=O(d);O(d,ga?a.begin+1:a.begin-1)},0)):(f.insertMode=!f.insertMode,O(d,f.insertMode||h.begin!=D()?h.begin:h.begin-1));var j=O(d),k=f.onKeyDown.call(this,c,y(),j.begin,f);W(d,k,j),ja=-1!=a.inArray(g,f.ignorables)}function Y(b,c,d,e,g,h){if(void 0==d&&ha)return!1;ha=!0;var i=this,j=a(i);b=b||window.event;var d=c?d:b.which||b.charCode||b.keyCode;if(!(c===!0||b.ctrlKey&&b.altKey)&&(b.ctrlKey||b.metaKey||ja))return!0;if(d){c!==!0&&46==d&&0==b.shiftKey&&","==f.radixPoint&&(d=44);var k,l=c?{begin:h,end:h}:O(i),m=String.fromCharCode(d),n=S(l.begin,l.end);n&&(o().undoPositions=a.extend(!0,{},o().validPositions),V(i,a.inputmask.keyCode.DELETE,l),f.insertMode||(f.insertMode=!f.insertMode,r(l.begin,g),f.insertMode=!f.insertMode),n=!f.multi),o().writeOutBuffer=!0;var q=ga&&!n?l.end:l.begin,s=B(q,m,g);if(s!==!1){if(s!==!0&&(q=void 0!=s.pos?s.pos:q,m=void 0!=s.c?s.c:m),p(!0),void 0!=s.caret)k=s.caret;else{var t=o().validPositions;k=!f.keepStatic&&(void 0!=t[q+1]&&w(q+1,t[q].locator.slice(),q).length>1||void 0!=t[q].alternation)?q+1:E(q)}o().p=k}if(e!==!1){var u=this;if(setTimeout(function(){f.onKeyValidation.call(u,s,f)},0),o().writeOutBuffer&&s!==!1){var v=y();H(i,v,c?void 0:f.numericInput?F(k):k),c!==!0&&setTimeout(function(){R(v)===!0&&j.trigger("complete"),ia=!0,j.trigger("input")},0)}else n&&(o().buffer=void 0,o().validPositions=o().undoPositions)}else n&&(o().buffer=void 0,o().validPositions=o().undoPositions);if(f.showTooltip&&j.prop("title",o().mask),b&&1!=c){b.preventDefault();var x=O(i),z=f.onKeyPress.call(this,b,y(),x.begin,f);W(i,z,x)}}}function Z(b){var c=a(this),d=this,e=b.keyCode,g=y(),h=O(d),i=f.onKeyUp.call(this,b,g,h.begin,f);W(d,i,h),e==a.inputmask.keyCode.TAB&&f.showMaskOnFocus&&(c.hasClass("focus-inputmask")&&0==d._valueGet().length?(p(),g=y(),H(d,g),O(d,0),da=y().join("")):(H(d,g),O(d,N(0),N(D()))))}function $(b){if(ia===!0&&"input"==b.type)return ia=!1,!0;var c=this,d=a(c),e=c._valueGet(),g=O(c);if("propertychange"==b.type&&c._valueGet().length<=D())return!0;"paste"==b.type&&(window.clipboardData&&window.clipboardData.getData?e=e.substr(0,g.begin)+window.clipboardData.getData("Text")+e.substr(g.end,e.length):b.originalEvent&&b.originalEvent.clipboardData&&b.originalEvent.clipboardData.getData&&(e=e.substr(0,g.begin)+b.originalEvent.clipboardData.getData("text/plain")+e.substr(g.end,e.length)));
3
- var h=a.isFunction(f.onBeforePaste)?f.onBeforePaste.call(c,e,f)||e:e;return J(c,!0,!1,ga?h.split("").reverse():h.split(""),!0),d.click(),R(y())===!0&&d.trigger("complete"),!1}function _(b){if(ia===!0&&"input"==b.type)return ia=!1,!0;var c=this,d=O(c),e=c._valueGet();e=e.replace(new RegExp("("+K(x().join(""))+")*"),""),d.begin>e.length&&(O(c,e.length),d=O(c)),y().length-e.length!=1||e.charAt(d.begin)==y()[d.begin]||e.charAt(d.begin+1)==y()[d.begin]||C(d.begin)||(b.keyCode=a.inputmask.keyCode.BACKSPACE,X.call(c,b)),b.preventDefault()}function aa(b){if(ia===!0&&"input"==b.type)return ia=!1,!0;var c=this,d=O(c),e=c._valueGet();O(c,d.begin-1);var g=a.Event("keypress");g.which=e.charCodeAt(d.begin-1),ha=!1,ja=!1,Y.call(c,g,void 0,void 0,!1);var h=o().p;H(c,y(),f.numericInput?F(h):h),b.preventDefault()}function ba(b){ia=!0;var c=this;return setTimeout(function(){O(c,O(c).begin-1);var d=a.Event("keypress");d.which=b.originalEvent.data.charCodeAt(0),ha=!1,ja=!1,Y.call(c,d,void 0,void 0,!1);var e=o().p;H(c,y(),f.numericInput?F(e):e)},0),!1}function ca(b){if(ea=a(b),ea.is(":input")&&c(ea.attr("type"))){if(ea.data("_inputmask",{maskset:e,opts:f,isRTL:!1}),f.showTooltip&&ea.prop("title",o().mask),("rtl"==b.dir||f.rightAlign)&&ea.css("text-align","right"),"rtl"==b.dir||f.numericInput){b.dir="ltr",ea.removeAttr("dir");var d=ea.data("_inputmask");d.isRTL=!0,ea.data("_inputmask",d),ga=!0}ea.unbind(".inputmask"),ea.removeClass("focus-inputmask"),ea.closest("form").bind("submit",function(){da!=y().join("")&&ea.change(),ea[0]._valueGet&&ea[0]._valueGet()==x().join("")&&ea[0]._valueSet(""),f.autoUnmask&&f.removeMaskOnSubmit&&ea.inputmask("remove")}).bind("reset",function(){setTimeout(function(){ea.trigger("setvalue")},0)}),ea.bind("mouseenter.inputmask",function(){var b=a(this),c=this;!b.hasClass("focus-inputmask")&&f.showMaskOnHover&&c._valueGet()!=y().join("")&&H(c,y())}).bind("blur.inputmask",function(){var b=a(this),c=this;if(b.data("_inputmask")){var d=c._valueGet(),e=y();b.removeClass("focus-inputmask"),da!=y().join("")&&b.change(),f.clearMaskOnLostFocus&&""!=d&&(d==x().join("")?c._valueSet(""):Q(c)),R(e)===!1&&(b.trigger("incomplete"),f.clearIncomplete&&(p(),f.clearMaskOnLostFocus?c._valueSet(""):(e=x().slice(),H(c,e))))}}).bind("focus.inputmask",function(){var b=a(this),c=this,d=c._valueGet();f.showMaskOnFocus&&!b.hasClass("focus-inputmask")&&(!f.showMaskOnHover||f.showMaskOnHover&&""==d)&&c._valueGet()!=y().join("")&&H(c,y(),E(q())),b.addClass("focus-inputmask"),da=y().join("")}).bind("mouseleave.inputmask",function(){var b=a(this),c=this;f.clearMaskOnLostFocus&&(b.hasClass("focus-inputmask")||c._valueGet()==b.attr("placeholder")||(c._valueGet()==x().join("")||""==c._valueGet()?c._valueSet(""):Q(c)))}).bind("click.inputmask",function(){var b=this;a(b).is(":focus")&&setTimeout(function(){var c=O(b);if(c.begin==c.end)if(f.radixFocus&&""!=f.radixPoint&&-1!=a.inArray(f.radixPoint,y())&&y().join("")==x().join(""))O(b,a.inArray(f.radixPoint,y()));else{var d=ga?N(c.begin):c.begin,e=E(q(d));e>d?O(b,C(d)?d:E(d)):O(b,e)}},0)}).bind("dblclick.inputmask",function(){var a=this;setTimeout(function(){O(a,0,E(q()))},0)}).bind(n+".inputmask dragdrop.inputmask drop.inputmask",$).bind("setvalue.inputmask",function(){var a=this;J(a,!0,!1,void 0,!0),da=y().join(""),(f.clearMaskOnLostFocus||f.clearIncomplete)&&a._valueGet()==x().join("")&&a._valueSet("")}).bind("cut.inputmask",function(b){ia=!0;var c=this,d=a(c),e=O(c);V(c,a.inputmask.keyCode.DELETE,e);var g=f.onKeyPress.call(this,b,y(),o().p,f);W(c,g,{begin:o().p,end:o().p}),c._valueGet()==x().join("")&&d.trigger("cleared"),f.showTooltip&&d.prop("title",o().mask)}).bind("complete.inputmask",f.oncomplete).bind("incomplete.inputmask",f.onincomplete).bind("cleared.inputmask",f.oncleared),ea.bind("keydown.inputmask",X).bind("keypress.inputmask",Y).bind("keyup.inputmask",Z).bind("compositionupdate.inputmask",ba),"paste"!==n||g||ea.bind("input.inputmask",aa),g&&ea.bind("input.inputmask",$),(j||l||k||m)&&("input"==n&&ea.unbind(n+".inputmask"),ea.bind("input.inputmask",_)),U(b);var h=a.isFunction(f.onBeforeMask)?f.onBeforeMask.call(b,b._valueGet(),f)||b._valueGet():b._valueGet();J(b,!0,!1,h.split(""),!0),da=y().join("");var i;try{i=document.activeElement}catch(a){}R(y())===!1&&f.clearIncomplete&&p(),f.clearMaskOnLostFocus?y().join("")==x().join("")?b._valueSet(""):Q(b):H(b,y()),i===b&&(ea.addClass("focus-inputmask"),O(b,E(q()))),T(b)}}var da,ea,fa,ga=!1,ha=!1,ia=!1,ja=!1;if(void 0!=d)switch(d.action){case"isComplete":return ea=a(d.el),e=ea.data("_inputmask").maskset,f=ea.data("_inputmask").opts,R(d.buffer);case"unmaskedvalue":return ea=d.$input,e=ea.data("_inputmask").maskset,f=ea.data("_inputmask").opts,ga=d.$input.data("_inputmask").isRTL,M(d.$input);case"mask":da=y().join(""),ca(d.el);break;case"format":ea=a({}),ea.data("_inputmask",{maskset:e,opts:f,isRTL:f.numericInput}),f.numericInput&&(ga=!0);var ka=(a.isFunction(f.onBeforeMask)?f.onBeforeMask.call(ea,d.value,f)||d.value:d.value).split("");return J(ea,!1,!1,ga?ka.reverse():ka,!0),f.onKeyPress.call(this,void 0,y(),0,f),d.metadata?{value:ga?y().slice().reverse().join(""):y().join(""),metadata:ea.inputmask("getmetadata")}:ga?y().slice().reverse().join(""):y().join("");case"isValid":ea=a({}),ea.data("_inputmask",{maskset:e,opts:f,isRTL:f.numericInput}),f.numericInput&&(ga=!0);var ka=d.value.split("");J(ea,!1,!0,ga?ka.reverse():ka);for(var la=y(),ma=P(),na=la.length-1;na>ma&&!C(na);na--);return la.splice(ma,na+1-ma),R(la)&&d.value==la.join("");case"getemptymask":return ea=a(d.el),e=ea.data("_inputmask").maskset,f=ea.data("_inputmask").opts,x();case"remove":var oa=d.el;ea=a(oa),e=ea.data("_inputmask").maskset,f=ea.data("_inputmask").opts,oa._valueSet(M(ea)),ea.unbind(".inputmask"),ea.removeClass("focus-inputmask"),ea.removeData("_inputmask");var pa;Object.getOwnPropertyDescriptor&&(pa=Object.getOwnPropertyDescriptor(oa,"value")),pa&&pa.get?oa._valueGet&&Object.defineProperty(oa,"value",{get:oa._valueGet,set:oa._valueSet}):document.__lookupGetter__&&oa.__lookupGetter__("value")&&oa._valueGet&&(oa.__defineGetter__("value",oa._valueGet),oa.__defineSetter__("value",oa._valueSet));try{delete oa._valueGet,delete oa._valueSet}catch(a){oa._valueGet=void 0,oa._valueSet=void 0}break;case"getmetadata":if(ea=a(d.el),e=ea.data("_inputmask").maskset,f=ea.data("_inputmask").opts,a.isArray(e.metadata)){for(var qa,ra=q(),sa=ra;sa>=0;sa--)if(o().validPositions[sa]&&void 0!=o().validPositions[sa].alternation){qa=o().validPositions[sa].alternation;break}return void 0!=qa?e.metadata[o().validPositions[ra].locator[qa]]:e.metadata[0]}return e.metadata}}if(void 0===a.fn.inputmask){var g="function"==typeof ScriptEngineMajorVersion?ScriptEngineMajorVersion():new Function("/*@cc_on return @_jscript_version; @*/")()>=10,h=navigator.userAgent,i=null!==h.match(new RegExp("iphone","i")),j=null!==h.match(new RegExp("android.*safari.*","i")),k=null!==h.match(new RegExp("android.*chrome.*","i")),l=null!==h.match(new RegExp("android.*firefox.*","i")),m=/Kindle/i.test(h)||/Silk/i.test(h)||/KFTT/i.test(h)||/KFOT/i.test(h)||/KFJWA/i.test(h)||/KFJWI/i.test(h)||/KFSOWI/i.test(h)||/KFTHWA/i.test(h)||/KFTHWI/i.test(h)||/KFAPWA/i.test(h)||/KFAPWI/i.test(h),n=b("paste")?"paste":b("input")?"input":"propertychange";a.inputmask={defaults:{placeholder:"_",optionalmarker:{start:"[",end:"]"},quantifiermarker:{start:"{",end:"}"},groupmarker:{start:"(",end:")"},alternatormarker:"|",escapeChar:"\\",mask:null,oncomplete:a.noop,onincomplete:a.noop,oncleared:a.noop,repeat:0,greedy:!0,autoUnmask:!1,removeMaskOnSubmit:!0,clearMaskOnLostFocus:!0,insertMode:!0,clearIncomplete:!1,aliases:{},alias:null,onKeyUp:a.noop,onKeyPress:a.noop,onKeyDown:a.noop,onBeforeMask:void 0,onBeforePaste:void 0,onUnMask:void 0,showMaskOnFocus:!0,showMaskOnHover:!0,onKeyValidation:a.noop,skipOptionalPartCharacter:" ",showTooltip:!1,numericInput:!1,rightAlign:!1,radixPoint:"",radixFocus:!1,nojumps:!1,nojumpsThreshold:0,keepStatic:void 0,definitions:{9:{validator:"[0-9]",cardinality:1,definitionSymbol:"*"},a:{validator:"[A-Za-zА-яЁёÀ-ÿµ]",cardinality:1,definitionSymbol:"*"},"*":{validator:"[0-9A-Za-zА-яЁёÀ-ÿµ]",cardinality:1}},ignorables:[8,9,13,19,27,33,34,35,36,37,38,39,40,45,46,93,112,113,114,115,116,117,118,119,120,121,122,123],isComplete:void 0},keyCode:{ALT:18,BACKSPACE:8,CAPS_LOCK:20,COMMA:188,COMMAND:91,COMMAND_LEFT:91,COMMAND_RIGHT:93,CONTROL:17,DELETE:46,DOWN:40,END:35,ENTER:13,ESCAPE:27,HOME:36,INSERT:45,LEFT:37,MENU:93,NUMPAD_ADD:107,NUMPAD_DECIMAL:110,NUMPAD_DIVIDE:111,NUMPAD_ENTER:108,NUMPAD_MULTIPLY:106,NUMPAD_SUBTRACT:109,PAGE_DOWN:34,PAGE_UP:33,PERIOD:190,RIGHT:39,SHIFT:16,SPACE:32,TAB:9,UP:38,WINDOWS:91},masksCache:{},escapeRegex:function(a){var b=["/",".","*","+","?","|","(",")","[","]","{","}","\\"];return a.replace(new RegExp("(\\"+b.join("|\\")+")","gim"),"\\$1")},format:function(b,c,g){var h=a.extend(!0,{},a.inputmask.defaults,c);return d(h.alias,c,h),f({action:"format",value:b,metadata:g},e(h),h)},isValid:function(b,c){var g=a.extend(!0,{},a.inputmask.defaults,c);return d(g.alias,c,g),f({action:"isValid",value:b},e(g),g)}},a.fn.inputmask=function(b,c,g,h,i){function j(b,c,e){var f=a(b);f.data("inputmask-alias")&&d(f.data("inputmask-alias"),{},c);for(var g in c){var h=f.data("inputmask-"+g.toLowerCase());void 0!=h&&("mask"==g&&0==h.indexOf("[")?(c[g]=h.replace(/[\s[\]]/g,"").split("','"),c[g][0]=c[g][0].replace("'",""),c[g][c[g].length-1]=c[g][c[g].length-1].replace("'","")):c[g]="boolean"==typeof h?h:h.toString(),e&&(e[g]=c[g]))}return c}g=g||f,h=h||"_inputmask";var k,l=a.extend(!0,{},a.inputmask.defaults,c);if("string"==typeof b)switch(b){case"mask":return d(l.alias,c,l),k=e(l,g!==f),void 0==k?this:this.each(function(){g({action:"mask",el:this},a.extend(!0,{},k),j(this,l))});case"unmaskedvalue":var m=a(this);return m.data(h)?g({action:"unmaskedvalue",$input:m}):m.val();case"remove":return this.each(function(){var b=a(this);b.data(h)&&g({action:"remove",el:this})});case"getemptymask":return this.data(h)?g({action:"getemptymask",el:this}):"";case"hasMaskedValue":return!!this.data(h)&&!this.data(h).opts.autoUnmask;case"isComplete":return!this.data(h)||g({action:"isComplete",buffer:this[0]._valueGet().split(""),el:this});case"getmetadata":return this.data(h)?g({action:"getmetadata",el:this}):void 0;case"_detectScope":return d(l.alias,c,l),void 0==i||d(i,c,l)||-1!=a.inArray(i,["mask","unmaskedvalue","remove","getemptymask","hasMaskedValue","isComplete","getmetadata","_detectScope"])||(l.mask=i),a.isFunction(l.mask)&&(l.mask=l.mask.call(this,l)),a.isArray(l.mask);default:return d(l.alias,c,l),d(b,c,l)||(l.mask=b),k=e(l,g!==f),void 0==k?this:this.each(function(){g({action:"mask",el:this},a.extend(!0,{},k),j(this,l))})}else{if("object"==typeof b)return l=a.extend(!0,{},a.inputmask.defaults,b),d(l.alias,b,l),k=e(l,g!==f),void 0==k?this:this.each(function(){g({action:"mask",el:this},a.extend(!0,{},k),j(this,l))});if(void 0==b)return this.each(function(){var b=a(this).attr("data-inputmask");if(b&&""!=b)try{b=b.replace(new RegExp("'","g"),'"');var e=a.parseJSON("{"+b+"}");a.extend(!0,e,c),l=a.extend(!0,{},a.inputmask.defaults,e),l=j(this,l),d(l.alias,e,l),l.alias=void 0,a(this).inputmask("mask",l,g)}catch(a){}if(a(this).attr("data-inputmask-mask")||a(this).attr("data-inputmask-alias")){l=a.extend(!0,{},a.inputmask.defaults,{});var f={};l=j(this,l,f),d(l.alias,f,l),l.alias=void 0,a(this).inputmask("mask",l,g)}})}}}return a.fn.inputmask}(jQuery),function(a){return a.extend(a.inputmask.defaults.definitions,{h:{validator:"[01][0-9]|2[0-3]",cardinality:2,prevalidator:[{validator:"[0-2]",cardinality:1}]},s:{validator:"[0-5][0-9]",cardinality:2,prevalidator:[{validator:"[0-5]",cardinality:1}]},d:{validator:"0[1-9]|[12][0-9]|3[01]",cardinality:2,prevalidator:[{validator:"[0-3]",cardinality:1}]},m:{validator:"0[1-9]|1[012]",cardinality:2,prevalidator:[{validator:"[01]",cardinality:1}]},y:{validator:"(19|20)\\d{2}",cardinality:4,prevalidator:[{validator:"[12]",cardinality:1},{validator:"(19|20)",cardinality:2},{validator:"(19|20)\\d",cardinality:3}]}}),a.extend(a.inputmask.defaults.aliases,{"dd/mm/yyyy":{mask:"1/2/y",placeholder:"dd/mm/yyyy",regex:{val1pre:new RegExp("[0-3]"),val1:new RegExp("0[1-9]|[12][0-9]|3[01]"),val2pre:function(b){var c=a.inputmask.escapeRegex.call(this,b);return new RegExp("((0[1-9]|[12][0-9]|3[01])"+c+"[01])")},val2:function(b){var c=a.inputmask.escapeRegex.call(this,b);return new RegExp("((0[1-9]|[12][0-9])"+c+"(0[1-9]|1[012]))|(30"+c+"(0[13-9]|1[012]))|(31"+c+"(0[13578]|1[02]))")}},leapday:"29/02/",separator:"/",yearrange:{minyear:1900,maxyear:2099},isInYearRange:function(a,b,c){if(isNaN(a))return!1;var d=parseInt(a.concat(b.toString().slice(a.length))),e=parseInt(a.concat(c.toString().slice(a.length)));return!isNaN(d)&&(d>=b&&c>=d)||!isNaN(e)&&(e>=b&&c>=e)},determinebaseyear:function(a,b,c){var d=(new Date).getFullYear();if(a>d)return a;if(d>b){for(var e=b.toString().slice(0,2),f=b.toString().slice(2,4);e+c>b;)e--;var g=e+f;return a>g?a:g}return d},onKeyUp:function(b){var c=a(this);if(b.ctrlKey&&b.keyCode==a.inputmask.keyCode.RIGHT){var d=new Date;c.val(d.getDate().toString()+(d.getMonth()+1).toString()+d.getFullYear().toString())}},definitions:{1:{validator:function(a,b,c,d,e){var f=e.regex.val1.test(a);return d||f||a.charAt(1)!=e.separator&&-1=="-./".indexOf(a.charAt(1))||!(f=e.regex.val1.test("0"+a.charAt(0)))?f:(b.buffer[c-1]="0",{refreshFromBuffer:{start:c-1,end:c},pos:c,c:a.charAt(0)})},cardinality:2,prevalidator:[{validator:function(a,b,c,d,e){isNaN(b.buffer[c+1])||(a+=b.buffer[c+1]);var f=1==a.length?e.regex.val1pre.test(a):e.regex.val1.test(a);return d||f||!(f=e.regex.val1.test("0"+a))?f:(b.buffer[c]="0",c++,{pos:c})},cardinality:1}]},2:{validator:function(a,b,c,d,e){var f=e.mask.indexOf("2")==e.mask.length-1?b.buffer.join("").substr(5,3):b.buffer.join("").substr(0,3);-1!=f.indexOf(e.placeholder[0])&&(f="01"+e.separator);var g=e.regex.val2(e.separator).test(f+a);if(!d&&!g&&(a.charAt(1)==e.separator||-1!="-./".indexOf(a.charAt(1)))&&(g=e.regex.val2(e.separator).test(f+"0"+a.charAt(0))))return b.buffer[c-1]="0",{refreshFromBuffer:{start:c-1,end:c},pos:c,c:a.charAt(0)};if(e.mask.indexOf("2")==e.mask.length-1&&g){var h=b.buffer.join("").substr(4,4)+a;if(h!=e.leapday)return!0;var i=parseInt(b.buffer.join("").substr(0,4),10);return i%4===0&&(i%100!==0||i%400===0)}return g},cardinality:2,prevalidator:[{validator:function(a,b,c,d,e){isNaN(b.buffer[c+1])||(a+=b.buffer[c+1]);var f=e.mask.indexOf("2")==e.mask.length-1?b.buffer.join("").substr(5,3):b.buffer.join("").substr(0,3);-1!=f.indexOf(e.placeholder[0])&&(f="01"+e.separator);var g=1==a.length?e.regex.val2pre(e.separator).test(f+a):e.regex.val2(e.separator).test(f+a);return d||g||!(g=e.regex.val2(e.separator).test(f+"0"+a))?g:(b.buffer[c]="0",c++,{pos:c})},cardinality:1}]},y:{validator:function(a,b,c,d,e){if(e.isInYearRange(a,e.yearrange.minyear,e.yearrange.maxyear)){var f=b.buffer.join("").substr(0,6);if(f!=e.leapday)return!0;var g=parseInt(a,10);return g%4===0&&(g%100!==0||g%400===0)}return!1},cardinality:4,prevalidator:[{validator:function(a,b,c,d,e){var f=e.isInYearRange(a,e.yearrange.minyear,e.yearrange.maxyear);if(!d&&!f){var g=e.determinebaseyear(e.yearrange.minyear,e.yearrange.maxyear,a+"0").toString().slice(0,1);if(f=e.isInYearRange(g+a,e.yearrange.minyear,e.yearrange.maxyear))return b.buffer[c++]=g.charAt(0),{pos:c};if(g=e.determinebaseyear(e.yearrange.minyear,e.yearrange.maxyear,a+"0").toString().slice(0,2),f=e.isInYearRange(g+a,e.yearrange.minyear,e.yearrange.maxyear))return b.buffer[c++]=g.charAt(0),b.buffer[c++]=g.charAt(1),{pos:c}}return f},cardinality:1},{validator:function(a,b,c,d,e){var f=e.isInYearRange(a,e.yearrange.minyear,e.yearrange.maxyear);if(!d&&!f){var g=e.determinebaseyear(e.yearrange.minyear,e.yearrange.maxyear,a).toString().slice(0,2);if(f=e.isInYearRange(a[0]+g[1]+a[1],e.yearrange.minyear,e.yearrange.maxyear))return b.buffer[c++]=g.charAt(1),{pos:c};if(g=e.determinebaseyear(e.yearrange.minyear,e.yearrange.maxyear,a).toString().slice(0,2),e.isInYearRange(g+a,e.yearrange.minyear,e.yearrange.maxyear)){var h=b.buffer.join("").substr(0,6);if(h!=e.leapday)f=!0;else{var i=parseInt(a,10);f=i%4===0&&(i%100!==0||i%400===0)}}else f=!1;if(f)return b.buffer[c-1]=g.charAt(0),b.buffer[c++]=g.charAt(1),b.buffer[c++]=a.charAt(0),{refreshFromBuffer:{start:c-3,end:c},pos:c}}return f},cardinality:2},{validator:function(a,b,c,d,e){return e.isInYearRange(a,e.yearrange.minyear,e.yearrange.maxyear)},cardinality:3}]}},insertMode:!1,autoUnmask:!1},"mm/dd/yyyy":{placeholder:"mm/dd/yyyy",alias:"dd/mm/yyyy",regex:{val2pre:function(b){var c=a.inputmask.escapeRegex.call(this,b);return new RegExp("((0[13-9]|1[012])"+c+"[0-3])|(02"+c+"[0-2])")},val2:function(b){var c=a.inputmask.escapeRegex.call(this,b);return new RegExp("((0[1-9]|1[012])"+c+"(0[1-9]|[12][0-9]))|((0[13-9]|1[012])"+c+"30)|((0[13578]|1[02])"+c+"31)")},val1pre:new RegExp("[01]"),val1:new RegExp("0[1-9]|1[012]")},leapday:"02/29/",onKeyUp:function(b){var c=a(this);if(b.ctrlKey&&b.keyCode==a.inputmask.keyCode.RIGHT){var d=new Date;c.val((d.getMonth()+1).toString()+d.getDate().toString()+d.getFullYear().toString())}}},"yyyy/mm/dd":{mask:"y/1/2",placeholder:"yyyy/mm/dd",alias:"mm/dd/yyyy",leapday:"/02/29",onKeyUp:function(b){var c=a(this);if(b.ctrlKey&&b.keyCode==a.inputmask.keyCode.RIGHT){var d=new Date;c.val(d.getFullYear().toString()+(d.getMonth()+1).toString()+d.getDate().toString())}}},"dd.mm.yyyy":{mask:"1.2.y",placeholder:"dd.mm.yyyy",leapday:"29.02.",separator:".",alias:"dd/mm/yyyy"},"dd-mm-yyyy":{mask:"1-2-y",placeholder:"dd-mm-yyyy",leapday:"29-02-",separator:"-",alias:"dd/mm/yyyy"},"mm.dd.yyyy":{mask:"1.2.y",placeholder:"mm.dd.yyyy",leapday:"02.29.",separator:".",alias:"mm/dd/yyyy"},"mm-dd-yyyy":{mask:"1-2-y",placeholder:"mm-dd-yyyy",leapday:"02-29-",separator:"-",alias:"mm/dd/yyyy"},"yyyy.mm.dd":{mask:"y.1.2",placeholder:"yyyy.mm.dd",leapday:".02.29",separator:".",alias:"yyyy/mm/dd"},"yyyy-mm-dd":{mask:"y-1-2",placeholder:"yyyy-mm-dd",leapday:"-02-29",separator:"-",alias:"yyyy/mm/dd"},datetime:{mask:"1/2/y h:s",placeholder:"dd/mm/yyyy hh:mm",alias:"dd/mm/yyyy",regex:{hrspre:new RegExp("[012]"),hrs24:new RegExp("2[0-4]|1[3-9]"),hrs:new RegExp("[01][0-9]|2[0-4]"),ampm:new RegExp("^[a|p|A|P][m|M]"),mspre:new RegExp("[0-5]"),ms:new RegExp("[0-5][0-9]")},timeseparator:":",hourFormat:"24",definitions:{h:{validator:function(a,b,c,d,e){if("24"==e.hourFormat&&24==parseInt(a,10))return b.buffer[c-1]="0",b.buffer[c]="0",{refreshFromBuffer:{start:c-1,end:c},c:"0"};var f=e.regex.hrs.test(a);if(!d&&!f&&(a.charAt(1)==e.timeseparator||-1!="-.:".indexOf(a.charAt(1)))&&(f=e.regex.hrs.test("0"+a.charAt(0))))return b.buffer[c-1]="0",b.buffer[c]=a.charAt(0),c++,{refreshFromBuffer:{start:c-2,end:c},pos:c,c:e.timeseparator};if(f&&"24"!==e.hourFormat&&e.regex.hrs24.test(a)){var g=parseInt(a,10);return 24==g?(b.buffer[c+5]="a",b.buffer[c+6]="m"):(b.buffer[c+5]="p",b.buffer[c+6]="m"),g-=12,10>g?(b.buffer[c]=g.toString(),b.buffer[c-1]="0"):(b.buffer[c]=g.toString().charAt(1),b.buffer[c-1]=g.toString().charAt(0)),{refreshFromBuffer:{start:c-1,end:c+6},c:b.buffer[c]}}return f},cardinality:2,prevalidator:[{validator:function(a,b,c,d,e){var f=e.regex.hrspre.test(a);return d||f||!(f=e.regex.hrs.test("0"+a))?f:(b.buffer[c]="0",c++,{pos:c})},cardinality:1}]},s:{validator:"[0-5][0-9]",cardinality:2,prevalidator:[{validator:function(a,b,c,d,e){var f=e.regex.mspre.test(a);return d||f||!(f=e.regex.ms.test("0"+a))?f:(b.buffer[c]="0",c++,{pos:c})},cardinality:1}]},t:{validator:function(a,b,c,d,e){return e.regex.ampm.test(a+"m")},casing:"lower",cardinality:1}},insertMode:!1,autoUnmask:!1},datetime12:{mask:"1/2/y h:s t\\m",placeholder:"dd/mm/yyyy hh:mm xm",alias:"datetime",hourFormat:"12"},"hh:mm t":{mask:"h:s t\\m",placeholder:"hh:mm xm",alias:"datetime",hourFormat:"12"},"h:s t":{mask:"h:s t\\m",placeholder:"hh:mm xm",alias:"datetime",hourFormat:"12"},"hh:mm:ss":{mask:"h:s:s",placeholder:"hh:mm:ss",alias:"datetime",autoUnmask:!1},"hh:mm":{mask:"h:s",placeholder:"hh:mm",alias:"datetime",autoUnmask:!1},date:{alias:"dd/mm/yyyy"},"mm/yyyy":{mask:"1/y",placeholder:"mm/yyyy",leapday:"donotuse",separator:"/",alias:"mm/dd/yyyy"}}),a.fn.inputmask}(jQuery),function(a){return a.extend(a.inputmask.defaults.definitions,{A:{validator:"[A-Za-zА-яЁёÀ-ÿµ]",cardinality:1,casing:"upper"},"#":{validator:"[0-9A-Za-zА-яЁёÀ-ÿµ]",cardinality:1,casing:"upper"}}),a.extend(a.inputmask.defaults.aliases,{url:{mask:"ir",placeholder:"",separator:"",defaultPrefix:"http://",regex:{urlpre1:new RegExp("[fh]"),urlpre2:new RegExp("(ft|ht)"),urlpre3:new RegExp("(ftp|htt)"),urlpre4:new RegExp("(ftp:|http|ftps)"),urlpre5:new RegExp("(ftp:/|ftps:|http:|https)"),urlpre6:new RegExp("(ftp://|ftps:/|http:/|https:)"),urlpre7:new RegExp("(ftp://|ftps://|http://|https:/)"),urlpre8:new RegExp("(ftp://|ftps://|http://|https://)")},definitions:{i:{validator:function(){return!0},cardinality:8,prevalidator:function(){for(var a=[],b=8,c=0;b>c;c++)a[c]=function(){var a=c;return{validator:function(b,c,d,e,f){if(f.regex["urlpre"+(a+1)]){var g,h=b;a+1-b.length>0&&(h=c.buffer.join("").substring(0,a+1-b.length)+""+h);var i=f.regex["urlpre"+(a+1)].test(h);if(!e&&!i){for(d-=a,g=0;g<f.defaultPrefix.length;g++)c.buffer[d]=f.defaultPrefix[g],d++;for(g=0;g<h.length-1;g++)c.buffer[d]=h[g],d++;return{pos:d}}return i}return!1},cardinality:a}}();return a}()},r:{validator:".",cardinality:50}},insertMode:!1,autoUnmask:!1},ip:{mask:"i[i[i]].i[i[i]].i[i[i]].i[i[i]]",definitions:{i:{validator:function(a,b,c){return c-1>-1&&"."!=b.buffer[c-1]?(a=b.buffer[c-1]+a,a=c-2>-1&&"."!=b.buffer[c-2]?b.buffer[c-2]+a:"0"+a):a="00"+a,new RegExp("25[0-5]|2[0-4][0-9]|[01][0-9][0-9]").test(a)},cardinality:1}}},email:{mask:"*{1,64}[.*{1,64}][.*{1,64}][.*{1,64}]@*{1,64}[.*{2,64}][.*{2,6}][.*{1,2}]",greedy:!1,onBeforePaste:function(a){return a=a.toLowerCase(),a.replace("mailto:","")},definitions:{"*":{validator:"[0-9A-Za-z!#$%&'*+/=?^_`{|}~-]",cardinality:1,casing:"lower"}}}}),a.fn.inputmask}(jQuery),function(a){return a.extend(a.inputmask.defaults.aliases,{numeric:{mask:function(a){if(0!==a.repeat&&isNaN(a.integerDigits)&&(a.integerDigits=a.repeat),a.repeat=0,a.groupSeparator==a.radixPoint&&(a.groupSeparator="."==a.radixPoint?",":","==a.radixPoint?".":"")," "===a.groupSeparator&&(a.skipOptionalPartCharacter=void 0),a.autoGroup=a.autoGroup&&""!=a.groupSeparator,a.autoGroup&&isFinite(a.integerDigits)){var b=Math.floor(a.integerDigits/a.groupSize),c=a.integerDigits%a.groupSize;a.integerDigits+=0==c?b-1:b}a.definitions[";"]=a.definitions["~"];var d=a.prefix;return d+="[+]",d+="~{1,"+a.integerDigits+"}",void 0!=a.digits&&(isNaN(a.digits)||parseInt(a.digits)>0)&&(d+=a.digitsOptional?"["+(a.decimalProtect?":":a.radixPoint)+";{"+a.digits+"}]":(a.decimalProtect?":":a.radixPoint)+";{"+a.digits+"}"),d+=a.suffix},placeholder:"",greedy:!1,digits:"*",digitsOptional:!0,groupSeparator:"",radixPoint:".",radixFocus:!0,groupSize:3,autoGroup:!1,allowPlus:!0,allowMinus:!0,integerDigits:"+",prefix:"",suffix:"",rightAlign:!0,decimalProtect:!0,postFormat:function(b,c,d,e){var f=!1,g=b[c];if(""==e.groupSeparator||-1!=a.inArray(e.radixPoint,b)&&c>=a.inArray(e.radixPoint,b)||new RegExp("[-+]").test(g))return{pos:c};var h=b.slice();g==e.groupSeparator&&(h.splice(c--,1),g=h[c]),d?h[c]="?":h.splice(c,0,"?");var i=h.join("");if(e.autoGroup||d&&-1!=i.indexOf(e.groupSeparator)){var j=a.inputmask.escapeRegex.call(this,e.groupSeparator);f=0==i.indexOf(e.groupSeparator),i=i.replace(new RegExp(j,"g"),"");var k=i.split(e.radixPoint);if(i=k[0],i!=e.prefix+"?0"&&i.length>=e.groupSize+e.prefix.length){f=!0;for(var l=new RegExp("([-+]?[\\d?]+)([\\d?]{"+e.groupSize+"})");l.test(i);)i=i.replace(l,"$1"+e.groupSeparator+"$2"),i=i.replace(e.groupSeparator+e.groupSeparator,e.groupSeparator)}k.length>1&&(i+=e.radixPoint+k[1])}b.length=i.length;for(var m=0,n=i.length;n>m;m++)b[m]=i.charAt(m);var o=a.inArray("?",b);return d?b[o]=g:b.splice(o,1),{pos:o,refreshFromBuffer:f}},onKeyDown:function(b,c,d,e){if(b.keyCode==a.inputmask.keyCode.TAB&&"0"!=e.placeholder.charAt(0)){var f=a.inArray(e.radixPoint,c);if(-1!=f&&isFinite(e.digits)){for(var g=1;g<=e.digits;g++)(void 0==c[f+g]||c[f+g]==e.placeholder.charAt(0))&&(c[f+g]="0");return{refreshFromBuffer:{start:++f,end:f+e.digits}}}}else if(e.autoGroup&&(b.keyCode==a.inputmask.keyCode.DELETE||b.keyCode==a.inputmask.keyCode.BACKSPACE)){var h=e.postFormat(c,d-1,!0,e);return h.caret=h.pos+1,h}},onKeyPress:function(a,b,c,d){if(d.autoGroup){var e=d.postFormat(b,c-1,!0,d);return e.caret=e.pos+1,e}},regex:{integerPart:function(){return new RegExp("[-+]?\\d+")},integerNPart:function(){return new RegExp("\\d+")}},signHandler:function(a,b,c,d,e){if(!d&&(e.allowMinus&&"-"===a||e.allowPlus&&"+"===a)){var f=b.join("").match(e.regex.integerPart(e));if(f&&f.length>0&&"0"!==f[f.index])return b[f.index]==("-"===a?"+":"-")?{pos:f.index,c:a,remove:f.index,caret:c}:b[f.index]==("-"===a?"-":"+")?{remove:f.index,caret:c-1}:{pos:f.index,c:a,caret:c+1}}return!1},radixHandler:function(b,c,d,e,f){if(!e&&b===f.radixPoint){var g=a.inArray(f.radixPoint,c.buffer),h=c.buffer.join("").match(f.regex.integerPart(f));if(-1!=g)return c.validPositions[g-1]?{caret:g+1}:{pos:h.index,c:h[0],caret:g+1}}return!1},leadingZeroHandler:function(b,c,d,e,f){var g=c.buffer.join("").match(f.regex.integerNPart(f)),h=a.inArray(f.radixPoint,c.buffer);if(g&&!e&&(-1==h||g.index<h))if(0==g[0].indexOf("0")&&d>=f.prefix.length){if(-1==h||h>=d&&void 0==c.validPositions[h])return c.buffer.splice(g.index,1),d=d>g.index?d-1:g.index,{pos:d,remove:g.index};if(d>g.index&&h>=d)return c.buffer.splice(g.index,1),d=d>g.index?d-1:g.index,{pos:d,remove:g.index}}else if("0"==b&&d<=g.index)return!1;return!0},definitions:{"~":{validator:function(b,c,d,e,f){var g=f.signHandler(b,c.buffer,d,e,f);if(!g&&(g=f.radixHandler(b,c,d,e,f),!g&&(g=e?new RegExp("[0-9"+a.inputmask.escapeRegex.call(this,f.groupSeparator)+"]").test(b):new RegExp("[0-9]").test(b),g===!0&&(g=f.leadingZeroHandler(b,c,d,e,f),g===!0)))){var h=a.inArray(f.radixPoint,c.buffer);f.digitsOptional===!1&&d>h&&!e&&(g={pos:d,remove:d}),g={pos:d}}return g},cardinality:1,prevalidator:null},"+":{validator:function(a,b,c,d,e){var f=e.signHandler(a,b.buffer,c,d,e);return f||(f=e.allowMinus&&"-"==a||e.allowPlus&&"+"==a),f},cardinality:1,prevalidator:null,placeholder:""},":":{validator:function(b,c,d,e,f){var g=f.signHandler(b,c.buffer,d,e,f);if(!g){var h="["+a.inputmask.escapeRegex.call(this,f.radixPoint)+"]";g=new RegExp(h).test(b),g&&c.validPositions[d]&&c.validPositions[d].match.placeholder==f.radixPoint&&(g={pos:d,remove:d})}return g},cardinality:1,prevalidator:null,placeholder:function(a){return a.radixPoint}}},insertMode:!0,autoUnmask:!1,onUnMask:function(b,c,d){var e=b.replace(d.prefix,"");return e=e.replace(d.suffix,""),e=e.replace(new RegExp(a.inputmask.escapeRegex.call(this,d.groupSeparator),"g"),"")},isComplete:function(b,c){var d=b.join(""),e=b.slice();if(c.postFormat(e,0,!0,c),e.join("")!=d)return!1;var f=d.replace(c.prefix,"");return f=f.replace(c.suffix,""),f=f.replace(new RegExp(a.inputmask.escapeRegex.call(this,c.groupSeparator),"g"),""),f=f.replace(a.inputmask.escapeRegex.call(this,c.radixPoint),"."),isFinite(f)},onBeforeMask:function(b,c){if(isFinite(b))return b.toString().replace(".",c.radixPoint);var d=b.match(/,/g),e=b.match(/\./g);return e&&d?e.length>d.length?(b=b.replace(/\./g,""),b=b.replace(",",c.radixPoint)):d.length>e.length&&(b=b.replace(/,/g,""),b=b.replace(".",c.radixPoint)):b=b.replace(new RegExp(a.inputmask.escapeRegex.call(this,c.groupSeparator),"g"),""),b}},currency:{prefix:"$ ",groupSeparator:",",radixPoint:".",alias:"numeric",placeholder:"0",autoGroup:!0,digits:2,digitsOptional:!1,clearMaskOnLostFocus:!1,decimalProtect:!0},decimal:{alias:"numeric"},integer:{alias:"numeric",digits:"0"}}),a.fn.inputmask}(jQuery),function(a){return a.extend(a.inputmask.defaults.aliases,{phone:{url:"phone-codes/phone-codes.js",maskInit:"+pp(pp)pppppppp",mask:function(b){b.definitions={p:{validator:function(){return!1},cardinality:1},"#":{validator:"[0-9]",cardinality:1}};var c=[];return a.ajax({url:b.url,async:!1,dataType:"json",success:function(a){c=a}}),c=c.sort(function(a,b){return(a.mask||a)<(b.mask||b)?-1:1}),c.splice(0,0,b.maskInit),c},nojumps:!0,nojumpsThreshold:1},phonebe:{alias:"phone",url:"phone-codes/phone-be.js",maskInit:"+32(pp)pppppppp",nojumpsThreshold:4}}),a.fn.inputmask}(jQuery),function(a){return a.extend(a.inputmask.defaults.aliases,{Regex:{mask:"r",greedy:!1,repeat:"*",regex:null,regexTokens:null,tokenizer:/\[\^?]?(?:[^\\\]]+|\\[\S\s]?)*]?|\\(?:0(?:[0-3][0-7]{0,2}|[4-7][0-7]?)?|[1-9][0-9]*|x[0-9A-Fa-f]{2}|u[0-9A-Fa-f]{4}|c[A-Za-z]|[\S\s]?)|\((?:\?[:=!]?)?|(?:[?*+]|\{[0-9]+(?:,[0-9]*)?\})\??|[^.?*+^${[()|\\]+|./g,quantifierFilter:/[0-9]+[^,]/,isComplete:function(a,b){return new RegExp(b.regex).test(a.join(""))},definitions:{r:{validator:function(b,c,d,e,f){function g(a,b){this.matches=[],this.isGroup=a||!1,this.isQuantifier=b||!1,this.quantifier={min:1,max:1},this.repeaterPart=void 0}function h(){var a,b,c=new g,d=[];for(f.regexTokens=[];a=f.tokenizer.exec(f.regex);)switch(b=a[0],b.charAt(0)){case"(":d.push(new g(!0));break;case")":var e=d.pop();d.length>0?d[d.length-1].matches.push(e):c.matches.push(e);break;case"{":case"+":case"*":var h=new g(!1,!0);b=b.replace(/[{}]/g,"");var i=b.split(","),j=isNaN(i[0])?i[0]:parseInt(i[0]),k=1==i.length?j:isNaN(i[1])?i[1]:parseInt(i[1]);if(h.quantifier={min:j,max:k},d.length>0){var l=d[d.length-1].matches;if(a=l.pop(),!a.isGroup){var e=new g(!0);e.matches.push(a),a=e}l.push(a),l.push(h)}else{if(a=c.matches.pop(),!a.isGroup){var e=new g(!0);e.matches.push(a),a=e}c.matches.push(a),c.matches.push(h)}break;default:d.length>0?d[d.length-1].matches.push(b):c.matches.push(b)}c.matches.length>0&&f.regexTokens.push(c)}function i(b,c){var d=!1;c&&(k+="(",m++);for(var e=0;e<b.matches.length;e++){var f=b.matches[e];if(1==f.isGroup)d=i(f,!0);else if(1==f.isQuantifier){var g=a.inArray(f,b.matches),h=b.matches[g-1],j=k;if(isNaN(f.quantifier.max)){for(;f.repeaterPart&&f.repeaterPart!=k&&f.repeaterPart.length>k.length&&!(d=i(h,!0)););d=d||i(h,!0),d&&(f.repeaterPart=k),k=j+f.quantifier.max}else{for(var l=0,o=f.quantifier.max-1;o>l&&!(d=i(h,!0));l++);k=j+"{"+f.quantifier.min+","+f.quantifier.max+"}"}}else if(void 0!=f.matches)for(var p=0;p<f.length&&!(d=i(f[p],c));p++);else{var q;if("["==f.charAt(0)){q=k,q+=f;for(var r=0;m>r;r++)q+=")";var s=new RegExp("^("+q+")$");d=s.test(n)}else for(var t=0,u=f.length;u>t;t++)if("\\"!=f.charAt(t)){q=k,q+=f.substr(0,t+1),q=q.replace(/\|$/,"");for(var r=0;m>r;r++)q+=")";var s=new RegExp("^("+q+")$");if(d=s.test(n))break}k+=f}if(d)break}return c&&(k+=")",m--),d}null==f.regexTokens&&h();var j=c.buffer.slice(),k="",l=!1,m=0;j.splice(d,0,b);for(var n=j.join(""),o=0;o<f.regexTokens.length;o++){var g=f.regexTokens[o];if(l=i(g,g.isGroup))break}return l},cardinality:1}}}}),a.fn.inputmask}(jQuery),jQuery(document).ready(function(a){jQuery(document).on("cf.add",function(){a("[data-inputmask]").inputmask()}),jQuery(document).trigger("cf.add")}),function(a){"function"==typeof define&&define.amd?define(["jquery"],a):a("object"==typeof exports?require("jquery"):jQuery)}(function(a){function b(){var a=document.createElement("input");return a.setAttribute("type","range"),"text"!==a.type}function c(a,b){var c=Array.prototype.slice.call(arguments,2);return setTimeout(function(){return a.apply(null,c)},b)}function d(a,b){return b=b||100,function(){if(!a.debouncing){var c=Array.prototype.slice.apply(arguments);a.lastReturnVal=a.apply(window,c),a.debouncing=!0}return clearTimeout(a.debounceTimeout),a.debounceTimeout=setTimeout(function(){a.debouncing=!1},b),a.lastReturnVal}}function e(b,e){if(this.$window=a(window),this.$document=a(document),this.$element=a(b),this.options=a.extend({},i,e),this._defaults=i,this._name=f,this.startEvent=this.options.startEvent.join("."+f+" ")+"."+f,this.moveEvent=this.options.moveEvent.join("."+f+" ")+"."+f,this.endEvent=this.options.endEvent.join("."+f+" ")+"."+f,
4
- this.polyfill=this.options.polyfill,this.onInit=this.options.onInit,this.onSlide=this.options.onSlide,this.onSlideEnd=this.options.onSlideEnd,this.polyfill&&h)return!1;this.identifier="js-"+f+"-"+ +new Date,this.min=parseFloat(this.$element[0].getAttribute("min")||0),this.max=parseFloat(this.$element[0].getAttribute("max")||100),this.value=parseFloat(this.$element[0].value||this.min+(this.max-this.min)/2),this.step=parseFloat(this.$element[0].getAttribute("step")||1),this.$fill=a('<div class="'+this.options.fillClass+'" />'),this.$handle=a('<div class="'+this.options.handleClass+'" />'),this.$range=a('<div class="'+this.options.rangeClass+'" id="'+this.identifier+'" />').insertAfter(this.$element).prepend(this.$fill,this.$handle),this.$element.css({position:"absolute",width:"1px",height:"1px",overflow:"hidden",opacity:"0"}),this.handleDown=a.proxy(this.handleDown,this),this.handleMove=a.proxy(this.handleMove,this),this.handleEnd=a.proxy(this.handleEnd,this),this.init();var g=this;this.$window.on("resize."+f,d(function(){c(function(){g.update()},300)},20)),this.$document.on(this.startEvent,"#"+this.identifier+":not(."+this.options.disabledClass+")",this.handleDown),this.$element.on("change."+f,function(a,b){if(!b||b.origin!==f){var c=a.target.value,d=g.getPositionFromValue(c);g.setPosition(d)}})}var f="rangeslider",g=[],h=b(),i={polyfill:!0,rangeClass:"rangeslider",disabledClass:"rangeslider--disabled",fillClass:"rangeslider__fill",handleClass:"rangeslider__handle",startEvent:["mousedown","touchstart","pointerdown"],moveEvent:["mousemove","touchmove","pointermove"],endEvent:["mouseup","touchend","pointerup"]};e.prototype.init=function(){this.onInit&&"function"==typeof this.onInit&&this.onInit(),this.update()},e.prototype.update=function(){this.handleWidth=this.$handle[0].offsetWidth,this.rangeWidth=this.$range[0].offsetWidth,this.maxHandleX=this.rangeWidth-this.handleWidth,this.grabX=this.handleWidth/2,this.position=this.getPositionFromValue(this.value),this.$element[0].disabled?this.$range.addClass(this.options.disabledClass):this.$range.removeClass(this.options.disabledClass),this.setPosition(this.position)},e.prototype.handleDown=function(a){if(a.preventDefault(),this.$document.on(this.moveEvent,this.handleMove),this.$document.on(this.endEvent,this.handleEnd),!((" "+a.target.className+" ").replace(/[\n\t]/g," ").indexOf(this.options.handleClass)>-1)){var b=this.getRelativePosition(this.$range[0],a),c=this.getPositionFromNode(this.$handle[0])-this.getPositionFromNode(this.$range[0]);this.setPosition(b-this.grabX),b>=c&&b<c+this.handleWidth&&(this.grabX=b-c)}},e.prototype.handleMove=function(a){a.preventDefault();var b=this.getRelativePosition(this.$range[0],a);this.setPosition(b-this.grabX)},e.prototype.handleEnd=function(a){a.preventDefault(),this.$document.off(this.moveEvent,this.handleMove),this.$document.off(this.endEvent,this.handleEnd);var b=this.getRelativePosition(this.$range[0],a);this.onSlideEnd&&"function"==typeof this.onSlideEnd&&this.onSlideEnd(b-this.grabX,this.value)},e.prototype.cap=function(a,b,c){return a<b?b:a>c?c:a},e.prototype.setPosition=function(a){var b,c;b=this.getValueFromPosition(this.cap(a,0,this.maxHandleX))/this.step*this.step,c=this.getPositionFromValue(b),this.$fill[0].style.width=c+this.grabX+"px",this.$handle[0].style.left=c+"px",this.setValue(b),this.position=c,this.value=b,this.onSlide&&"function"==typeof this.onSlide&&this.onSlide(c,b)},e.prototype.getPositionFromNode=function(a){for(var b=0;null!==a;)b+=a.offsetLeft,a=a.offsetParent;return b},e.prototype.getRelativePosition=function(a,b){return(b.pageX||b.originalEvent.clientX||b.originalEvent.touches[0].clientX||b.currentPoint.x)-this.getPositionFromNode(a)},e.prototype.getPositionFromValue=function(a){var b,c;return b=(a-this.min)/(this.max-this.min),c=b*this.maxHandleX},e.prototype.getValueFromPosition=function(a){var b,c;return b=a/(this.maxHandleX||1),c=this.step*Math.ceil((b*(this.max-this.min)+this.min)/this.step),Number(c.toFixed(2))},e.prototype.setValue=function(a){a!==this.value&&this.$element.val(a).trigger("change",{origin:f})},e.prototype.destroy=function(){this.$document.off(this.startEvent,"#"+this.identifier,this.handleDown),this.$element.off("."+f).removeAttr("style").removeData("plugin_"+f),this.$range&&this.$range.length&&this.$range[0].parentNode.removeChild(this.$range[0]),g.splice(g.indexOf(this.$element[0]),1),g.length||this.$window.off("."+f)},a.fn[f]=function(b){return this.each(function(){var c=a(this),d=c.data("plugin_"+f);d||(c.data("plugin_"+f,d=new e(this,b)),g.push(this)),"string"==typeof b&&d[b]()})}}),function(a){"use strict";var b={init:function(c){return this.each(function(){this.self=a(this),b.destroy.call(this.self),this.opt=a.extend(!0,{},a.fn.raty.defaults,c),b._adjustCallback.call(this),b._adjustNumber.call(this),"img"!==this.opt.starType&&b._adjustStarType.call(this),b._adjustPath.call(this),b._createStars.call(this),this.opt.cancel&&b._createCancel.call(this),this.opt.precision&&b._adjustPrecision.call(this),b._createScore.call(this),b._apply.call(this,this.opt.score),b._target.call(this,this.opt.score),this.opt.readOnly?b._lock.call(this):(this.style.cursor="pointer",b._binds.call(this)),this.self.data("options",this.opt)})},_adjustCallback:function(){for(var a=["number","readOnly","score","scoreName"],b=0;b<a.length;b++)"function"==typeof this.opt[a[b]]&&(this.opt[a[b]]=this.opt[a[b]].call(this))},_adjustNumber:function(){this.opt.number=b._between(this.opt.number,1,this.opt.numberMax)},_adjustPath:function(){this.opt.path=this.opt.path||"",this.opt.path&&"/"!==this.opt.path.charAt(this.opt.path.length-1)&&(this.opt.path+="/")},_adjustPrecision:function(){this.opt.half=!0,this.opt.targetType="score"},_adjustStarType:function(){this.opt.path="";for(var a=["cancelOff","cancelOn","starHalf","starOff","starOn"],b=0;b<a.length;b++)this.opt[a[b]]=this.opt[a[b]].replace(".","-")},_apply:function(a){b._fill.call(this,a),a&&(a>0&&this.score.val(b._between(a,0,this.opt.number)),b._roundStars.call(this,a))},_between:function(a,b,c){return Math.min(Math.max(parseFloat(a),b),c)},_binds:function(){this.cancel&&(b._bindOverCancel.call(this),b._bindClickCancel.call(this),b._bindOutCancel.call(this)),b._bindOver.call(this),b._bindClick.call(this),b._bindOut.call(this)},_bindClick:function(){var b=this;b.stars.on("click.raty",function(c){var d=a(this);b.score.val(b.opt.half||b.opt.precision?b.self.data("score"):this.alt||d.data("alt")),b.opt.click&&b.opt.click.call(b,+b.score.val(),c)})},_bindClickCancel:function(){var a=this;a.cancel.on("click.raty",function(b){a.score.removeAttr("value"),a.opt.click&&a.opt.click.call(a,null,b)})},_bindOut:function(){var a=this;a.self.on("mouseleave.raty",function(c){var d=+a.score.val()||void 0;b._apply.call(a,d),b._target.call(a,d,c),a.opt.mouseout&&a.opt.mouseout.call(a,d,c)})},_bindOutCancel:function(){var b=this;b.cancel.on("mouseleave.raty",function(c){var d=a(this),e=b.opt.path+b.opt.cancelOff;if("img"===b.opt.starType)d.attr("src",e);else{var f=b.opt.path+b.opt.cancelOn;d.removeClass(f).addClass(e)}if(b.opt.mouseout){var g=+b.score.val()||void 0;b.opt.mouseout.call(b,g,c)}})},_bindOver:function(){var a=this,c=a.opt.half?"mousemove.raty":"mouseover.raty";a.stars.on(c,function(c){var d=b._getScoreByPosition.call(a,c,this);b._fill.call(a,d),a.opt.half&&(b._roundStars.call(a,d),a.self.data("score",d)),b._target.call(a,d,c),a.opt.mouseover&&a.opt.mouseover.call(a,d,c)})},_bindOverCancel:function(){var c=this;c.cancel.on("mouseover.raty",function(d){var e=c.opt.path+c.opt.cancelOn,f=a(this),g=c.opt.path+c.opt.starOff;if("img"===c.opt.starType)f.attr("src",e),c.stars.attr("src",g);else{c.stars.attr("class",g);var h=c.opt.path+c.opt.cancelOff;f.removeClass(h).addClass(e).css("color",c.opt.starColor)}b._target.call(c,null,d),c.opt.mouseover&&c.opt.mouseover.call(c,null)})},_buildScoreField:function(){return a("<input />",{name:this.opt.scoreName,type:"hidden"}).appendTo(this)},_createCancel:function(){var b=this.opt.path+this.opt.cancelOff,c=a("<"+this.opt.starType+" />",{title:this.opt.cancelHint,class:"raty-cancel"}).css("marginRight",this.opt.space?this.opt.spaceWidth+"px":"0");"img"===this.opt.starType?c.attr({src:b,alt:"x"}):c.attr("data-alt","x").addClass(b),"left"===this.opt.cancelPlace?this.self.prepend("&#160;").prepend(c):this.self.append("&#160;").append(c),this.cancel=c},_createScore:function(){var c=a(this.opt.targetScore);this.score=c.length?c:b._buildScoreField.call(this)},_createStars:function(){for(var c=1;c<=this.opt.number;c++){var d,e=this.opt.score&&this.opt.score>=c?"starOn":"starOff",f=b._getHint.call(this,c);e=this.opt.path+this.opt[e],d="img"!==this.opt.starType?{"data-alt":c,class:e}:{src:e,alt:c},d.title=f,a("<"+this.opt.starType+" />",d).css("marginRight",c<this.opt.number&&this.opt.space?this.opt.spaceWidth+"px":"0").appendTo(this),this.opt.space}this.stars=this.self.children(this.opt.starType)},_error:function(b){a(this).text(b),a.error(b)},_fill:function(a){for(var c=0,d=1;d<=this.stars.length;d++){var e,f=this.stars.eq(d-1),g=b._turnOn.call(this,d,a);if(this.opt.iconRange&&this.opt.iconRange.length>c){var h=this.opt.iconRange[c];e=b._getIconRange.call(this,h,g),d<=h.range&&("img"===this.opt.starType?f.attr("src",e):f.attr("class",e)),d===h.range&&c++}else e=this.opt.path+this.opt[g?"starOn":"starOff"],"img"===this.opt.starType?f.attr("src",e):f.attr("class",e),g?f.css("color",this.opt.starColor):f.css("color","")}},_getIconRange:function(a,b){return this.opt.path+(b?a.on||this.opt.starOn:a.off||this.opt.starOff)},_getScoreByPosition:function(c,d){var e=a(d),f=parseInt(d.alt||e.data("alt"),10);if(this.opt.half){var g=b._getSize.call(this),h=parseFloat((c.pageX-e.offset().left)/g);f=this.opt.precision?f-1+h:f-1+(h>.5?1:.5)}return f},_getSize:function(){var a;return a="img"===this.opt.starType?this.stars[0].width:parseFloat(this.stars.eq(0).css("font-size")),a||b._error.call(this,"Could not be possible get the icon size!"),a},_turnOn:function(a,b){return this.opt.single?a===b:a<=b},_getHint:function(a){var b=this.opt.hints[a-1];return""===b?"":b||a},_lock:function(){var a=parseInt(this.score.val(),10),c=a?b._getHint.call(this,a):this.opt.noRatedMsg;this.style.cursor="",this.title=c,this.score.prop("readonly",!0),this.stars.prop("title",c),this.cancel&&this.cancel.hide(),this.self.data("readonly",!0)},_roundStars:function(a){var b=(a%1).toFixed(2);if(b>this.opt.round.down){var c="starOn";this.opt.halfShow&&b<this.opt.round.up?c="starHalf":b<this.opt.round.full&&(c="starOff");var d=this.stars[Math.ceil(a)-1];"img"===this.opt.starType?d.src=this.opt.path+this.opt[c]:d.style.className=this.opt[c]}},_target:function(c,d){if(this.opt.target){var e=a(this.opt.target);e.length||b._error.call(this,"Target selector invalid or missing!");var f=d&&"mouseover"===d.type;if(void 0===c)c=this.opt.targetText;else if(null===c)c=f?this.opt.cancelHint:this.opt.targetText;else{"hint"===this.opt.targetType?c=b._getHint.call(this,Math.ceil(c)):this.opt.precision&&(c=parseFloat(c).toFixed(1));var g=d&&"mousemove"===d.type;f||g||this.opt.targetKeep||(c=this.opt.targetText)}c&&(c=this.opt.targetFormat.toString().replace("{score}",c)),e.is(":input")?e.val(c):e.html(c)}},_unlock:function(){this.style.cursor="pointer",this.removeAttribute("title"),this.score.removeAttr("readonly"),this.self.data("readonly",!1);for(var a=0;a<this.opt.number;a++)this.stars[a].title=b._getHint.call(this,a+1);this.cancel&&this.cancel.css("display","")},cancel:function(c){return this.each(function(){var d=a(this);d.data("readonly")!==!0&&(b[c?"click":"score"].call(d,null),this.score.removeAttr("value"))})},click:function(c){return this.each(function(){a(this).data("readonly")!==!0&&(b._apply.call(this,c),this.opt.click&&this.opt.click.call(this,c,a.Event("click")),b._target.call(this,c))})},destroy:function(){return this.each(function(){var b=a(this),c=b.data("raw");c?b.off(".raty").empty().css({cursor:c.style.cursor}).removeData("readonly"):b.data("raw",b.clone()[0])})},getScore:function(){var a,b=[];return this.each(function(){a=this.score.val(),b.push(a?+a:void 0)}),b.length>1?b:b[0]},move:function(c){return this.each(function(){var d=parseInt(c,10),e=a(this).data("options"),f=(+c).toFixed(1).split(".")[1];d>=e.number&&(d=e.number-1,f=10);var g=b._getSize.call(this),h=g/10,i=a(this.stars[d]),j=i.offset().left+h*parseInt(f,10),k=a.Event("mousemove",{pageX:j});i.trigger(k)})},readOnly:function(c){return this.each(function(){var d=a(this);d.data("readonly")!==c&&(c?(d.off(".raty").children("img").off(".raty"),b._lock.call(this)):(b._binds.call(this),b._unlock.call(this)),d.data("readonly",c))})},reload:function(){return b.set.call(this,{})},score:function(){var c=a(this);return arguments.length?b.setScore.apply(c,arguments):b.getScore.call(c)},set:function(b){return this.each(function(){var c=a(this),d=c.data("options"),e=a.extend({},d,b);c.raty(e)})},setScore:function(c){return this.each(function(){a(this).data("readonly")!==!0&&(b._apply.call(this,c),b._target.call(this,c))})}};a.fn.raty=function(c){return b[c]?b[c].apply(this,Array.prototype.slice.call(arguments,1)):"object"!=typeof c&&c?void a.error("Method "+c+" does not exist!"):b.init.apply(this,arguments)},a.fn.raty.defaults={cancel:!1,cancelHint:"Cancel this rating!",cancelOff:"raty-cancel-off",cancelOn:"raty-cancel-on",cancelPlace:"left",click:void 0,half:!1,halfShow:!0,hints:["1"],iconRange:void 0,mouseout:void 0,mouseover:void 0,noRatedMsg:"Not rated yet!",number:5,numberMax:20,path:void 0,precision:!1,readOnly:!1,round:{down:.25,full:.6,up:.76},score:void 0,scoreName:"score",single:!1,space:!0,spaceWidth:3,starColor:"#ff00aa",starHalf:"star-half.png",starOff:"raty-dot-off",starOn:"raty-dot-on",starType:"img",target:void 0,targetFormat:"{score}",targetKeep:!1,targetScore:void 0,targetText:"",targetType:"hint"}}(jQuery),jQuery(function(a){a("body").on("click",".cf-toggle-group-buttons a",function(){var b=a(this),c=b.closest(".caldera-config-field"),d=c.find('[data-ref="'+b.attr("id")+'"]');c.find(".btn").removeClass(b.data("active")).addClass(b.data("default")),b.addClass(b.data("active")).removeClass(b.data("default")),d.prop("checked",!0).trigger("change")})});var cf_jsfields_init,cf_presubmit;!function(a){cf_validate_form=function(a){return a.parsley({errorsWrapper:'<span class="help-block caldera_ajax_error_block"></span>',errorTemplate:"<span></span>",errorsContainer:function(a){return a.$element.closest(".form-group")}}).on("field:error",function(){this.$element.closest(".form-group").addClass("has-error")}).on("field:success",function(){this.$element.closest(".form-group").removeClass("has-error")})},a("[data-sync]").each(function(){var b=a(this);new CalderaFormsFieldSync(b,b.data("binds"),b.closest("form"),a)}),a(document).on("change keypress","[data-sync]",function(){a(this).data("unsync",!0)}),cf_jsfields_init=function(){a(".init_field_type[data-type]").each(function(b,c){var d=a(c);"function"==typeof window[d.data("type")+"_init"]&&window[d.data("type")+"_init"](d.prop("id"),d[0])}),window.Parsley.on("field:validated",function(){setTimeout(function(){a(document).trigger("cf.error")},15)}),"undefined"==typeof resBaldrickTriggers&&a(".caldera_forms_form").length,a(document).trigger("cf.fieldsInit")},a("document").ready(function(){cf_jsfields_init()}),a(".caldera-form-page").length&&a(".caldera-form-page").on("keypress","[data-field]:not(textarea)",function(a){13===a.keyCode&&a.preventDefault()}),a(document).on("click",".cf_modal_button",function(b){b.preventDefault();var c=a(this);a(c.attr("href")).show()}),a(document).on("click",".caldera-front-modal-closer",function(b){b.preventDefault();var c=a(this);c.closest(".caldera-front-modal-container").hide()}),a(document).on("cf.add cf.enable cf.disable cf.pagenav",cf_jsfields_init),a(document).on("click","[data-page]",function(b){var c,d,e,f=a(this),g=f.closest(".caldera-form-page"),h=f.closest("form.caldera_forms_form"),i=h.data("instance"),j=h.find(".caldera-form-page:visible").data("formpage"),k=g.data("formpage")?g.data("formpage"):f.data("page"),l=a('.breadcrumb[data-form="caldera_form_'+i+'"]'),m=!0,n={};if(h.length){if(cf_validate_form(h).destroy(),e=h.find("[data-field]"),h.find(".has-error").removeClass("has-error"),"prev"!==f.data("page")&&k>=j)for(var o=0;o<e.length;o++){var p=a(e[o]);if(p.is(":radio,:checkbox")){if(!p.hasClass("option-required")||!1===p.is(":visible"))continue;n[p.data("field")]||(n[p.data("field")]=[]),n[p.data("field")].push(p.prop("checked"))}else{if(p.prop("required")&&!1===p.is(":visible"))continue;if(p.prop("required")&&!0!==p.parsley().isValid()){if(p.is(":visible"))p.parsley().validate(),b.preventDefault();else{var q=parseFloat(p.closest(".caldera-form-page[data-formpage]").data("formpage"));q<parseFloat(k)&&h.find('[data-page="'+q+'"]').addClass("has-error")}m=!1}}}for(var r in n)n[r].indexOf(!0)<0?(a('[for="'+r+"_"+i+'"]').parent().addClass("has-error"),m=!1):a('[for="'+r+"_"+i+'"]').parent().removeClass("has-error");if(!1===m)return cf_validate_form(h).validate(),!1;"next"===f.data("page")?(l&&l.find("li.active").removeClass("active").children().attr("aria-expanded","false"),c=h.find('.caldera-form-page[data-formpage="'+(k+1)+'"]'),c.length&&(g.hide().attr("aria-hidden","true").css("visibility","hidden"),c.show().attr("aria-hidden","false").css("visibility","visible"),l&&l.find('a[data-page="'+(k+1)+'"]').attr("aria-expanded","true").parent().addClass("active"))):"prev"===f.data("page")?(l&&l.find("li.active").removeClass("active").children().attr("aria-expanded","false"),d=h.find('.caldera-form-page[data-formpage="'+(k-1)+'"]'),d.length&&(g.hide().attr("aria-hidden","true").css("visibility","hidden"),d.show().attr("aria-hidden","false").css("visibility","visible"),l&&l.find('a[data-page="'+(k-1)+'"]').attr("aria-expanded","true").parent().addClass("active"))):f.data("pagenav")&&(b.preventDefault(),f.closest(".breadcrumb").find("li.active").removeClass("active").children().attr("aria-expanded","false"),a("#"+f.data("pagenav")+" .caldera-form-page").hide().attr("aria-hidden","true").css("visibility","hidden"),a("#"+f.data("pagenav")+'\t.caldera-form-page[data-formpage="'+f.data("page")+'"]').show().attr("aria-hidden","false").css("visibility","visible"),f.parent().addClass("active").children().attr("aria-expanded","true")),a("html, body").animate({scrollTop:h.offset().top-100},200),a(document).trigger("cf.pagenav")}});var b;a(".caldera-grid .breadcrumb").each(function(c,d){a(d).find("a[data-pagenav]").each(function(c,d){var e=a(d),f=e.data("pagenav"),g=a("#"+f+' .caldera-form-page[data-formpage="'+e.data("page")+'"]');g.find(".has-error").length&&(e.parent().addClass("error"),"undefined"==typeof b&&(e.trigger("click"),b=!0))})}),a(document).on("click",'form.caldera_forms_form [type="submit"]',function(b){var c=a(this),d=c.closest(".caldera_forms_form"),e=cf_validate_form(d);e.validate()?e.destroy():b.preventDefault()})}(jQuery),window.addEventListener("load",function(){!function(a){"use strict";if("object"==typeof CF_API_DATA){var b,c={};a(".caldera_forms_form").each(function(d,e){b=a(e).data("form-id"),c[b]=new CalderaFormsResetNonce(b,CF_API_DATA,a),c[b].init()})}if("object"==typeof CFFIELD_CONFIG){var d,e,f,g,h;a(".caldera_forms_form").each(function(b,c){h=a(c),d=h.attr("id"),g=h.data("instance"),"object"==typeof CFFIELD_CONFIG[g]&&(f=CFFIELD_CONFIG[g],e=new Caldera_Forms_Field_Config(f,a(document.getElementById(d)),a),e.init())})}}(jQuery)});
1
+ function color_picker_init(){jQuery(".minicolor-picker").miniColors()}function toggle_button_init(a,b){var c=jQuery(b),d=c.find(".cf-toggle-group-radio:checked");d.length&&jQuery("#"+d.data("ref")).trigger("click")}function Caldera_Forms_Field_Config(a,b,c){function d(a,b,c,d){var g=b.parent().parent();return g.removeClass("has-error"),g.find(".help-block").remove(),a?(g.removeClass("has-error"),f(),!0):(g.addClass("has-error").append('<span id="cf-error-'+b.attr("id")+'" class="help-block '+d+'">'+c+"</span>"),b.prop("required")&&e(),b.addClass("parsely-error"),!1)}function e(){i.prop("disabled",!0).attr("aria-disabled",!0)}function f(){i.prop("disabled",!1).attr("aria-disabled",!1)}var g=this,h={},i=b.find(":submit, .cf-page-btn-next");this.init=function(){c.each(a,function(a,b){h[b.id]=g[b.type](b)})},this.button=function(a){var b=a.id;c(document).on("click dblclick","#"+b,function(a){c("#"+b+"_btn").val(a.type).trigger("change")})},this.html=function(a){function b(){void 0==e[a.tmplId]&&(e[a.tmplId]=c(document.getElementById(a.tmplId)).html());for(var b=e[a.tmplId],d=c(document.getElementById(a.contentId)),g=0;g<f.length;g++){for(var h=c('[data-field="'+f[g]+'"]'),i=[],j=0;j<h.length;j++)if(!c(h[j]).is(":radio,:checkbox")||c(h[j]).prop("checked"))if(c(h[j]).is("input:file")){var k=h[j].value.split("\\");i.push(k[k.length-1])}else h[j].value&&i.push(h[j].value);b=b.replace(new RegExp("{{"+f[g]+"}}","g"),i.join(", "))}d.html(b).trigger("change")}function d(){c.each(a.bindFields,function(a,d){c(document.getElementById(d)).on("click keyup",b)})}if(0!=a.sync){var e={},f=a.binds;c(document).on("cf.pagenav cf.add cf.disable",function(){d()}),d(),b()}},this.summary=this.html;var j={};this.range_slider=function(a){var b=c(document.getElementById(a.id));b.on("change",function(){c("#"+a.id+"_value").html(this.value)}).css("width","100%"),c(document).on("cf.pagenav cf.add cf.disable cf.modal",function(){var b=document.getElementById(a.id);if(null!=b){var d=c(b),e=d.val();d.rangeslider("destroy"),d.rangeslider(j[a.id].init),d.val(e).change()}}),function(){"object"!=j[a.id]&&(j[a.id]={value:a.default,init:{}});var d={onSlide:function(b,d){j[a.id].value=d,d=d.toFixed(a.value),c("#"+a.id+"_value").html(d)},onInit:function(){this.value=j[a.id].value,b.parent().find(".rangeslider").css("backgroundColor",a.trackcolor),b.parent().find(".rangeslider__fill").css("backgroundColor",a.color),b.parent().find(".rangeslider__handle").css("backgroundColor",a.handle).css("borderColor",a.handleborder)},polyfill:!1};b.rangeslider(d),j[a.id].init=d}()},this.star_rating=function(a){var b=a.options.score,d=c(document.getElementById(a.starFieldId)),e=(c(document.getElementById(a.id)),function(){var c=a.options;c.click=function(){b=d.raty("score"),d.trigger("change")},d.raty(c),d.raty("score",b)});e();var f=!1;jQuery(document).on("cf.add",function(){!1===f&&(f=!0,d.length&&(d.raty("destroy"),e()),setTimeout(function(){f=!1},500))})},this.toggle_switch=function(a){c(document).on("reset","#"+a.id,function(b){c.each(a.options,function(b,d){c(document.getElemenetById(d)).removeClass(a.selectedClassName).addClass(a.defaultClassName)}),c(document.getElementById(a.id)).prop("checked","")})},this.phone_better=function(a){var e=c(document.getElementById(a.id)),f=function(){var b=document.getElementById("cf-error-"+a.id);null!=b&&b.remove()},g=function(){f();var b;c.trim(e.val())&&(b=!!e.intlTelInput("isValidNumber"));var g,h=e.intlTelInput("getValidationError");return 0==h?(b=!0,g=""):g="undefined"!=a.messages[h]?a.messages[h]:a.messages.generic,d(b,e,g,"help-block-phone_better"),b};e.intlTelInput(a.options),e.on("keyup change",f),e.blur(function(){f(),g()}),e.on("change",g),b.on("submit",function(){g()})},this.wysiwyg=function(a){var b=document.getElementById(a.id);if(null!=b){var d=c(b);d.trumbowyg(a.options);var e=d.parent().find(".trumbowyg-editor");e.html(d.html()),e.bind("input propertychange",function(){d.html(e.html())})}},this.credit_card_number=function(a){function b(b){var d={0:"amex",1:"discover",2:"visa",3:"discover",4:"mastercard"},e="credit-card.svg";c.each(d,function(a,c){if(0===b.indexOf(c))return e="cc-"+c+".svg",!1}),f.css("background",'url("'+a.imgPath+e+'")')}var f=c(document.getElementById(a.id));0==a.exp&&0==a.cvc||function(){e();var b=c(document.getElementById(a.cvc)),d=c(document.getElementById(a.exp));b.blur(function(){b.val()&&g.creditCardUtil.validateCVC(f,b),d.val()&&g.creditCardUtil.validateExp(d)})}(),f.length&&(f.payment("formatCardNumber"),f.blur(function(){var e=f.val(),g=c.payment.validateCardNumber(e),h=c.payment.cardType(e);d(g,f,a.invalid,"help-block-credit_card_number help-block-credit_card"),g&&b(h)}))},this.credit_card_exp=function(a){var b=c(document.getElementById(a.id));b.length&&(b.payment("formatCardExpiry"),b.blur(function(){d(g.creditCardUtil.validateExp(b),b,a.invalid,"help-block-credit_card_exp help-block-credit_card")}))},this.credit_card_cvc=function(a){var b=c(document.getElementById(a.id));if(b.length&&(b.payment("formatCardCVC"),!1!==a.ccField)){var e=c(document.getElementById(a.ccField));b.blur(function(){d(g.creditCardUtil.validateExp(e,b),b,a.invalid,"help-block-credit_card_cvc help-block-credit_card")})}},this.creditCardUtil={validateCVC:function(a,b){var d=b.val(),e=c.payment.validateCardNumber(a.val()),f=!1;if(e){var g=c.payment.cardType(a.val());f=c.payment.validateCardCVC(d,g)}return f},validateExp:function(a){var b=a.val().split("/");if(b&&2==b.length)return c.payment.validateCardExpiry(b[0].trim(),b[1].trim())}},this.color_picker=function(a){c(document.getElementById(a.id)).miniColors(a.settings),c(document).on("cf.pagenav cf.add cf.disable cf.modal",function(){c(document.getElementById(a.id)).miniColors(a.settings)})}}function CalderaFormsFieldSync(a,b,c,d){for(var e=0;e<b.length;e++)d(document).on("keyup change blur mouseover","[data-field='"+b[e]+"']",function(){var b=a.data("sync");if(id=a.data("field"),reg=new RegExp("{{([^}]*?)}}","g"),template=b.match(reg),!a.data("unsync")&&void 0!=template&&template.length){for(var e=0;e<template.length;e++){for(var f=template[e].replace(/\}/g,"").replace(/\{/g,""),g=new RegExp(template[e],"g"),h=c.find("[data-field='"+f+"']"),i="",j=0;j<h.length;j++){var k=d(h[j]);(!k.is(":radio")&&!k.is(":checkbox")||k.is(":checked"))&&(i+=k.val())}b=b.replace(g,i)}a.val(b)}}),d("[data-field='"+b[e]+"']").trigger("change")}function CalderaFormsResetNonce(a,b,c){function d(a){return(new Date).getTime()-36e3>a}function e(){c.ajax({url:b.rest.tokens.nonce,method:"POST",beforeSend:function(a){a.setRequestHeader("X-WP-Nonce",b.rest.nonce)},data:{form_id:a}}).success(function(a){f.val(a.nonce),f.data("nonce-time",(new Date).getTime())})}var f;this.init=function(){f=c("#"+b.nonce.field+"_"+a),d(f.data("nonce-time"))&&e()}}jQuery&&function(a){a.extend(a.fn,{miniColors:function(b,c){var d=function(b,c,d){var e=s(b.val());e||(e="ffffff");var f=x(e),h=a('<span class="input-group-addon" style="background-color: #'+e+'" href="#"></span>');h.insertAfter(b),b.addClass("miniColors").data("original-maxlength",b.attr("maxlength")||null).data("original-autocomplete",b.attr("autocomplete")||null).data("letterCase",c.letterCase?c.letterCase:"uppercase").data("trigger",h).data("hsb",f).data("change",c.change?c.change:null).data("close",c.close?c.close:null).data("open",c.open?c.open:null).attr("maxlength",7).attr("autocomplete","off").val("#"+o(e,c.letterCase)).trigger("change"),c.readonly&&b.prop("readonly",!0),c.disabled&&g(b),h.on("click.miniColors",function(a){a.preventDefault(),""===b.val()&&b.val("#").trigger("change"),i(b)}),b.on("focus.miniColors",function(a){""===b.val()&&b.val("#").trigger("change"),i(b)}),b.on("blur.miniColors",function(a){var c=s(y(b.data("hsb")));b.val(c?"#"+o(c,b.data("letterCase")):"").trigger("change")}),b.on("keydown.miniColors",function(a){9===a.keyCode&&j(b)}),b.on("keyup.miniColors",function(a){n(b)}),b.on("paste.miniColors",function(a){setTimeout(function(){n(b)},5)})},e=function(b){j(),b=a(b),b.data("trigger").remove(),b.attr("autocomplete",b.data("original-autocomplete")).attr("maxlength",b.data("original-maxlength")).removeData().removeClass("miniColors").off(".miniColors"),a(document).off(".miniColors")},f=function(a){a.prop("disabled",!1).data("trigger").css("opacity",1)},g=function(a){j(a),a.prop("disabled",!0).data("trigger").css("opacity",.5)},i=function(b){if(b.prop("disabled"))return!1;j();var c=a('<div class="miniColors-selector"></div>');c.append('<div class="miniColors-colors" style="background-color: #FFF;"><div class="miniColors-colorPicker"><div class="miniColors-colorPicker-inner"></div></div>').append('<div class="miniColors-hues"><div class="miniColors-huePicker"></div></div>').css("display","none").addClass(b.attr("class")).removeClass("form-control");var d=b.data("hsb");c.find(".miniColors-colors").css("backgroundColor","#"+y({h:d.h,s:100,b:100}));var e=b.data("colorPosition");e||(e=p(d)),c.find(".miniColors-colorPicker").css("top",e.y+"px").css("left",e.x+"px");var f=b.data("huePosition");f||(f=q(d)),c.find(".miniColors-huePicker").css("top",f.y+"px"),b.data("selector",c).data("huePicker",c.find(".miniColors-huePicker")).data("colorPicker",c.find(".miniColors-colorPicker")).data("mousebutton",0),a("BODY").append(c);var g=b.data("trigger"),h=!b.is(":visible"),i=h?g.offset().top+g.outerHeight():b.offset().top+b.outerHeight(),m=h?g.offset().left:b.offset().left,n=c.outerWidth(),o=c.outerHeight(),r=g.outerWidth(),s=g.outerHeight(),u=a(window).height(),v=a(window).width(),w=a(window).scrollTop(),x=a(window).scrollLeft();i+o>u+w&&(i=i-o-s),m+n>v+x&&(m=m-n+r),c.css({top:i,left:m}).fadeIn(100),c.on("selectstart",function(){return!1}),(!a.browser.msie||a.browser.msie&&a.browser.version>=9)&&a(window).on("resize.miniColors",function(a){j(b)}),a(document).on("mousedown.miniColors touchstart.miniColors",function(c){b.data("mousebutton",1);var d=a(c.target).parents().andSelf();if(d.hasClass("miniColors-colors")&&(c.preventDefault(),b.data("moving","colors"),k(b,c)),d.hasClass("miniColors-hues")&&(c.preventDefault(),b.data("moving","hues"),l(b,c)),d.hasClass("miniColors-selector"))return void c.preventDefault();d.hasClass("miniColors")||j(b)}),a(document).on("mouseup.miniColors touchend.miniColors",function(a){a.preventDefault(),b.data("mousebutton",0).removeData("moving")}).on("mousemove.miniColors touchmove.miniColors",function(a){a.preventDefault(),1===b.data("mousebutton")&&("colors"===b.data("moving")&&k(b,a),"hues"===b.data("moving")&&l(b,a))}),b.data("open")&&b.data("open").call(b.get(0),"#"+y(d),t(d))},j=function(b){b||(b=a(".miniColors")),b.each(function(){var c=a(this).data("selector");a(this).removeData("selector"),a(c).fadeOut(100,function(){if(b.data("close")){var c=b.data("hsb"),d=y(c);b.data("close").call(b.get(0),"#"+d,t(c))}a(this).remove()})}),a(document).off(".miniColors")},k=function(a,b){var c=a.data("colorPicker");c.hide();var d={x:b.pageX,y:b.pageY};b.originalEvent.changedTouches&&(d.x=b.originalEvent.changedTouches[0].pageX,d.y=b.originalEvent.changedTouches[0].pageY),d.x=d.x-a.data("selector").find(".miniColors-colors").offset().left-5,d.y=d.y-a.data("selector").find(".miniColors-colors").offset().top-5,d.x<=-5&&(d.x=-5),d.x>=144&&(d.x=144),d.y<=-5&&(d.y=-5),d.y>=144&&(d.y=144),a.data("colorPosition",d),c.css("left",d.x).css("top",d.y).show();var e=Math.round(.67*(d.x+5));e<0&&(e=0),e>100&&(e=100);var f=100-Math.round(.67*(d.y+5));f<0&&(f=0),f>100&&(f=100);var g=a.data("hsb");g.s=e,g.b=f,m(a,g,!0)},l=function(a,b){var c=a.data("huePicker");c.hide();var d={y:b.pageY};b.originalEvent.changedTouches&&(d.y=b.originalEvent.changedTouches[0].pageY),d.y=d.y-a.data("selector").find(".miniColors-colors").offset().top-1,d.y<=-1&&(d.y=-1),d.y>=149&&(d.y=149),a.data("huePosition",d),c.css("top",d.y).show();var e=Math.round(2.4*(150-d.y-1));e<0&&(e=0),e>360&&(e=360);var f=a.data("hsb");f.h=e,m(a,f,!0)},m=function(a,b,c){a.data("hsb",b);var d=y(b);if(c&&a.val("#"+o(d,a.data("letterCase"))).trigger("change"),a.data("trigger").css("backgroundColor","#"+d),a.data("selector")&&a.data("selector").find(".miniColors-colors").css("backgroundColor","#"+y({h:b.h,s:100,b:100})),a.data("change")){if(d===a.data("lastChange"))return;a.data("change").call(a.get(0),"#"+d,t(b)),a.data("lastChange",d)}},n=function(b){b.val("#"+r(b.val())).trigger("change");var c=s(b.val());if(!c)return!1;var d=x(c),e=b.data("hsb");if(d.h===e.h&&d.s===e.s&&d.b===e.b)return!0;var f=p(d);a(b.data("colorPicker")).css("top",f.y+"px").css("left",f.x+"px"),b.data("colorPosition",f);var g=q(d);return a(b.data("huePicker")).css("top",g.y+"px"),b.data("huePosition",g),m(b,d),!0},o=function(a,b){return"lowercase"===b?a.toLowerCase():"uppercase"===b?a.toUpperCase():a},p=function(a){var b=Math.ceil(a.s/.67);b<0&&(b=0),b>150&&(b=150);var c=150-Math.ceil(a.b/.67);return c<0&&(c=0),c>150&&(c=150),{x:b-5,y:c-5}},q=function(a){var b=150-a.h/2.4;return b<0&&(h=0),b>150&&(h=150),{y:b-1}},r=function(a){return a.replace(/[^A-F0-9]/gi,"")},s=function(a){return(a=r(a))?(3===a.length&&(a=a[0]+a[0]+a[1]+a[1]+a[2]+a[2]),6===a.length?a:null):null},t=function(a){var b={},c=Math.round(a.h),d=Math.round(255*a.s/100),e=Math.round(255*a.b/100);if(0===d)b.r=b.g=b.b=e;else{var f=e,g=(255-d)*e/255,h=c%60*(f-g)/60;360===c&&(c=0),c<60?(b.r=f,b.b=g,b.g=g+h):c<120?(b.g=f,b.b=g,b.r=f-h):c<180?(b.g=f,b.r=g,b.b=g+h):c<240?(b.b=f,b.r=g,b.g=f-h):c<300?(b.b=f,b.g=g,b.r=g+h):c<360?(b.r=f,b.g=g,b.b=f-h):(b.r=0,b.g=0,b.b=0)}return{r:Math.round(b.r),g:Math.round(b.g),b:Math.round(b.b)}},u=function(b){var c=[b.r.toString(16),b.g.toString(16),b.b.toString(16)];return a.each(c,function(a,b){1===b.length&&(c[a]="0"+b)}),c.join("")},v=function(a){return a=parseInt(a.indexOf("#")>-1?a.substring(1):a,16),{r:a>>16,g:(65280&a)>>8,b:255&a}},w=function(a){var b={h:0,s:0,b:0},c=Math.min(a.r,a.g,a.b),d=Math.max(a.r,a.g,a.b),e=d-c;return b.b=d,b.s=0!==d?255*e/d:0,0!==b.s?a.r===d?b.h=(a.g-a.b)/e:a.g===d?b.h=2+(a.b-a.r)/e:b.h=4+(a.r-a.g)/e:b.h=-1,b.h*=60,b.h<0&&(b.h+=360),b.s*=100/255,b.b*=100/255,b},x=function(a){var b=w(v(a));return 0===b.s&&(b.h=360),b},y=function(a){return u(t(a))};switch(b){case"readonly":return a(this).each(function(){a(this).hasClass("miniColors")&&a(this).prop("readonly",c)}),a(this);case"disabled":return a(this).each(function(){a(this).hasClass("miniColors")&&(c?g(a(this)):f(a(this)))}),a(this);case"value":if(void 0===c){if(!a(this).hasClass("miniColors"))return;var z=a(this),A=s(z.val());return A?"#"+o(A,z.data("letterCase")):null}return a(this).each(function(){a(this).hasClass("miniColors")&&(a(this).val(c).trigger("change"),n(a(this)))}),a(this);case"destroy":return a(this).each(function(){a(this).hasClass("miniColors")&&e(a(this))}),a(this);default:return b||(b={}),a(this).each(function(){"input"===a(this)[0].tagName.toLowerCase()&&(a(this).data("trigger")||d(a(this),b))}),a(this)}}})}(jQuery),document.addEventListener("load",color_picker_init,!1),jQuery(document).ajaxComplete(function(){color_picker_init()}),function(a,b){function c(){return new Date(Date.UTC.apply(Date,arguments))}function d(){var a=new Date;return c(a.getFullYear(),a.getMonth(),a.getDate())}function e(a){return function(){return this[a].apply(this,arguments)}}function f(b,c){function d(a,b){return b.toLowerCase()}var e,f=a(b).data(),g={},h=new RegExp("^"+c.toLowerCase()+"([A-Z])");c=new RegExp("^"+c.toLowerCase());for(var i in f)c.test(i)&&(e=i.replace(h,d),g[e]=f[i]);return g}function g(b){var c={};if(o[b]||(b=b.split("-")[0],o[b])){var d=o[b];return a.each(n,function(a,b){b in d&&(c[b]=d[b])}),c}}var h=a(window),i=function(){var b={get:function(a){return this.slice(a)[0]},contains:function(a){for(var b=a&&a.valueOf(),c=0,d=this.length;c<d;c++)if(this[c].valueOf()===b)return c;return-1},remove:function(a){this.splice(a,1)},replace:function(b){b&&(a.isArray(b)||(b=[b]),this.clear(),this.push.apply(this,b))},clear:function(){this.splice(0)},copy:function(){var a=new i;return a.replace(this),a}};return function(){var c=[];return c.push.apply(c,arguments),a.extend(c,b),c}}(),j=function(b,c){this.dates=new i,this.viewDate=d(),this.focusDate=null,this._process_options(c),this.element=a(b),this.isInline=!1,this.isInput=this.element.is("input"),this.component=!!this.element.is(".date")&&this.element.find(".add-on, .input-group-addon, .btn"),this.hasInput=this.component&&this.element.find("input").length,this.component&&0===this.component.length&&(this.component=!1),this.picker=a(p.template),this._buildEvents(),this._attachEvents(),this.isInline?this.picker.addClass("cfdatepicker-inline").appendTo(this.element):this.picker.addClass("cfdatepicker-dropdown dropdown-menu"),this.o.rtl&&this.picker.addClass("cfdatepicker-rtl"),this.viewMode=this.o.startView,this.o.calendarWeeks&&this.picker.find("tfoot th.today").attr("colspan",function(a,b){return parseInt(b)+1}),this._allow_update=!1,this.setStartDate(this._o.startDate),this.setEndDate(this._o.endDate),this.setDaysOfWeekDisabled(this.o.daysOfWeekDisabled),this.fillDow(),this.fillMonths(),this._allow_update=!0,this.update(),this.showMode(),this.isInline&&this.show()};j.prototype={constructor:j,_process_options:function(b){this._o=a.extend({},this._o,b);var c=this.o=a.extend({},this._o),d=c.language;switch(o[d]||(d=d.split("-")[0],o[d]||(d=m.language)),c.language=d,c.startView){case 2:case"decade":c.startView=2;break;case 1:case"year":c.startView=1;break;default:c.startView=0}switch(c.minViewMode){case 1:case"months":c.minViewMode=1;break;case 2:case"years":c.minViewMode=2;break;default:c.minViewMode=0}c.startView=Math.max(c.startView,c.minViewMode),!0!==c.multidate&&(c.multidate=Number(c.multidate)||!1,!1!==c.multidate?c.multidate=Math.max(0,c.multidate):c.multidate=1),c.multidateSeparator=String(c.multidateSeparator),c.weekStart%=7,c.weekEnd=(c.weekStart+6)%7;var e=p.parseFormat(c.format);c.startDate!==-1/0&&(c.startDate?c.startDate instanceof Date?c.startDate=this._local_to_utc(this._zero_time(c.startDate)):c.startDate=p.parseDate(c.startDate,e,c.language):c.startDate=-1/0),c.endDate!==1/0&&(c.endDate?c.endDate instanceof Date?c.endDate=this._local_to_utc(this._zero_time(c.endDate)):c.endDate=p.parseDate(c.endDate,e,c.language):c.endDate=1/0),c.daysOfWeekDisabled=c.daysOfWeekDisabled||[],a.isArray(c.daysOfWeekDisabled)||(c.daysOfWeekDisabled=c.daysOfWeekDisabled.split(/[,\s]*/)),c.daysOfWeekDisabled=a.map(c.daysOfWeekDisabled,function(a){return parseInt(a,10)});var f=String(c.orientation).toLowerCase().split(/\s+/g),g=c.orientation.toLowerCase();if(f=a.grep(f,function(a){return/^auto|left|right|top|bottom$/.test(a)}),c.orientation={x:"auto",y:"auto"},g&&"auto"!==g)if(1===f.length)switch(f[0]){case"top":case"bottom":c.orientation.y=f[0];break;case"left":case"right":c.orientation.x=f[0]}else g=a.grep(f,function(a){return/^left|right$/.test(a)}),c.orientation.x=g[0]||"auto",g=a.grep(f,function(a){return/^top|bottom$/.test(a)}),c.orientation.y=g[0]||"auto";else;},_events:[],_secondaryEvents:[],_applyEvents:function(a){for(var b,c,d,e=0;e<a.length;e++)b=a[e][0],2===a[e].length?(c=void 0,d=a[e][1]):3===a[e].length&&(c=a[e][1],d=a[e][2]),b.on(d,c)},_unapplyEvents:function(a){for(var b,c,d,e=0;e<a.length;e++)b=a[e][0],2===a[e].length?(d=void 0,c=a[e][1]):3===a[e].length&&(d=a[e][1],c=a[e][2]),b.off(c,d)},_buildEvents:function(){this.isInput?this._events=[[this.element,{focus:a.proxy(this.show,this),keyup:a.proxy(function(b){-1===a.inArray(b.keyCode,[27,37,39,38,40,32,13,9])&&this.update()},this),keydown:a.proxy(this.keydown,this)}]]:this.component&&this.hasInput?this._events=[[this.element.find("input"),{focus:a.proxy(this.show,this),keyup:a.proxy(function(b){-1===a.inArray(b.keyCode,[27,37,39,38,40,32,13,9])&&this.update()},this),keydown:a.proxy(this.keydown,this)}],[this.component,{click:a.proxy(this.show,this)}]]:this.element.is("div")?this.isInline=!0:this._events=[[this.element,{click:a.proxy(this.show,this)}]],this._events.push([this.element,"*",{blur:a.proxy(function(a){this._focused_from=a.target},this)}],[this.element,{blur:a.proxy(function(a){this._focused_from=a.target},this)}]),this._secondaryEvents=[[this.picker,{click:a.proxy(this.click,this)}],[a(window),{resize:a.proxy(this.place,this)}],[a(document),{"mousedown touchstart":a.proxy(function(a){this.element.is(a.target)||this.element.find(a.target).length||this.picker.is(a.target)||this.picker.find(a.target).length||this.hide()},this)}]]},_attachEvents:function(){this._detachEvents(),this._applyEvents(this._events)},_detachEvents:function(){this._unapplyEvents(this._events)},_attachSecondaryEvents:function(){this._detachSecondaryEvents(),this._applyEvents(this._secondaryEvents)},_detachSecondaryEvents:function(){this._unapplyEvents(this._secondaryEvents)},_trigger:function(b,c){var d=c||this.dates.get(-1),e=this._utc_to_local(d);this.element.trigger({type:b,date:e,dates:a.map(this.dates,this._utc_to_local),format:a.proxy(function(a,b){0===arguments.length?(a=this.dates.length-1,b=this.o.format):"string"==typeof a&&(b=a,a=this.dates.length-1),b=b||this.o.format;var c=this.dates.get(a);return p.formatDate(c,b,this.o.language)},this)})},show:function(){this.isInline||this.picker.appendTo("body"),this.picker.show(),this.place(),this._attachSecondaryEvents(),this._trigger("show")},hide:function(){this.isInline||this.picker.is(":visible")&&(this.focusDate=null,this.picker.hide().detach(),this._detachSecondaryEvents(),this.viewMode=this.o.startView,this.showMode(),this.o.forceParse&&(this.isInput&&this.element.val()||this.hasInput&&this.element.find("input").val())&&this.setValue(),this._trigger("hide"))},remove:function(){this.hide(),this._detachEvents(),this._detachSecondaryEvents(),this.picker.remove(),delete this.element.data().cfdatepicker,this.isInput||delete this.element.data().date},_utc_to_local:function(a){return a&&new Date(a.getTime()+6e4*a.getTimezoneOffset())},_local_to_utc:function(a){return a&&new Date(a.getTime()-6e4*a.getTimezoneOffset())},_zero_time:function(a){return a&&new Date(a.getFullYear(),a.getMonth(),a.getDate())},_zero_utc_time:function(a){return a&&new Date(Date.UTC(a.getUTCFullYear(),a.getUTCMonth(),a.getUTCDate()))},getDates:function(){return a.map(this.dates,this._utc_to_local)},getUTCDates:function(){return a.map(this.dates,function(a){return new Date(a)})},getDate:function(){return this._utc_to_local(this.getUTCDate())},getUTCDate:function(){return new Date(this.dates.get(-1))},setDates:function(){var b=a.isArray(arguments[0])?arguments[0]:arguments;this.update.apply(this,b),this._trigger("changeDate"),this.setValue()},setUTCDates:function(){var b=a.isArray(arguments[0])?arguments[0]:arguments;this.update.apply(this,a.map(b,this._utc_to_local)),this._trigger("changeDate"),this.setValue()},setDate:e("setDates"),setUTCDate:e("setUTCDates"),setValue:function(){var a=this.getFormattedDate();this.isInput?this.element.val(a).change():this.component&&this.element.find("input").val(a).change()},getFormattedDate:function(b){void 0===b&&(b=this.o.format);var c=this.o.language;return a.map(this.dates,function(a){return p.formatDate(a,b,c)}).join(this.o.multidateSeparator)},setStartDate:function(a){this._process_options({startDate:a}),this.update(),this.updateNavArrows()},setEndDate:function(a){this._process_options({endDate:a}),this.update(),this.updateNavArrows()},setDaysOfWeekDisabled:function(a){this._process_options({daysOfWeekDisabled:a}),this.update(),this.updateNavArrows()},place:function(){if(!this.isInline){var b,c=this.picker.outerWidth(),d=this.picker.outerHeight(),e=h.width(),f=h.height(),g=h.scrollTop(),i=jQuery(this.element).data("form-id"),j=document.getElementById("modal-"+i+"-content");b=null!==j?1e4:parseInt(this.element.parents().filter(function(){return"auto"!==a(this).css("z-index")}).first().css("z-index"))+10;var k=this.component?this.component.parent().offset():this.element.offset(),l=this.component?this.component.outerHeight(!0):this.element.outerHeight(!1),m=this.component?this.component.outerWidth(!0):this.element.outerWidth(!1),n=k.left,o=k.top;this.picker.removeClass("cfdatepicker-orient-top cfdatepicker-orient-bottom cfdatepicker-orient-right cfdatepicker-orient-left"),"auto"!==this.o.orientation.x?(this.picker.addClass("cfdatepicker-orient-"+this.o.orientation.x),"right"===this.o.orientation.x&&(n-=c-m)):(this.picker.addClass("cfdatepicker-orient-left"),k.left<0?n-=k.left-10:k.left+c>e&&(n=e-c-10));var p,q,r=this.o.orientation.y;"auto"===r&&(p=-g+k.top-d,q=g+f-(k.top+l+d),r=Math.max(p,q)===q?"top":"bottom"),this.picker.addClass("cfdatepicker-orient-"+r),"top"===r?o+=l:o-=d+parseInt(this.picker.css("padding-top")),this.picker.css({top:o,left:n,zIndex:b})}},_allow_update:!0,update:function(){if(this._allow_update){var b=this.dates.copy(),c=[],d=!1;arguments.length?(a.each(arguments,a.proxy(function(a,b){b instanceof Date&&(b=this._local_to_utc(b)),c.push(b)},this)),d=!0):(c=this.isInput?this.element.val():this.element.data("date")||this.element.find("input").val(),c=c&&this.o.multidate?c.split(this.o.multidateSeparator):[c],delete this.element.data().date),c=a.map(c,a.proxy(function(a){return p.parseDate(a,this.o.format,this.o.language)},this)),c=a.grep(c,a.proxy(function(a){return a<this.o.startDate||a>this.o.endDate||!a},this),!0),this.dates.replace(c),this.dates.length?this.viewDate=new Date(this.dates.get(-1)):this.viewDate<this.o.startDate?this.viewDate=new Date(this.o.startDate):this.viewDate>this.o.endDate&&(this.viewDate=new Date(this.o.endDate)),d?this.setValue():c.length&&String(b)!==String(this.dates)&&this._trigger("changeDate"),!this.dates.length&&b.length&&this._trigger("clearDate"),this.fill()}},fillDow:function(){var a=this.o.weekStart,b="<tr>";if(this.o.calendarWeeks){var c='<th class="cw">&nbsp;</th>';b+=c,this.picker.find(".cfdatepicker-days thead tr:first-child").prepend(c)}for(;a<this.o.weekStart+7;)b+='<th class="dow">'+o[this.o.language].daysMin[a++%7]+"</th>";b+="</tr>",this.picker.find(".cfdatepicker-days thead").append(b)},fillMonths:function(){for(var a="",b=0;b<12;)a+='<span class="month">'+o[this.o.language].monthsShort[b++]+"</span>";this.picker.find(".cfdatepicker-months td").html(a)},setRange:function(b){b&&b.length?this.range=a.map(b,function(a){return a.valueOf()}):delete this.range,this.fill()},getClassNames:function(b){var c=[],d=this.viewDate.getUTCFullYear(),e=this.viewDate.getUTCMonth(),f=new Date;return b.getUTCFullYear()<d||b.getUTCFullYear()===d&&b.getUTCMonth()<e?c.push("old"):(b.getUTCFullYear()>d||b.getUTCFullYear()===d&&b.getUTCMonth()>e)&&c.push("new"),this.focusDate&&b.valueOf()===this.focusDate.valueOf()&&c.push("focused"),this.o.todayHighlight&&b.getUTCFullYear()===f.getFullYear()&&b.getUTCMonth()===f.getMonth()&&b.getUTCDate()===f.getDate()&&c.push("today"),-1!==this.dates.contains(b)&&c.push("active"),(b.valueOf()<this.o.startDate||b.valueOf()>this.o.endDate||-1!==a.inArray(b.getUTCDay(),this.o.daysOfWeekDisabled))&&c.push("disabled"),this.range&&(b>this.range[0]&&b<this.range[this.range.length-1]&&c.push("range"),-1!==a.inArray(b.valueOf(),this.range)&&c.push("selected")),c},fill:function(){var b,d=new Date(this.viewDate),e=d.getUTCFullYear(),f=d.getUTCMonth(),g=this.o.startDate!==-1/0?this.o.startDate.getUTCFullYear():-1/0,h=this.o.startDate!==-1/0?this.o.startDate.getUTCMonth():-1/0,i=this.o.endDate!==1/0?this.o.endDate.getUTCFullYear():1/0,j=this.o.endDate!==1/0?this.o.endDate.getUTCMonth():1/0,k=o[this.o.language].today||o.en.today||"",l=o[this.o.language].clear||o.en.clear||"";this.picker.find(".cfdatepicker-days thead th.cfdatepicker-switch").text(o[this.o.language].months[f]+" "+e),this.picker.find("tfoot th.today").text(k).toggle(!1!==this.o.todayBtn),this.picker.find("tfoot th.clear").text(l).toggle(!1!==this.o.clearBtn),this.updateNavArrows(),this.fillMonths();var m=c(e,f-1,28),n=p.getDaysInMonth(m.getUTCFullYear(),m.getUTCMonth());m.setUTCDate(n),m.setUTCDate(n-(m.getUTCDay()-this.o.weekStart+7)%7);var q=new Date(m);q.setUTCDate(q.getUTCDate()+42),q=q.valueOf();for(var r,s=[];m.valueOf()<q;){if(m.getUTCDay()===this.o.weekStart&&(s.push("<tr>"),this.o.calendarWeeks)){var t=new Date(+m+(this.o.weekStart-m.getUTCDay()-7)%7*864e5),u=new Date(Number(t)+(11-t.getUTCDay())%7*864e5),v=new Date(Number(v=c(u.getUTCFullYear(),0,1))+(11-v.getUTCDay())%7*864e5),w=(u-v)/864e5/7+1;s.push('<td class="cw">'+w+"</td>")}if(r=this.getClassNames(m),r.push("day"),this.o.beforeShowDay!==a.noop){var x=this.o.beforeShowDay(this._utc_to_local(m));void 0===x?x={}:"boolean"==typeof x?x={enabled:x}:"string"==typeof x&&(x={classes:x}),!1===x.enabled&&r.push("disabled"),x.classes&&(r=r.concat(x.classes.split(/\s+/))),x.tooltip&&(b=x.tooltip)}r=a.unique(r),s.push('<td class="'+r.join(" ")+'"'+(b?' title="'+b+'"':"")+">"+m.getUTCDate()+"</td>"),m.getUTCDay()===this.o.weekEnd&&s.push("</tr>"),m.setUTCDate(m.getUTCDate()+1)}this.picker.find(".cfdatepicker-days tbody").empty().append(s.join(""));var y=this.picker.find(".cfdatepicker-months").find("th:eq(1)").text(e).end().find("span").removeClass("active");a.each(this.dates,function(a,b){b.getUTCFullYear()===e&&y.eq(b.getUTCMonth()).addClass("active")}),(e<g||e>i)&&y.addClass("disabled"),e===g&&y.slice(0,h).addClass("disabled"),e===i&&y.slice(j+1).addClass("disabled"),s="",e=10*parseInt(e/10,10);var z=this.picker.find(".cfdatepicker-years").find("th:eq(1)").text(e+"-"+(e+9)).end().find("td");e-=1;for(var A,B=a.map(this.dates,function(a){return a.getUTCFullYear()}),C=-1;C<11;C++)A=["year"],-1===C?A.push("old"):10===C&&A.push("new"),-1!==a.inArray(e,B)&&A.push("active"),(e<g||e>i)&&A.push("disabled"),s+='<span class="'+A.join(" ")+'">'+e+"</span>",e+=1;z.html(s)},updateNavArrows:function(){if(this._allow_update){var a=new Date(this.viewDate),b=a.getUTCFullYear(),c=a.getUTCMonth();switch(this.viewMode){case 0:this.o.startDate!==-1/0&&b<=this.o.startDate.getUTCFullYear()&&c<=this.o.startDate.getUTCMonth()?this.picker.find(".prev").css({visibility:"hidden"}):this.picker.find(".prev").css({visibility:"visible"}),this.o.endDate!==1/0&&b>=this.o.endDate.getUTCFullYear()&&c>=this.o.endDate.getUTCMonth()?this.picker.find(".next").css({visibility:"hidden"}):this.picker.find(".next").css({visibility:"visible"});break;case 1:case 2:this.o.startDate!==-1/0&&b<=this.o.startDate.getUTCFullYear()?this.picker.find(".prev").css({visibility:"hidden"}):this.picker.find(".prev").css({visibility:"visible"}),this.o.endDate!==1/0&&b>=this.o.endDate.getUTCFullYear()?this.picker.find(".next").css({visibility:"hidden"}):this.picker.find(".next").css({visibility:"visible"})}}},click:function(b){b.preventDefault();var d,e,f,g=a(b.target).closest("span, td, th");if(1===g.length)switch(g[0].nodeName.toLowerCase()){case"th":switch(g[0].className){case"cfdatepicker-switch":this.showMode(1);break;case"prev":case"next":var h=p.modes[this.viewMode].navStep*("prev"===g[0].className?-1:1);switch(this.viewMode){case 0:this.viewDate=this.moveMonth(this.viewDate,h),this._trigger("changeMonth",this.viewDate);break;case 1:case 2:this.viewDate=this.moveYear(this.viewDate,h),1===this.viewMode&&this._trigger("changeYear",this.viewDate)}this.fill();break;case"today":var i=new Date;i=c(i.getFullYear(),i.getMonth(),i.getDate(),0,0,0),this.showMode(-2);var j="linked"===this.o.todayBtn?null:"view";this._setDate(i,j);break;case"clear":var k;this.isInput?k=this.element:this.component&&(k=this.element.find("input")),k&&k.val("").change(),this.update(),this._trigger("changeDate"),this.o.autoclose&&this.hide()}break;case"span":g.is(".disabled")||(this.viewDate.setUTCDate(1),g.is(".month")?(f=1,e=g.parent().find("span").index(g),d=this.viewDate.getUTCFullYear(),this.viewDate.setUTCMonth(e),this._trigger("changeMonth",this.viewDate),1===this.o.minViewMode&&this._setDate(c(d,e,f))):(f=1,e=0,d=parseInt(g.text(),10)||0,this.viewDate.setUTCFullYear(d),this._trigger("changeYear",this.viewDate),2===this.o.minViewMode&&this._setDate(c(d,e,f))),this.showMode(-1),this.fill());break;case"td":
2
+ g.is(".day")&&!g.is(".disabled")&&(f=parseInt(g.text(),10)||1,d=this.viewDate.getUTCFullYear(),e=this.viewDate.getUTCMonth(),g.is(".old")?0===e?(e=11,d-=1):e-=1:g.is(".new")&&(11===e?(e=0,d+=1):e+=1),this._setDate(c(d,e,f)))}this.picker.is(":visible")&&this._focused_from&&a(this._focused_from).focus(),delete this._focused_from},_toggle_multidate:function(a){var b=this.dates.contains(a);if(a?-1!==b?this.dates.remove(b):this.dates.push(a):this.dates.clear(),"number"==typeof this.o.multidate)for(;this.dates.length>this.o.multidate;)this.dates.remove(0)},_setDate:function(a,b){b&&"date"!==b||this._toggle_multidate(a&&new Date(a)),b&&"view"!==b||(this.viewDate=a&&new Date(a)),this.fill(),this.setValue(),this._trigger("changeDate");var c;this.isInput?c=this.element:this.component&&(c=this.element.find("input")),c&&c.change(),!this.o.autoclose||b&&"date"!==b||this.hide()},moveMonth:function(a,b){if(a){if(!b)return a;var c,d,e=new Date(a.valueOf()),f=e.getUTCDate(),g=e.getUTCMonth(),h=Math.abs(b);if(b=b>0?1:-1,1===h)d=-1===b?function(){return e.getUTCMonth()===g}:function(){return e.getUTCMonth()!==c},c=g+b,e.setUTCMonth(c),(c<0||c>11)&&(c=(c+12)%12);else{for(var i=0;i<h;i++)e=this.moveMonth(e,b);c=e.getUTCMonth(),e.setUTCDate(f),d=function(){return c!==e.getUTCMonth()}}for(;d();)e.setUTCDate(--f),e.setUTCMonth(c);return e}},moveYear:function(a,b){return this.moveMonth(a,12*b)},dateWithinRange:function(a){return a>=this.o.startDate&&a<=this.o.endDate},keydown:function(a){if(this.picker.is(":not(:visible)"))return void(27===a.keyCode&&this.show());var b,c,e,f=!1,g=this.focusDate||this.viewDate;switch(a.keyCode){case 27:this.focusDate?(this.focusDate=null,this.viewDate=this.dates.get(-1)||this.viewDate,this.fill()):this.hide(),a.preventDefault();break;case 37:case 39:if(!this.o.keyboardNavigation)break;b=37===a.keyCode?-1:1,a.ctrlKey?(c=this.moveYear(this.dates.get(-1)||d(),b),e=this.moveYear(g,b),this._trigger("changeYear",this.viewDate)):a.shiftKey?(c=this.moveMonth(this.dates.get(-1)||d(),b),e=this.moveMonth(g,b),this._trigger("changeMonth",this.viewDate)):(c=new Date(this.dates.get(-1)||d()),c.setUTCDate(c.getUTCDate()+b),e=new Date(g),e.setUTCDate(g.getUTCDate()+b)),this.dateWithinRange(c)&&(this.focusDate=this.viewDate=e,this.setValue(),this.fill(),a.preventDefault());break;case 38:case 40:if(!this.o.keyboardNavigation)break;b=38===a.keyCode?-1:1,a.ctrlKey?(c=this.moveYear(this.dates.get(-1)||d(),b),e=this.moveYear(g,b),this._trigger("changeYear",this.viewDate)):a.shiftKey?(c=this.moveMonth(this.dates.get(-1)||d(),b),e=this.moveMonth(g,b),this._trigger("changeMonth",this.viewDate)):(c=new Date(this.dates.get(-1)||d()),c.setUTCDate(c.getUTCDate()+7*b),e=new Date(g),e.setUTCDate(g.getUTCDate()+7*b)),this.dateWithinRange(c)&&(this.focusDate=this.viewDate=e,this.setValue(),this.fill(),a.preventDefault());break;case 32:break;case 13:g=this.focusDate||this.dates.get(-1)||this.viewDate,this._toggle_multidate(g),f=!0,this.focusDate=null,this.viewDate=this.dates.get(-1)||this.viewDate,this.setValue(),this.fill(),this.picker.is(":visible")&&(a.preventDefault(),this.o.autoclose&&this.hide());break;case 9:this.focusDate=null,this.viewDate=this.dates.get(-1)||this.viewDate,this.fill(),this.hide()}if(f){this.dates.length?this._trigger("changeDate"):this._trigger("clearDate");var h;this.isInput?h=this.element:this.component&&(h=this.element.find("input")),h&&h.change()}},showMode:function(a){a&&(this.viewMode=Math.max(this.o.minViewMode,Math.min(2,this.viewMode+a))),this.picker.find(">div").hide().filter(".cfdatepicker-"+p.modes[this.viewMode].clsName).css("display","block"),this.updateNavArrows()}};var k=function(b,c){this.element=a(b),this.inputs=a.map(c.inputs,function(a){return a.jquery?a[0]:a}),delete c.inputs,a(this.inputs).cfdatepicker(c).bind("changeDate",a.proxy(this.dateUpdated,this)),this.pickers=a.map(this.inputs,function(b){return a(b).data("cfdatepicker")}),this.updateDates()};k.prototype={updateDates:function(){this.dates=a.map(this.pickers,function(a){return a.getUTCDate()}),this.updateRanges()},updateRanges:function(){var b=a.map(this.dates,function(a){return a.valueOf()});a.each(this.pickers,function(a,c){c.setRange(b)})},dateUpdated:function(b){if(!this.updating){this.updating=!0;var c=a(b.target).data("cfdatepicker"),d=c.getUTCDate(),e=a.inArray(b.target,this.inputs),f=this.inputs.length;if(-1!==e){if(a.each(this.pickers,function(a,b){b.getUTCDate()||b.setUTCDate(d)}),d<this.dates[e])for(;e>=0&&d<this.dates[e];)this.pickers[e--].setUTCDate(d);else if(d>this.dates[e])for(;e<f&&d>this.dates[e];)this.pickers[e++].setUTCDate(d);this.updateDates(),delete this.updating}}},remove:function(){a.map(this.pickers,function(a){a.remove()}),delete this.element.data().cfdatepicker}};var l=a.fn.cfdatepicker;a.fn.cfdatepicker=function(b){var c=Array.apply(null,arguments);c.shift();var d;return this.each(function(){var e=a(this),h=e.data("cfdatepicker"),i="object"==typeof b&&b;if(!h){var l=f(this,"date"),n=a.extend({},m,l,i),o=g(n.language),p=a.extend({},m,o,l,i);if(e.is(".input-daterange")||p.inputs){var q={inputs:p.inputs||e.find("input").toArray()};e.data("cfdatepicker",h=new k(this,a.extend(p,q)))}else e.data("cfdatepicker",h=new j(this,p))}if("string"==typeof b&&"function"==typeof h[b]&&void 0!==(d=h[b].apply(h,c)))return!1}),void 0!==d?d:this};var m=a.fn.cfdatepicker.defaults={autoclose:!1,beforeShowDay:a.noop,calendarWeeks:!1,clearBtn:!1,daysOfWeekDisabled:[],endDate:1/0,forceParse:!0,format:"mm/dd/yyyy",keyboardNavigation:!0,language:"en",minViewMode:0,multidate:!1,multidateSeparator:",",orientation:"auto",rtl:!1,startDate:-1/0,startView:0,todayBtn:!1,todayHighlight:!1,weekStart:0},n=a.fn.cfdatepicker.locale_opts=["format","rtl","weekStart"];a.fn.cfdatepicker.Constructor=j;var o=a.fn.cfdatepicker.dates={en:{days:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday","Sunday"],daysShort:["Sun","Mon","Tue","Wed","Thu","Fri","Sat","Sun"],daysMin:["Su","Mo","Tu","We","Th","Fr","Sa","Su"],months:["January","February","March","April","May","June","July","August","September","October","November","December"],monthsShort:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],today:"Today",clear:"Clear"}},p={modes:[{clsName:"days",navFnc:"Month",navStep:1},{clsName:"months",navFnc:"FullYear",navStep:1},{clsName:"years",navFnc:"FullYear",navStep:10}],isLeapYear:function(a){return a%4==0&&a%100!=0||a%400==0},getDaysInMonth:function(a,b){return[31,p.isLeapYear(a)?29:28,31,30,31,30,31,31,30,31,30,31][b]},validParts:/dd?|DD?|mm?|MM?|yy(?:yy)?/g,nonpunctuation:/[^ -\/:-@\[\u3400-\u9fff-`{-~\t\n\r]+/g,parseFormat:function(a){var b=a.replace(this.validParts,"\0").split("\0"),c=a.match(this.validParts);if(!b||!b.length||!c||0===c.length)throw new Error("Invalid date format.");return{separators:b,parts:c}},parseDate:function(b,d,e){function f(){var a=this.slice(0,l[i].length);return a===l[i].slice(0,a.length)}if(b){if(b instanceof Date)return b;"string"==typeof d&&(d=p.parseFormat(d));var g,h,i,k=/([\-+]\d+)([dmwy])/,l=b.match(/([\-+]\d+)([dmwy])/g);if(/^[\-+]\d+[dmwy]([\s,]+[\-+]\d+[dmwy])*$/.test(b)){for(b=new Date,i=0;i<l.length;i++)switch(g=k.exec(l[i]),h=parseInt(g[1]),g[2]){case"d":b.setUTCDate(b.getUTCDate()+h);break;case"m":b=j.prototype.moveMonth.call(j.prototype,b,h);break;case"w":b.setUTCDate(b.getUTCDate()+7*h);break;case"y":b=j.prototype.moveYear.call(j.prototype,b,h)}return c(b.getUTCFullYear(),b.getUTCMonth(),b.getUTCDate(),0,0,0)}l=b&&b.match(this.nonpunctuation)||[],b=new Date;var m,n,q={},r=["yyyy","yy","M","MM","m","mm","d","dd"],s={yyyy:function(a,b){return a.setUTCFullYear(b)},yy:function(a,b){return a.setUTCFullYear(2e3+b)},m:function(a,b){if(isNaN(a))return a;for(b-=1;b<0;)b+=12;for(b%=12,a.setUTCMonth(b);a.getUTCMonth()!==b;)a.setUTCDate(a.getUTCDate()-1);return a},d:function(a,b){return a.setUTCDate(b)}};s.M=s.MM=s.mm=s.m,s.dd=s.d,b=c(b.getFullYear(),b.getMonth(),b.getDate(),0,0,0);var t=d.parts.slice();if(l.length!==t.length&&(t=a(t).filter(function(b,c){return-1!==a.inArray(c,r)}).toArray()),l.length===t.length){var u;for(i=0,u=t.length;i<u;i++){if(m=parseInt(l[i],10),g=t[i],isNaN(m))switch(g){case"MM":n=a(o[e].months).filter(f),m=a.inArray(n[0],o[e].months)+1;break;case"M":n=a(o[e].monthsShort).filter(f),m=a.inArray(n[0],o[e].monthsShort)+1}q[g]=m}var v,w;for(i=0;i<r.length;i++)(w=r[i])in q&&!isNaN(q[w])&&(v=new Date(b),s[w](v,q[w]),isNaN(v)||(b=v))}return b}},formatDate:function(b,c,d){if(!b)return"";"string"==typeof c&&(c=p.parseFormat(c));var e={d:b.getUTCDate(),D:o[d].daysShort[b.getUTCDay()],DD:o[d].days[b.getUTCDay()],m:b.getUTCMonth()+1,M:o[d].monthsShort[b.getUTCMonth()],MM:o[d].months[b.getUTCMonth()],yy:b.getUTCFullYear().toString().substring(2),yyyy:b.getUTCFullYear()};e.dd=(e.d<10?"0":"")+e.d,e.mm=(e.m<10?"0":"")+e.m,b=[];for(var f=a.extend([],c.separators),g=0,h=c.parts.length;g<=h;g++)f.length&&b.push(f.shift()),b.push(e[c.parts[g]]);return b.join("")},headTemplate:'<thead><tr><th class="prev">&laquo;</th><th colspan="5" class="cfdatepicker-switch"></th><th class="next">&raquo;</th></tr></thead>',contTemplate:'<tbody><tr><td colspan="7"></td></tr></tbody>',footTemplate:'<tfoot><tr><th colspan="7" class="today"></th></tr><tr><th colspan="7" class="clear"></th></tr></tfoot>'};p.template='<div class="cfdatepicker"><div class="cfdatepicker-days"><table class=" table-condensed">'+p.headTemplate+"<tbody></tbody>"+p.footTemplate+'</table></div><div class="cfdatepicker-months"><table class="table-condensed">'+p.headTemplate+p.contTemplate+p.footTemplate+'</table></div><div class="cfdatepicker-years"><table class="table-condensed">'+p.headTemplate+p.contTemplate+p.footTemplate+"</table></div></div>",a.fn.cfdatepicker.DPGlobal=p,a.fn.cfdatepicker.noConflict=function(){return a.fn.cfdatepicker=l,this},a(document).on("focus.cfdatepicker.data-api click.cfdatepicker.data-api",'[data-provide="cfdatepicker"]',function(b){var c=a(this);c.data("cfdatepicker")||(b.preventDefault(),c.cfdatepicker("show").on("show",function(){a(this).trigger("blur")}).on("hide",function(){a(this).attr("disabled",!1)}))})}(window.jQuery),function(a){function b(a){var b=document.createElement("input"),c="on"+a,d=c in b;return d||(b.setAttribute(c,"return;"),d="function"==typeof b[c]),b=null,d}function c(a){var b="text"==a||"tel"==a;if(!b){var c=document.createElement("input");c.setAttribute("type",a),b="text"===c.type,c=null}return b}function d(b,c,e){var f=e.aliases[b];return!!f&&(f.alias&&d(f.alias,void 0,e),a.extend(!0,e,f),a.extend(!0,e,c),!0)}function e(b,c){function d(a){function c(a,b,c,d){this.matches=[],this.isGroup=a||!1,this.isOptional=b||!1,this.isQuantifier=c||!1,this.isAlternator=d||!1,this.quantifier={min:1,max:1}}function d(a,c,d){var e=b.definitions[c],f=0==a.matches.length;if(d=void 0!=d?d:a.matches.length,e&&!l){for(var g=e.prevalidator,h=g?g.length:0,i=1;i<e.cardinality;i++){var j=h>=i?g[i-1]:[],k=j.validator,m=j.cardinality;a.matches.splice(d++,0,{fn:k?"string"==typeof k?new RegExp(k):new function(){this.test=k}:new RegExp("."),cardinality:m||1,optionality:a.isOptional,newBlockMarker:f,casing:e.casing,def:e.definitionSymbol||c,placeholder:e.placeholder,mask:c})}a.matches.splice(d++,0,{fn:e.validator?"string"==typeof e.validator?new RegExp(e.validator):new function(){this.test=e.validator}:new RegExp("."),cardinality:e.cardinality,optionality:a.isOptional,newBlockMarker:f,casing:e.casing,def:e.definitionSymbol||c,placeholder:e.placeholder,mask:c})}else a.matches.splice(d++,0,{fn:null,cardinality:0,optionality:a.isOptional,newBlockMarker:f,casing:null,def:c,placeholder:void 0,mask:c}),l=!1}for(var e,f,g,h,i,j,k=/(?:[?*+]|\{[0-9\+\*]+(?:,[0-9\+\*]*)?\})\??|[^.?*+^${[]()|\\]+|./g,l=!1,m=new c,n=[],o=[];e=k.exec(a);)switch(f=e[0],f.charAt(0)){case b.optionalmarker.end:case b.groupmarker.end:if(g=n.pop(),n.length>0){if(h=n[n.length-1],h.matches.push(g),h.isAlternator){i=n.pop();for(var p=0;p<i.matches.length;p++)i.matches[p].isGroup=!1;n.length>0?(h=n[n.length-1],h.matches.push(i)):m.matches.push(i)}}else m.matches.push(g);break;case b.optionalmarker.start:n.push(new c(!1,!0));break;case b.groupmarker.start:n.push(new c(!0));break;case b.quantifiermarker.start:var q=new c(!1,!1,!0);f=f.replace(/[{}]/g,"");var r=f.split(","),s=isNaN(r[0])?r[0]:parseInt(r[0]),t=1==r.length?s:isNaN(r[1])?r[1]:parseInt(r[1]);if(("*"==t||"+"==t)&&(s="*"==t?0:1),q.quantifier={min:s,max:t},n.length>0){var u=n[n.length-1].matches;if(e=u.pop(),!e.isGroup){var v=new c(!0);v.matches.push(e),e=v}u.push(e),u.push(q)}else{if(e=m.matches.pop(),!e.isGroup){var v=new c(!0);v.matches.push(e),e=v}m.matches.push(e),m.matches.push(q)}break;case b.escapeChar:l=!0;break;case b.alternatormarker:n.length>0?(h=n[n.length-1],j=h.matches.pop()):j=m.matches.pop(),j.isAlternator?n.push(j):(i=new c(!1,!1,!1,!0),i.matches.push(j),n.push(i));break;default:if(n.length>0){if(h=n[n.length-1],h.matches.length>0&&(j=h.matches[h.matches.length-1],j.isGroup&&(j.isGroup=!1,d(j,b.groupmarker.start,0),d(j,b.groupmarker.end))),d(h,f),h.isAlternator){i=n.pop();for(var p=0;p<i.matches.length;p++)i.matches[p].isGroup=!1;n.length>0?(h=n[n.length-1],h.matches.push(i)):m.matches.push(i)}}else m.matches.length>0&&(j=m.matches[m.matches.length-1],j.isGroup&&(j.isGroup=!1,d(j,b.groupmarker.start,0),d(j,b.groupmarker.end))),d(m,f)}return m.matches.length>0&&(j=m.matches[m.matches.length-1],j.isGroup&&(j.isGroup=!1,d(j,b.groupmarker.start,0),d(j,b.groupmarker.end)),o.push(m)),o}function e(c,e){if(b.numericInput&&!0!==b.multi){c=c.split("").reverse();for(var f=0;f<c.length;f++)c[f]==b.optionalmarker.start?c[f]=b.optionalmarker.end:c[f]==b.optionalmarker.end?c[f]=b.optionalmarker.start:c[f]==b.groupmarker.start?c[f]=b.groupmarker.end:c[f]==b.groupmarker.end&&(c[f]=b.groupmarker.start);c=c.join("")}if(void 0!=c&&""!=c){if(1==c.length&&0==b.greedy&&0!=b.repeat&&(b.placeholder=""),b.repeat>0||"*"==b.repeat||"+"==b.repeat){var g="*"==b.repeat?0:"+"==b.repeat?1:b.repeat;c=b.groupmarker.start+c+b.groupmarker.end+b.quantifiermarker.start+g+","+b.repeat+b.quantifiermarker.end}return void 0==a.inputmask.masksCache[c]&&(a.inputmask.masksCache[c]={mask:c,maskToken:d(c),validPositions:{},_buffer:void 0,buffer:void 0,tests:{},metadata:e}),a.extend(!0,{},a.inputmask.masksCache[c])}}var f=void 0;if(a.isFunction(b.mask)&&(b.mask=b.mask.call(this,b)),a.isArray(b.mask))if(c)f=[],a.each(b.mask,function(b,c){f.push(void 0==c.mask||a.isFunction(c.mask)?e(c.toString(),c):e(c.mask.toString(),c))});else{b.keepStatic=void 0==b.keepStatic||b.keepStatic;var g="(";a.each(b.mask,function(b,c){g.length>1&&(g+=")|("),g+=void 0==c.mask||a.isFunction(c.mask)?c.toString():c.mask.toString()}),g+=")",f=e(g,b.mask)}else b.mask&&(f=void 0==b.mask.mask||a.isFunction(b.mask.mask)?e(b.mask.toString(),b.mask):e(b.mask.mask.toString(),b.mask));return f}function f(d,e,f){function h(a,b,c){b=b||0;var d,e,f,g=[],h=0;do{if(!0===a&&o().validPositions[h]){var i=o().validPositions[h];e=i.match,d=i.locator.slice(),g.push(!0===c?i.input:I(h,e))}else{if(b>h){f=w(h,d,h-1)[0]}else f=t(h,d,h-1);e=f.match,d=f.locator.slice(),g.push(I(h,e))}h++}while((void 0==ea||ea>h-1)&&null!=e.fn||null==e.fn&&""!=e.def||b>=h);return g.pop(),g}function o(){return e}function p(a){var b=o();b.buffer=void 0,b.tests={},!0!==a&&(b._buffer=void 0,b.validPositions={},b.p=0)}function q(a){var b=o(),c=-1,d=b.validPositions;void 0==a&&(a=-1);var e=c,f=c;for(var g in d){var h=parseInt(g);(-1==a||null!=d[h].match.fn)&&(a>h&&(e=h),h>=a&&(f=h))}return c=a-e>1||a>f?e:f}function r(b,c,d){if(f.insertMode&&void 0!=o().validPositions[b]&&void 0==d){var e,g=a.extend(!0,{},o().validPositions),h=q();for(e=b;h>=e;e++)delete o().validPositions[e];o().validPositions[b]=c;var i,j=!0;for(e=b;h>=e;e++){var k=g[e];if(void 0!=k){var l=o().validPositions;i=!f.keepStatic&&(void 0!=l[e+1]&&w(e+1,l[e].locator.slice(),e).length>1||l[e]&&void 0!=l[e].alternation)?e+1:E(e),j=v(i,k.match.def)?j&&!1!==B(i,k.input,!0,!0):null==k.match.fn}if(!j)break}if(!j)return o().validPositions=a.extend(!0,{},g),!1}else o().validPositions[b]=c;return!0}function s(a,b){var c,d=a;for(void 0!=o().validPositions[a]&&o().validPositions[a].input==f.radixPoint&&(b++,d++),c=d;b>c;c++)void 0==o().validPositions[c]||o().validPositions[c].input==f.radixPoint&&c!=q()||delete o().validPositions[c];for(c=b;c<=q();){var e=o().validPositions[c],g=o().validPositions[d];void 0!=e&&void 0==g?(v(d,e.match.def)&&!1!==B(d,e.input,!0)&&(delete o().validPositions[c],c++),d++):c++}var h=q();h>=a&&void 0!=o().validPositions[h]&&o().validPositions[h].input==f.radixPoint&&delete o().validPositions[h],p(!0)}function t(b,c,d){for(var e,g=w(b,c,d),h=q(),i=o().validPositions[h]||w(0)[0],j=void 0!=i.alternation?i.locator[i.alternation].split(","):[],k=0;k<g.length&&(e=g[k],!(f.greedy||e.match&&(!1===e.match.optionality||!1===e.match.newBlockMarker)&&!0!==e.match.optionalQuantifier&&(void 0==i.alternation||void 0!=e.locator[i.alternation]&&function(b,c,d){for(var e=!1,f=b.locator[c].toString().split(","),g=0;g<f.length;g++)if(-1!=a.inArray(f[g],d)){e=!0;break}return e}(e,i.alternation,j))));k++);return e}function u(a){return o().validPositions[a]?o().validPositions[a].match:w(a)[0].match}function v(a,b){for(var c=!1,d=w(a),e=0;e<d.length;e++)if(d[e].match&&d[e].match.def==b){c=!0;break}return c}function w(b,c,d){function e(c,d,g,i){function l(g,i,n){if(h>1e4)return alert("jquery.inputmask: There is probably an error in your mask definition or in the code. Create an issue on github with an example of the mask you are using. "+o().mask),!0;if(h==b&&void 0==g.matches)return j.push({match:g,locator:i.reverse()}),!0;if(void 0!=g.matches){if(g.isGroup&&!0!==n){if(g=l(c.matches[m+1],i))return!0}else if(g.isOptional){var p=g;if(g=e(g,d,i,n)){var q=j[j.length-1].match,r=0==a.inArray(q,p.matches);r&&(k=!0),h=b}}else if(g.isAlternator){var s,t=g,u=[],v=j.slice(),w=i.length,x=d.length>0?d.shift():-1;if(-1==x||"string"==typeof x){var y,z=h,A=d.slice();"string"==typeof x&&(y=x.split(","));for(var B=0;B<t.matches.length;B++){j=[],g=l(t.matches[B],[B].concat(i),n)||g,s=j.slice(),h=z,j=[];for(var C=0;C<A.length;C++)d[C]=A[C];for(var D=0;D<s.length;D++)for(var E=s[D],F=0;F<u.length;F++){var G=u[F];if(E.match.mask==G.match.mask&&("string"!=typeof x||-1!=a.inArray(E.locator[w].toString(),y))){s.splice(D,1),G.locator[w]=G.locator[w]+","+E.locator[w],G.alternation=w;break}}u=u.concat(s)}"string"==typeof x&&(u=a.map(u,function(b,c){if(isFinite(c)){var d=b.locator[w].toString().split(",");b.locator[w]=void 0,b.alternation=void 0;for(var e=0;e<d.length;e++)-1!=a.inArray(d[e],y)&&(void 0!=b.locator[w]?(b.locator[w]+=",",b.alternation=w,b.locator[w]+=d[e]):b.locator[w]=parseInt(d[e]));if(void 0!=b.locator[w])return b}})),j=v.concat(u),k=!0}else g=l(t.matches[x],[x].concat(i),n);if(g)return!0}else if(g.isQuantifier&&!0!==n){var H=g;f.greedy=f.greedy&&isFinite(H.quantifier.max);for(var I=d.length>0&&!0!==n?d.shift():0;I<(isNaN(H.quantifier.max)?I+1:H.quantifier.max)&&b>=h;I++){var J=c.matches[a.inArray(H,c.matches)-1];if(g=l(J,[I].concat(i),!0)){var q=j[j.length-1].match;q.optionalQuantifier=I>H.quantifier.min-1;var r=0==a.inArray(q,J.matches);if(r){if(I>H.quantifier.min-1){k=!0,h=b;break}return!0}return!0}}}else if(g=e(g,d,i,n))return!0}else h++}for(var m=d.length>0?d.shift():0;m<c.matches.length;m++)if(!0!==c.matches[m].isQuantifier){var n=l(c.matches[m],[m].concat(g),i);if(n&&h==b)return n;if(h>b)break}}var g=o().maskToken,h=c?d:0,i=c||[0],j=[],k=!1;if(void 0==c){for(var l,m=b-1;void 0==(l=o().validPositions[m])&&m>-1;)m--;if(void 0!=l&&m>-1)h=m,i=l.locator.slice();else{for(m=b-1;void 0==(l=o().tests[m])&&m>-1;)m--;void 0!=l&&m>-1&&(h=m,i=l[0].locator.slice())}}for(var n=i.shift();n<g.length;n++){if(e(g[n],i,[n])&&h==b||h>b)break}return(0==j.length||k)&&j.push({match:{fn:null,cardinality:0,optionality:!0,casing:null,def:""},locator:[]}),o().tests[b]=a.extend(!0,[],j),o().tests[b]}function x(){return void 0==o()._buffer&&(o()._buffer=h(!1,1)),o()._buffer}function y(){return void 0==o().buffer&&(o().buffer=h(!0,q(),!0)),o().buffer}function z(a,b){var c=y().slice();if(!0===a)p(),a=0,b=c.length;else for(var d=a;b>d;d++)delete o().validPositions[d],delete o().tests[d];for(var d=a;b>d;d++)c[d]!=f.skipOptionalPartCharacter&&B(d,c[d],!0,!0)}function A(a,b){switch(b.casing){case"upper":a=a.toUpperCase();break;case"lower":a=a.toLowerCase()}return a}function B(b,c,d,e){function g(b,c,d,e){var g=!1;return a.each(w(b),function(h,i){for(var j=i.match,k=c?1:0,l="",m=(y(),j.cardinality);m>k;m--)l+=G(b-(m-1));if(c&&(l+=c),!1!==(g=null!=j.fn?j.fn.test(l,o(),b,d,f):(c==j.def||c==f.skipOptionalPartCharacter)&&""!=j.def&&{c:j.def,pos:b})){var n=void 0!=g.c?g.c:c;n=n==f.skipOptionalPartCharacter&&null===j.fn?j.def:n;var t=b;if(void 0!=g.remove&&s(g.remove,g.remove+1),g.refreshFromBuffer){var u=g.refreshFromBuffer;if(d=!0,z(!0===u?u:u.start,u.end),void 0==g.pos&&void 0==g.c)return g.pos=q(),!1;if((t=void 0!=g.pos?g.pos:b)!=b)return g=a.extend(g,B(t,n,!0)),!1}else if(!0!==g&&void 0!=g.pos&&g.pos!=b&&(t=g.pos,z(b,t),t!=b))return g=a.extend(g,B(t,n,!0)),!1;return(1==g||void 0!=g.pos||void 0!=g.c)&&(h>0&&p(!0),r(t,a.extend({},i,{input:A(n,j)}),e)||(g=!1),!1)}}),g}d=!0===d;for(var h=y(),i=b-1;i>-1&&(!o().validPositions[i]||null!=o().validPositions[i].match.fn);i--)void 0==o().validPositions[i]&&(!C(i)||h[i]!=I(i))&&w(i).length>1&&g(i,h[i],!0);var j=b,k=!1;if(e&&j>=D()&&p(!0),j<D()&&(k=g(j,c,d,e),!d&&!1===k)){var l=o().validPositions[j];if(!l||null!=l.match.fn||l.match.def!=c&&c!=f.skipOptionalPartCharacter){if((f.insertMode||void 0==o().validPositions[E(j)])&&!C(j))for(var m=j+1,n=E(j);n>=m;m++)if(!1!==(k=g(m,c,d,e))){j=m;break}}else k={caret:E(j)}}return!1===k&&f.keepStatic&&R(h)&&(k=function(b,c,d,e){var g,h,i=a.extend(!0,{},o().validPositions);for(g=q();g>=0;g--)if(o().validPositions[g]&&void 0!=o().validPositions[g].alternation){h=o().validPositions[g].alternation;break}if(void 0!=h)for(var j in o().validPositions)if(parseInt(j)>parseInt(g)&&void 0===o().validPositions[j].alternation){for(var k=o().validPositions[j],l=k.locator[h],m=o().validPositions[g].locator[h].split(","),n=0;n<m.length;n++)if(l<m[n]){for(var r,s,t=j-1;t>=0;t--)if(void 0!=(r=o().validPositions[t])){s=r.locator[h],r.locator[h]=m[n];break}if(l!=r.locator[h]){for(var u=y().slice(),v=j;v<q()+1;v++)delete o().validPositions[v],delete o().tests[v];p(!0),f.keepStatic=!f.keepStatic;for(var v=j;v<u.length;v++)u[v]!=f.skipOptionalPartCharacter&&B(q()+1,u[v],!1,!0);r.locator[h]=s;var w=B(b,c,d,e);if(f.keepStatic=!f.keepStatic,w)return w;p(),o().validPositions=a.extend(!0,{},i)}}break}return!1}(b,c,d,e)),!0===k&&(k={pos:j}),k}function C(a){var b=u(a);return null!=b.fn&&b.fn}function D(){var a;if(ea=da.prop("maxLength"),-1==ea&&(ea=void 0),0==f.greedy){var b,c=q(),d=o().validPositions[c],e=void 0!=d?d.locator.slice():void 0;for(b=c+1;void 0==d||null!=d.match.fn||null==d.match.fn&&""!=d.match.def;b++)d=t(b,e,b-1),e=d.locator.slice();a=b}else a=y().length;return void 0==ea||ea>a?a:ea}function E(a){var b=D();if(a>=b)return b;for(var c=a;++c<b&&!C(c)&&(!0!==f.nojumps||f.nojumpsThreshold>c););return c}function F(a){var b=a;if(0>=b)return 0;for(;--b>0&&!C(b););return b}function G(a){return void 0==o().validPositions[a]?I(a):o().validPositions[a].input}function H(a,b,c){a._valueSet(b.join("")),void 0!=c&&O(a,c)}function I(b,c){c=c||u(b);var d=a.isFunction(c.placeholder)?c.placeholder.call(this,f):c.placeholder;return void 0!=d?d:null==c.fn?c.def:f.placeholder.charAt(b%f.placeholder.length)}function J(b,c,d,e,g){var h=void 0!=e?e.slice():L(b._valueGet()).split("");if(p(),c&&b._valueSet(""),a.each(h,function(c,e){if(!0===g){var f=q(),h=-1==f?c:E(f);-1==a.inArray(e,x().slice(f+1,h))&&Y.call(b,void 0,!0,e.charCodeAt(0),!1,d,d?c:o().p)}else Y.call(b,void 0,!0,e.charCodeAt(0),!1,d,d?c:o().p),d=d||c>0&&c>o().p}),c){var i=f.onKeyPress.call(this,void 0,y(),0,f);W(b,i),H(b,y(),a(b).is(":focus")?E(q(0)):void 0)}}function K(b){return a.inputmask.escapeRegex.call(this,b)}function L(a){return a.replace(new RegExp("("+K(x().join(""))+")*$"),"")}function M(b){if(b.data("_inputmask")&&!b.hasClass("hasDatepicker")){var c=[],d=o().validPositions;for(var e in d)d[e].match&&null!=d[e].match.fn&&c.push(d[e].input);var g=(fa?c.reverse():c).join(""),h=(fa?y().slice().reverse():y()).join("");return a.isFunction(f.onUnMask)&&(g=f.onUnMask.call(b,h,g,f)||g),g}return b[0]._valueGet()}function N(a){if(fa&&"number"==typeof a&&(!f.greedy||""!=f.placeholder)){a=y().length-a}return a}function O(b,c,d){var e,g=b.jquery&&b.length>0?b[0]:b;if("number"!=typeof c){var h=a(g).data("_inputmask");return!a(g).is(":visible")&&h&&void 0!=h.caret?(c=h.caret.begin,d=h.caret.end):g.setSelectionRange?(c=g.selectionStart,d=g.selectionEnd):document.selection&&document.selection.createRange&&(e=document.selection.createRange(),c=0-e.duplicate().moveStart("character",-1e5),d=c+e.text.length),c=N(c),d=N(d),{begin:c,end:d}}c=N(c),d=N(d),d="number"==typeof d?d:c;var h=a(g).data("_inputmask")||{};h.caret={begin:c,end:d},a(g).data("_inputmask",h),a(g).is(":visible")&&(g.scrollLeft=g.scrollWidth,0==f.insertMode&&c==d&&d++,g.setSelectionRange?(g.selectionStart=c,g.selectionEnd=d):g.createTextRange&&(e=g.createTextRange(),e.collapse(!0),e.moveEnd("character",d),e.moveStart("character",c),e.select()))}function P(b){var c,d,e=y(),f=e.length,g=q(),h={},i=o().validPositions[g],j=void 0!=i?i.locator.slice():void 0;for(c=g+1;c<e.length;c++)d=t(c,j,c-1),j=d.locator.slice(),h[c]=a.extend(!0,{},d);var k=i&&void 0!=i.alternation?i.locator[i.alternation].split(","):[];for(c=f-1;c>g&&(d=h[c].match,(d.optionality||d.optionalQuantifier||i&&void 0!=i.alternation&&void 0!=h[c].locator[i.alternation]&&-1!=a.inArray(h[c].locator[i.alternation].toString(),k))&&e[c]==I(c,d));c--)f--;return b?{l:f,def:h[f]?h[f].match:void 0}:f}function Q(a){for(var b=y(),c=b.slice(),d=P(),e=c.length-1;e>d&&!C(e);e--);c.splice(d,e+1-d),H(a,c)}function R(b){if(a.isFunction(f.isComplete))return f.isComplete.call(da,b,f);if("*"!=f.repeat){var c=!1,d=P(!0),e=F(d.l);if(q()==e&&(void 0==d.def||d.def.newBlockMarker||d.def.optionalQuantifier)){c=!0;for(var g=0;e>=g;g++){var h=C(g);if(h&&(void 0==b[g]||b[g]==I(g))||!h&&b[g]!=I(g)){c=!1;break}}}return c}}function S(a,b){return fa?a-b>1||a-b==1&&f.insertMode:b-a>1||b-a==1&&f.insertMode}function T(b){var c=a._data(b).events;a.each(c,function(b,c){a.each(c,function(a,b){if("inputmask"==b.namespace&&"setvalue"!=b.type){var c=b.handler;b.handler=function(a){return this.readOnly||this.disabled?void a.preventDefault:c.apply(this,arguments)}}})})}function U(b){function c(){var b=a(this),c=a(this).data("_inputmask");return c?c.opts.autoUnmask?b.inputmask("unmaskedvalue"):e.call(this)!=x().join("")?e.call(this):"":e.call(this)}function d(b){var c=a(this).data("_inputmask");c?(f.call(this,a.isFunction(c.opts.onBeforeMask)?c.opts.onBeforeMask.call(na,b,c.opts)||b:b),a(this).triggerHandler("setvalue.inputmask")):f.call(this,b)}var e,f;b._valueGet||(Object.getOwnPropertyDescriptor&&Object.getOwnPropertyDescriptor(b,"value"),document.__lookupGetter__&&b.__lookupGetter__("value")?(e=b.__lookupGetter__("value"),f=b.__lookupSetter__("value"),b.__defineGetter__("value",c),b.__defineSetter__("value",d)):(e=function(){return b.value},f=function(a){b.value=a},function(b){if(void 0==a.valHooks[b]||1!=a.valHooks[b].inputmaskpatch){var c=a.valHooks[b]&&a.valHooks[b].get?a.valHooks[b].get:function(a){return a.value},d=a.valHooks[b]&&a.valHooks[b].set?a.valHooks[b].set:function(a,b){return a.value=b,a};a.valHooks[b]={get:function(b){var d=a(b);if(d.data("_inputmask")){if(d.data("_inputmask").opts.autoUnmask)return d.inputmask("unmaskedvalue");var e=c(b),f=d.data("_inputmask"),g=f.maskset,h=g._buffer;return h=h?h.join(""):"",e!=h?e:""}return c(b)},set:function(b,c){var e,f=a(b),g=f.data("_inputmask");return g?(e=d(b,a.isFunction(g.opts.onBeforeMask)?g.opts.onBeforeMask.call(na,c,g.opts)||c:c),f.triggerHandler("setvalue.inputmask")):e=d(b,c),e},inputmaskpatch:!0}}}(b.type),function(b){a(b).bind("mouseenter.inputmask",function(){var b=a(this),c=this,d=c._valueGet();""!=d&&d!=y().join("")&&b.trigger("setvalue")});var c=a._data(b).events,d=c.mouseover;if(d){for(var e=d[d.length-1],f=d.length-1;f>0;f--)d[f]=d[f-1];d[0]=e}}(b)),b._valueGet=function(){return fa?e.call(this).split("").reverse().join(""):e.call(this)},b._valueSet=function(a){f.call(this,fa?a.split("").reverse().join(""):a)})}function V(b,c,d){if((f.numericInput||fa)&&(c==a.inputmask.keyCode.BACKSPACE?c=a.inputmask.keyCode.DELETE:c==a.inputmask.keyCode.DELETE&&(c=a.inputmask.keyCode.BACKSPACE),fa)){var e=d.end;d.end=d.begin,d.begin=e}c==a.inputmask.keyCode.BACKSPACE&&d.end-d.begin<=1?d.begin=F(d.begin):c==a.inputmask.keyCode.DELETE&&d.begin==d.end&&d.end++,s(d.begin,d.end),function(){if(f.keepStatic){p(!0);var a,c=[];for(a=q();a>=0;a--)if(o().validPositions[a]){if(void 0!=o().validPositions[a].alternation)break;c.push(o().validPositions[a].input),delete o().validPositions[a]}if(a>0)for(;c.length>0;)o().p=E(q()),Y.call(b,void 0,!0,c.pop().charCodeAt(0),!1,!1,o().p)}}();var g=q(d.begin);g<d.begin?(-1==g&&p(),o().p=E(g)):o().p=d.begin}function W(a,b,c){if(b&&b.refreshFromBuffer){var d=b.refreshFromBuffer;z(!0===d?d:d.start,d.end),p(!0),void 0!=c&&(H(a,y()),O(a,b.caret||c.begin,b.caret||c.end))}}function X(c){ga=!1;var d=this,e=a(d),g=c.keyCode,h=O(d);g==a.inputmask.keyCode.BACKSPACE||g==a.inputmask.keyCode.DELETE||i&&127==g||c.ctrlKey&&88==g&&!b("cut")?(c.preventDefault(),88==g&&(ca=y().join("")),V(d,g,h),H(d,y(),o().p),d._valueGet()==x().join("")&&e.trigger("cleared"),f.showTooltip&&e.prop("title",o().mask)):g==a.inputmask.keyCode.END||g==a.inputmask.keyCode.PAGE_DOWN?setTimeout(function(){var a=E(q());f.insertMode||a!=D()||c.shiftKey||a--,O(d,c.shiftKey?h.begin:a,a)},0):g==a.inputmask.keyCode.HOME&&!c.shiftKey||g==a.inputmask.keyCode.PAGE_UP?O(d,0,c.shiftKey?h.begin:0):g==a.inputmask.keyCode.ESCAPE||90==g&&c.ctrlKey?(J(d,!0,!1,ca.split("")),e.click()):g!=a.inputmask.keyCode.INSERT||c.shiftKey||c.ctrlKey?0!=f.insertMode||c.shiftKey||(g==a.inputmask.keyCode.RIGHT?setTimeout(function(){var a=O(d);O(d,a.begin)},0):g==a.inputmask.keyCode.LEFT&&setTimeout(function(){var a=O(d);O(d,fa?a.begin+1:a.begin-1)},0)):(f.insertMode=!f.insertMode,O(d,f.insertMode||h.begin!=D()?h.begin:h.begin-1));var j=O(d),k=f.onKeyDown.call(this,c,y(),j.begin,f);W(d,k,j),ia=-1!=a.inArray(g,f.ignorables)}function Y(b,c,d,e,g,h){if(void 0==d&&ga)return!1;ga=!0;var i=this,j=a(i);b=b||window.event;var d=c?d:b.which||b.charCode||b.keyCode;if(!(!0===c||b.ctrlKey&&b.altKey)&&(b.ctrlKey||b.metaKey||ia))return!0;if(d){!0!==c&&46==d&&0==b.shiftKey&&","==f.radixPoint&&(d=44);var k,l=c?{begin:h,end:h}:O(i),m=String.fromCharCode(d),n=S(l.begin,l.end);n&&(o().undoPositions=a.extend(!0,{},o().validPositions),V(i,a.inputmask.keyCode.DELETE,l),f.insertMode||(f.insertMode=!f.insertMode,r(l.begin,g),f.insertMode=!f.insertMode),n=!f.multi),o().writeOutBuffer=!0;var q=fa&&!n?l.end:l.begin,s=B(q,m,g);if(!1!==s){if(!0!==s&&(q=void 0!=s.pos?s.pos:q,m=void 0!=s.c?s.c:m),p(!0),void 0!=s.caret)k=s.caret;else{var t=o().validPositions;k=!f.keepStatic&&(void 0!=t[q+1]&&w(q+1,t[q].locator.slice(),q).length>1||void 0!=t[q].alternation)?q+1:E(q)}o().p=k}if(!1!==e){var u=this;if(setTimeout(function(){f.onKeyValidation.call(u,s,f)},0),o().writeOutBuffer&&!1!==s){var v=y();H(i,v,c?void 0:f.numericInput?F(k):k),!0!==c&&setTimeout(function(){!0===R(v)&&j.trigger("complete"),ha=!0,j.trigger("input")},0)}else n&&(o().buffer=void 0,o().validPositions=o().undoPositions)}else n&&(o().buffer=void 0,o().validPositions=o().undoPositions);if(f.showTooltip&&j.prop("title",o().mask),b&&1!=c){b.preventDefault();var x=O(i);W(i,f.onKeyPress.call(this,b,y(),x.begin,f),x)}}}function Z(b){var c=a(this),d=this,e=b.keyCode,g=y(),h=O(d);W(d,f.onKeyUp.call(this,b,g,h.begin,f),h),e==a.inputmask.keyCode.TAB&&f.showMaskOnFocus&&(c.hasClass("focus-inputmask")&&0==d._valueGet().length?(p(),g=y(),H(d,g),
3
+ O(d,0),ca=y().join("")):(H(d,g),O(d,N(0),N(D()))))}function $(b){if(!0===ha&&"input"==b.type)return ha=!1,!0;var c=this,d=a(c),e=c._valueGet(),g=O(c);if("propertychange"==b.type&&c._valueGet().length<=D())return!0;"paste"==b.type&&(window.clipboardData&&window.clipboardData.getData?e=e.substr(0,g.begin)+window.clipboardData.getData("Text")+e.substr(g.end,e.length):b.originalEvent&&b.originalEvent.clipboardData&&b.originalEvent.clipboardData.getData&&(e=e.substr(0,g.begin)+b.originalEvent.clipboardData.getData("text/plain")+e.substr(g.end,e.length)));var h=a.isFunction(f.onBeforePaste)?f.onBeforePaste.call(c,e,f)||e:e;return J(c,!0,!1,fa?h.split("").reverse():h.split(""),!0),d.click(),!0===R(y())&&d.trigger("complete"),!1}function _(b){if(!0===ha&&"input"==b.type)return ha=!1,!0;var c=this,d=O(c),e=c._valueGet();e=e.replace(new RegExp("("+K(x().join(""))+")*"),""),d.begin>e.length&&(O(c,e.length),d=O(c)),y().length-e.length!=1||e.charAt(d.begin)==y()[d.begin]||e.charAt(d.begin+1)==y()[d.begin]||C(d.begin)||(b.keyCode=a.inputmask.keyCode.BACKSPACE,X.call(c,b)),b.preventDefault()}function aa(b){if(!0===ha&&"input"==b.type)return ha=!1,!0;var c=this,d=O(c),e=c._valueGet();O(c,d.begin-1);var g=a.Event("keypress");g.which=e.charCodeAt(d.begin-1),ga=!1,ia=!1,Y.call(c,g,void 0,void 0,!1);var h=o().p;H(c,y(),f.numericInput?F(h):h),b.preventDefault()}function ba(b){ha=!0;var c=this;return setTimeout(function(){O(c,O(c).begin-1);var d=a.Event("keypress");d.which=b.originalEvent.data.charCodeAt(0),ga=!1,ia=!1,Y.call(c,d,void 0,void 0,!1);var e=o().p;H(c,y(),f.numericInput?F(e):e)},0),!1}var ca,da,ea,fa=!1,ga=!1,ha=!1,ia=!1;if(void 0!=d)switch(d.action){case"isComplete":return da=a(d.el),e=da.data("_inputmask").maskset,f=da.data("_inputmask").opts,R(d.buffer);case"unmaskedvalue":return da=d.$input,e=da.data("_inputmask").maskset,f=da.data("_inputmask").opts,fa=d.$input.data("_inputmask").isRTL,M(d.$input);case"mask":ca=y().join(""),function(b){if(da=a(b),da.is(":input")&&c(da.attr("type"))){if(da.data("_inputmask",{maskset:e,opts:f,isRTL:!1}),f.showTooltip&&da.prop("title",o().mask),("rtl"==b.dir||f.rightAlign)&&da.css("text-align","right"),"rtl"==b.dir||f.numericInput){b.dir="ltr",da.removeAttr("dir");var d=da.data("_inputmask");d.isRTL=!0,da.data("_inputmask",d),fa=!0}da.unbind(".inputmask"),da.removeClass("focus-inputmask"),da.closest("form").bind("submit",function(){ca!=y().join("")&&da.change(),da[0]._valueGet&&da[0]._valueGet()==x().join("")&&da[0]._valueSet(""),f.autoUnmask&&f.removeMaskOnSubmit&&da.inputmask("remove")}).bind("reset",function(){setTimeout(function(){da.trigger("setvalue")},0)}),da.bind("mouseenter.inputmask",function(){var b=a(this),c=this;!b.hasClass("focus-inputmask")&&f.showMaskOnHover&&c._valueGet()!=y().join("")&&H(c,y())}).bind("blur.inputmask",function(){var b=a(this),c=this;if(b.data("_inputmask")){var d=c._valueGet(),e=y();b.removeClass("focus-inputmask"),ca!=y().join("")&&b.change(),f.clearMaskOnLostFocus&&""!=d&&(d==x().join("")?c._valueSet(""):Q(c)),!1===R(e)&&(b.trigger("incomplete"),f.clearIncomplete&&(p(),f.clearMaskOnLostFocus?c._valueSet(""):(e=x().slice(),H(c,e))))}}).bind("focus.inputmask",function(){var b=a(this),c=this,d=c._valueGet();f.showMaskOnFocus&&!b.hasClass("focus-inputmask")&&(!f.showMaskOnHover||f.showMaskOnHover&&""==d)&&c._valueGet()!=y().join("")&&H(c,y(),E(q())),b.addClass("focus-inputmask"),ca=y().join("")}).bind("mouseleave.inputmask",function(){var b=a(this),c=this;f.clearMaskOnLostFocus&&(b.hasClass("focus-inputmask")||c._valueGet()==b.attr("placeholder")||(c._valueGet()==x().join("")||""==c._valueGet()?c._valueSet(""):Q(c)))}).bind("click.inputmask",function(){var b=this;a(b).is(":focus")&&setTimeout(function(){var c=O(b);if(c.begin==c.end)if(f.radixFocus&&""!=f.radixPoint&&-1!=a.inArray(f.radixPoint,y())&&y().join("")==x().join(""))O(b,a.inArray(f.radixPoint,y()));else{var d=fa?N(c.begin):c.begin,e=E(q(d));e>d?O(b,C(d)?d:E(d)):O(b,e)}},0)}).bind("dblclick.inputmask",function(){var a=this;setTimeout(function(){O(a,0,E(q()))},0)}).bind(n+".inputmask dragdrop.inputmask drop.inputmask",$).bind("setvalue.inputmask",function(){var a=this;J(a,!0,!1,void 0,!0),ca=y().join(""),(f.clearMaskOnLostFocus||f.clearIncomplete)&&a._valueGet()==x().join("")&&a._valueSet("")}).bind("cut.inputmask",function(b){ha=!0;var c=this,d=a(c),e=O(c);V(c,a.inputmask.keyCode.DELETE,e),W(c,f.onKeyPress.call(this,b,y(),o().p,f),{begin:o().p,end:o().p}),c._valueGet()==x().join("")&&d.trigger("cleared"),f.showTooltip&&d.prop("title",o().mask)}).bind("complete.inputmask",f.oncomplete).bind("incomplete.inputmask",f.onincomplete).bind("cleared.inputmask",f.oncleared),da.bind("keydown.inputmask",X).bind("keypress.inputmask",Y).bind("keyup.inputmask",Z).bind("compositionupdate.inputmask",ba),"paste"!==n||g||da.bind("input.inputmask",aa),g&&da.bind("input.inputmask",$),(j||l||k||m)&&("input"==n&&da.unbind(n+".inputmask"),da.bind("input.inputmask",_)),U(b);J(b,!0,!1,(a.isFunction(f.onBeforeMask)?f.onBeforeMask.call(b,b._valueGet(),f)||b._valueGet():b._valueGet()).split(""),!0),ca=y().join("");var h;try{h=document.activeElement}catch(a){}!1===R(y())&&f.clearIncomplete&&p(),f.clearMaskOnLostFocus?y().join("")==x().join("")?b._valueSet(""):Q(b):H(b,y()),h===b&&(da.addClass("focus-inputmask"),O(b,E(q()))),T(b)}}(d.el);break;case"format":da=a({}),da.data("_inputmask",{maskset:e,opts:f,isRTL:f.numericInput}),f.numericInput&&(fa=!0);var ja=(a.isFunction(f.onBeforeMask)?f.onBeforeMask.call(da,d.value,f)||d.value:d.value).split("");return J(da,!1,!1,fa?ja.reverse():ja,!0),f.onKeyPress.call(this,void 0,y(),0,f),d.metadata?{value:fa?y().slice().reverse().join(""):y().join(""),metadata:da.inputmask("getmetadata")}:fa?y().slice().reverse().join(""):y().join("");case"isValid":da=a({}),da.data("_inputmask",{maskset:e,opts:f,isRTL:f.numericInput}),f.numericInput&&(fa=!0);var ja=d.value.split("");J(da,!1,!0,fa?ja.reverse():ja);for(var ka=y(),la=P(),ma=ka.length-1;ma>la&&!C(ma);ma--);return ka.splice(la,ma+1-la),R(ka)&&d.value==ka.join("");case"getemptymask":return da=a(d.el),e=da.data("_inputmask").maskset,f=da.data("_inputmask").opts,x();case"remove":var na=d.el;da=a(na),e=da.data("_inputmask").maskset,f=da.data("_inputmask").opts,na._valueSet(M(da)),da.unbind(".inputmask"),da.removeClass("focus-inputmask"),da.removeData("_inputmask");var oa;Object.getOwnPropertyDescriptor&&(oa=Object.getOwnPropertyDescriptor(na,"value")),oa&&oa.get?na._valueGet&&Object.defineProperty(na,"value",{get:na._valueGet,set:na._valueSet}):document.__lookupGetter__&&na.__lookupGetter__("value")&&na._valueGet&&(na.__defineGetter__("value",na._valueGet),na.__defineSetter__("value",na._valueSet));try{delete na._valueGet,delete na._valueSet}catch(a){na._valueGet=void 0,na._valueSet=void 0}break;case"getmetadata":if(da=a(d.el),e=da.data("_inputmask").maskset,f=da.data("_inputmask").opts,a.isArray(e.metadata)){for(var pa,qa=q(),ra=qa;ra>=0;ra--)if(o().validPositions[ra]&&void 0!=o().validPositions[ra].alternation){pa=o().validPositions[ra].alternation;break}return void 0!=pa?e.metadata[o().validPositions[qa].locator[pa]]:e.metadata[0]}return e.metadata}}if(void 0===a.fn.inputmask){var g="function"==typeof ScriptEngineMajorVersion?ScriptEngineMajorVersion():new Function("/*@cc_on return @_jscript_version; @*/")()>=10,h=navigator.userAgent,i=null!==h.match(new RegExp("iphone","i")),j=null!==h.match(new RegExp("android.*safari.*","i")),k=null!==h.match(new RegExp("android.*chrome.*","i")),l=null!==h.match(new RegExp("android.*firefox.*","i")),m=/Kindle/i.test(h)||/Silk/i.test(h)||/KFTT/i.test(h)||/KFOT/i.test(h)||/KFJWA/i.test(h)||/KFJWI/i.test(h)||/KFSOWI/i.test(h)||/KFTHWA/i.test(h)||/KFTHWI/i.test(h)||/KFAPWA/i.test(h)||/KFAPWI/i.test(h),n=b("paste")?"paste":b("input")?"input":"propertychange";a.inputmask={defaults:{placeholder:"_",optionalmarker:{start:"[",end:"]"},quantifiermarker:{start:"{",end:"}"},groupmarker:{start:"(",end:")"},alternatormarker:"|",escapeChar:"\\",mask:null,oncomplete:a.noop,onincomplete:a.noop,oncleared:a.noop,repeat:0,greedy:!0,autoUnmask:!1,removeMaskOnSubmit:!0,clearMaskOnLostFocus:!0,insertMode:!0,clearIncomplete:!1,aliases:{},alias:null,onKeyUp:a.noop,onKeyPress:a.noop,onKeyDown:a.noop,onBeforeMask:void 0,onBeforePaste:void 0,onUnMask:void 0,showMaskOnFocus:!0,showMaskOnHover:!0,onKeyValidation:a.noop,skipOptionalPartCharacter:" ",showTooltip:!1,numericInput:!1,rightAlign:!1,radixPoint:"",radixFocus:!1,nojumps:!1,nojumpsThreshold:0,keepStatic:void 0,definitions:{9:{validator:"[0-9]",cardinality:1,definitionSymbol:"*"},a:{validator:"[A-Za-zА-яЁёÀ-ÿµ]",cardinality:1,definitionSymbol:"*"},"*":{validator:"[0-9A-Za-zА-яЁёÀ-ÿµ]",cardinality:1}},ignorables:[8,9,13,19,27,33,34,35,36,37,38,39,40,45,46,93,112,113,114,115,116,117,118,119,120,121,122,123],isComplete:void 0},keyCode:{ALT:18,BACKSPACE:8,CAPS_LOCK:20,COMMA:188,COMMAND:91,COMMAND_LEFT:91,COMMAND_RIGHT:93,CONTROL:17,DELETE:46,DOWN:40,END:35,ENTER:13,ESCAPE:27,HOME:36,INSERT:45,LEFT:37,MENU:93,NUMPAD_ADD:107,NUMPAD_DECIMAL:110,NUMPAD_DIVIDE:111,NUMPAD_ENTER:108,NUMPAD_MULTIPLY:106,NUMPAD_SUBTRACT:109,PAGE_DOWN:34,PAGE_UP:33,PERIOD:190,RIGHT:39,SHIFT:16,SPACE:32,TAB:9,UP:38,WINDOWS:91},masksCache:{},escapeRegex:function(a){var b=["/",".","*","+","?","|","(",")","[","]","{","}","\\"];return a.replace(new RegExp("(\\"+b.join("|\\")+")","gim"),"\\$1")},format:function(b,c,g){var h=a.extend(!0,{},a.inputmask.defaults,c);return d(h.alias,c,h),f({action:"format",value:b,metadata:g},e(h),h)},isValid:function(b,c){var g=a.extend(!0,{},a.inputmask.defaults,c);return d(g.alias,c,g),f({action:"isValid",value:b},e(g),g)}},a.fn.inputmask=function(b,c,g,h,i){function j(b,c,e){var f=a(b);f.data("inputmask-alias")&&d(f.data("inputmask-alias"),{},c);for(var g in c){var h=f.data("inputmask-"+g.toLowerCase());void 0!=h&&("mask"==g&&0==h.indexOf("[")?(c[g]=h.replace(/[\s[\]]/g,"").split("','"),c[g][0]=c[g][0].replace("'",""),c[g][c[g].length-1]=c[g][c[g].length-1].replace("'","")):c[g]="boolean"==typeof h?h:h.toString(),e&&(e[g]=c[g]))}return c}g=g||f,h=h||"_inputmask";var k,l=a.extend(!0,{},a.inputmask.defaults,c);if("string"==typeof b)switch(b){case"mask":return d(l.alias,c,l),k=e(l,g!==f),void 0==k?this:this.each(function(){g({action:"mask",el:this},a.extend(!0,{},k),j(this,l))});case"unmaskedvalue":var m=a(this);return m.data(h)?g({action:"unmaskedvalue",$input:m}):m.val();case"remove":return this.each(function(){a(this).data(h)&&g({action:"remove",el:this})});case"getemptymask":return this.data(h)?g({action:"getemptymask",el:this}):"";case"hasMaskedValue":return!!this.data(h)&&!this.data(h).opts.autoUnmask;case"isComplete":return!this.data(h)||g({action:"isComplete",buffer:this[0]._valueGet().split(""),el:this});case"getmetadata":return this.data(h)?g({action:"getmetadata",el:this}):void 0;case"_detectScope":return d(l.alias,c,l),void 0==i||d(i,c,l)||-1!=a.inArray(i,["mask","unmaskedvalue","remove","getemptymask","hasMaskedValue","isComplete","getmetadata","_detectScope"])||(l.mask=i),a.isFunction(l.mask)&&(l.mask=l.mask.call(this,l)),a.isArray(l.mask);default:return d(l.alias,c,l),d(b,c,l)||(l.mask=b),k=e(l,g!==f),void 0==k?this:this.each(function(){g({action:"mask",el:this},a.extend(!0,{},k),j(this,l))})}else{if("object"==typeof b)return l=a.extend(!0,{},a.inputmask.defaults,b),d(l.alias,b,l),k=e(l,g!==f),void 0==k?this:this.each(function(){g({action:"mask",el:this},a.extend(!0,{},k),j(this,l))});if(void 0==b)return this.each(function(){var b=a(this).attr("data-inputmask");if(b&&""!=b)try{b=b.replace(new RegExp("'","g"),'"');var e=a.parseJSON("{"+b+"}");a.extend(!0,e,c),l=a.extend(!0,{},a.inputmask.defaults,e),l=j(this,l),d(l.alias,e,l),l.alias=void 0,a(this).inputmask("mask",l,g)}catch(a){}if(a(this).attr("data-inputmask-mask")||a(this).attr("data-inputmask-alias")){l=a.extend(!0,{},a.inputmask.defaults,{});var f={};l=j(this,l,f),d(l.alias,f,l),l.alias=void 0,a(this).inputmask("mask",l,g)}})}}}a.fn.inputmask}(jQuery),function(a){a.extend(a.inputmask.defaults.definitions,{h:{validator:"[01][0-9]|2[0-3]",cardinality:2,prevalidator:[{validator:"[0-2]",cardinality:1}]},s:{validator:"[0-5][0-9]",cardinality:2,prevalidator:[{validator:"[0-5]",cardinality:1}]},d:{validator:"0[1-9]|[12][0-9]|3[01]",cardinality:2,prevalidator:[{validator:"[0-3]",cardinality:1}]},m:{validator:"0[1-9]|1[012]",cardinality:2,prevalidator:[{validator:"[01]",cardinality:1}]},y:{validator:"(19|20)\\d{2}",cardinality:4,prevalidator:[{validator:"[12]",cardinality:1},{validator:"(19|20)",cardinality:2},{validator:"(19|20)\\d",cardinality:3}]}}),a.extend(a.inputmask.defaults.aliases,{"dd/mm/yyyy":{mask:"1/2/y",placeholder:"dd/mm/yyyy",regex:{val1pre:new RegExp("[0-3]"),val1:new RegExp("0[1-9]|[12][0-9]|3[01]"),val2pre:function(b){var c=a.inputmask.escapeRegex.call(this,b);return new RegExp("((0[1-9]|[12][0-9]|3[01])"+c+"[01])")},val2:function(b){var c=a.inputmask.escapeRegex.call(this,b);return new RegExp("((0[1-9]|[12][0-9])"+c+"(0[1-9]|1[012]))|(30"+c+"(0[13-9]|1[012]))|(31"+c+"(0[13578]|1[02]))")}},leapday:"29/02/",separator:"/",yearrange:{minyear:1900,maxyear:2099},isInYearRange:function(a,b,c){if(isNaN(a))return!1;var d=parseInt(a.concat(b.toString().slice(a.length))),e=parseInt(a.concat(c.toString().slice(a.length)));return!isNaN(d)&&(d>=b&&c>=d)||!isNaN(e)&&(e>=b&&c>=e)},determinebaseyear:function(a,b,c){var d=(new Date).getFullYear();if(a>d)return a;if(d>b){for(var e=b.toString().slice(0,2),f=b.toString().slice(2,4);e+c>b;)e--;var g=e+f;return a>g?a:g}return d},onKeyUp:function(b){var c=a(this);if(b.ctrlKey&&b.keyCode==a.inputmask.keyCode.RIGHT){var d=new Date;c.val(d.getDate().toString()+(d.getMonth()+1).toString()+d.getFullYear().toString())}},definitions:{1:{validator:function(a,b,c,d,e){var f=e.regex.val1.test(a);return d||f||a.charAt(1)!=e.separator&&-1=="-./".indexOf(a.charAt(1))||!(f=e.regex.val1.test("0"+a.charAt(0)))?f:(b.buffer[c-1]="0",{refreshFromBuffer:{start:c-1,end:c},pos:c,c:a.charAt(0)})},cardinality:2,prevalidator:[{validator:function(a,b,c,d,e){isNaN(b.buffer[c+1])||(a+=b.buffer[c+1]);var f=1==a.length?e.regex.val1pre.test(a):e.regex.val1.test(a);return d||f||!(f=e.regex.val1.test("0"+a))?f:(b.buffer[c]="0",c++,{pos:c})},cardinality:1}]},2:{validator:function(a,b,c,d,e){var f=e.mask.indexOf("2")==e.mask.length-1?b.buffer.join("").substr(5,3):b.buffer.join("").substr(0,3);-1!=f.indexOf(e.placeholder[0])&&(f="01"+e.separator);var g=e.regex.val2(e.separator).test(f+a);if(!d&&!g&&(a.charAt(1)==e.separator||-1!="-./".indexOf(a.charAt(1)))&&(g=e.regex.val2(e.separator).test(f+"0"+a.charAt(0))))return b.buffer[c-1]="0",{refreshFromBuffer:{start:c-1,end:c},pos:c,c:a.charAt(0)};if(e.mask.indexOf("2")==e.mask.length-1&&g){if(b.buffer.join("").substr(4,4)+a!=e.leapday)return!0;var h=parseInt(b.buffer.join("").substr(0,4),10);return h%4==0&&(h%100!=0||h%400==0)}return g},cardinality:2,prevalidator:[{validator:function(a,b,c,d,e){isNaN(b.buffer[c+1])||(a+=b.buffer[c+1]);var f=e.mask.indexOf("2")==e.mask.length-1?b.buffer.join("").substr(5,3):b.buffer.join("").substr(0,3);-1!=f.indexOf(e.placeholder[0])&&(f="01"+e.separator);var g=1==a.length?e.regex.val2pre(e.separator).test(f+a):e.regex.val2(e.separator).test(f+a);return d||g||!(g=e.regex.val2(e.separator).test(f+"0"+a))?g:(b.buffer[c]="0",c++,{pos:c})},cardinality:1}]},y:{validator:function(a,b,c,d,e){if(e.isInYearRange(a,e.yearrange.minyear,e.yearrange.maxyear)){if(b.buffer.join("").substr(0,6)!=e.leapday)return!0;var f=parseInt(a,10);return f%4==0&&(f%100!=0||f%400==0)}return!1},cardinality:4,prevalidator:[{validator:function(a,b,c,d,e){var f=e.isInYearRange(a,e.yearrange.minyear,e.yearrange.maxyear);if(!d&&!f){var g=e.determinebaseyear(e.yearrange.minyear,e.yearrange.maxyear,a+"0").toString().slice(0,1);if(f=e.isInYearRange(g+a,e.yearrange.minyear,e.yearrange.maxyear))return b.buffer[c++]=g.charAt(0),{pos:c};if(g=e.determinebaseyear(e.yearrange.minyear,e.yearrange.maxyear,a+"0").toString().slice(0,2),f=e.isInYearRange(g+a,e.yearrange.minyear,e.yearrange.maxyear))return b.buffer[c++]=g.charAt(0),b.buffer[c++]=g.charAt(1),{pos:c}}return f},cardinality:1},{validator:function(a,b,c,d,e){var f=e.isInYearRange(a,e.yearrange.minyear,e.yearrange.maxyear);if(!d&&!f){var g=e.determinebaseyear(e.yearrange.minyear,e.yearrange.maxyear,a).toString().slice(0,2);if(f=e.isInYearRange(a[0]+g[1]+a[1],e.yearrange.minyear,e.yearrange.maxyear))return b.buffer[c++]=g.charAt(1),{pos:c};if(g=e.determinebaseyear(e.yearrange.minyear,e.yearrange.maxyear,a).toString().slice(0,2),e.isInYearRange(g+a,e.yearrange.minyear,e.yearrange.maxyear)){if(b.buffer.join("").substr(0,6)!=e.leapday)f=!0;else{var h=parseInt(a,10);f=h%4==0&&(h%100!=0||h%400==0)}}else f=!1;if(f)return b.buffer[c-1]=g.charAt(0),b.buffer[c++]=g.charAt(1),b.buffer[c++]=a.charAt(0),{refreshFromBuffer:{start:c-3,end:c},pos:c}}return f},cardinality:2},{validator:function(a,b,c,d,e){return e.isInYearRange(a,e.yearrange.minyear,e.yearrange.maxyear)},cardinality:3}]}},insertMode:!1,autoUnmask:!1},"mm/dd/yyyy":{placeholder:"mm/dd/yyyy",alias:"dd/mm/yyyy",regex:{val2pre:function(b){var c=a.inputmask.escapeRegex.call(this,b);return new RegExp("((0[13-9]|1[012])"+c+"[0-3])|(02"+c+"[0-2])")},val2:function(b){var c=a.inputmask.escapeRegex.call(this,b);return new RegExp("((0[1-9]|1[012])"+c+"(0[1-9]|[12][0-9]))|((0[13-9]|1[012])"+c+"30)|((0[13578]|1[02])"+c+"31)")},val1pre:new RegExp("[01]"),val1:new RegExp("0[1-9]|1[012]")},leapday:"02/29/",onKeyUp:function(b){var c=a(this);if(b.ctrlKey&&b.keyCode==a.inputmask.keyCode.RIGHT){var d=new Date;c.val((d.getMonth()+1).toString()+d.getDate().toString()+d.getFullYear().toString())}}},"yyyy/mm/dd":{mask:"y/1/2",placeholder:"yyyy/mm/dd",alias:"mm/dd/yyyy",leapday:"/02/29",onKeyUp:function(b){var c=a(this);if(b.ctrlKey&&b.keyCode==a.inputmask.keyCode.RIGHT){var d=new Date;c.val(d.getFullYear().toString()+(d.getMonth()+1).toString()+d.getDate().toString())}}},"dd.mm.yyyy":{mask:"1.2.y",placeholder:"dd.mm.yyyy",leapday:"29.02.",separator:".",alias:"dd/mm/yyyy"},"dd-mm-yyyy":{mask:"1-2-y",placeholder:"dd-mm-yyyy",leapday:"29-02-",separator:"-",alias:"dd/mm/yyyy"},"mm.dd.yyyy":{mask:"1.2.y",placeholder:"mm.dd.yyyy",leapday:"02.29.",separator:".",alias:"mm/dd/yyyy"},"mm-dd-yyyy":{mask:"1-2-y",placeholder:"mm-dd-yyyy",leapday:"02-29-",separator:"-",alias:"mm/dd/yyyy"},"yyyy.mm.dd":{mask:"y.1.2",placeholder:"yyyy.mm.dd",leapday:".02.29",separator:".",alias:"yyyy/mm/dd"},"yyyy-mm-dd":{mask:"y-1-2",placeholder:"yyyy-mm-dd",leapday:"-02-29",separator:"-",alias:"yyyy/mm/dd"},datetime:{mask:"1/2/y h:s",placeholder:"dd/mm/yyyy hh:mm",alias:"dd/mm/yyyy",regex:{hrspre:new RegExp("[012]"),hrs24:new RegExp("2[0-4]|1[3-9]"),hrs:new RegExp("[01][0-9]|2[0-4]"),ampm:new RegExp("^[a|p|A|P][m|M]"),mspre:new RegExp("[0-5]"),ms:new RegExp("[0-5][0-9]")},timeseparator:":",hourFormat:"24",definitions:{h:{validator:function(a,b,c,d,e){if("24"==e.hourFormat&&24==parseInt(a,10))return b.buffer[c-1]="0",b.buffer[c]="0",{refreshFromBuffer:{start:c-1,end:c},c:"0"};var f=e.regex.hrs.test(a);if(!d&&!f&&(a.charAt(1)==e.timeseparator||-1!="-.:".indexOf(a.charAt(1)))&&(f=e.regex.hrs.test("0"+a.charAt(0))))return b.buffer[c-1]="0",b.buffer[c]=a.charAt(0),c++,{refreshFromBuffer:{start:c-2,end:c},pos:c,c:e.timeseparator};if(f&&"24"!==e.hourFormat&&e.regex.hrs24.test(a)){var g=parseInt(a,10);return 24==g?(b.buffer[c+5]="a",b.buffer[c+6]="m"):(b.buffer[c+5]="p",b.buffer[c+6]="m"),g-=12,10>g?(b.buffer[c]=g.toString(),b.buffer[c-1]="0"):(b.buffer[c]=g.toString().charAt(1),b.buffer[c-1]=g.toString().charAt(0)),{refreshFromBuffer:{start:c-1,end:c+6},c:b.buffer[c]}}return f},cardinality:2,prevalidator:[{validator:function(a,b,c,d,e){var f=e.regex.hrspre.test(a);return d||f||!(f=e.regex.hrs.test("0"+a))?f:(b.buffer[c]="0",c++,{pos:c})},cardinality:1}]},s:{validator:"[0-5][0-9]",cardinality:2,prevalidator:[{validator:function(a,b,c,d,e){var f=e.regex.mspre.test(a);return d||f||!(f=e.regex.ms.test("0"+a))?f:(b.buffer[c]="0",c++,{pos:c})},cardinality:1}]},t:{validator:function(a,b,c,d,e){return e.regex.ampm.test(a+"m")},casing:"lower",cardinality:1}},insertMode:!1,autoUnmask:!1},datetime12:{mask:"1/2/y h:s t\\m",placeholder:"dd/mm/yyyy hh:mm xm",alias:"datetime",hourFormat:"12"},"hh:mm t":{mask:"h:s t\\m",placeholder:"hh:mm xm",alias:"datetime",hourFormat:"12"},"h:s t":{mask:"h:s t\\m",placeholder:"hh:mm xm",alias:"datetime",hourFormat:"12"},"hh:mm:ss":{mask:"h:s:s",placeholder:"hh:mm:ss",alias:"datetime",autoUnmask:!1},"hh:mm":{mask:"h:s",placeholder:"hh:mm",alias:"datetime",autoUnmask:!1},date:{alias:"dd/mm/yyyy"},"mm/yyyy":{mask:"1/y",placeholder:"mm/yyyy",leapday:"donotuse",separator:"/",alias:"mm/dd/yyyy"}}),a.fn.inputmask}(jQuery),function(a){a.extend(a.inputmask.defaults.definitions,{A:{validator:"[A-Za-zА-яЁёÀ-ÿµ]",cardinality:1,casing:"upper"},"#":{validator:"[0-9A-Za-zА-яЁёÀ-ÿµ]",cardinality:1,casing:"upper"}}),a.extend(a.inputmask.defaults.aliases,{url:{mask:"ir",placeholder:"",separator:"",defaultPrefix:"http://",regex:{urlpre1:new RegExp("[fh]"),urlpre2:new RegExp("(ft|ht)"),urlpre3:new RegExp("(ftp|htt)"),urlpre4:new RegExp("(ftp:|http|ftps)"),urlpre5:new RegExp("(ftp:/|ftps:|http:|https)"),urlpre6:new RegExp("(ftp://|ftps:/|http:/|https:)"),urlpre7:new RegExp("(ftp://|ftps://|http://|https:/)"),urlpre8:new RegExp("(ftp://|ftps://|http://|https://)")},definitions:{i:{validator:function(){return!0},cardinality:8,prevalidator:function(){for(var a=[],b=0;8>b;b++)a[b]=function(){var a=b;return{validator:function(b,c,d,e,f){if(f.regex["urlpre"+(a+1)]){var g,h=b;a+1-b.length>0&&(h=c.buffer.join("").substring(0,a+1-b.length)+""+h);var i=f.regex["urlpre"+(a+1)].test(h);if(!e&&!i){for(d-=a,g=0;g<f.defaultPrefix.length;g++)c.buffer[d]=f.defaultPrefix[g],d++;for(g=0;g<h.length-1;g++)c.buffer[d]=h[g],d++;return{pos:d}}return i}return!1},cardinality:a}}();return a}()},r:{validator:".",cardinality:50}},insertMode:!1,autoUnmask:!1},ip:{mask:"i[i[i]].i[i[i]].i[i[i]].i[i[i]]",definitions:{i:{validator:function(a,b,c){return c-1>-1&&"."!=b.buffer[c-1]?(a=b.buffer[c-1]+a,a=c-2>-1&&"."!=b.buffer[c-2]?b.buffer[c-2]+a:"0"+a):a="00"+a,new RegExp("25[0-5]|2[0-4][0-9]|[01][0-9][0-9]").test(a)},cardinality:1}}},email:{mask:"*{1,64}[.*{1,64}][.*{1,64}][.*{1,64}]@*{1,64}[.*{2,64}][.*{2,6}][.*{1,2}]",greedy:!1,onBeforePaste:function(a){return a=a.toLowerCase(),a.replace("mailto:","")},definitions:{"*":{validator:"[0-9A-Za-z!#$%&'*+/=?^_`{|}~-]",cardinality:1,casing:"lower"}}}}),a.fn.inputmask}(jQuery),function(a){a.extend(a.inputmask.defaults.aliases,{numeric:{mask:function(a){if(0!==a.repeat&&isNaN(a.integerDigits)&&(a.integerDigits=a.repeat),a.repeat=0,a.groupSeparator==a.radixPoint&&(a.groupSeparator="."==a.radixPoint?",":","==a.radixPoint?".":"")," "===a.groupSeparator&&(a.skipOptionalPartCharacter=void 0),a.autoGroup=a.autoGroup&&""!=a.groupSeparator,a.autoGroup&&isFinite(a.integerDigits)){var b=Math.floor(a.integerDigits/a.groupSize),c=a.integerDigits%a.groupSize;a.integerDigits+=0==c?b-1:b}a.definitions[";"]=a.definitions["~"];var d=a.prefix;return d+="[+]",d+="~{1,"+a.integerDigits+"}",void 0!=a.digits&&(isNaN(a.digits)||parseInt(a.digits)>0)&&(d+=a.digitsOptional?"["+(a.decimalProtect?":":a.radixPoint)+";{"+a.digits+"}]":(a.decimalProtect?":":a.radixPoint)+";{"+a.digits+"}"),d+=a.suffix},placeholder:"",greedy:!1,digits:"*",digitsOptional:!0,groupSeparator:"",radixPoint:".",radixFocus:!0,groupSize:3,autoGroup:!1,allowPlus:!0,allowMinus:!0,integerDigits:"+",prefix:"",suffix:"",rightAlign:!0,decimalProtect:!0,postFormat:function(b,c,d,e){var f=!1,g=b[c];if(""==e.groupSeparator||-1!=a.inArray(e.radixPoint,b)&&c>=a.inArray(e.radixPoint,b)||new RegExp("[-+]").test(g))return{pos:c};var h=b.slice();g==e.groupSeparator&&(h.splice(c--,1),g=h[c]),d?h[c]="?":h.splice(c,0,"?");var i=h.join("");if(e.autoGroup||d&&-1!=i.indexOf(e.groupSeparator)){var j=a.inputmask.escapeRegex.call(this,e.groupSeparator);f=0==i.indexOf(e.groupSeparator),i=i.replace(new RegExp(j,"g"),"");var k=i.split(e.radixPoint);if((i=k[0])!=e.prefix+"?0"&&i.length>=e.groupSize+e.prefix.length){f=!0;for(var l=new RegExp("([-+]?[\\d?]+)([\\d?]{"+e.groupSize+"})");l.test(i);)i=i.replace(l,"$1"+e.groupSeparator+"$2"),i=i.replace(e.groupSeparator+e.groupSeparator,e.groupSeparator)}k.length>1&&(i+=e.radixPoint+k[1])}b.length=i.length;for(var m=0,n=i.length;n>m;m++)b[m]=i.charAt(m);var o=a.inArray("?",b);return d?b[o]=g:b.splice(o,1),{pos:o,refreshFromBuffer:f}},onKeyDown:function(b,c,d,e){if(b.keyCode==a.inputmask.keyCode.TAB&&"0"!=e.placeholder.charAt(0)){var f=a.inArray(e.radixPoint,c);if(-1!=f&&isFinite(e.digits)){for(var g=1;g<=e.digits;g++)(void 0==c[f+g]||c[f+g]==e.placeholder.charAt(0))&&(c[f+g]="0");return{refreshFromBuffer:{start:++f,end:f+e.digits}}}}else if(e.autoGroup&&(b.keyCode==a.inputmask.keyCode.DELETE||b.keyCode==a.inputmask.keyCode.BACKSPACE)){var h=e.postFormat(c,d-1,!0,e);return h.caret=h.pos+1,h}},onKeyPress:function(a,b,c,d){if(d.autoGroup){var e=d.postFormat(b,c-1,!0,d);return e.caret=e.pos+1,e}},regex:{integerPart:function(){return new RegExp("[-+]?\\d+")},integerNPart:function(){return new RegExp("\\d+")}},signHandler:function(a,b,c,d,e){if(!d&&(e.allowMinus&&"-"===a||e.allowPlus&&"+"===a)){var f=b.join("").match(e.regex.integerPart(e));if(f&&f.length>0&&"0"!==f[f.index])return b[f.index]==("-"===a?"+":"-")?{pos:f.index,c:a,remove:f.index,caret:c}:b[f.index]==("-"===a?"-":"+")?{remove:f.index,caret:c-1}:{pos:f.index,c:a,caret:c+1}}return!1},radixHandler:function(b,c,d,e,f){if(!e&&b===f.radixPoint){var g=a.inArray(f.radixPoint,c.buffer),h=c.buffer.join("").match(f.regex.integerPart(f));if(-1!=g)return c.validPositions[g-1]?{caret:g+1}:{pos:h.index,c:h[0],caret:g+1}}return!1},leadingZeroHandler:function(b,c,d,e,f){var g=c.buffer.join("").match(f.regex.integerNPart(f)),h=a.inArray(f.radixPoint,c.buffer);if(g&&!e&&(-1==h||g.index<h))if(0==g[0].indexOf("0")&&d>=f.prefix.length){if(-1==h||h>=d&&void 0==c.validPositions[h])return c.buffer.splice(g.index,1),d=d>g.index?d-1:g.index,{pos:d,remove:g.index};if(d>g.index&&h>=d)return c.buffer.splice(g.index,1),d=d>g.index?d-1:g.index,{pos:d,remove:g.index}}else if("0"==b&&d<=g.index)return!1;return!0},definitions:{"~":{validator:function(b,c,d,e,f){var g=f.signHandler(b,c.buffer,d,e,f);if(!g&&!(g=f.radixHandler(b,c,d,e,f))&&!0===(g=e?new RegExp("[0-9"+a.inputmask.escapeRegex.call(this,f.groupSeparator)+"]").test(b):new RegExp("[0-9]").test(b))&&!0===(g=f.leadingZeroHandler(b,c,d,e,f))){var h=a.inArray(f.radixPoint,c.buffer);!1===f.digitsOptional&&d>h&&!e&&(g={pos:d,remove:d}),g={pos:d}}return g},cardinality:1,prevalidator:null},"+":{validator:function(a,b,c,d,e){var f=e.signHandler(a,b.buffer,c,d,e);return f||(f=e.allowMinus&&"-"==a||e.allowPlus&&"+"==a),f},cardinality:1,prevalidator:null,placeholder:""},":":{validator:function(b,c,d,e,f){var g=f.signHandler(b,c.buffer,d,e,f);if(!g){var h="["+a.inputmask.escapeRegex.call(this,f.radixPoint)+"]";(g=new RegExp(h).test(b))&&c.validPositions[d]&&c.validPositions[d].match.placeholder==f.radixPoint&&(g={pos:d,remove:d})}return g},cardinality:1,prevalidator:null,placeholder:function(a){return a.radixPoint}}},insertMode:!0,autoUnmask:!1,onUnMask:function(b,c,d){var e=b.replace(d.prefix,"");return e=e.replace(d.suffix,""),e=e.replace(new RegExp(a.inputmask.escapeRegex.call(this,d.groupSeparator),"g"),"")},isComplete:function(b,c){var d=b.join(""),e=b.slice();if(c.postFormat(e,0,!0,c),e.join("")!=d)return!1;var f=d.replace(c.prefix,"");return f=f.replace(c.suffix,""),f=f.replace(new RegExp(a.inputmask.escapeRegex.call(this,c.groupSeparator),"g"),""),f=f.replace(a.inputmask.escapeRegex.call(this,c.radixPoint),"."),isFinite(f)},onBeforeMask:function(b,c){if(isFinite(b))return b.toString().replace(".",c.radixPoint);var d=b.match(/,/g),e=b.match(/\./g);return e&&d?e.length>d.length?(b=b.replace(/\./g,""),b=b.replace(",",c.radixPoint)):d.length>e.length&&(b=b.replace(/,/g,""),b=b.replace(".",c.radixPoint)):b=b.replace(new RegExp(a.inputmask.escapeRegex.call(this,c.groupSeparator),"g"),""),b}},currency:{prefix:"$ ",groupSeparator:",",radixPoint:".",alias:"numeric",placeholder:"0",autoGroup:!0,digits:2,digitsOptional:!1,clearMaskOnLostFocus:!1,decimalProtect:!0},decimal:{alias:"numeric"},integer:{alias:"numeric",digits:"0"}}),a.fn.inputmask}(jQuery),function(a){a.extend(a.inputmask.defaults.aliases,{phone:{url:"phone-codes/phone-codes.js",maskInit:"+pp(pp)pppppppp",mask:function(b){b.definitions={p:{validator:function(){return!1},cardinality:1},"#":{validator:"[0-9]",cardinality:1}};var c=[];return a.ajax({url:b.url,async:!1,dataType:"json",success:function(a){c=a}}),c=c.sort(function(a,b){return(a.mask||a)<(b.mask||b)?-1:1}),c.splice(0,0,b.maskInit),c},nojumps:!0,nojumpsThreshold:1},phonebe:{alias:"phone",url:"phone-codes/phone-be.js",maskInit:"+32(pp)pppppppp",nojumpsThreshold:4}}),a.fn.inputmask}(jQuery),function(a){a.extend(a.inputmask.defaults.aliases,{Regex:{mask:"r",greedy:!1,repeat:"*",regex:null,regexTokens:null,tokenizer:/\[\^?]?(?:[^\\\]]+|\\[\S\s]?)*]?|\\(?:0(?:[0-3][0-7]{0,2}|[4-7][0-7]?)?|[1-9][0-9]*|x[0-9A-Fa-f]{2}|u[0-9A-Fa-f]{4}|c[A-Za-z]|[\S\s]?)|\((?:\?[:=!]?)?|(?:[?*+]|\{[0-9]+(?:,[0-9]*)?\})\??|[^.?*+^${[()|\\]+|./g,quantifierFilter:/[0-9]+[^,]/,isComplete:function(a,b){return new RegExp(b.regex).test(a.join(""))},definitions:{r:{validator:function(b,c,d,e,f){function g(a,b){this.matches=[],this.isGroup=a||!1,this.isQuantifier=b||!1,this.quantifier={min:1,max:1},this.repeaterPart=void 0}function h(b,c){var d=!1;c&&(j+="(",l++);for(var e=0;e<b.matches.length;e++){var f=b.matches[e];if(1==f.isGroup)d=h(f,!0);else if(1==f.isQuantifier){var g=a.inArray(f,b.matches),i=b.matches[g-1],k=j;if(isNaN(f.quantifier.max)){for(;f.repeaterPart&&f.repeaterPart!=j&&f.repeaterPart.length>j.length&&!(d=h(i,!0)););d=d||h(i,!0),d&&(f.repeaterPart=j),j=k+f.quantifier.max}else{for(var n=0,o=f.quantifier.max-1;o>n&&!(d=h(i,!0));n++);j=k+"{"+f.quantifier.min+","+f.quantifier.max+"}"}}else if(void 0!=f.matches)for(var p=0;p<f.length&&!(d=h(f[p],c));p++);else{var q;if("["==f.charAt(0)){q=j,q+=f;for(var r=0;l>r;r++)q+=")";var s=new RegExp("^("+q+")$");d=s.test(m)}else for(var t=0,u=f.length;u>t;t++)if("\\"!=f.charAt(t)){q=j,q+=f.substr(0,t+1),q=q.replace(/\|$/,"");for(var r=0;l>r;r++)q+=")";var s=new RegExp("^("+q+")$");if(d=s.test(m))break}j+=f}if(d)break}return c&&(j+=")",l--),d}null==f.regexTokens&&function(){var a,b,c=new g,d=[];for(f.regexTokens=[];a=f.tokenizer.exec(f.regex);)switch(b=a[0],b.charAt(0)){case"(":d.push(new g(!0));break;case")":var e=d.pop();d.length>0?d[d.length-1].matches.push(e):c.matches.push(e);break;case"{":case"+":case"*":var h=new g(!1,!0);b=b.replace(/[{}]/g,"");var i=b.split(","),j=isNaN(i[0])?i[0]:parseInt(i[0]),k=1==i.length?j:isNaN(i[1])?i[1]:parseInt(i[1]);if(h.quantifier={min:j,max:k},d.length>0){var l=d[d.length-1].matches;if(a=l.pop(),!a.isGroup){var e=new g(!0);e.matches.push(a),a=e}l.push(a),l.push(h)}else{if(a=c.matches.pop(),!a.isGroup){var e=new g(!0);e.matches.push(a),a=e}c.matches.push(a),c.matches.push(h)}break;default:d.length>0?d[d.length-1].matches.push(b):c.matches.push(b)}c.matches.length>0&&f.regexTokens.push(c)}();var i=c.buffer.slice(),j="",k=!1,l=0;i.splice(d,0,b);for(var m=i.join(""),n=0;n<f.regexTokens.length;n++){var g=f.regexTokens[n];if(k=h(g,g.isGroup))break}return k},cardinality:1}}}}),a.fn.inputmask}(jQuery),jQuery(document).ready(function(a){jQuery(document).on("cf.add",function(){a("[data-inputmask]").inputmask()}),jQuery(document).trigger("cf.add")}),function(a){"function"==typeof define&&define.amd?define(["jquery"],a):a("object"==typeof exports?require("jquery"):jQuery)}(function(a){function b(a,b){var c=Array.prototype.slice.call(arguments,2);return setTimeout(function(){return a.apply(null,c)},b)}function c(a,b){return b=b||100,function(){if(!a.debouncing){var c=Array.prototype.slice.apply(arguments);a.lastReturnVal=a.apply(window,c),a.debouncing=!0}return clearTimeout(a.debounceTimeout),
4
+ a.debounceTimeout=setTimeout(function(){a.debouncing=!1},b),a.lastReturnVal}}function d(d,f){if(this.$window=a(window),this.$document=a(document),this.$element=a(d),this.options=a.extend({},h,f),this._defaults=h,this._name=e,this.startEvent=this.options.startEvent.join("."+e+" ")+"."+e,this.moveEvent=this.options.moveEvent.join("."+e+" ")+"."+e,this.endEvent=this.options.endEvent.join("."+e+" ")+"."+e,this.polyfill=this.options.polyfill,this.onInit=this.options.onInit,this.onSlide=this.options.onSlide,this.onSlideEnd=this.options.onSlideEnd,this.polyfill&&g)return!1;this.identifier="js-"+e+"-"+ +new Date,this.min=parseFloat(this.$element[0].getAttribute("min")||0),this.max=parseFloat(this.$element[0].getAttribute("max")||100),this.value=parseFloat(this.$element[0].value||this.min+(this.max-this.min)/2),this.step=parseFloat(this.$element[0].getAttribute("step")||1),this.$fill=a('<div class="'+this.options.fillClass+'" />'),this.$handle=a('<div class="'+this.options.handleClass+'" />'),this.$range=a('<div class="'+this.options.rangeClass+'" id="'+this.identifier+'" />').insertAfter(this.$element).prepend(this.$fill,this.$handle),this.$element.css({position:"absolute",width:"1px",height:"1px",overflow:"hidden",opacity:"0"}),this.handleDown=a.proxy(this.handleDown,this),this.handleMove=a.proxy(this.handleMove,this),this.handleEnd=a.proxy(this.handleEnd,this),this.init();var i=this;this.$window.on("resize."+e,c(function(){b(function(){i.update()},300)},20)),this.$document.on(this.startEvent,"#"+this.identifier+":not(."+this.options.disabledClass+")",this.handleDown),this.$element.on("change."+e,function(a,b){if(!b||b.origin!==e){var c=a.target.value,d=i.getPositionFromValue(c);i.setPosition(d)}})}var e="rangeslider",f=[],g=function(){var a=document.createElement("input");return a.setAttribute("type","range"),"text"!==a.type}(),h={polyfill:!0,rangeClass:"rangeslider",disabledClass:"rangeslider--disabled",fillClass:"rangeslider__fill",handleClass:"rangeslider__handle",startEvent:["mousedown","touchstart","pointerdown"],moveEvent:["mousemove","touchmove","pointermove"],endEvent:["mouseup","touchend","pointerup"]};d.prototype.init=function(){this.onInit&&"function"==typeof this.onInit&&this.onInit(),this.update()},d.prototype.update=function(){this.handleWidth=this.$handle[0].offsetWidth,this.rangeWidth=this.$range[0].offsetWidth,this.maxHandleX=this.rangeWidth-this.handleWidth,this.grabX=this.handleWidth/2,this.position=this.getPositionFromValue(this.value),this.$element[0].disabled?this.$range.addClass(this.options.disabledClass):this.$range.removeClass(this.options.disabledClass),this.setPosition(this.position)},d.prototype.handleDown=function(a){if(a.preventDefault(),this.$document.on(this.moveEvent,this.handleMove),this.$document.on(this.endEvent,this.handleEnd),!((" "+a.target.className+" ").replace(/[\n\t]/g," ").indexOf(this.options.handleClass)>-1)){var b=this.getRelativePosition(this.$range[0],a),c=this.getPositionFromNode(this.$handle[0])-this.getPositionFromNode(this.$range[0]);this.setPosition(b-this.grabX),b>=c&&b<c+this.handleWidth&&(this.grabX=b-c)}},d.prototype.handleMove=function(a){a.preventDefault();var b=this.getRelativePosition(this.$range[0],a);this.setPosition(b-this.grabX)},d.prototype.handleEnd=function(a){a.preventDefault(),this.$document.off(this.moveEvent,this.handleMove),this.$document.off(this.endEvent,this.handleEnd);var b=this.getRelativePosition(this.$range[0],a);this.onSlideEnd&&"function"==typeof this.onSlideEnd&&this.onSlideEnd(b-this.grabX,this.value)},d.prototype.cap=function(a,b,c){return a<b?b:a>c?c:a},d.prototype.setPosition=function(a){var b,c;b=this.getValueFromPosition(this.cap(a,0,this.maxHandleX))/this.step*this.step,c=this.getPositionFromValue(b),this.$fill[0].style.width=c+this.grabX+"px",this.$handle[0].style.left=c+"px",this.setValue(b),this.position=c,this.value=b,this.onSlide&&"function"==typeof this.onSlide&&this.onSlide(c,b)},d.prototype.getPositionFromNode=function(a){for(var b=0;null!==a;)b+=a.offsetLeft,a=a.offsetParent;return b},d.prototype.getRelativePosition=function(a,b){return(b.pageX||b.originalEvent.clientX||b.originalEvent.touches[0].clientX||b.currentPoint.x)-this.getPositionFromNode(a)},d.prototype.getPositionFromValue=function(a){var b;return b=(a-this.min)/(this.max-this.min),b*this.maxHandleX},d.prototype.getValueFromPosition=function(a){var b,c;return b=a/(this.maxHandleX||1),c=this.step*Math.ceil((b*(this.max-this.min)+this.min)/this.step),Number(c.toFixed(2))},d.prototype.setValue=function(a){a!==this.value&&this.$element.val(a).trigger("change",{origin:e})},d.prototype.destroy=function(){this.$document.off(this.startEvent,"#"+this.identifier,this.handleDown),this.$element.off("."+e).removeAttr("style").removeData("plugin_"+e),this.$range&&this.$range.length&&this.$range[0].parentNode.removeChild(this.$range[0]),f.splice(f.indexOf(this.$element[0]),1),f.length||this.$window.off("."+e)},a.fn[e]=function(b){return this.each(function(){var c=a(this),g=c.data("plugin_"+e);g||(c.data("plugin_"+e,g=new d(this,b)),f.push(this)),"string"==typeof b&&g[b]()})}}),function(a){"use strict";var b={init:function(c){return this.each(function(){this.self=a(this),b.destroy.call(this.self),this.opt=a.extend(!0,{},a.fn.raty.defaults,c),b._adjustCallback.call(this),b._adjustNumber.call(this),"img"!==this.opt.starType&&b._adjustStarType.call(this),b._adjustPath.call(this),b._createStars.call(this),this.opt.cancel&&b._createCancel.call(this),this.opt.precision&&b._adjustPrecision.call(this),b._createScore.call(this),b._apply.call(this,this.opt.score),b._target.call(this,this.opt.score),this.opt.readOnly?b._lock.call(this):(this.style.cursor="pointer",b._binds.call(this)),this.self.data("options",this.opt)})},_adjustCallback:function(){for(var a=["number","readOnly","score","scoreName"],b=0;b<a.length;b++)"function"==typeof this.opt[a[b]]&&(this.opt[a[b]]=this.opt[a[b]].call(this))},_adjustNumber:function(){this.opt.number=b._between(this.opt.number,1,this.opt.numberMax)},_adjustPath:function(){this.opt.path=this.opt.path||"",this.opt.path&&"/"!==this.opt.path.charAt(this.opt.path.length-1)&&(this.opt.path+="/")},_adjustPrecision:function(){this.opt.half=!0,this.opt.targetType="score"},_adjustStarType:function(){this.opt.path="";for(var a=["cancelOff","cancelOn","starHalf","starOff","starOn"],b=0;b<a.length;b++)this.opt[a[b]]=this.opt[a[b]].replace(".","-")},_apply:function(a){b._fill.call(this,a),a&&(a>0&&this.score.val(b._between(a,0,this.opt.number)),b._roundStars.call(this,a))},_between:function(a,b,c){return Math.min(Math.max(parseFloat(a),b),c)},_binds:function(){this.cancel&&(b._bindOverCancel.call(this),b._bindClickCancel.call(this),b._bindOutCancel.call(this)),b._bindOver.call(this),b._bindClick.call(this),b._bindOut.call(this)},_bindClick:function(){var b=this;b.stars.on("click.raty",function(c){var d=a(this);b.score.val(b.opt.half||b.opt.precision?b.self.data("score"):this.alt||d.data("alt")),b.opt.click&&b.opt.click.call(b,+b.score.val(),c)})},_bindClickCancel:function(){var a=this;a.cancel.on("click.raty",function(b){a.score.removeAttr("value"),a.opt.click&&a.opt.click.call(a,null,b)})},_bindOut:function(){var a=this;a.self.on("mouseleave.raty",function(c){var d=+a.score.val()||void 0;b._apply.call(a,d),b._target.call(a,d,c),a.opt.mouseout&&a.opt.mouseout.call(a,d,c)})},_bindOutCancel:function(){var b=this;b.cancel.on("mouseleave.raty",function(c){var d=a(this),e=b.opt.path+b.opt.cancelOff;if("img"===b.opt.starType)d.attr("src",e);else{var f=b.opt.path+b.opt.cancelOn;d.removeClass(f).addClass(e)}if(b.opt.mouseout){var g=+b.score.val()||void 0;b.opt.mouseout.call(b,g,c)}})},_bindOver:function(){var a=this,c=a.opt.half?"mousemove.raty":"mouseover.raty";a.stars.on(c,function(c){var d=b._getScoreByPosition.call(a,c,this);b._fill.call(a,d),a.opt.half&&(b._roundStars.call(a,d),a.self.data("score",d)),b._target.call(a,d,c),a.opt.mouseover&&a.opt.mouseover.call(a,d,c)})},_bindOverCancel:function(){var c=this;c.cancel.on("mouseover.raty",function(d){var e=c.opt.path+c.opt.cancelOn,f=a(this),g=c.opt.path+c.opt.starOff;if("img"===c.opt.starType)f.attr("src",e),c.stars.attr("src",g);else{c.stars.attr("class",g);var h=c.opt.path+c.opt.cancelOff;f.removeClass(h).addClass(e).css("color",c.opt.starColor)}b._target.call(c,null,d),c.opt.mouseover&&c.opt.mouseover.call(c,null)})},_buildScoreField:function(){return a("<input />",{name:this.opt.scoreName,type:"hidden"}).appendTo(this)},_createCancel:function(){var b=this.opt.path+this.opt.cancelOff,c=a("<"+this.opt.starType+" />",{title:this.opt.cancelHint,class:"raty-cancel"}).css("marginRight",this.opt.space?this.opt.spaceWidth+"px":"0");"img"===this.opt.starType?c.attr({src:b,alt:"x"}):c.attr("data-alt","x").addClass(b),"left"===this.opt.cancelPlace?this.self.prepend("&#160;").prepend(c):this.self.append("&#160;").append(c),this.cancel=c},_createScore:function(){var c=a(this.opt.targetScore);this.score=c.length?c:b._buildScoreField.call(this)},_createStars:function(){for(var c=1;c<=this.opt.number;c++){var d,e=this.opt.score&&this.opt.score>=c?"starOn":"starOff",f=b._getHint.call(this,c);e=this.opt.path+this.opt[e],d="img"!==this.opt.starType?{"data-alt":c,class:e}:{src:e,alt:c},d.title=f,a("<"+this.opt.starType+" />",d).css("marginRight",c<this.opt.number&&this.opt.space?this.opt.spaceWidth+"px":"0").appendTo(this),this.opt.space}this.stars=this.self.children(this.opt.starType)},_error:function(b){a(this).text(b),a.error(b)},_fill:function(a){for(var c=0,d=1;d<=this.stars.length;d++){var e,f=this.stars.eq(d-1),g=b._turnOn.call(this,d,a);if(this.opt.iconRange&&this.opt.iconRange.length>c){var h=this.opt.iconRange[c];e=b._getIconRange.call(this,h,g),d<=h.range&&("img"===this.opt.starType?f.attr("src",e):f.attr("class",e)),d===h.range&&c++}else e=this.opt.path+this.opt[g?"starOn":"starOff"],"img"===this.opt.starType?f.attr("src",e):f.attr("class",e),g?f.css("color",this.opt.starColor):f.css("color","")}},_getIconRange:function(a,b){return this.opt.path+(b?a.on||this.opt.starOn:a.off||this.opt.starOff)},_getScoreByPosition:function(c,d){var e=a(d),f=parseInt(d.alt||e.data("alt"),10);if(this.opt.half){var g=b._getSize.call(this),h=parseFloat((c.pageX-e.offset().left)/g);f=this.opt.precision?f-1+h:f-1+(h>.5?1:.5)}return f},_getSize:function(){var a;return a="img"===this.opt.starType?this.stars[0].width:parseFloat(this.stars.eq(0).css("font-size")),a||b._error.call(this,"Could not be possible get the icon size!"),a},_turnOn:function(a,b){return this.opt.single?a===b:a<=b},_getHint:function(a){var b=this.opt.hints[a-1];return""===b?"":b||a},_lock:function(){var a=parseInt(this.score.val(),10),c=a?b._getHint.call(this,a):this.opt.noRatedMsg;this.style.cursor="",this.title=c,this.score.prop("readonly",!0),this.stars.prop("title",c),this.cancel&&this.cancel.hide(),this.self.data("readonly",!0)},_roundStars:function(a){var b=(a%1).toFixed(2);if(b>this.opt.round.down){var c="starOn";this.opt.halfShow&&b<this.opt.round.up?c="starHalf":b<this.opt.round.full&&(c="starOff");var d=this.stars[Math.ceil(a)-1];"img"===this.opt.starType?d.src=this.opt.path+this.opt[c]:d.style.className=this.opt[c]}},_target:function(c,d){if(this.opt.target){var e=a(this.opt.target);e.length||b._error.call(this,"Target selector invalid or missing!");var f=d&&"mouseover"===d.type;if(void 0===c)c=this.opt.targetText;else if(null===c)c=f?this.opt.cancelHint:this.opt.targetText;else{"hint"===this.opt.targetType?c=b._getHint.call(this,Math.ceil(c)):this.opt.precision&&(c=parseFloat(c).toFixed(1));var g=d&&"mousemove"===d.type;f||g||this.opt.targetKeep||(c=this.opt.targetText)}c&&(c=this.opt.targetFormat.toString().replace("{score}",c)),e.is(":input")?e.val(c):e.html(c)}},_unlock:function(){this.style.cursor="pointer",this.removeAttribute("title"),this.score.removeAttr("readonly"),this.self.data("readonly",!1);for(var a=0;a<this.opt.number;a++)this.stars[a].title=b._getHint.call(this,a+1);this.cancel&&this.cancel.css("display","")},cancel:function(c){return this.each(function(){var d=a(this);!0!==d.data("readonly")&&(b[c?"click":"score"].call(d,null),this.score.removeAttr("value"))})},click:function(c){return this.each(function(){!0!==a(this).data("readonly")&&(b._apply.call(this,c),this.opt.click&&this.opt.click.call(this,c,a.Event("click")),b._target.call(this,c))})},destroy:function(){return this.each(function(){var b=a(this),c=b.data("raw");c?b.off(".raty").empty().css({cursor:c.style.cursor}).removeData("readonly"):b.data("raw",b.clone()[0])})},getScore:function(){var a,b=[];return this.each(function(){a=this.score.val(),b.push(a?+a:void 0)}),b.length>1?b:b[0]},move:function(c){return this.each(function(){var d=parseInt(c,10),e=a(this).data("options"),f=(+c).toFixed(1).split(".")[1];d>=e.number&&(d=e.number-1,f=10);var g=b._getSize.call(this),h=g/10,i=a(this.stars[d]),j=i.offset().left+h*parseInt(f,10),k=a.Event("mousemove",{pageX:j});i.trigger(k)})},readOnly:function(c){return this.each(function(){var d=a(this);d.data("readonly")!==c&&(c?(d.off(".raty").children("img").off(".raty"),b._lock.call(this)):(b._binds.call(this),b._unlock.call(this)),d.data("readonly",c))})},reload:function(){return b.set.call(this,{})},score:function(){var c=a(this);return arguments.length?b.setScore.apply(c,arguments):b.getScore.call(c)},set:function(b){return this.each(function(){var c=a(this),d=c.data("options"),e=a.extend({},d,b);c.raty(e)})},setScore:function(c){return this.each(function(){!0!==a(this).data("readonly")&&(b._apply.call(this,c),b._target.call(this,c))})}};a.fn.raty=function(c){return b[c]?b[c].apply(this,Array.prototype.slice.call(arguments,1)):"object"!=typeof c&&c?void a.error("Method "+c+" does not exist!"):b.init.apply(this,arguments)},a.fn.raty.defaults={cancel:!1,cancelHint:"Cancel this rating!",cancelOff:"raty-cancel-off",cancelOn:"raty-cancel-on",cancelPlace:"left",click:void 0,half:!1,halfShow:!0,hints:["1"],iconRange:void 0,mouseout:void 0,mouseover:void 0,noRatedMsg:"Not rated yet!",number:5,numberMax:20,path:void 0,precision:!1,readOnly:!1,round:{down:.25,full:.6,up:.76},score:void 0,scoreName:"score",single:!1,space:!0,spaceWidth:3,starColor:"#ff00aa",starHalf:"star-half.png",starOff:"raty-dot-off",starOn:"raty-dot-on",starType:"img",target:void 0,targetFormat:"{score}",targetKeep:!1,targetScore:void 0,targetText:"",targetType:"hint"}}(jQuery),jQuery(function(a){a("body").on("click",".cf-toggle-group-buttons a",function(){var b=a(this),c=b.closest(".caldera-config-field"),d=c.find('[data-ref="'+b.attr("id")+'"]');c.find(".btn").removeClass(b.data("active")).addClass(b.data("default")),b.addClass(b.data("active")).removeClass(b.data("default")),d.prop("checked",!0).trigger("change")})});var cf_jsfields_init,cf_presubmit;!function(a){cf_validate_form=function(a){return a.parsley({errorsWrapper:'<span class="help-block caldera_ajax_error_block"></span>',errorTemplate:"<span></span>",errorsContainer:function(a){return a.$element.closest(".form-group")}}).on("field:error",function(a){if("number"==this.$element.attr("type")&&0==this.$element.attr("min")){var b=this.$element.val();return void(0<=b&&(void 0==this.$element.attr("max")||b<=this.$element.attr("max"))&&(a.validationResult=!0))}this.$element.closest(".form-group").addClass("has-error")}).on("field:success",function(){this.$element.closest(".form-group").removeClass("has-error")})},a("[data-sync]").each(function(){var b=a(this);new CalderaFormsFieldSync(b,b.data("binds"),b.closest("form"),a)}),a(document).on("change keypress","[data-sync]",function(){a(this).data("unsync",!0)}),cf_jsfields_init=function(){a(".init_field_type[data-type]").each(function(b,c){var d=a(c);"function"==typeof window[d.data("type")+"_init"]&&window[d.data("type")+"_init"](d.prop("id"),d[0])}),window.Parsley.on("field:validated",function(){setTimeout(function(){a(document).trigger("cf.error")},15)}),"undefined"==typeof resBaldrickTriggers&&a(".caldera_forms_form").length,a(document).trigger("cf.fieldsInit")},a("document").ready(function(){cf_jsfields_init()}),a(".caldera-form-page").length&&a(".caldera-form-page").on("keypress","[data-field]:not(textarea)",function(a){13===a.keyCode&&a.preventDefault()}),a(document).on("click",".cf_modal_button",function(b){b.preventDefault();var c=a(this);a(c.attr("href")).show()}),a(document).on("click",".caldera-front-modal-closer",function(b){b.preventDefault(),a(this).closest(".caldera-front-modal-container").hide()}),a(document).on("cf.add cf.enable cf.disable cf.pagenav",cf_jsfields_init),a(document).on("click","[data-page]",function(b){var c,d,e,f=a(this),g=f.closest(".caldera-form-page"),h=f.closest("form.caldera_forms_form"),i=h.data("instance"),j=h.find(".caldera-form-page:visible").data("formpage"),k=g.data("formpage")?g.data("formpage"):f.data("page"),l=a('.breadcrumb[data-form="caldera_form_'+i+'"]'),m=!0,n={};if(h.length){if(cf_validate_form(h).destroy(),e=h.find("[data-field]"),h.find(".has-error").removeClass("has-error"),"prev"!==f.data("page")&&k>=j)for(var o=0;o<e.length;o++){var p=a(e[o]);if(p.is(":radio,:checkbox")){if(!p.hasClass("option-required")||!1===p.is(":visible"))continue;n[p.data("field")]||(n[p.data("field")]=[]),n[p.data("field")].push(p.prop("checked"))}else{if(p.prop("required")&&!1===p.is(":visible"))continue;if(p.prop("required")&&!0!==p.parsley().isValid()){if(p.is(":visible"))p.parsley().validate(),b.preventDefault();else{var q=parseFloat(p.closest(".caldera-form-page[data-formpage]").data("formpage"));q<parseFloat(k)&&h.find('[data-page="'+q+'"]').addClass("has-error")}m=!1}}}for(var r in n)n[r].indexOf(!0)<0?(a('[for="'+r+"_"+i+'"]').parent().addClass("has-error"),m=!1):a('[for="'+r+"_"+i+'"]').parent().removeClass("has-error");if(!1===m)return cf_validate_form(h).validate(),!1;"next"===f.data("page")?(l&&l.find("li.active").removeClass("active").children().attr("aria-expanded","false"),c=h.find('.caldera-form-page[data-formpage="'+(k+1)+'"]'),c.length&&(g.hide().attr("aria-hidden","true").css("visibility","hidden"),c.show().attr("aria-hidden","false").css("visibility","visible"),l&&l.find('a[data-page="'+(k+1)+'"]').attr("aria-expanded","true").parent().addClass("active"))):"prev"===f.data("page")?(l&&l.find("li.active").removeClass("active").children().attr("aria-expanded","false"),d=h.find('.caldera-form-page[data-formpage="'+(k-1)+'"]'),d.length&&(g.hide().attr("aria-hidden","true").css("visibility","hidden"),d.show().attr("aria-hidden","false").css("visibility","visible"),l&&l.find('a[data-page="'+(k-1)+'"]').attr("aria-expanded","true").parent().addClass("active"))):f.data("pagenav")&&(b.preventDefault(),f.closest(".breadcrumb").find("li.active").removeClass("active").children().attr("aria-expanded","false"),a("#"+f.data("pagenav")+" .caldera-form-page").hide().attr("aria-hidden","true").css("visibility","hidden"),a("#"+f.data("pagenav")+'\t.caldera-form-page[data-formpage="'+f.data("page")+'"]').show().attr("aria-hidden","false").css("visibility","visible"),f.parent().addClass("active").children().attr("aria-expanded","true")),a("html, body").animate({scrollTop:h.offset().top-100},200),a(document).trigger("cf.pagenav")}});var b;a(".caldera-grid .breadcrumb").each(function(c,d){a(d).find("a[data-pagenav]").each(function(c,d){var e=a(d),f=e.data("pagenav");a("#"+f+' .caldera-form-page[data-formpage="'+e.data("page")+'"]').find(".has-error").length&&(e.parent().addClass("error"),void 0===b&&(e.trigger("click"),b=!0))})}),a(document).on("click",'form.caldera_forms_form [type="submit"]',function(b){var c=a(this),d=c.closest(".caldera_forms_form"),e=cf_validate_form(d);e.validate()?e.destroy():b.preventDefault()})}(jQuery),window.addEventListener("load",function(){!function(a){"use strict";if("object"==typeof CF_API_DATA){var b,c={};a(".caldera_forms_form").each(function(d,e){b=a(e).data("form-id"),c[b]=new CalderaFormsResetNonce(b,CF_API_DATA,a),c[b].init()})}if("object"==typeof CFFIELD_CONFIG){var d,e,f,g,h;a(".caldera_forms_form").each(function(b,c){h=a(c),d=h.attr("id"),g=h.data("instance"),"object"==typeof CFFIELD_CONFIG[g]&&(f=CFFIELD_CONFIG[g],e=new Caldera_Forms_Field_Config(f,a(document.getElementById(d)),a),e.init())})}}(jQuery)});
assets/build/js/caldera-modals.min.js CHANGED
@@ -1 +1 @@
1
- !function(a){var b=null,c={},d=[],e=[],f=a("html"),g=a("body"),h=a(window),i=function(){if(d.length||e.length){var a=d.length?d[d.length-1]:e[e.length-1],j=h.width(),k=h.height(),l=c[a].config.height,m=l,n=c[a].config.width,o=0,p=!1,q=!1;if(b&&f.addClass("has-caldera-modal"),o=(k-c[a].config.height)/2.2,o<0&&(o=0),l+2*c[a].config.padding>k&&b&&(l=k-2*c[a].config.padding,m="100%",b&&b.css({paddingTop:c[a].config.padding,paddingBottom:c[a].config.padding}),q=!0),n+2*c[a].config.padding>=j&&(n="100%",b&&b.css({paddingLeft:c[a].config.padding,paddingRight:c[a].config.padding}),q=!0),!0===q&&(j<=700&&j>600?(b&&(l=k-2*c[a].config.padding),n=j,m=l-2*c[a].config.padding,n="100%",o=0,b&&b.css({padding:c[a].config.padding})):j<=600&&(b&&(l=k),n=j,m="100%",o=0,b&&b.css({padding:0}))),b&&b.is(":hidden")&&(p=!0,b.show()),c[a].header&&(b&&b.show(),l-=c[a].header.outerHeight(),c[a].closer.css({padding:c[a].header.outerHeight()/2-.5}),c[a].title.css({paddingRight:c[a].closer.outerWidth()})),c[a].footer&&(b&&b.show(),l-=c[a].footer.outerHeight()),b&&p===!0&&(b.hide(),p=!1),l!=m&&c[a].body.css({height:l}),c[a].modal.css({width:n}),c[a].config.sticky&&c[a].config.minimized){var r={},s=c[a].title.outerHeight()-c[a].modal.outerHeight();c[a].config.sticky.indexOf("bottom")>-1?r["margin-bottom"]=s:c[a].config.sticky.indexOf("top")>-1&&(r["margin-top"]=s),c[a].modal.css(r),c[a].config.sticky.length>=3&&(g.css("margin-"+c[a].config.sticky[0],c[a].title.outerHeight()),q?c[a].modal.css(c[a].config.sticky[1],0):c[a].modal.css(c[a].config.sticky[1],parseFloat(c[a].config.sticky[2])))}return b&&(c[a].modal.css({marginTop:o,height:m}),setTimeout(function(){c[a].modal.addClass("caldera-animate")},10),b.fadeIn(c[a].config.speed)),c[a].resize=i,c}},j=function(e){var g=a(e).data("modal"),h=0,i={};if(e&&c[g].config.sticky)return c[g].config.minimized?(c[g].config.minimized=!1,h=0):(c[g].config.minimized=!0,h=c[g].title.outerHeight()-c[g].modal.outerHeight()),c[g].config.sticky.indexOf("bottom")>-1?i["margin-bottom"]=h:c[g].config.sticky.indexOf("top")>-1&&(i["margin-top"]=h),void c[g].modal.stop().animate(i,c[g].config.speed);var j;d.length&&(j=d.pop(),c[j].modal.hasClass("caldera-animate")&&!d.length?(c[j].modal.removeClass("caldera-animate"),setTimeout(function(){c[j].modal.remove(),delete c[j]},500)):b&&c[j].modal.hide(0,function(){a(this).remove(),delete c[j]})),d.length?c[d[d.length-1]].modal.show():(b&&b.fadeOut(250,function(){a(this).remove(),b=null}),f.removeClass("has-caldera-modal"))};a.calderaModal=function(f){var h=a.extend(!0,{element:"div",height:550,width:620,padding:12,speed:250},f);b||h.sticky||(b=a("<div>",{class:"caldera-backdrop"}),h.focus||b.on("click",function(a){a.target==this&&j()}),g.append(b),b.hide());var k=h.element,l=h.modal;if(d.length&&d[d.length-1]!==l&&c[d[d.length-1]].modal.hide(),"undefined"==typeof c[l]?(h.sticky&&(h.sticky=h.sticky.split(" "),h.sticky.length<2&&(h.sticky=null),e.push(l)),c[l]={config:h,modal:a("<"+k+">",{id:l+"_calderaModal",tabIndex:-1,"ariaLabelled-by":l+"_calderaModalLable",class:"caldera-modal-wrap"+(h.sticky?" caldera-sticky-modal "+h.sticky[0]+"-"+h.sticky[1]:"")})},h.sticky||d.push(l)):(c[l].config=h,c[l].modal.empty()),h.animate&&b){var m=h.animate.split(" "),n=h.speed+"ms",o=h.animateEase?h.animateEase:"ease";1===m.length&&(m[1]=0),c[l].modal.css({transform:"translate("+m[0]+", "+m[1]+")","-web-kit-transition":"transform "+n+" "+o,"-moz-transition":"transform "+n+" "+o,transition:"transform "+n+" "+o})}if(c[l].body=a("<div>",{class:"caldera-modal-body",id:l+"_calderaModalBody"}),c[l].content=a("<div>",{class:"caldera-modal-content",id:l+"_calderaModalContent"}),c[l].content.css({margin:h.padding}),c[l].body.append(c[l].content).appendTo(c[l].modal),b?b.append(c[l].modal):c[l].modal.appendTo(a("body")),h.footer)if(c[l].footer=a("<div>",{class:"caldera-modal-footer",id:l+"_calderaModalFooter"}),c[l].footer.css({padding:h.padding}),c[l].footer.appendTo(c[l].modal),"function"==typeof window[h.footer])c[l].footer.append(window[h.footer](f,this));else if("string"==typeof h.footer)try{var p=a(h.footer);c[l].footer.html(p.html())}catch(a){c[l].footer.html(h.footer)}if(h.title){var q="prependTo";c[l].header=a("<div>",{class:"caldera-modal-title",id:l+"_calderaModalTitle"}),c[l].closer=a("<a>",{href:"#close",class:"caldera-modal-closer","data-dismiss":"modal","aria-hidden":"true",id:l+"_calderaModalCloser"}).html("&times;"),c[l].title=a("<h3>",{class:"modal-label",id:l+"_calderaModalLable"}),c[l].title.html(h.title).appendTo(c[l].header),c[l].title.css({padding:h.padding}),c[l].title.append(c[l].closer),c[l].config.sticky?(c[l].config.minimized&&!0!==c[l].config.minimized&&(setTimeout(function(){c[l].title.trigger("click")},parseInt(c[l].config.minimized)),c[l].config.minimized=!1),c[l].closer.hide(),c[l].title.addClass("caldera-modal-closer").data("modal",l).appendTo(c[l].header),c[l].config.sticky.indexOf("top")>-1&&(q="appendTo")):c[l].closer.data("modal",l).appendTo(c[l].header),c[l].header[q](c[l].modal)}if(c[l].modal.outerHeight(h.height),c[l].modal.outerWidth(h.width),h.content)if("function"==typeof h.content)c[l].content.append(h.content(f,c[l],this));else if("function"==typeof window[h.content])c[l].content.append(window[h.content](f,c[l],this));else if("string"==typeof h.content)try{var r=a(h.content);r.length?(c[l].content.append(r.detach()),r.show()):c[l].content.html(h.content)}catch(a){c[l].content.html(h.content)}return i(),c[l]},a.fn.calderaModal=function(b){return b||(b={}),b=a.extend({},this.data(),b),a.calderaModal(b)},window.addEventListener?(window.addEventListener("resize",i,!1),window.addEventListener("keypress",function(a){27===a.keyCode&&null!==b&&b.trigger("click")},!1)):window.attachEvent?window.attachEvent("onresize",i):window.onresize=i,a(document).on("click","[data-modal]:not(.caldera-modal-closer)",function(b){b.preventDefault(),a(this).calderaModal()}),a(window).load(function(){a("[data-modal][data-autoload]").each(function(){a(this).calderaModal()})}),a(document).on("click",".caldera-modal-closer",function(a){a.preventDefault(),j(this)})}(jQuery);
1
+ !function(a){var b=null,c={},d=[],e=[],f=a("html"),g=a("body"),h=a(window),i=function(){if(d.length||e.length){var a=d.length?d[d.length-1]:e[e.length-1],j=h.width(),k=h.height(),l=c[a].config.height,m=l,n=c[a].config.width,o=0,p=!1,q=!1;if(b&&f.addClass("has-caldera-modal"),o=(k-c[a].config.height)/2.2,o<0&&(o=0),l+2*c[a].config.padding>k&&b&&(l=k-2*c[a].config.padding,m="100%",b&&b.css({paddingTop:c[a].config.padding,paddingBottom:c[a].config.padding}),q=!0),n+2*c[a].config.padding>=j&&(n="100%",b&&b.css({paddingLeft:c[a].config.padding,paddingRight:c[a].config.padding}),q=!0),!0===q&&(j<=700&&j>600?(b&&(l=k-2*c[a].config.padding),n=j,m=l-2*c[a].config.padding,n="100%",o=0,b&&b.css({padding:c[a].config.padding})):j<=600&&(b&&(l=k),n=j,m="100%",o=0,b&&b.css({padding:0}))),b&&b.is(":hidden")&&(p=!0,b.show()),c[a].header&&(b&&b.show(),l-=c[a].header.outerHeight(),c[a].closer.css({padding:c[a].header.outerHeight()/2-.5}),c[a].title.css({paddingRight:c[a].closer.outerWidth()})),c[a].footer&&(b&&b.show(),l-=c[a].footer.outerHeight()),b&&!0===p&&(b.hide(),p=!1),l!=m&&c[a].body.css({height:l}),c[a].modal.css({width:n}),c[a].config.sticky&&c[a].config.minimized){var r={},s=c[a].title.outerHeight()-c[a].modal.outerHeight();c[a].config.sticky.indexOf("bottom")>-1?r["margin-bottom"]=s:c[a].config.sticky.indexOf("top")>-1&&(r["margin-top"]=s),c[a].modal.css(r),c[a].config.sticky.length>=3&&(g.css("margin-"+c[a].config.sticky[0],c[a].title.outerHeight()),q?c[a].modal.css(c[a].config.sticky[1],0):c[a].modal.css(c[a].config.sticky[1],parseFloat(c[a].config.sticky[2])))}return b&&(c[a].modal.css({marginTop:o,height:m}),setTimeout(function(){c[a].modal.addClass("caldera-animate")},10),b.fadeIn(c[a].config.speed)),c[a].resize=i,c}},j=function(e){var g=a(e).data("modal"),h=0,i={};if(e&&c[g].config.sticky)return c[g].config.minimized?(c[g].config.minimized=!1,h=0):(c[g].config.minimized=!0,h=c[g].title.outerHeight()-c[g].modal.outerHeight()),c[g].config.sticky.indexOf("bottom")>-1?i["margin-bottom"]=h:c[g].config.sticky.indexOf("top")>-1&&(i["margin-top"]=h),void c[g].modal.stop().animate(i,c[g].config.speed);var j;d.length&&(j=d.pop(),c[j].modal.hasClass("caldera-animate")&&!d.length?(c[j].modal.removeClass("caldera-animate"),setTimeout(function(){c[j].modal.remove(),delete c[j]},500)):b&&c[j].modal.hide(0,function(){a(this).remove(),delete c[j]})),d.length?c[d[d.length-1]].modal.show():(b&&b.fadeOut(250,function(){a(this).remove(),b=null}),f.removeClass("has-caldera-modal"))};a.calderaModal=function(f){var h=a.extend(!0,{element:"div",height:550,width:620,padding:12,speed:250},f);b||h.sticky||(b=a("<div>",{class:"caldera-backdrop"}),h.focus||b.on("click",function(a){a.target==this&&j()}),g.append(b),b.hide());var k=h.element,l=h.modal;if(d.length&&d[d.length-1]!==l&&c[d[d.length-1]].modal.hide(),void 0===c[l]?(h.sticky&&(h.sticky=h.sticky.split(" "),h.sticky.length<2&&(h.sticky=null),e.push(l)),c[l]={config:h,modal:a("<"+k+">",{id:l+"_calderaModal",tabIndex:-1,"ariaLabelled-by":l+"_calderaModalLable",class:"caldera-modal-wrap"+(h.sticky?" caldera-sticky-modal "+h.sticky[0]+"-"+h.sticky[1]:"")})},h.sticky||d.push(l)):(c[l].config=h,c[l].modal.empty()),h.animate&&b){var m=h.animate.split(" "),n=h.speed+"ms",o=h.animateEase?h.animateEase:"ease";1===m.length&&(m[1]=0),c[l].modal.css({transform:"translate("+m[0]+", "+m[1]+")","-web-kit-transition":"transform "+n+" "+o,"-moz-transition":"transform "+n+" "+o,transition:"transform "+n+" "+o})}if(c[l].body=a("<div>",{class:"caldera-modal-body",id:l+"_calderaModalBody"}),c[l].content=a("<div>",{class:"caldera-modal-content",id:l+"_calderaModalContent"}),c[l].content.css({margin:h.padding}),c[l].body.append(c[l].content).appendTo(c[l].modal),b?b.append(c[l].modal):c[l].modal.appendTo(a("body")),h.footer)if(c[l].footer=a("<div>",{class:"caldera-modal-footer",id:l+"_calderaModalFooter"}),c[l].footer.css({padding:h.padding}),c[l].footer.appendTo(c[l].modal),"function"==typeof window[h.footer])c[l].footer.append(window[h.footer](f,this));else if("string"==typeof h.footer)try{var p=a(h.footer);c[l].footer.html(p.html())}catch(a){c[l].footer.html(h.footer)}if(h.title){var q="prependTo";c[l].header=a("<div>",{class:"caldera-modal-title",id:l+"_calderaModalTitle"}),c[l].closer=a("<a>",{href:"#close",class:"caldera-modal-closer","data-dismiss":"modal","aria-hidden":"true",id:l+"_calderaModalCloser"}).html("&times;"),c[l].title=a("<h3>",{class:"modal-label",id:l+"_calderaModalLable"}),c[l].title.html(h.title).appendTo(c[l].header),c[l].title.css({padding:h.padding}),c[l].title.append(c[l].closer),c[l].config.sticky?(c[l].config.minimized&&!0!==c[l].config.minimized&&(setTimeout(function(){c[l].title.trigger("click")},parseInt(c[l].config.minimized)),c[l].config.minimized=!1),c[l].closer.hide(),c[l].title.addClass("caldera-modal-closer").data("modal",l).appendTo(c[l].header),c[l].config.sticky.indexOf("top")>-1&&(q="appendTo")):c[l].closer.data("modal",l).appendTo(c[l].header),c[l].header[q](c[l].modal)}if(c[l].modal.outerHeight(h.height),c[l].modal.outerWidth(h.width),h.content)if("function"==typeof h.content)c[l].content.append(h.content(f,c[l],this));else if("function"==typeof window[h.content])c[l].content.append(window[h.content](f,c[l],this));else if("string"==typeof h.content)try{var r=a(h.content);r.length?(c[l].content.append(r.detach()),r.show()):c[l].content.html(h.content)}catch(a){c[l].content.html(h.content)}return i(),c[l]},a.fn.calderaModal=function(b){return b||(b={}),b=a.extend({},this.data(),b),a.calderaModal(b)},window.addEventListener?(window.addEventListener("resize",i,!1),window.addEventListener("keypress",function(a){27===a.keyCode&&null!==b&&b.trigger("click")},!1)):window.attachEvent?window.attachEvent("onresize",i):window.onresize=i,a(document).on("click","[data-modal]:not(.caldera-modal-closer)",function(b){b.preventDefault(),a(this).calderaModal()}),a(window).load(function(){a("[data-modal][data-autoload]").each(function(){a(this).calderaModal()})}),a(document).on("click",".caldera-modal-closer",function(a){a.preventDefault(),j(this)})}(jQuery);
assets/build/js/conditionals.min.js CHANGED
@@ -1 +1 @@
1
- var calders_forms_check_conditions,calders_forms_init_conditions;!function(a){Array.prototype.indexOf||(Array.prototype.indexOf=function(a){var b=this.length>>>0,c=Number(arguments[1])||0;for(c=c<0?Math.ceil(c):Math.floor(c),c<0&&(c+=b);c<b;c++)if(c in this&&this[c]===a)return c;return-1}),cf_debounce=function(a,b,c){var d;return function(){var e=this,f=arguments,g=function(){d=null,c||a.apply(e,f)},h=c&&!d;clearTimeout(d),d=setTimeout(g,b),h&&a.apply(e,f)}},calders_forms_check_conditions=function(b){if("undefined"!=typeof caldera_conditionals&&"undefined"!=typeof caldera_conditionals[b]){var c=a("#"+b);for(var d in caldera_conditionals[b]){var e=jQuery("#conditional_"+d);if(e.length){var f=caldera_conditionals[b][d].type,g=caldera_conditionals[b][d].group,h=[];for(var i in g){var j={},k=g[i];for(var l in k){var m=c.find('[data-field="'+k[l].field+'"]'),n=[],o="function"==typeof k[l].value?k[l].value():k[l].value;if("undefined"!=typeof k[l].selectors)for(var p in k[l].selectors){var q=new RegExp(p,"g");o=o.replace(q,a(k[l].selectors[p]).val())}if(j[l]=!1,m.is(":radio,:checkbox")?m=m.filter(":checked"):m.is("div")&&(m=jQuery("<input>").val(m.html())),m.length)for(var r=0;r<m.length;r++)n.push(m[r].value);else n.push(k[l].field);switch(k[l].compare){case"is":n.length&&n.indexOf(o.toString())>=0&&(j[l]=!0);break;case"isnot":n.length&&n.indexOf(o)<0&&(j[l]=!0);break;case">":case"greater":j[l]=parseFloat(n.reduce(function(a,b){return a+b}))>parseFloat(o);break;case"<":case"smaller":j[l]=parseFloat(n.reduce(function(a,b){return a+b}))<parseFloat(o);break;case"startswith":for(var r=0;r<n.length;r++)n[r].toLowerCase().substr(0,o.toLowerCase().length)===o.toLowerCase()&&(j[l]=!0);break;case"endswith":for(var r=0;r<n.length;r++)n[r].toLowerCase().substr(n[r].toLowerCase().length-o.toLowerCase().length)===o.toLowerCase()&&(j[l]=!0);break;case"contains":for(var r=0;r<n.length;r++)n[r].toLowerCase().indexOf(o)>=0&&(j[l]=!0)}}istrue=!0;for(var s in j)if(j[s]===!1){istrue=!1;break}h.push(istrue)}var t,u=jQuery("#conditional-"+d+"-tmpl").html(),v=jQuery("#conditional_"+d),w=jQuery('[data-field="'+d+'"]');h.length&&h.indexOf(!0)>=0?"show"===f?t="show":"hide"===f?t="hide":"disable"===f&&(t="disable"):t="show"===f?"hide":"disable"===f?"enable":"show","show"===t?v.html().length||(v.html(u).trigger("cf.add"),jQuery(document).trigger("cf.add")):"hide"===t?v.html().length&&(w.val("").empty().prop("checked",!1),v.empty().trigger("cf.remove"),jQuery(document).trigger("cf.remove")):"enable"===t?v.html().length?(w.prop("disabled",!1),jQuery("#"+d).prop("disabled",!1)):(v.html(u).trigger("cf.add"),jQuery(document).trigger("cf.add").trigger("cf.enable")):"disable"===t&&(v.html().length?(w.prop("disabled","disabled"),jQuery("#"+d).prop("disabled","disabled")):(v.html(u).trigger("cf.remove"),jQuery(document).trigger("cf.remove").trigger("cf.disable"),jQuery('[data-field="'+d+'"]').prop("disabled","disabled")))}}}},calders_forms_init_conditions=function(){jQuery(".caldera_forms_form").on("change keyup","[data-field]",cf_debounce(function(b){var c=a(this).closest(".caldera_forms_form").prop("id");calders_forms_check_conditions(c)},10))},"undefined"!=typeof caldera_conditionals&&(calders_forms_init_conditions(),jQuery(".caldera_forms_form").find("[data-field]").first().trigger("change"))}(jQuery);
1
+ var calders_forms_check_conditions,calders_forms_init_conditions;!function(a){var b={};Array.prototype.indexOf||(Array.prototype.indexOf=function(a){var b=this.length>>>0,c=Number(arguments[1])||0;for(c=c<0?Math.ceil(c):Math.floor(c),c<0&&(c+=b);c<b;c++)if(c in this&&this[c]===a)return c;return-1}),cf_debounce=function(a,b,c){var d;return function(){var e=this,f=arguments,g=function(){d=null,c||a.apply(e,f)},h=c&&!d;clearTimeout(d),d=setTimeout(g,b),h&&a.apply(e,f)}},calders_forms_check_conditions=function(c){function d(a){if(b[a])return b[a]}if("undefined"!=typeof caldera_conditionals&&void 0!==caldera_conditionals[c]){var e=a(document.getElementById(c));for(var f in caldera_conditionals[c]){if(jQuery("#conditional_"+f).length){var g=caldera_conditionals[c][f].type,h=caldera_conditionals[c][f].group,i=[];for(var j in h){var k={},l=h[j];for(var m in l){var n=e.find('[data-field="'+l[m].field+'"]'),o=[],p="function"==typeof l[m].value?l[m].value():l[m].value;if(void 0!==l[m].selectors)for(var q in l[m].selectors){var r=new RegExp(q,"g");p=p.replace(r,a(l[m].selectors[q]).val())}if(k[m]=!1,n.is(":radio,:checkbox")?n=n.filter(":checked"):n.is("div")&&(n=jQuery("<input>").val(n.html())),n.length)for(var s=0;s<n.length;s++)o.push(n[s].value);else o.push(l[m].field);switch(l[m].compare){case"is":o.length&&o.indexOf(p.toString())>=0&&(k[m]=!0);break;case"isnot":o.length&&o.indexOf(p)<0&&(k[m]=!0);break;case">":case"greater":k[m]=parseFloat(o.reduce(function(a,b){return a+b}))>parseFloat(p);break;case"<":case"smaller":k[m]=parseFloat(o.reduce(function(a,b){return a+b}))<parseFloat(p);break;case"startswith":for(var s=0;s<o.length;s++)o[s].toLowerCase().substr(0,p.toLowerCase().length)===p.toLowerCase()&&(k[m]=!0);break;case"endswith":for(var s=0;s<o.length;s++)o[s].toLowerCase().substr(o[s].toLowerCase().length-p.toLowerCase().length)===p.toLowerCase()&&(k[m]=!0);break;case"contains":for(var s=0;s<o.length;s++)o[s].toLowerCase().indexOf(p)>=0&&(k[m]=!0)}}istrue=!0;for(var t in k)if(!1===k[t]){istrue=!1;break}i.push(istrue)}var u,v=jQuery("#conditional-"+f+"-tmpl").html(),w=jQuery("#conditional_"+f),x=jQuery('[data-field="'+f+'"]');i.length&&i.indexOf(!0)>=0?"show"===g?u="show":"hide"===g?u="hide":"disable"===g&&(u="disable"):u="show"===g?"hide":"disable"===g?"enable":"show","show"===u?w.html().length||(w.html(v).trigger("cf.add"),jQuery(document).trigger("cf.add"),function(b){var c=d(b);if(void 0!=c)if("object"==typeof c)for(var e in c)!0===c[e]&&a(document.getElementById(e)).prop("checked",!0);else a("#"+b).val(c)}(f)):"hide"===u?w.html().length&&(!function(c){var d=a(document.getElementById(c));if(d.length){var e=d.val();e&&(b[c]=e)}else{var f;d=a("."+c),b[c]={},d.each(function(d,e){f=a(e),f.prop("checked")?b[c][f.attr("id")]=!0:b[c][f.attr("id")]=!1})}}(f),x.val("").empty().prop("checked",!1),w.empty().trigger("cf.remove"),jQuery(document).trigger("cf.remove")):"enable"===u?w.html().length?(x.prop("disabled",!1),$field.prop("disabled",!1)):(w.html(v).trigger("cf.add"),jQuery(document).trigger("cf.add").trigger("cf.enable")):"disable"===u&&(w.html().length?(x.prop("disabled","disabled"),$field.prop("disabled","disabled")):(w.html(v).trigger("cf.remove"),jQuery(document).trigger("cf.remove").trigger("cf.disable"),jQuery('[data-field="'+f+'"]').prop("disabled","disabled")))}}}},calders_forms_init_conditions=function(){jQuery(".caldera_forms_form").on("change keyup","[data-field]",cf_debounce(function(b){var c=a(this).closest(".caldera_forms_form").prop("id");calders_forms_check_conditions(c)},10))},"undefined"!=typeof caldera_conditionals&&(calders_forms_init_conditions(),jQuery(".caldera_forms_form").find("[data-field]").first().trigger("change"))}(jQuery);
assets/build/js/edit.min.js CHANGED
@@ -1,3 +1,3 @@
1
- function new_conditional_group(a){var b=a.trigger.data("id"),c="cl"+Math.round(18746582734*Math.random()),d="rw"+Math.round(98347598345*Math.random()),e=[{id:d,type:a.trigger.data("type"),lines:[{id:c}]}];return{group:e,id:b}}function new_conditional_line(a){var b=a.trigger.data("id"),c=a.trigger.data("group"),d=a.trigger.data("type"),e="cl"+Math.round(18746582734*Math.random()),f={id:b,type:d,lineid:e,rowid:c,name:"config["+d+"]["+b+"][conditions][group]["+c+"]["+e+"]"};return f}function build_conditions_config(a){var b=JSON.parse(a.trigger.val());return b.id=a.trigger.data("id"),b}function pre_compile_templates(){for(var a=jQuery(".cf-editor-template"),b=0;b<a.length;b++)compiled_templates[a[b].id]=Handlebars.compile(a[b].innerHTML)}function get_compiled_template(a){return"object"!=typeof compiled_templates&&pre_compile_templates(),compiled_templates[a+"_tmpl"]?compiled_templates[a+"_tmpl"]:compiled_templates.noconfig_field_templ}function setup_field_type(a){return{id:a.trigger.prop("id")}}function check_required_bindings(a){var b,c=(jQuery(".caldera-header-save-button"),jQuery(".layout-form-field")),d=jQuery(".caldera-processor-nav"),e=!0;b=a?jQuery(a):jQuery(".caldera-config-field .required"),b.removeClass("has-error"),c.removeClass("has-error"),d.removeClass("has-error"),jQuery(".error-tag").remove(),required_errors={},b.each(function(a,b){var c=jQuery(b),d=c.closest(".caldera-config-editor-panel");if(b.value.length){if(c.hasClass("field-slug"))for(var f=jQuery(".field-slug").not(c),g=0;g<f.length;g++)if(f[g].value===b.value){var c=jQuery(f[g]);required_errors[d.prop("id")]||(required_errors[d.prop("id")]=0);var h=c.closest(".caldera-editor-field-config-wrapper"),i=c.closest(".caldera-editor-processor-config-wrapper");h.length&&jQuery('.layout-form-field[data-config="'+h.prop("id")+'"]').addClass("has-error"),i.length&&jQuery("."+i.prop("id")).addClass("has-error"),required_errors[d.prop("id")]+=1,c.addClass("has-error"),e=!1;break}if(c.hasClass("toggle_value_field"))for(var j=c.closest(".caldera-config-group").find(".toggle_value_field").not(c),g=0;g<j.length;g++)if(j[g].value===b.value){var c=jQuery(j[g]);required_errors[d.prop("id")]||(required_errors[d.prop("id")]=0);var h=c.closest(".caldera-editor-field-config-wrapper"),i=c.closest(".caldera-editor-processor-config-wrapper");h.length&&jQuery('.layout-form-field[data-config="'+h.prop("id")+'"]').addClass("has-error"),i.length&&jQuery("."+i.prop("id")).addClass("has-error"),required_errors[d.prop("id")]+=1,c.addClass("has-error"),e=!1;break}}else{required_errors[d.prop("id")]||(required_errors[d.prop("id")]=0);var h=c.closest(".caldera-editor-field-config-wrapper"),i=c.closest(".caldera-editor-processor-config-wrapper");h.length&&jQuery('.layout-form-field[data-config="'+h.prop("id")+'"]').addClass("has-error"),i.length&&jQuery("."+i.prop("id")).addClass("has-error"),required_errors[d.prop("id")]+=1,c.addClass("has-error"),e=!1}});for(var f in required_errors)jQuery(".caldera-forms-options-form").find('a[href="#'+f+'"]').append('<span class="error-tag">'+required_errors[f]+"</span>");return jQuery(".caldera-conditional-field-set").trigger("change"),e}function new_conditional_group(a){var b=a.trigger.data("id"),c="cl"+Math.round(18746582734*Math.random()),d="rw"+Math.round(98347598345*Math.random()),e=[{id:d,type:a.trigger.data("type"),lines:[{id:c}]}];return{group:e,id:b}}function new_conditional_line(a){var b=a.trigger.data("id"),c=a.trigger.data("group"),d=a.trigger.data("type"),e="cl"+Math.round(18746582734*Math.random()),f={id:b,type:d,lineid:e,rowid:c,name:"config["+d+"]["+b+"][conditions][group]["+c+"]["+e+"]"};return f}function build_conditions_config(a){var b=JSON.parse(a.trigger.val());return b.id=a.trigger.data("id"),b}function setup_field_type(a){return{id:a.trigger.prop("id")}}function check_required_bindings(a){var b,c=(jQuery(".caldera-header-save-button"),jQuery(".layout-form-field")),d=jQuery(".caldera-processor-nav"),e=!0;b=a?jQuery(a):jQuery(".caldera-config-field .required"),b.removeClass("has-error"),c.removeClass("has-error"),d.removeClass("has-error"),jQuery(".error-tag").remove(),required_errors={},b.each(function(a,b){var c=jQuery(b),d=c.closest(".caldera-config-editor-panel");if(b.value.length){if(c.hasClass("field-slug"))for(var f=jQuery(".field-slug").not(c),g=0;g<f.length;g++)if(f[g].value===b.value){var c=jQuery(f[g]);required_errors[d.prop("id")]||(required_errors[d.prop("id")]=0);var h=c.closest(".caldera-editor-field-config-wrapper"),i=c.closest(".caldera-editor-processor-config-wrapper");h.length&&jQuery('.layout-form-field[data-config="'+h.prop("id")+'"]').addClass("has-error"),i.length&&jQuery("."+i.prop("id")).addClass("has-error"),required_errors[d.prop("id")]+=1,c.addClass("has-error"),e=!1;break}if(c.hasClass("toggle_value_field"))for(var j=c.closest(".caldera-config-group").find(".toggle_value_field").not(c),g=0;g<j.length;g++)if(j[g].value===b.value){var c=jQuery(j[g]);required_errors[d.prop("id")]||(required_errors[d.prop("id")]=0);var h=c.closest(".caldera-editor-field-config-wrapper"),i=c.closest(".caldera-editor-processor-config-wrapper");h.length&&jQuery('.layout-form-field[data-config="'+h.prop("id")+'"]').addClass("has-error"),i.length&&jQuery("."+i.prop("id")).addClass("has-error"),required_errors[d.prop("id")]+=1,c.addClass("has-error"),e=!1;break}}else{required_errors[d.prop("id")]||(required_errors[d.prop("id")]=0);var h=c.closest(".caldera-editor-field-config-wrapper"),i=c.closest(".caldera-editor-processor-config-wrapper");h.length&&jQuery('.layout-form-field[data-config="'+h.prop("id")+'"]').addClass("has-error"),i.length&&jQuery("."+i.prop("id")).addClass("has-error"),required_errors[d.prop("id")]+=1,c.addClass("has-error"),e=!1}});for(var f in required_errors)jQuery(".caldera-forms-options-form").find('a[href="#'+f+'"]').append('<span class="error-tag">'+required_errors[f]+"</span>");return jQuery(".caldera-conditional-field-set").trigger("change"),e}var cfAdminAJAX;cfAdminAJAX="object"==typeof CF_ADMIN?CF_ADMIN.adminAjax:ajaxurl,jQuery(document).ready(function(a){function b(b){var d=a(b),e=d.val(),f=d.closest(".caldera-editor-field-config-wrapper"),g=f.find(".caldera-config-field-setup"),h=get_compiled_template(e);if(config=f.find(".field_config_string").val(),current_type=d.data("type"),f.find(".caldera-config-group").show(),d.addClass("field-initialized"),config.length&&current_type===d.val()?config=JSON.parse(config):config=fieldtype_defaults[d.val()+"_cfg"],config||(config={}),config._id=d.data("field"),config._name="config[fields]["+d.data("field")+"][config]",h=a("<div>").html(h(config)),g.html(h.html()),"function"==typeof window[d.val()+"_init"]&&window[d.val()+"_init"](d.data("field"),g),fieldtype_defaults[d.val()+"_nosupport"]&&(fieldtype_defaults[d.val()+"_nosupport"].indexOf("hide_label")>=0&&f.find(".hide-label-field").hide().find(".field-config").prop("checked",!1),fieldtype_defaults[d.val()+"_nosupport"].indexOf("caption")>=0&&f.find(".caption-field").hide().find(".field-config").val(""),fieldtype_defaults[d.val()+"_nosupport"].indexOf("required")>=0&&f.find(".required-field").hide().find(".field-config").prop("checked",!1),fieldtype_defaults[d.val()+"_nosupport"].indexOf("custom_class")>=0&&f.find(".customclass-field").hide().find(".field-config").val(""),fieldtype_defaults[d.val()+"_nosupport"].indexOf("entry_list")>=0&&f.find(".entrylist-field").hide().find(".field-config").prop("checked",!1)),f.find(".toggle_show_values").trigger("change"),!a(".caldera-select-field-type").not(".field-initialized").length){if(core_form||(core_form=jQuery(".caldera-forms-options-form")),core_form.hasClass("builder-loaded"))c(d.data("field"));else{for(var i=a(".caldera-select-field-type.field-initialized"),j=0;j<i.length;j++)c(a(i[j]).data("field"));core_form.addClass("builder-loaded")}a(".caldera-header-save-button").prop("disabled",!1),rebuild_field_binding(),baldrickTriggers()}a(".color-field").length&&a(".color-field").wpColorPicker({change:function(b){var c=a(this);c.data("ev")&&clearTimeout(c.data("ev")),c.data("ev",setTimeout(function(){c.trigger("record")},200)),c.data("target")&&(a(c.data("target")).css(c.data("style"),c.val()),a(c.data("target")).val(c.val()))}})}function c(b){var c=a("#"+b),d=c.find(".caldera-select-field-type"),e=d.val(),f=a('.layout-form-field[data-config="'+b+'"]'),g=f.find(".field_preview"),h=(a("#preview-"+e+"_tmpl").html(),get_compiled_template("preview-"+e)),i={id:b},j=c.find(".field-config");j.each(function(c,d){for(var e=a(d),f=e.prop("name").split("["+b+"]")[1].substr(1),g=f.substr(0,f.length-1).split("]["),h=e.is(":checkbox,:radio")?e.filter(":checked").val():e.val(),j={},k=g.length-1;k>=0;k--)if(k===g.length-1)j[g[k]]=h;else{var l=j;j={},j[g[k]]=l}a.extend(!0,i,j)}),g.html(h(i)),f.removeClass("button"),a(".preview-field-config").prop("disabled",!0)}function d(b){var c,d=a(".caldera-editor-fields-panel"),e=(a(".caldera-editor-groups-panel"),a(".caldera-group-nav")),f=a('[data-group="'+b+'"]'),g=f.find(".caldera-config-group-name"),h=f.find(".caldera-config-group-slug"),i=f.find(".caldera-config-group-desc"),j=f.find(".caldera-config-group-admin"),k=a(".active-group-name"),l=a(".active-group-slug"),m=a(".active-group-desc"),n=a(".active-group-admin"),o=a(".caldera-editor-fields-list ul"),p=f.find(".caldera-config-group-repeat"),q=a(".repeat-config-button"),r=(a(".caldera-editor-group-settings"),a(".caldera-config-group-remove"));a(".new-group-input").remove(),a(".new-field-input").remove(),e.removeClass("active"),d.show(),o.hide(),o.removeClass("active").find("li.active").removeClass("active"),o.hide(),f.addClass("active"),c=a(".caldera-editor-fields-list ul.active li"),c.length?r.hide():r.show(),a(".caldera-editor-field-config-wrapper").hide(),f.show(),k.val(g.val()),l.val(h.val()),m.val(i.val()),"1"===j.val()?n.prop("checked",!0):n.prop("checked",!1),"1"===p.val()?q.addClass("field-edit-open"):q.removeClass("field-edit-open")}a(".caldera-header-save-button").baldrick({method:"POST",request:"admin.php?page=caldera-forms",before:function(b,c){if(c.preventDefault(),!check_required_bindings())return!1;a("#save_indicator").addClass("loading"),"undefined"!=typeof tinyMCE&&tinyMCE.triggerSave();var d=a(".caldera-forms-options-form").formJSON();return d.conditions&&(d.config.conditional_groups={conditions:d.conditions}),a(b).data("cf_edit_nonce",d.cf_edit_nonce),a(b).data("_wp_http_referer",d._wp_http_referer),a(b).data("sender","ajax"),a(b).data("config",JSON.stringify(d.config)),!0},callback:function(b){if(!1===b.data){var c=a(".updated_notice_box");c.stop().animate({top:0},200,function(){setTimeout(function(){c.stop().animate({top:-75},200)},2e3)})}},complete:function(b){a(".wrapper-instance-pane .field-config").prop("disabled",!1)}}),a("body").on("click",".toggle_processor_event input",function(b){var c=a(this),d=c.closest(".wrapper-instance-pane"),e=d.find(".caldera-config-processor-setup"),f=d.find(".caldera-config-processor-notice");c.is(":checked")?(c.parent().addClass("activated"),c.parent().find(".is_active").show().attr("aria-hidden",!1).css("visibility","visible"),c.parent().find(".not_active").hide().attr("aria-hidden",!0).css("visibility","hidden")):(c.parent().removeClass("activated"),c.parent().find(".is_active").hide().attr("aria-hidden",!0).css("visibility","hidden"),c.parent().find(".not_active").show().attr("aria-hidden",!1).css("visibility","visible")),d.find(".toggle_processor_event .activated").length?(e.slideDown(100),f.slideUp(100)):(e.slideUp(100),f.slideDown(100))}),a("body").on("click",".toggle_option_tab > a",function(b){b.preventDefault();var c=a(this),d=a(c.attr("href")),e=c.parent().find("a"),f=c.closest(".caldera-editor-config-wrapper").find(".wrapper-instance-pane");e.removeClass("button-primary"),f.hide(),d.show(),c.addClass("button-primary"),a(".caldera-conditionals-usetype").trigger("change")}),a(".caldera-editor-body").on("change",".caldera-select-field-type",function(a){b(this)}),a(".caldera-editor-body").on("click",".caldera-group-nav a",function(b){b.preventDefault(),d(a(this).attr("href").substr(1))}),a(".caldera-editor-body").on("click",".caldera-editor-fields-list a",function(b){b.preventDefault();var c=a(this),d=a(c.attr("href"));a(".new-group-input").remove(),a(".new-field-input").remove(),a(".caldera-editor-fields-list li.active").removeClass("active"),c.parent().addClass("active"),a(".caldera-editor-field-config-wrapper").hide(),d.show()}),a(".caldera-editor-body").on("click",".group-config-button",function(b){var c=a(this),d=a(".caldera-editor-group-settings"),e=c.closest(".caldera-editor-fields-panel"),f=a(".caldera-config-group-remove");e.find(".caldera-field-line").length?f.hide():f.show(),c.hasClass("field-edit-open")?(d.slideUp(100),c.removeClass("field-edit-open")):(d.slideDown(100),c.addClass("field-edit-open"))}),a(".caldera-editor-body").on("keydown",".field-config",function(b){a(this).is("textarea")||13===b.which&&b.preventDefault()}),a(".caldera-editor-body").on("change",".field-label",function(b){var c=a(this).closest(".caldera-editor-field-config-wrapper").prop("id");field_line=a('[data-field="'+c+'"]'),field_title=a("#"+c+" .caldera-editor-field-title, .layout-form-field.field-edit-open .layout_field_name"),slug=a("#"+c+" .field-slug"),field_line.find("a").html('<i class="icn-field"></i> '+this.value),field_title.text(this.value),"change"===b.type&&slug.trigger("change"),rebuild_field_binding()}),a(".caldera-editor-body").on("change",".active-group-name",function(b){b.preventDefault();var c=a(".caldera-group-nav.active"),d=(c.data("group"),c.find(".caldera-config-group-name")),e=c.find("span");"focusout"!==b.type||this.value.length||(this.value="Group "+(parseInt(c.index())+1)),d.val(this.value),e.text(this.value)}),a(".caldera-editor-body").on("change",".active-group-slug",function(b){b.preventDefault();var c=a(".caldera-group-nav.active"),d=(c.data("group"),c.find(".caldera-config-group-name").val()),e=c.find(".caldera-config-group-slug"),f=(c.find("span"),this.value.split(" ").join("_").split("-").join("_").replace(/[^a-z0-9_]/gi,"").toLowerCase());"focusout"!==b.type||this.value.length||(f=d.split(" ").join("_").split("-").join("_").replace(/[^a-z0-9_]/gi,"").toLowerCase()),e.val(f),this.value=f}),a(".caldera-editor-body").on("change",".active-group-desc",function(b){b.preventDefault();var c=a(".caldera-group-nav.active"),d=(c.data("group"),c.find(".caldera-config-group-desc"));d.val(this.value)}),a(".caldera-editor-body").on("change",".active-group-admin",function(b){b.preventDefault();var c=a(".caldera-group-nav.active"),d=(c.data("group"),c.find(".caldera-config-group-name").val(),c.find(".caldera-config-group-admin"));c.find("span"),this.value.split(" ").join("_").split("-").join("_").replace(/[^a-z0-9_]/gi,"").toLowerCase();a(this).prop("checked")?(d.val(1),c.addClass("is-admin")):(d.val(0),c.removeClass("is-admin"))}),a(".caldera-editor-body").on("click",".repeat-config-button",function(b){b.preventDefault();var c=a(".caldera-group-nav.active"),d=(c.data("group"),c.find("a .group-type")),e=c.find(".caldera-config-group-repeat"),f=a(this);f.hasClass("field-edit-open")?(e.val("0"),d.removeClass("icn-repeat").addClass("icn-folder"),f.removeClass("field-edit-open")):(e.val("1"),d.addClass("icn-repeat").removeClass("icn-folder"),f.addClass("field-edit-open"))}),a(".caldera-editor-body").on("click",".delete-field",function(){var b=a(this),c=b.closest(".caldera-editor-field-config-wrapper").prop("id");confirm(b.data("confirm"))&&(a("#"+c).remove(),a('option[value="'+c+'"]').remove(),a('[data-bind="'+c+'"]').remove(),delete current_form_fields[c],a('[data-config="'+c+'"]').slideUp(200,function(){var b=a(this);b.remove(),rebuild_field_binding(),a(document).trigger("field.removed")}))}),a(".caldera-editor-body").on("click",".add-new-group,.add-field",function(){var b=a(this);if(a(".new-group-input").remove(),a(".new-field-input").remove(),b.hasClass("add-field")){var c=a('<input type="text" class="new-field-input block-input">');c.appendTo(a(".caldera-editor-fields-list ul.active")).focus()}else{var d=a('<input type="text" class="new-group-input block-input">');d.appendTo(a(".caldera-editor-groups-panel")).focus()}}),a(".caldera-editor-body").on("change keypress",".new-group-input",function(b){if("keypress"===b.type){if(13!==b.which)return;b.preventDefault()}var c,e,f=this.value,g=a(this),h=a(".caldera-editor-groups-panel ul"),i=a(".caldera-editor-fields-list");if(f.length){c=Handlebars.compile(a("#caldera_group_line_templ").html()),e={id:f.split(" ").join("_").split("-").join("_").replace(/[^a-z0-9_]/gi,"").toLowerCase(),name:f},h.append(c(e));var j=a('<ul data-group="'+e.id+'">').hide();j.appendTo(i),g.remove(),d(e.id)}else g.remove()}),a(".caldera-editor-body").on("change keypress",".new-field-input",function(b){if("keypress"===b.type){if(13!==b.which)return;b.preventDefault()}var c,d,e,f=this.value,g=a(this),h=g.parent(),i=a(".caldera-editor-field-config"),j=a(".caldera-config-group-remove");if(f.length){j.hide(),c=Handlebars.compile(a("#caldera_field_line_templ").html()),d=Handlebars.compile(a("#caldera_field_config_wrapper_templ").html()),e={id:f.split(" ").join("_").split("-").join("_").replace(/[^a-z0-9_]/gi,"").toLowerCase(),label:f,slug:f.split(" ").join("_").split("-").join("_").replace(/[^a-z0-9_]/gi,"").toLowerCase(),group:a(".caldera-group-nav.active").data("group")};var k=a(c(e));k.appendTo(h),i.append(d(e)),k.find("a").trigger("click"),g.remove()}else g.remove()}),a(".caldera-editor-body").on("change",".field-slug",function(b){this.value.length?this.value=this.value.split(" ").join("_").split("-").join("_").replace(/[^a-z0-9_]/gi,"").toLowerCase():"change"===b.type&&(this.value=a(this).closest(".caldera-editor-field-config-wrapper").find(".field-label").val().split(" ").join("_").split("-").join("_").replace(/[^a-z0-9_]/gi,"").toLowerCase())}),a(".caldera-editor-body").on("click",".caldera-add-group",function(b){var c=a(this),d=c.data("group"),e=a("#"+d+"_panel_tmpl").html();c.parent().parent().append(e)}),a(".caldera-editor-body").on("click",".caldera-config-group-remove",function(b){var c=a(".active-group-slug").val();a('[data-group="'+c+'"]').hide(0,function(){a(this).remove();var b=a(".caldera-group-nav");b.length?b.first().find("a").trigger("click"):a(".caldera-editor-fields-panel").hide()})}),a("body").on("click",".set-current-field",function(b){b.preventDefault();var c=a(this);a("#"+c.data("field")+"_type").val(c.data("type")).trigger("change"),a("#"+c.data("field")+"_lable").focus(),a("#field_setup_baldrickModalCloser").trigger("click")}),a(".caldera-editor-body").on("change record",".field-config",function(b){var d=a(this),e=d.closest(".caldera-editor-field-config-wrapper");current_form_fields&&(d.prop("id")===e.prop("id")+"_lable"&&(current_form_fields[e.prop("id")].label=this.value),d.prop("id")===e.prop("id")+"_slug"&&(current_form_fields[e.prop("id")].slug=this.value),d.prop("id")===e.prop("id")+"_type"&&(current_form_fields[e.prop("id")].type=this.value),e.length&&c(e.prop("id")))}),a(".caldera-editor-body").on("focus",".caldera-field-bind",function(b){var c=a(this),d=this.value;if(b.type&&"focusin"===b.type)return c.removeClass("bound_field").addClass("reload-binding"),rebind_field_bindings(),void(this.value=d)}),a(".caldera-editor-body").on("change",".caldera-conditional-field-set",function(b){var c,d,e=a(this),f=e.parent().find(".compare-type"),g=e.data("condition"),h=e.data("id"),i="config["+g+"]["+h+"][conditions][group]["+e.data("row")+"]["+e.data("line")+"]",j=e.data("line"),k=a("#"+j+"_value"),l=k.find(".caldera-conditional-value-field").first(),m=[],n=this.value;if("{"!==n.substr(0,1)&&(c=a("#"+n),d=c.find(".field-button-type"),m=c.find(".caldera-config-group-toggle-options")),e.hasClass(".bind_init")&&e.addClass("bound_triggered"),l.length&&l.val().length&&k.data("value",l.val()),f.show(),m.length){var o=m.find(".toggle_option_row"),p='<select name="'+i+'[value]" class="caldera-processor-value-bind caldera-conditional-value-field" data-field="'+n+'" style="max-width: 220px; width: 220px;">';p+='<option value=""></option>',o.each(function(b,c){var d=a(c).find(".toggle_label_field"),e=d.data("option"),f="";k.data("value")&&(k.data("value").toString()!==e&&k.data("value").toString()!==a(c).find(".toggle_value_field").val()||(f=' selected="selected"')),p+='<option value="'+e+'"'+f+">"+d.val()+"</option>"}),p+="</select>"}else d&&"button"==d.val()?(f.val("is").hide(),p='<select name="'+i+'[value]" class="caldera-processor-value-bind caldera-conditional-value-field" data-field="'+n+'" style="max-width: 220px; width: 220px;">',p+='<option value="click" '+("click"===k.data("value")?'selected="selected"':"")+">Click</option>",p+='<option value="dblclick" '+("dblclick"===k.data("value")?'selected="selected"':"")+">Double Click</option>",p+="</select>"):p='<input name="'+i+'[value]" type="text" class="caldera-conditional-value-field magic-tag-enabled" value="'+(k.data("value")?k.data("value"):"")+'" style="max-width: 205px;">';k.html(p),init_magic_tags()}),a(".caldera-editor-body").on("change",".caldera-conditionals-usetype",function(b){var c=a(this);"show"===this.value||"hide"===this.value||"disable"===this.value||"use"===this.value||"not"===this.value?(a("#"+c.data("id")+"_condition_group_add").show(),a("#"+c.data("id")+"_conditional_wrap").show()):(a("#"+c.data("id")+"_condition_group_add").hide(),a("#"+c.data("id")+"_conditional_wrap").hide())}),a(".caldera-editor-body").on("click",".remove-conditional-line",function(b){b.preventDefault();var c=a(this),d=c.closest(".caldera-condition-line"),e=c.closest(".caldera-condition-group");d.remove(),e.find(".caldera-condition-line").length||e.remove()}),a(".caldera-group-nav").first().find("a").trigger("click"),a(".caldera-editor-body").on("change",".toggle_show_values",function(b){var c=a(this),d=c.closest(".caldera-config-group-toggle-options");values=d.find(".toggle_value_field"),lables=d.find(".toggle_label_field"),field_lables=d.find(".caldera-config-group-option-labels"),c.prop("checked")?(values.show().parent().show(),values.show().parent().parent().show(),lables.css("width",""),field_lables.show()):(values.hide().parent().hide(),lables.css("width",245),field_lables.hide()),lables.trigger("toggle.values"),init_magic_tags()}),a(".caldera-editor-body").on("change",".auto-populate-type",function(){a(this).closest(".wrapper-instance-pane").find(".auto-populate-options").trigger("change")}),a(".caldera-editor-body").on("change",".auto-populate-options",function(){var b=a(this),c=b.closest(".wrapper-instance-pane"),d=c.find(".caldera-config-group-toggle-options"),e=c.find(".caldera-config-group-auto-options"),f=e.find(".auto-populate-type");e.find(".auto-populate-type-panel").hide(),b.prop("checked")?(d.hide(),e.show()):(d.show(),e.hide()),e.find(".caldera-config-group-auto-"+f.val()).show()}),a("body").on("change",".pin-toggle-roles",function(){var b=a(this),c=a("#caldera-pin-rules");"1"===b.val()?c.show():c.hide()}),a("body").on("click",".magic-tag-init",function(b){var c=a(this),d=c.prev();d.focus().trigger("init.magic")}),a("body").on("keyup focus select click init.magic",".magic-tag-enabled",function(b){init_magic_tags();var c=a(this),d=c.parent(),e=d.closest(".wrapper-instance-pane").find(".caldera-select-field-type").val()?d.closest(".wrapper-instance-pane").find(".caldera-select-field-type").val():"hidden",f=d.find(".magic-tags-autocomplete"),g=f.find("ul"),h=this.value,i=[],j="",k=this.selectionStart,l=this.selectionEnd;if(f.length&&f.data("focus"))return void b.preventDefault();if(c.data("tag",""),this.selectionEnd>this.selectionStart)j=this.value.substr(this.selectionStart,this.selectionEnd-this.selectionStart);else if(("select"===b.type||"keyup"===b.type)&&40!==b.which&&38!==b.which&&39!==b.which&&37!==b.which){for(k=this.selectionStart;k>0;k--){var m=h.substr(k-1,1);if(" "===m||"\n"===m||("%"===m||"}"===m)&&this.selectionStart===k)break}for(l=this.selectionStart;l<h.length;l++){var m=h.substr(l,1);if(" "===m||"\n"===m||("%"===m||"{"===m)&&this.selectionStart===l)break}j=h.substr(k,l-k)}if("focusout"!==b.type){"init"!==b.type&&j.length<3&&f.length&&f.remove(),f.length||(f=a('<div class="magic-tags-autocomplete"></div>'),g=a("<ul></ul>"),g.appendTo(f),f.insertAfter(c),f.on("mouseenter",function(){a(this).data("focus",!0)}),f.on("mouseleave",function(){a(this).data("focus",!1),setTimeout(function(){f.remove()},200),c.is(":focus")||c.trigger("focusout")})),g.empty();var n="system",o=!1;"hidden"===e||"dropdown"===e||"radio"===e||"toggle_switch"===e||"checkbox"===e?(o=!0,e="text",n="all"):"paragraph"!==e&&"html"!==e||(e="text"),c.data("type")&&(e=c.data("type")),e=e.split(","),e.push("vars");for(var p=0;p<e.length;p++)for(var q in system_values)if("undefined"!=typeof system_values[q].tags&&"undefined"!=typeof system_values[q].tags[e[p]]){if(i=[q],"system"!==q&&"variable"!==q&&"field"!==q){var r=jQuery(".processor-"+q),s=c.closest(".caldera-editor-processor-config-wrapper"),t=s.prop("id");i=[];for(var u=0;u<r.length;u++)if(s.length||o!==!0){if(t===r[u].id)continue;jQuery("li."+r[u].id).index()<jQuery("li."+t).index()&&i.push(r[u].id)}else i.push(r[u].id)}for(var v=0;v<i.length;v++)if("all"===n||n===q||"variable"===q){var w=a('<li class="header">'+system_values[q].type+(v>0?" ["+(v+1)+"]":"")+"</li>"),x=0;w.appendTo(g);for(var y=0;y<system_values[q].tags[e[p]].length;y++)if(!c.data("parent")||"variable:"+c.data("parent")!==system_values[q].tags[e[p]][y]){var z=system_values[q].wrap[0]+system_values[q].tags[e[p]][y]+system_values[q].wrap[1];if(i[v]!==q&&i.length>1&&(z=system_values[q].wrap[0]+system_values[q].tags[e[p]][y]+":"+i[v]+system_values[q].wrap[1]),z.indexOf(j)>=0||"init"===b.type){x+=1;var A=z.replace(j,"<strong>"+j+"</strong>"),B=a('<li class="tag" data-tag="'+z+'">'+A+"</li>");B.on("click",function(){var b=a(this).data("tag");c.val(h.substr(0,k)+b+h.substr(l)).trigger("change").focus(),c[0].selectionStart=k+b.length-(b.indexOf("*")>0?2:0),c[0].selectionEnd=k+b.length-(b.indexOf("*")>0?1:0),l=k=c[0].selectionEnd,h+=b,c.trigger("init.magic")}),B.appendTo(g)}}0===x&&w.remove()}}}g.children().length||f.remove(),"focusout"===b.type&&setTimeout(function(){f.remove()},200)}),pre_compile_templates(),a(".caldera-select-field-type").not(".field-initialized").each(function(a,c){b(c)})});var rebuild_field_binding,rebind_field_bindings,current_form_fields={},required_errors={},add_new_grid_page,add_page_grid,init_magic_tags,core_form,compiled_templates={};init_magic_tags=function(){var a=jQuery(".magic-tag-enabled");a.each(function(a,b){var c=jQuery(b);if(c.hasClass("magic-tag-init-bound")){var d=c.parent().find(".magic-tag-init");return void(c.is(":visible")?d.show():d.hide())}var e=jQuery('<span class=""></span>'),f=jQuery('<span style="position:relative;display:inline-block; width:100%;"></span>');c.is("input")&&e.css("borderBottom","none"),c.hasClass("caldera-conditional-value-field")&&f.width("auto"),c.wrap(f),e.insertAfter(c),c.addClass("magic-tag-init-bound"),c.is(":visible")?e.show():e.hide()})},rebuild_field_binding=function(){if(core_form||(core_form=jQuery(".caldera-forms-options-form")),core_form.hasClass("builder-loaded")){var a=jQuery(".caldera-editor-field-config-wrapper");system_values.field={tags:{text:[]},type:"Fields",wrap:["%","%"]};for(var b=0;b<a.length;b++){var c=a[b].id,d=jQuery("#"+c+"_lable").val(),e=jQuery("#"+c+"_slug").val(),f=jQuery("#"+c+"_type").val();"undefined"==typeof system_values.field.tags[f]&&(system_values.field.tags[f]=[]),system_values.field.tags[f].push(e),"text"!==f&&system_values.field.tags.text.push(e),current_form_fields[c]={label:d,slug:e,type:f},jQuery("option.bound-field").trigger("change").each(function(a,b){var c=jQuery(b);0!==c.prop("value").indexOf("{")?c.text(jQuery("#"+c.prop("value")+"_lable").val()+" ["+jQuery("#"+c.prop("value")+"_lable").val()+"]"):c.text(c.prop("value").replace("{","").replace("}",""))}).removeClass("bound-field")}}},rebind_field_bindings=function(){var a,b,c=jQuery(".caldera-field-bind").not(".bound_field");if(c.length){c.addClass("bound_field");for(var d=0;d<c.length;d++){var e=jQuery(c[d]),f=e.val(),g=e.data("default"),h=e.data("exclude"),i=0,j=e.closest(".caldera-editor-processor-config-wrapper"),k=j.prop("id"),l="";if(g&&!e.hasClass("reload-binding")&&(f=g),e.is("select")){e.empty();var m=jQuery('<optgroup label="Fields">');for(var n in current_form_fields)e.data("type")&&e.data("type").split(",").indexOf(current_form_fields[n].type)<0||(e.data("id")!==n&&m.append('<option value="'+n+'"'+(f===n?'selected="selected"':"")+">"+current_form_fields[n].label+" ["+current_form_fields[n].slug+"]</option>"),i+=1);m.appendTo(e),0===i&&e.empty();for(var o in system_values)if(a=[],!(h&&h.split(",").indexOf(o)>=0)){if("system"!==o&&"variable"!==o)for(var p=jQuery(".processor-"+o),q=0;q<p.length;q++)k!==p[q].id&&(a.push(p[q].id),p.length>1&&(b=jQuery("li."+p[q].id+" .processor-line-number"))&&b.html("["+(q+1)+"]"));else a.push("__system__");var r=[];e.data("type")?(r=e.data("type").split(","),r.push("vars")):r=["text","vars"];for(var s=0;s<r.length;s++)if(system_values[o].tags&&system_values[o].tags[r[s]])for(var t=0;t<a.length;t++){jQuery("li."+a[t]).index()>jQuery("li."+k).index()&&"__system__"!==a[t]?e.closest(".caldera-editor-processors-panel-wrap").length&&(l=' disabled="disabled"'):l="";for(var m=jQuery('<optgroup label="'+system_values[o].type+("__system__"!==a[t]?" "+jQuery("li."+a[t]).find(".processor-line-number").html():"")+'"'+l+">"),u=0;u<system_values[o].tags[r[s]].length;u++){var v=system_values[o].tags[r[s]][u];"__system__"!==a[t]&&(v=v.replace(o,a[t])),m.append('<option value="{'+v+'}"'+(f==="{"+v+"}"?'selected="selected"':"")+l+">"+system_values[o].tags[r[s]][u]+"</option>"),i+=1}m.children().length&&m.appendTo(e)}}if(0===i){if(e.empty(),e.data("type")){e.append('<option value="">No '+e.data("type").split(",").join(" or ")+" in form</option>");var w=!0}}else e.prop("disabled",!1);e.hasClass("required")||"undefined"!=typeof w||e.prepend('<option value=""></option>'),e.val(f)}}init_magic_tags(),jQuery(document).trigger("bound.fields"),jQuery(".caldera-header-save-button").prop("disabled",!1)}},jQuery(document).ready(function(a){function b(){var b=a(".layout-grid-panel"),c=0;b.each(function(b,d){var e=a(d),f=e.find(".layout-structure"),g=e.find(".row"),h=[];g.each(function(b,d){var e=a(d),f=e.children().not(".column-merge"),g=[];c+=1,f.each(function(b,d){span=a(d).attr("class").split("-"),g.push(span[2]);var e=a(d).find(".field-location");e.length&&e.each(function(d,e){var f=a(e);f.val(c+":"+(b+1)).removeAttr("disabled")})}),h.push(g.join(":"))}),f.val(h.join("|"))})}function c(b,c,e){var f,g,h="fld_"+Math.round(1e7*Math.random()),i=h,j=a("#field_config_panels");b.prop("id","").prop("title",""),f=Handlebars.compile(a("#caldera_field_config_wrapper_templ").html()),g=a.extend({},{id:i,label:"",slug:""},e),g.slug="",j.append(f(g)),b.removeClass("button-small").removeClass("button").removeClass("button-primary").removeClass("ui-draggable").removeClass("layout-new-form-field").addClass("layout-form-field").attr("data-config",h).css({display:"",opacity:""}),b.find(".layout_field_name").remove(),b.find(".field-location").prop("name","config[layout_grid][fields]["+h+"]"),b.find(".settings-panel").show(),b.appendTo(c),d(),b.find(".icon-edit").trigger("click"),a("#"+h+"_lable").focus().select(),baldrickTriggers(),a(document).trigger("field.added"),e?a("#"+i+"_type").data("type",g.type).trigger("change"):a("#"+h).trigger("field.drop"),rebuild_field_binding()}function d(){a(".toggle-options").sortable({handle:".dashicons-sort"}),a("#grid-pages-panel").sortable({placeholder:"row-drop-helper",handle:".sort-handle",items:".first-row-level",axis:"y",stop:function(){b()}}),a(".layout-column").sortable({connectWith:".layout-column",appendTo:"#grid-pages-panel",helper:"clone",items:".layout-form-field",handle:".drag-handle",cursor:"move",
2
- opacity:.7,cursorAt:{left:100,top:15},start:function(a,b){b.helper.css({width:"200px",height:"35px",paddingTop:"20px"})},stop:function(a,c){c.item.removeAttr("style"),b()}}),a("h3 .layout-new-form-field").draggable({helper:"clone",appendTo:"body"}),a(".page-toggle.button").droppable({accept:".layout-form-field",over:function(b,c){a(this).trigger("click"),a(".layout-column").sortable("refresh")}}),a(".layout-column").droppable({greedy:!0,activeClass:"ui-state-dropper",hoverClass:"ui-state-hoverable",accept:".layout-new-form-field",drop:function(b,d){var e=d.draggable.clone(),f=a(this);c(e,f)}}),b()}function e(){if(h){var b=a(".column-fieldinsert");b.length?(b.stop().fadeToggle(700),a(".layout-new-form-field").stop().fadeToggle(700)):cf_clear_puler()}}function f(){a(".caldera-editor-processors-panel ul").sortable({update:function(){rebuild_field_binding()}})}function g(b){var c=a(b),d=a("#"+c.val()+"-tmpl").length?a("#"+c.val()+"-tmpl").html():"",e=c.closest(".caldera-editor-processor-config-wrapper"),f=e.find(".caldera-config-processor-setup"),g=Handlebars.compile(d),h=e.find(".processor_config_string").val(),i=c.data("type");h=h.length&&i===c.val()?JSON.parse(h):processor_defaults[c.val()+"_cfg"],h||(h={}),h._id=e.prop("id"),h._name="config[processors]["+e.prop("id")+"][config]",g=a("<div>").html(g(h)),f.html(g.html()),"function"==typeof window[c.val()+"_init"]&&window[c.val()+"_init"](e.prop("id"),f),e.find(".no-conditions").length&&e.find(".toggle_option_tab").remove(),rebuild_field_binding(),baldrickTriggers(),a(".wp-baldrick").baldrick({request:cfAdminAJAX,method:"POST",before:function(b){var c=a(b);c.data("addNode")&&!c.data("request")&&c.data("request","cf_get_default_setting")}})}add_new_grid_page=function(a){return{page_no:"pg_"+Math.round(1e7*Math.random())}},add_page_grid=function(b){var c=a(".page-toggle").length+1,e=a('<button type="button" data-name="Page '+c+'" data-page="'+b.rawData.page_no+'" class="page-toggle button">'+b.params.trigger.data("addtitle")+" "+c+"</button> "),f=a("#page-toggles");e.appendTo(f),f.show(),d(),e.trigger("click"),1===c&&f.hide(),a(document).trigger("add.page")},a(document).on("remove.page add.page load.page",function(b){var c=a(".page-toggle").length,d=a("#tab_pages");c<=1?d.hide():d.show()}),d(),a("#grid-pages-panel").on("click",".column-fieldinsert .dashicons-plus-alt",function(b){var d=a(this).closest(".column-container"),e=a("#newfield-tool").clone().css("display","");c(e,d)}),a("#grid-pages-panel").on("click",".column-split",function(b){var c=a(this).parent().parent(),e=c.attr("class").split("-"),f=a("<div>").insertAfter(c),g=Math.ceil(e[2]/2),h=Math.floor(e[2]/2);e[2]=g,c.attr("class",e.join("-")),e[2]=h,f.addClass(e.join("-")).append('<div class="layout-column column-container">'),a(this).remove(),d(),jQuery(".column-tools").remove(),jQuery(".column-merge").remove()}),a("#grid-pages-panel").on("click",".column-remove",function(c){var d=a(this).closest(".row"),e=d.find(".layout-form-field"),f=d.closest(".layout-grid-panel");if(e.length){if(!confirm(a("#row-remove-fields-message").text()))return;e.each(function(b,c){var d=a(c).data("config");a("#"+d).remove(),a('option[value="'+d+'"]').remove(),a('[data-bind="'+d+'"]').remove(),delete current_form_fields[d]})}d.slideUp(200,function(){if(a(this).remove(),b(),rebuild_field_binding(),!f.find(".row").length){f.remove();var c=a("#page-toggles .button-primary"),d=c.prev(),e=c.next();c.remove(),d.length?d.trigger("click"):e.trigger("click")}a(document).trigger("remove.page")}),jQuery(".column-tools").remove(),jQuery(".column-merge").remove()}),a(".caldera-config-editor-main-panel").on("click",".caldera-add-row",function(c){c.preventDefault();var e=a(".page-active");if(!e.length)return void a(".caldera-add-page").trigger("click");var f=a('<div style="display:none;" class="first-row-level row"><div class="col-xs-12"><div class="layout-column column-container"></div></div></div>');a(".page-active").append(f),f.slideDown(200),d(),b()}),a("#grid-pages-panel").on("click",".column-join",function(c){var d=a(this).parent().parent().parent(),e=d.prev(),f=e.attr("class").split("-"),g=d.attr("class").split("-");f[2]=parseFloat(f[2])+parseFloat(g[2]),d.find(".layout-column").contents().appendTo(e.find(".layout-column")),e.attr("class",f.join("-")),d.remove(),b(),jQuery(".column-tools").remove(),jQuery(".column-merge").remove()}),a("#grid-pages-panel").on("mouseenter",".row",function(c){var d=jQuery(this);jQuery(".column-tools,.column-merge").remove(),d.children().children().first().append('<div class="column-remove column-tools"><i class="icon-remove"></i></div>'),d.children().children().last().append('<div class="column-sort column-tools" style="text-align:right;"><i class="dashicons dashicons-menu drag-handle sort-handle"></i></div>'),d.children().children().not(":first").prepend('<div class="column-merge"><div class="column-join column-tools"><i class="icon-join"></i></div></div>');var e=d.parent().parent().parent().width()/12-1;d.children().children().each(function(b,c){var d=a(c),e=d.width()/2-5;d.prepend('<div class="column-fieldinsert column-tools"><i class="dashicons dashicons-plus-alt"></i></div>'),d.parent().hasClass("col-xs-1")||(d.prepend('<div class="column-split column-tools"><i class="dashicons dashicons-leftright"></i></div>'),d.find(".column-split").css("left",e))}),jQuery(".column-merge").draggable({axis:"x",helper:"clone",appendTo:d,grid:[e,0],drag:function(c,d){a(this).addClass("dragging"),a(".column-tools").remove(),a(".column-split").remove();var e=a(this).parent().parent(),f=d.helper,g=d.originalPosition.left>f.position().left?"left":"right",h=e.prev(),i=Math.round(e.parent().width()/12-10),j=Math.abs(d.originalPosition.left-f.position().left);if(e.parent().addClass("sizing"),j>=i){var k=h.attr("class").split("-"),l=e.attr("class").split("-");k[2]=parseFloat(k[2]),l[2]=parseFloat(l[2]),"left"===g?(k[2]--,l[2]++,k[2]>0&&k[2]<k[2]+l[2]?(h.attr("class",k.join("-")),e.attr("class",l.join("-")),d.originalPosition.left=f.position().left):a(this).draggable("option","disabled",!0)):(k[2]++,l[2]--,l[2]>0&&l[2]<l[2]+l[2]?(h.attr("class",k.join("-")),e.attr("class",l.join("-")),d.originalPosition.left=f.position().left):a(this).draggable("option","disabled",!0)),b()}},stop:function(){a(this).removeClass("dragging").parent().parent().parent().removeClass("sizing")}})}),a("#grid-pages-panel").on("mouseleave",".row",function(a){jQuery(".column-tools").remove(),jQuery(".column-merge").remove()}),a("#grid-pages-panel").on("click",".layout-form-field .icon-remove",function(){var b=a(this),c=b.parent(),d=a("#"+c.data("config"));c.slideUp(100,function(){a(this).remove()}),d.slideUp(100,function(){a(this).remove()})}),a(document).on("click",".layout-form-field .dashicons-admin-page",function(){var b=a(this),d=b.parent(),e=d.data("config"),f=a("#"+e).formJSON(),g=b.closest(".column-container"),h=d.clone().css("display",""),i={};d.hasClass("field-edit-open")&&(d.removeClass("field-edit-open"),h.removeClass("field-edit-open"),a(".caldera-editor-field-config-wrapper").hide()),f.config.fields[e]&&(i=f.config.fields[e],delete i.ID),c(h,g,i)}),a(document).on("click",".layout-form-field .icon-edit",function(){var b=a(this),c=b.parent(),d=a("#"+c.data("config")+"_type").val();a(".caldera-editor-field-config-wrapper").hide(),c.hasClass("field-edit-open")?c.removeClass("field-edit-open"):(a(".layout-form-field").removeClass("field-edit-open"),c.addClass("field-edit-open"),a("#"+c.data("config")).show()),a(document).trigger("show."+c.data("config")),a(document).trigger("show.fieldedit"),"radio"!==d&&"checkbox"!==d&&"dropdown"!==d&&"toggle_switch"!==d||a("#"+c.data("config")+"_auto").trigger("change")}),a("body").on("click",".layout-modal-edit-closer,.layout-modal-save-action",function(b){b.preventDefault();var c=a(this),d=a(".layout-form-field.edit-open"),e=c.closest(".layout-modal-container");settings=e.find(".settings-panel").first(),a(".edit-open").removeClass("edit-open"),settings.appendTo(d.find(".settings-wrapper")).hide(),e.hide()}),a(".layout-editor-body").on("change",".layout-core-pod-query",function(){a(this).parent().find(".settings-panel-row").remove(),a(".edit-open").find(".drag-handle .set-pod").html(" - "+a(this).val())}),a(".layout-editor-body").on("click",".remove-where",function(){a(this).closest(".settings-panel-row").remove()}),a(".layout-editor-body").on("click",".use-pod-container",function(){var b=a(this),c=b.prev(),d=c.val();if(d.length){a(".edit-open").find(".drag-handle .set-pod").html(" - "+c.val()),b.parent().parent().find(".spinner").css("display","inline-block");var e={action:"pq_loadpod",pod_reference:{pod:d}};a.post(cfAdminAJAX,e,function(c){b.parent().find(".spinner").css("display","none");var d=a("#where-line-tmpl").html(),e="",f=b.closest(".settings-panel").data("container");for(var g in c)e+='<option value="'+c[g]+'">'+c[g]+"</option>";d=d.replace(/{{fields}}/g,e).replace(/{{container_id}}/g,f),b.parent().append(d)})}}),a(".caldera-editor-header").on("click",".column-sort .icon-edit",function(a){}),a(".layout-editor-body").on("tray_loaded",".layout-template-tray",function(){d()}),a(".caldera-editor-header").on("click",".caldera-editor-header-nav a",function(b){b.preventDefault();var c=a(this);a(".caldera-editor-header-nav li").removeClass("active"),a(".caldera-editor-body").hide(),a(c.attr("href")).show(),c.parent().addClass("active"),rebind_field_bindings()}),a("body").on("change",".required",function(){check_required_bindings(this)}),a("body").on("submit",".caldera-forms-options-form",function(b){var c=a(".required.has-error");c.length&&b.preventDefault()}),a(".caldera-editor-body").on("click",".add-toggle-option",function(b){var c=a(this);if(c.data("bulk"))return a(c.data("bulk")).toggle(),void a(c.data("bulk")).find("textarea").focus();var d=c.closest(".caldera-editor-field-config-wrapper"),e=d.find(".toggle-options"),f=a("#field-option-row-tmpl").html(),g=Handlebars.compile(f),h="opt"+parseInt(1048576*(Math.random()+1)),i={_name:"config[fields]["+d.prop("id")+"][config]",option:{}};if(c.data("options")){for(var j=a(c.data("options")),k=j.val().split("\n"),l=!1,m=0;m<k.length;m++){var n=k[m],o=n,p=o.split("|");p.length>1&&(o=p[0],n=p[1],l=!0),i.option["opt"+parseInt(1048576*(Math.random()+m))]={value:o,label:n,default:!1}}a(c.data("options")).parent().hide(),j.val(""),!0===l?d.find(".toggle_show_values").prop("checked",!0):d.find(".toggle_show_values").prop("checked",!1),e.empty()}else i.option[h]={value:"",label:"",default:!1};a(".preset_options").val(""),e.append(g(i)),d.find(".toggle_show_values").trigger("change"),a(".toggle-options").sortable({handle:".dashicons-sort"}),k||e.find(".toggle_label_field").last().focus()}),a(".caldera-editor-body").on("change",".preset_options",function(b){var c=a(this),d=c.val(),e=a(c.data("bulk"));preset_options&&preset_options[d]&&preset_options[d].data&&("object"==typeof preset_options[d].data&&preset_options[d].data.length&&(preset_options[d].data=preset_options[d].data.join("\n")),e.val(preset_options[d].data))}),a(".caldera-editor-body").on("click",".toggle-remove-option",function(b){var c=a(this).closest(".caldera-editor-field-config-wrapper").find(".field-config").first();a(this).parent().remove(),c.trigger("change"),a(document).trigger("option.remove")}),a(".caldera-editor-body").on("click",".page-toggle",function(b){var c=a(this),d=c.parent(),e=d.find(".button");e.removeClass("button-primary"),a(".layout-grid-panel").hide().removeClass("page-active"),a("#"+c.data("page")).show().addClass("page-active"),c.addClass("button-primary"),e.each(function(b,c){a(c).html(d.data("title")+" "+(b+1))}),1===e.length&&d.hide()}),a(".caldera-editor-body").on("blur toggle.values",".toggle_label_field",function(b){var c=a(this),d=c.prev();d.val().length||d.val(c.val())}),a(document).on("change focusout",".toggle_value_field",function(){a(document).trigger("show.fieldedit")}),a(document).on("show.fieldedit option.remove",function(b){a(".toggle_value_field.has-error").removeClass("has-error");for(var c=a("#"+a(".layout-form-field.field-edit-open").data("config")),d=c.find(".toggle_value_field"),e=c.find(".notice"),f=0,g=0;g<d.length;g++){for(var h=(d[g].value,0),i=0;i<d.length;i++)d[g]!==d[i]&&d[g].value===d[i].value&&(a(d[i]).addClass("has-error"),h++);h>0&&(a(d[g]).addClass("has-error"),f++)}f>0?(e.slideDown(),b.preventDefault()):e.slideUp()});var h=!1;focus_initial_field=function(b){var c=a(".layout-grid-panel .icon-edit").first();c.length?c.trigger("click"):(a(".layout-column.column-container").first().trigger("mouseover"),h=setInterval(e,500)),a(document).off("load.page",focus_initial_field)},a(document).on("load.page",focus_initial_field),cf_clear_puler=function(){h&&(clearTimeout(h),a(document).off("mouseover",".layout-new-form-field, .column-fieldinsert",cf_clear_puler)),a(".layout-new-form-field, .column-fieldinsert").fadeIn()},a(document).on("mouseover",".layout-new-form-field, .column-fieldinsert",cf_clear_puler),rebuild_field_binding(),a(document).trigger("load.page"),a("body").on("click",".caldera-processor-nav a",function(b){b.preventDefault();var c=a(this);a(".caldera-processor-nav").removeClass("active"),a(".caldera-editor-processor-config-wrapper").hide(),a(c.attr("href")).show(),c.parent().addClass("active")}),a("body").on("click",".add-new-processor",function(b){var c=a(this),d=Handlebars.compile(a("#processor-wrapper-tmpl").html());wrap=a(".active-processors-list"),process_conf=a(".caldera-editor-processor-config"),processid=Math.round(1e8*Math.random()),new_templ=Handlebars.compile(a("#processor-line-tmpl").html()),new_proc={id:"fp_"+processid,type:c.data("type")},wrap.append(new_templ(new_proc)),process_conf.append(d(new_proc)),a("#form_processor_baldrickModalCloser").trigger("click"),a(".caldera-processor-nav a").last().trigger("click"),a("#fp_"+processid+"_type").val(c.data("type")).trigger("change"),f(),baldrickTriggers()}),a("body").on("click",".delete-processor",function(b){var c=a(this),d=c.closest(".caldera-editor-processor-config-wrapper");d.data("type");confirm(c.data("confirm"))&&(a("."+d.prop("id")).remove(),d.remove(),a(".caldera-processor-nav a").first().trigger("click"),rebuild_field_binding())}),a("body").on("change",".caldera-select-processor-type",function(b){var c=a(this),d=c.closest(".caldera-editor-processor-config-wrapper"),e=c.find('option[value="'+c.val()+'"]').text(),f=d.find(".caldera-editor-processor-title"),h=a(".caldera-processor-nav.active a");""===e&&(e=f.data("title")),f.html(e),h.html(e+' <span class="processor-line-number"></span>').parent().addClass("processor_type_"+c.val()),g(this),rebuild_field_binding()}),a(document).on("click","#cf-shortcode-preview",function(){a(this).focus().select()}),a(document).on("change",".cf-email-preview-toggle",function(){var b=a(this),c=a(".caldera-header-email-preview-button");b.is(":checked")?c.show().attr("aria-hidden","false").css("visibility","visible"):c.hide().attr("aria-hidden","true").css("visibility","hidden")}),rebuild_field_binding(),a(".caldera-select-processor-type").each(function(a,b){g(b)}),f()}),Handlebars.registerHelper("_field",function(a){var b=this,c="",d="",e="",f=this[a.hash.slug]?' data-default="'+this[a.hash.slug]+'"':"";a.hash.required&&(c=" required"),a.hash.exclude&&(e='data-exclude="'+a.hash.exclude+'"'),a.hash.array&&(d="[]","true"!==a.hash.array&&(f='value="'+a.hash.array+'"')),out="<select "+(a.hash.type?'data-type="'+a.hash.type+'"':"")+f+" "+e+' name="'+this._name+"["+a.hash.slug+"]"+d+'" id="'+this._id+"_"+a.hash.slug+'" class="block-input field-config caldera-field-bind'+c+'">',this[a.hash.slug]?out+='<option class="bound-field" value="'+this[a.hash.slug]+'" class="bound-field"></option>':a.hash.required||(out+='<option value=""></option>');for(var g in current_form_fields){var h="";a.hash.type&&current_form_fields[g].type!==a.hash.type||(b[a.hash.slug]&&b[a.hash.slug]===g&&(h=' selected="selected"'),out+='<option value="'+g+'"'+h+">"+current_form_fields[g].label+" ["+current_form_fields[g].slug+"]</option>")}return out+="</select>",a.hash.required&&(out+='<input class="field-config" name="'+this._name+'[_required_bounds][]" type="hidden" value="'+a.hash.slug+'">'),out}),Handlebars.registerHelper("console",function(a,b){console.log(this)}),jQuery(document).ready(function(a){function b(b){var d=a(b),e=d.closest(".caldera-editor-field-config-wrapper"),f=e.find(".caldera-config-field-setup"),g=compiled_templates[d.val()+"_tmpl"]?compiled_templates[d.val()+"_tmpl"]:compiled_templates.noconfig_field_templ,h=e.find(".field_config_string").val(),i=d.data("type");if(e.find(".caldera-config-group").show(),d.addClass("field-initialized"),h=h.length&&i===d.val()?JSON.parse(h):fieldtype_defaults[d.val()+"_cfg"],h||(h={}),h._id=d.data("field"),h._name="config[fields]["+d.data("field")+"][config]",g=a("<div>").html(g(h)),f.html(g.html()),"function"==typeof window[d.val()+"_init"]&&window[d.val()+"_init"](d.data("field"),f),fieldtype_defaults[d.val()+"_nosupport"]&&(fieldtype_defaults[d.val()+"_nosupport"].indexOf("hide_label")>=0&&e.find(".hide-label-field").hide().find(".field-config").prop("checked",!1),fieldtype_defaults[d.val()+"_nosupport"].indexOf("caption")>=0&&e.find(".caption-field").hide().find(".field-config").val(""),fieldtype_defaults[d.val()+"_nosupport"].indexOf("required")>=0&&e.find(".required-field").hide().find(".field-config").prop("checked",!1),fieldtype_defaults[d.val()+"_nosupport"].indexOf("custom_class")>=0&&e.find(".customclass-field").hide().find(".field-config").val(""),fieldtype_defaults[d.val()+"_nosupport"].indexOf("entry_list")>=0&&e.find(".entrylist-field").hide().find(".field-config").prop("checked",!1)),e.find(".toggle_show_values").trigger("change"),!a(".caldera-select-field-type").not(".field-initialized").length){if(core_form||(core_form=jQuery(".caldera-forms-options-form")),core_form.hasClass("builder-loaded"))c(d.data("field"));else{for(var j=a(".caldera-select-field-type.field-initialized"),k=0;k<j.length;k++)c(a(j[k]).data("field"));core_form.addClass("builder-loaded")}a(".caldera-header-save-button").prop("disabled",!1),rebuild_field_binding(),baldrickTriggers()}a(".color-field").length&&a(".color-field").wpColorPicker({change:function(b){var c=a(this);c.data("ev")&&clearTimeout(c.data("ev")),c.data("ev",setTimeout(function(){c.trigger("record")},200)),c.data("target")&&(a(c.data("target")).css(c.data("style"),c.val()),a(c.data("target")).val(c.val()))}})}function c(b){var c=a("#"+b),d=c.find(".caldera-select-field-type"),e=a('.layout-form-field[data-config="'+b+'"]'),f=e.find(".field_preview"),g=(a("#preview-"+d.val()+"_tmpl").html(),compiled_templates["preview-"+d.val()+"_tmpl"]),h={id:b},i=c.find(".field-config");i.each(function(c,d){for(var e=a(d),f=e.prop("name").split("["+b+"]")[1].substr(1),g=f.substr(0,f.length-1).split("]["),i=e.is(":checkbox,:radio")?e.filter(":checked").val():e.val(),j={},k=g.length-1;k>=0;k--)if(k===g.length-1)j[g[k]]=i;else{var l=j;j={},j[g[k]]=l}a.extend(!0,h,j)}),f.html(g(h)),e.removeClass("button"),a(".preview-field-config").prop("disabled",!0)}function d(b){var c,d=a(".caldera-editor-fields-panel"),e=(a(".caldera-editor-groups-panel"),a(".caldera-group-nav")),f=a('[data-group="'+b+'"]'),g=f.find(".caldera-config-group-name"),h=f.find(".caldera-config-group-slug"),i=f.find(".caldera-config-group-desc"),j=f.find(".caldera-config-group-admin"),k=a(".active-group-name"),l=a(".active-group-slug"),m=a(".active-group-desc"),n=a(".active-group-admin"),o=a(".caldera-editor-fields-list ul"),p=f.find(".caldera-config-group-repeat"),q=a(".repeat-config-button"),r=(a(".caldera-editor-group-settings"),a(".caldera-config-group-remove"));a(".new-group-input").remove(),a(".new-field-input").remove(),e.removeClass("active"),d.show(),o.hide(),o.removeClass("active").find("li.active").removeClass("active"),o.hide(),f.addClass("active"),c=a(".caldera-editor-fields-list ul.active li"),c.length?r.hide():r.show(),a(".caldera-editor-field-config-wrapper").hide(),f.show(),k.val(g.val()),l.val(h.val()),m.val(i.val()),"1"===j.val()?n.prop("checked",!0):n.prop("checked",!1),"1"===p.val()?q.addClass("field-edit-open"):q.removeClass("field-edit-open")}a(".caldera-header-save-button").baldrick({method:"POST",request:"admin.php?page=caldera-forms",before:function(b,c){if(c.preventDefault(),!check_required_bindings())return!1;a("#save_indicator").addClass("loading"),"undefined"!=typeof tinyMCE&&tinyMCE.triggerSave();var d=a(".caldera-forms-options-form").formJSON();return d.conditions&&(d.config.conditional_groups={conditions:d.conditions}),a(b).data("cf_edit_nonce",d.cf_edit_nonce),a(b).data("_wp_http_referer",d._wp_http_referer),a(b).data("sender","ajax"),a(b).data("config",JSON.stringify(d.config)),!0},callback:function(b){if(!1===b.data){var c=a(".updated_notice_box");c.stop().animate({top:0},200,function(){setTimeout(function(){c.stop().animate({top:-75},200)},2e3)})}},complete:function(b){a(".wrapper-instance-pane .field-config").prop("disabled",!1)}}),a("body").on("click",".toggle_processor_event input",function(b){var c=a(this),d=c.closest(".wrapper-instance-pane"),e=d.find(".caldera-config-processor-setup"),f=d.find(".caldera-config-processor-notice");c.is(":checked")?(c.parent().addClass("activated"),c.parent().find(".is_active").show().attr("aria-hidden",!1).css("visibility","visible"),c.parent().find(".not_active").hide().attr("aria-hidden",!0).css("visibility","hidden")):(c.parent().removeClass("activated"),c.parent().find(".is_active").hide().attr("aria-hidden",!0).css("visibility","hidden"),c.parent().find(".not_active").show().attr("aria-hidden",!1).css("visibility","visible")),d.find(".toggle_processor_event .activated").length?(e.slideDown(100),f.slideUp(100)):(e.slideUp(100),f.slideDown(100))}),a("body").on("click",".toggle_option_tab > a",function(b){b.preventDefault();var c=a(this),d=a(c.attr("href")),e=c.parent().find("a"),f=c.closest(".caldera-editor-config-wrapper").find(".wrapper-instance-pane");e.removeClass("button-primary"),f.hide(),d.show(),c.addClass("button-primary"),a(".caldera-conditionals-usetype").trigger("change")}),a(".caldera-editor-body").on("change",".caldera-select-field-type",function(a){b(this)}),a(".caldera-editor-body").on("click",".caldera-group-nav a",function(b){b.preventDefault(),d(a(this).attr("href").substr(1))}),a(".caldera-editor-body").on("click",".caldera-editor-fields-list a",function(b){b.preventDefault();var c=a(this),d=a(c.attr("href"));a(".new-group-input").remove(),a(".new-field-input").remove(),a(".caldera-editor-fields-list li.active").removeClass("active"),c.parent().addClass("active"),a(".caldera-editor-field-config-wrapper").hide(),d.show()}),a(".caldera-editor-body").on("click",".group-config-button",function(b){var c=a(this),d=a(".caldera-editor-group-settings"),e=c.closest(".caldera-editor-fields-panel"),f=a(".caldera-config-group-remove");e.find(".caldera-field-line").length?f.hide():f.show(),c.hasClass("field-edit-open")?(d.slideUp(100),c.removeClass("field-edit-open")):(d.slideDown(100),c.addClass("field-edit-open"))}),a(".caldera-editor-body").on("keydown",".field-config",function(b){a(this).is("textarea")||13===b.which&&b.preventDefault()}),a(".caldera-editor-body").on("change",".field-label",function(b){var c=a(this).closest(".caldera-editor-field-config-wrapper").prop("id");field_line=a('[data-field="'+c+'"]'),field_title=a("#"+c+" .caldera-editor-field-title, .layout-form-field.field-edit-open .layout_field_name"),slug=a("#"+c+" .field-slug"),field_line.find("a").html('<i class="icn-field"></i> '+this.value),field_title.text(this.value),"change"===b.type&&slug.trigger("change"),rebuild_field_binding()}),a(".caldera-editor-body").on("change",".active-group-name",function(b){b.preventDefault();var c=a(".caldera-group-nav.active"),d=(c.data("group"),c.find(".caldera-config-group-name")),e=c.find("span");"focusout"!==b.type||this.value.length||(this.value="Group "+(parseInt(c.index())+1)),d.val(this.value),e.text(this.value)}),a(".caldera-editor-body").on("change",".active-group-slug",function(b){b.preventDefault();var c=a(".caldera-group-nav.active"),d=(c.data("group"),c.find(".caldera-config-group-name").val()),e=c.find(".caldera-config-group-slug"),f=(c.find("span"),this.value.split(" ").join("_").split("-").join("_").replace(/[^a-z0-9_]/gi,"").toLowerCase());"focusout"!==b.type||this.value.length||(f=d.split(" ").join("_").split("-").join("_").replace(/[^a-z0-9_]/gi,"").toLowerCase()),e.val(f),this.value=f}),a(".caldera-editor-body").on("change",".active-group-desc",function(b){b.preventDefault();var c=a(".caldera-group-nav.active"),d=(c.data("group"),c.find(".caldera-config-group-desc"));d.val(this.value)}),a(".caldera-editor-body").on("change",".active-group-admin",function(b){b.preventDefault();var c=a(".caldera-group-nav.active"),d=(c.data("group"),c.find(".caldera-config-group-name").val(),c.find(".caldera-config-group-admin"));c.find("span"),this.value.split(" ").join("_").split("-").join("_").replace(/[^a-z0-9_]/gi,"").toLowerCase(),a(this).prop("checked")?(d.val(1),c.addClass("is-admin")):(d.val(0),c.removeClass("is-admin"))}),a(".caldera-editor-body").on("click",".repeat-config-button",function(b){b.preventDefault();var c=a(".caldera-group-nav.active"),d=(c.data("group"),c.find("a .group-type")),e=c.find(".caldera-config-group-repeat"),f=a(this);f.hasClass("field-edit-open")?(e.val("0"),d.removeClass("icn-repeat").addClass("icn-folder"),f.removeClass("field-edit-open")):(e.val("1"),d.addClass("icn-repeat").removeClass("icn-folder"),f.addClass("field-edit-open"))}),a(".caldera-editor-body").on("click",".delete-field",function(){var b=a(this),c=b.closest(".caldera-editor-field-config-wrapper").prop("id");confirm(b.data("confirm"))&&(a("#"+c).remove(),a('option[value="'+c+'"]').remove(),a('[data-bind="'+c+'"]').remove(),delete current_form_fields[c],a('[data-config="'+c+'"]').slideUp(200,function(){var b=a(this);b.remove(),rebuild_field_binding(),a(document).trigger("field.removed")}))}),a(".caldera-editor-body").on("click",".add-new-group,.add-field",function(){var b=a(this);if(a(".new-group-input").remove(),a(".new-field-input").remove(),b.hasClass("add-field")){var c=a('<input type="text" class="new-field-input block-input">');c.appendTo(a(".caldera-editor-fields-list ul.active")).focus()}else{var d=a('<input type="text" class="new-group-input block-input">');d.appendTo(a(".caldera-editor-groups-panel")).focus()}}),a(".caldera-editor-body").on("change keypress",".new-group-input",function(b){if("keypress"===b.type){if(13!==b.which)return;b.preventDefault()}var c,e,f=this.value,g=a(this),h=a(".caldera-editor-groups-panel ul"),i=a(".caldera-editor-fields-list");if(f.length){c=Handlebars.compile(a("#caldera_group_line_templ").html()),e={id:f.split(" ").join("_").split("-").join("_").replace(/[^a-z0-9_]/gi,"").toLowerCase(),name:f},h.append(c(e));var j=a('<ul data-group="'+e.id+'">').hide();j.appendTo(i),g.remove(),d(e.id)}else g.remove()}),a(".caldera-editor-body").on("change keypress",".new-field-input",function(b){if("keypress"===b.type){if(13!==b.which)return;b.preventDefault()}var c,d,e,f=this.value,g=a(this),h=g.parent(),i=a(".caldera-editor-field-config"),j=a(".caldera-config-group-remove");if(f.length){j.hide(),c=Handlebars.compile(a("#caldera_field_line_templ").html()),d=Handlebars.compile(a("#caldera_field_config_wrapper_templ").html()),e={id:f.split(" ").join("_").split("-").join("_").replace(/[^a-z0-9_]/gi,"").toLowerCase(),label:f,slug:f.split(" ").join("_").split("-").join("_").replace(/[^a-z0-9_]/gi,"").toLowerCase(),group:a(".caldera-group-nav.active").data("group")};var k=a(c(e));k.appendTo(h),i.append(d(e)),k.find("a").trigger("click"),g.remove()}else g.remove()}),a(".caldera-editor-body").on("change",".field-slug",function(b){this.value.length?this.value=this.value.split(" ").join("_").split("-").join("_").replace(/[^a-z0-9_]/gi,"").toLowerCase():"change"===b.type&&(this.value=a(this).closest(".caldera-editor-field-config-wrapper").find(".field-label").val().split(" ").join("_").split("-").join("_").replace(/[^a-z0-9_]/gi,"").toLowerCase())}),a(".caldera-editor-body").on("click",".caldera-add-group",function(b){var c=a(this),d=c.data("group"),e=a("#"+d+"_panel_tmpl").html();c.parent().parent().append(e)}),a(".caldera-editor-body").on("click",".caldera-config-group-remove",function(b){var c=a(".active-group-slug").val();a('[data-group="'+c+'"]').hide(0,function(){a(this).remove();var b=a(".caldera-group-nav");b.length?b.first().find("a").trigger("click"):a(".caldera-editor-fields-panel").hide()})}),a("body").on("click",".set-current-field",function(b){b.preventDefault();var c=a(this);a("#"+c.data("field")+"_type").val(c.data("type")).trigger("change"),a("#"+c.data("field")+"_lable").focus(),a("#field_setup_baldrickModalCloser").trigger("click")}),a(".caldera-editor-body").on("change record",".field-config",function(b){var d=a(this),e=d.closest(".caldera-editor-field-config-wrapper");current_form_fields&&(d.prop("id")===e.prop("id")+"_lable"&&(current_form_fields[e.prop("id")].label=this.value),d.prop("id")===e.prop("id")+"_slug"&&(current_form_fields[e.prop("id")].slug=this.value),d.prop("id")===e.prop("id")+"_type"&&(current_form_fields[e.prop("id")].type=this.value),e.length&&c(e.prop("id")))}),a(".caldera-editor-body").on("focus",".caldera-field-bind",function(b){var c=a(this),d=this.value;if(b.type&&"focusin"===b.type)return c.removeClass("bound_field").addClass("reload-binding"),rebind_field_bindings(),void(this.value=d)}),a(".caldera-editor-body").on("change",".caldera-conditional-field-set",function(b){var c,d,e=a(this),f=e.parent().find(".compare-type"),g=e.data("condition"),h=e.data("id"),i="config["+g+"]["+h+"][conditions][group]["+e.data("row")+"]["+e.data("line")+"]",j=e.data("line"),k=a("#"+j+"_value"),l=k.find(".caldera-conditional-value-field").first(),m=[],n=this.value;if("{"!==n.substr(0,1)&&(c=a("#"+n),d=c.find(".field-button-type"),m=c.find(".caldera-config-group-toggle-options")),e.hasClass(".bind_init")&&e.addClass("bound_triggered"),l.length&&l.val().length&&k.data("value",l.val()),f.show(),m.length){var o=m.find(".toggle_option_row"),p='<select name="'+i+'[value]" class="caldera-processor-value-bind caldera-conditional-value-field" data-field="'+n+'" style="max-width: 220px; width: 220px;">';p+='<option value=""></option>',o.each(function(b,c){var d=a(c).find(".toggle_label_field"),e=d.data("option"),f="";k.data("value")&&(k.data("value").toString()!==e&&k.data("value").toString()!==a(c).find(".toggle_value_field").val()||(f=' selected="selected"')),p+='<option value="'+e+'"'+f+">"+d.val()+"</option>"}),p+="</select>"}else d&&"button"==d.val()?(f.val("is").hide(),p='<select name="'+i+'[value]" class="caldera-processor-value-bind caldera-conditional-value-field" data-field="'+n+'" style="max-width: 220px; width: 220px;">',p+='<option value="click" '+("click"===k.data("value")?'selected="selected"':"")+">Click</option>",p+='<option value="dblclick" '+("dblclick"===k.data("value")?'selected="selected"':"")+">Double Click</option>",p+="</select>"):p='<input name="'+i+'[value]" type="text" class="caldera-conditional-value-field magic-tag-enabled" value="'+(k.data("value")?k.data("value"):"")+'" style="max-width: 205px;">';k.html(p),init_magic_tags()}),a(".caldera-editor-body").on("change",".caldera-conditionals-usetype",function(b){var c=a(this);"show"===this.value||"hide"===this.value||"disable"===this.value||"use"===this.value||"not"===this.value?(a("#"+c.data("id")+"_condition_group_add").show(),a("#"+c.data("id")+"_conditional_wrap").show()):(a("#"+c.data("id")+"_condition_group_add").hide(),a("#"+c.data("id")+"_conditional_wrap").hide())}),a(".caldera-editor-body").on("click",".remove-conditional-line",function(b){b.preventDefault();var c=a(this),d=c.closest(".caldera-condition-line"),e=c.closest(".caldera-condition-group");d.remove(),e.find(".caldera-condition-line").length||e.remove();
3
- }),a(".caldera-group-nav").first().find("a").trigger("click"),a(".caldera-editor-body").on("change",".toggle_show_values",function(b){var c=a(this),d=c.closest(".caldera-config-group-toggle-options");values=d.find(".toggle_value_field"),lables=d.find(".toggle_label_field"),field_lables=d.find(".caldera-config-group-option-labels"),c.prop("checked")?(values.show().parent().show(),values.show().parent().parent().show(),lables.css("width",""),field_lables.show()):(values.hide().parent().hide(),lables.css("width",245),field_lables.hide()),lables.trigger("toggle.values"),init_magic_tags()}),a(".caldera-editor-body").on("change",".auto-populate-type",function(){a(this).closest(".wrapper-instance-pane").find(".auto-populate-options").trigger("change")}),a(".caldera-editor-body").on("change",".auto-populate-options",function(){var b=a(this),c=b.closest(".wrapper-instance-pane"),d=c.find(".caldera-config-group-toggle-options"),e=c.find(".caldera-config-group-auto-options"),f=e.find(".auto-populate-type");e.find(".auto-populate-type-panel").hide(),b.prop("checked")?(d.hide(),e.show()):(d.show(),e.hide()),e.find(".caldera-config-group-auto-"+f.val()).show()}),a("body").on("change",".pin-toggle-roles",function(){var b=a(this),c=a("#caldera-pin-rules");"1"===b.val()?c.show():c.hide()}),a("body").on("click",".magic-tag-init",function(b){var c=a(this),d=c.prev();d.focus().trigger("init.magic")}),a("body").on("keyup focus select click init.magic",".magic-tag-enabled",function(b){init_magic_tags();var c=a(this),d=c.parent(),e=d.closest(".wrapper-instance-pane").find(".caldera-select-field-type").val()?d.closest(".wrapper-instance-pane").find(".caldera-select-field-type").val():"hidden",f=d.find(".magic-tags-autocomplete"),g=f.find("ul"),h=this.value,i=[],j="",k=this.selectionStart,l=this.selectionEnd;if(f.length&&f.data("focus"))return void b.preventDefault();if(c.data("tag",""),this.selectionEnd>this.selectionStart)j=this.value.substr(this.selectionStart,this.selectionEnd-this.selectionStart);else if(("select"===b.type||"keyup"===b.type)&&40!==b.which&&38!==b.which&&39!==b.which&&37!==b.which){for(k=this.selectionStart;k>0;k--){var m=h.substr(k-1,1);if(" "===m||"\n"===m||("%"===m||"}"===m)&&this.selectionStart===k)break}for(l=this.selectionStart;l<h.length;l++){var m=h.substr(l,1);if(" "===m||"\n"===m||("%"===m||"{"===m)&&this.selectionStart===l)break}j=h.substr(k,l-k)}if("focusout"!==b.type){"init"!==b.type&&j.length<3&&f.length&&f.remove(),f.length||(f=a('<div class="magic-tags-autocomplete"></div>'),g=a("<ul></ul>"),g.appendTo(f),f.insertAfter(c),f.on("mouseenter",function(){a(this).data("focus",!0)}),f.on("mouseleave",function(){a(this).data("focus",!1),setTimeout(function(){f.remove()},200),c.is(":focus")||c.trigger("focusout")})),g.empty();var n="system",o=!1;"hidden"===e||"dropdown"===e||"radio"===e||"toggle_switch"===e||"checkbox"===e?(o=!0,e="text",n="all"):"paragraph"!==e&&"html"!==e||(e="text"),c.data("type")&&(e=c.data("type")),e=e.split(","),e.push("vars");for(var p=0;p<e.length;p++)for(var q in system_values)if("undefined"!=typeof system_values[q].tags&&"undefined"!=typeof system_values[q].tags[e[p]]){if(i=[q],"system"!==q&&"variable"!==q&&"field"!==q){var r=jQuery(".processor-"+q),s=c.closest(".caldera-editor-processor-config-wrapper"),t=s.prop("id");i=[];for(var u=0;u<r.length;u++)if(s.length||o!==!0){if(t===r[u].id)continue;jQuery("li."+r[u].id).index()<jQuery("li."+t).index()&&i.push(r[u].id)}else i.push(r[u].id)}for(var v=0;v<i.length;v++)if("all"===n||n===q||"variable"===q){var w=a('<li class="header">'+system_values[q].type+(v>0?" ["+(v+1)+"]":"")+"</li>"),x=0;w.appendTo(g);for(var y=0;y<system_values[q].tags[e[p]].length;y++)if(!c.data("parent")||"variable:"+c.data("parent")!==system_values[q].tags[e[p]][y]){var z=system_values[q].wrap[0]+system_values[q].tags[e[p]][y]+system_values[q].wrap[1];if(i[v]!==q&&i.length>1&&(z=system_values[q].wrap[0]+system_values[q].tags[e[p]][y]+":"+i[v]+system_values[q].wrap[1]),z.indexOf(j)>=0||"init"===b.type){x+=1;var A=z.replace(j,"<strong>"+j+"</strong>"),B=a('<li class="tag" data-tag="'+z+'">'+A+"</li>");B.on("click",function(){var b=a(this).data("tag");c.val(h.substr(0,k)+b+h.substr(l)).trigger("change").focus(),c[0].selectionStart=k+b.length-(b.indexOf("*")>0?2:0),c[0].selectionEnd=k+b.length-(b.indexOf("*")>0?1:0),l=k=c[0].selectionEnd,h+=b,c.trigger("init.magic")}),B.appendTo(g)}}0===x&&w.remove()}}}g.children().length||f.remove(),"focusout"===b.type&&setTimeout(function(){f.remove()},200)});for(var e=a(".cf-editor-template"),f=0;f<e.length;f++)compiled_templates[e[f].id]=Handlebars.compile(e[f].innerHTML);a(".caldera-select-field-type").not(".field-initialized").each(function(a,c){b(c)})});var rebuild_field_binding,rebind_field_bindings,current_form_fields={},required_errors={},add_new_grid_page,add_page_grid,init_magic_tags,core_form,compiled_templates={};init_magic_tags=function(){var a=jQuery(".magic-tag-enabled");a.each(function(a,b){var c=jQuery(b);if(c.hasClass("magic-tag-init-bound")){var d=c.parent().find(".magic-tag-init");return void(c.is(":visible")?d.show():d.hide())}var e=jQuery('<span class=""></span>'),f=jQuery('<span style="position:relative;display:inline-block; width:100%;"></span>');c.is("input")&&e.css("borderBottom","none"),c.hasClass("caldera-conditional-value-field")&&f.width("auto"),c.wrap(f),e.insertAfter(c),c.addClass("magic-tag-init-bound"),c.is(":visible")?e.show():e.hide()})},rebuild_field_binding=function(){if(core_form||(core_form=jQuery(".caldera-forms-options-form")),core_form.hasClass("builder-loaded")){var a=jQuery(".caldera-editor-field-config-wrapper");system_values.field={tags:{text:[]},type:"Fields",wrap:["%","%"]};for(var b=0;b<a.length;b++){var c=a[b].id,d=jQuery("#"+c+"_lable").val(),e=jQuery("#"+c+"_slug").val(),f=jQuery("#"+c+"_type").val();"undefined"==typeof system_values.field.tags[f]&&(system_values.field.tags[f]=[]),system_values.field.tags[f].push(e),"text"!==f&&system_values.field.tags.text.push(e),current_form_fields[c]={label:d,slug:e,type:f},jQuery("option.bound-field").trigger("change").each(function(a,b){var c=jQuery(b);0!==c.prop("value").indexOf("{")?c.text(jQuery("#"+c.prop("value")+"_lable").val()+" ["+jQuery("#"+c.prop("value")+"_lable").val()+"]"):c.text(c.prop("value").replace("{","").replace("}",""))}).removeClass("bound-field")}}},rebind_field_bindings=function(){var a,b,c=jQuery(".caldera-field-bind").not(".bound_field");if(c.length){c.addClass("bound_field");for(var d=0;d<c.length;d++){var e=jQuery(c[d]),f=e.val(),g=e.data("default"),h=e.data("exclude"),i=0,j=e.closest(".caldera-editor-processor-config-wrapper"),k=j.prop("id"),l="";if(g&&!e.hasClass("reload-binding")&&(f=g),e.is("select")){e.empty();var m=jQuery('<optgroup label="Fields">');for(var n in current_form_fields)e.data("type")&&e.data("type").split(",").indexOf(current_form_fields[n].type)<0||(e.data("id")!==n&&m.append('<option value="'+n+'"'+(f===n?'selected="selected"':"")+">"+current_form_fields[n].label+" ["+current_form_fields[n].slug+"]</option>"),i+=1);m.appendTo(e),0===i&&e.empty();for(var o in system_values)if(a=[],!(h&&h.split(",").indexOf(o)>=0)){if("system"!==o&&"variable"!==o)for(var p=jQuery(".processor-"+o),q=0;q<p.length;q++)k!==p[q].id&&(a.push(p[q].id),p.length>1&&(b=jQuery("li."+p[q].id+" .processor-line-number"))&&b.html("["+(q+1)+"]"));else a.push("__system__");var r=[];e.data("type")?(r=e.data("type").split(","),r.push("vars")):r=["text","vars"];for(var s=0;s<r.length;s++)if(system_values[o].tags&&system_values[o].tags[r[s]])for(var t=0;t<a.length;t++){jQuery("li."+a[t]).index()>jQuery("li."+k).index()&&"__system__"!==a[t]?e.closest(".caldera-editor-processors-panel-wrap").length&&(l=' disabled="disabled"'):l="";for(var m=jQuery('<optgroup label="'+system_values[o].type+("__system__"!==a[t]?" "+jQuery("li."+a[t]).find(".processor-line-number").html():"")+'"'+l+">"),u=0;u<system_values[o].tags[r[s]].length;u++){var v=system_values[o].tags[r[s]][u];"__system__"!==a[t]&&(v=v.replace(o,a[t])),m.append('<option value="{'+v+'}"'+(f==="{"+v+"}"?'selected="selected"':"")+l+">"+system_values[o].tags[r[s]][u]+"</option>"),i+=1}m.children().length&&m.appendTo(e)}}if(0===i){if(e.empty(),e.data("type")){e.append('<option value="">No '+e.data("type").split(",").join(" or ")+" in form</option>");var w=!0}}else e.prop("disabled",!1);e.hasClass("required")||"undefined"!=typeof w||e.prepend('<option value=""></option>'),e.val(f)}}init_magic_tags(),jQuery(document).trigger("bound.fields"),jQuery(".caldera-header-save-button").prop("disabled",!1)}},jQuery(document).ready(function(a){function b(){var b=a(".layout-grid-panel"),c=0;b.each(function(b,d){var e=a(d),f=e.find(".layout-structure"),g=e.find(".row"),h=[];g.each(function(b,d){var e=a(d),f=e.children().not(".column-merge"),g=[];c+=1,f.each(function(b,d){span=a(d).attr("class").split("-"),g.push(span[2]);var e=a(d).find(".field-location");e.length&&e.each(function(d,e){var f=a(e);f.val(c+":"+(b+1)).removeAttr("disabled")})}),h.push(g.join(":"))}),f.val(h.join("|"))})}function c(b,c,e){var f,g,h="fld_"+Math.round(1e7*Math.random()),i=h,j=a("#field_config_panels");b.prop("id","").prop("title",""),f=Handlebars.compile(a("#caldera_field_config_wrapper_templ").html()),g=a.extend({},{id:i,label:"",slug:""},e),g.slug="",j.append(f(g)),b.removeClass("button-small").removeClass("button").removeClass("button-primary").removeClass("ui-draggable").removeClass("layout-new-form-field").addClass("layout-form-field").attr("data-config",h).css({display:"",opacity:""}),b.find(".layout_field_name").remove(),b.find(".field-location").prop("name","config[layout_grid][fields]["+h+"]"),b.find(".settings-panel").show(),b.appendTo(c),d(),b.find(".icon-edit").trigger("click"),a("#"+h+"_lable").focus().select(),baldrickTriggers(),a(document).trigger("field.added"),e?a("#"+i+"_type").data("type",g.type).trigger("change"):a("#"+h).trigger("field.drop"),rebuild_field_binding()}function d(){a(".toggle-options").sortable({handle:".dashicons-sort"}),a("#grid-pages-panel").sortable({placeholder:"row-drop-helper",handle:".sort-handle",items:".first-row-level",axis:"y",stop:function(){b()}}),a(".layout-column").sortable({connectWith:".layout-column",appendTo:"#grid-pages-panel",helper:"clone",items:".layout-form-field",handle:".drag-handle",cursor:"move",opacity:.7,cursorAt:{left:100,top:15},start:function(a,b){b.helper.css({width:"200px",height:"35px",paddingTop:"20px"})},stop:function(a,c){c.item.removeAttr("style"),b()}}),a("h3 .layout-new-form-field").draggable({helper:"clone",appendTo:"body"}),a(".page-toggle.button").droppable({accept:".layout-form-field",over:function(b,c){a(this).trigger("click"),a(".layout-column").sortable("refresh")}}),a(".layout-column").droppable({greedy:!0,activeClass:"ui-state-dropper",hoverClass:"ui-state-hoverable",accept:".layout-new-form-field",drop:function(b,d){var e=d.draggable.clone(),f=a(this);c(e,f)}}),b()}function e(){if(h){var b=a(".column-fieldinsert");b.length?(b.stop().fadeToggle(700),a(".layout-new-form-field").stop().fadeToggle(700)):cf_clear_puler()}}function f(){a(".caldera-editor-processors-panel ul").sortable({update:function(){rebuild_field_binding()}})}function g(b){var c=a(b),d=a("#"+c.val()+"-tmpl").length?a("#"+c.val()+"-tmpl").html():"",e=c.closest(".caldera-editor-processor-config-wrapper"),f=e.find(".caldera-config-processor-setup"),g=Handlebars.compile(d),h=e.find(".processor_config_string").val(),i=c.data("type");h=h.length&&i===c.val()?JSON.parse(h):processor_defaults[c.val()+"_cfg"],h||(h={}),h._id=e.prop("id"),h._name="config[processors]["+e.prop("id")+"][config]",g=a("<div>").html(g(h)),f.html(g.html()),"function"==typeof window[c.val()+"_init"]&&window[c.val()+"_init"](e.prop("id"),f),e.find(".no-conditions").length&&e.find(".toggle_option_tab").remove(),rebuild_field_binding(),baldrickTriggers(),a(".wp-baldrick").baldrick({request:ajaxurl,method:"POST",before:function(b){var c=a(b);c.data("addNode")&&!c.data("request")&&c.data("request","cf_get_default_setting")}})}add_new_grid_page=function(a){return{page_no:"pg_"+Math.round(1e7*Math.random())}},add_page_grid=function(b){var c=a(".page-toggle").length+1,e=a('<button type="button" data-name="Page '+c+'" data-page="'+b.rawData.page_no+'" class="page-toggle button">'+b.params.trigger.data("addtitle")+" "+c+"</button> "),f=a("#page-toggles");e.appendTo(f),f.show(),d(),e.trigger("click"),1===c&&f.hide(),a(document).trigger("add.page")},a(document).on("remove.page add.page load.page",function(b){var c=a(".page-toggle").length,d=a("#tab_pages");c<=1?d.hide():d.show()}),d(),a("#grid-pages-panel").on("click",".column-fieldinsert .dashicons-plus-alt",function(b){var d=a(this).closest(".column-container"),e=a("#newfield-tool").clone().css("display","");c(e,d)}),a("#grid-pages-panel").on("click",".column-split",function(b){var c=a(this).parent().parent(),e=c.attr("class").split("-"),f=a("<div>").insertAfter(c),g=Math.ceil(e[2]/2),h=Math.floor(e[2]/2);e[2]=g,c.attr("class",e.join("-")),e[2]=h,f.addClass(e.join("-")).append('<div class="layout-column column-container">'),a(this).remove(),d(),jQuery(".column-tools").remove(),jQuery(".column-merge").remove()}),a("#grid-pages-panel").on("click",".column-remove",function(c){var d=a(this).closest(".row"),e=d.find(".layout-form-field"),f=d.closest(".layout-grid-panel");if(e.length){if(!confirm(a("#row-remove-fields-message").text()))return;e.each(function(b,c){var d=a(c).data("config");a("#"+d).remove(),a('option[value="'+d+'"]').remove(),a('[data-bind="'+d+'"]').remove(),delete current_form_fields[d]})}d.slideUp(200,function(){if(a(this).remove(),b(),rebuild_field_binding(),!f.find(".row").length){f.remove();var c=a("#page-toggles .button-primary"),d=c.prev(),e=c.next();c.remove(),d.length?d.trigger("click"):e.trigger("click")}a(document).trigger("remove.page")}),jQuery(".column-tools").remove(),jQuery(".column-merge").remove()}),a(".caldera-config-editor-main-panel").on("click",".caldera-add-row",function(c){c.preventDefault();var e=a(".page-active");if(!e.length)return void a(".caldera-add-page").trigger("click");var f=a('<div style="display:none;" class="first-row-level row"><div class="col-xs-12"><div class="layout-column column-container"></div></div></div>');a(".page-active").append(f),f.slideDown(200),d(),b()}),a("#grid-pages-panel").on("click",".column-join",function(c){var d=a(this).parent().parent().parent(),e=d.prev(),f=e.attr("class").split("-"),g=d.attr("class").split("-");f[2]=parseFloat(f[2])+parseFloat(g[2]),d.find(".layout-column").contents().appendTo(e.find(".layout-column")),e.attr("class",f.join("-")),d.remove(),b(),jQuery(".column-tools").remove(),jQuery(".column-merge").remove()}),a("#grid-pages-panel").on("mouseenter",".row",function(c){var d=jQuery(this);jQuery(".column-tools,.column-merge").remove(),d.children().children().first().append('<div class="column-remove column-tools"><i class="icon-remove"></i></div>'),d.children().children().last().append('<div class="column-sort column-tools" style="text-align:right;"><i class="dashicons dashicons-menu drag-handle sort-handle"></i></div>'),d.children().children().not(":first").prepend('<div class="column-merge"><div class="column-join column-tools"><i class="icon-join"></i></div></div>');var e=d.parent().parent().parent().width()/12-1;d.children().children().each(function(b,c){var d=a(c),e=d.width()/2-5;d.prepend('<div class="column-fieldinsert column-tools"><i class="dashicons dashicons-plus-alt"></i></div>'),d.parent().hasClass("col-xs-1")||(d.prepend('<div class="column-split column-tools"><i class="dashicons dashicons-leftright"></i></div>'),d.find(".column-split").css("left",e))}),jQuery(".column-merge").draggable({axis:"x",helper:"clone",appendTo:d,grid:[e,0],drag:function(c,d){a(this).addClass("dragging"),a(".column-tools").remove(),a(".column-split").remove();var e=a(this).parent().parent(),f=d.helper,g=d.originalPosition.left>f.position().left?"left":"right",h=e.prev(),i=Math.round(e.parent().width()/12-10),j=Math.abs(d.originalPosition.left-f.position().left);if(e.parent().addClass("sizing"),j>=i){var k=h.attr("class").split("-"),l=e.attr("class").split("-");k[2]=parseFloat(k[2]),l[2]=parseFloat(l[2]),"left"===g?(k[2]--,l[2]++,k[2]>0&&k[2]<k[2]+l[2]?(h.attr("class",k.join("-")),e.attr("class",l.join("-")),d.originalPosition.left=f.position().left):a(this).draggable("option","disabled",!0)):(k[2]++,l[2]--,l[2]>0&&l[2]<l[2]+l[2]?(h.attr("class",k.join("-")),e.attr("class",l.join("-")),d.originalPosition.left=f.position().left):a(this).draggable("option","disabled",!0)),b()}},stop:function(){a(this).removeClass("dragging").parent().parent().parent().removeClass("sizing")}})}),a("#grid-pages-panel").on("mouseleave",".row",function(a){jQuery(".column-tools").remove(),jQuery(".column-merge").remove()}),a("#grid-pages-panel").on("click",".layout-form-field .icon-remove",function(){var b=a(this),c=b.parent(),d=a("#"+c.data("config"));c.slideUp(100,function(){a(this).remove()}),d.slideUp(100,function(){a(this).remove()})}),a(document).on("click",".layout-form-field .dashicons-admin-page",function(){var b=a(this),d=b.parent(),e=d.data("config"),f=a("#"+e).formJSON(),g=b.closest(".column-container"),h=d.clone().css("display",""),i={};d.hasClass("field-edit-open")&&(d.removeClass("field-edit-open"),h.removeClass("field-edit-open"),a(".caldera-editor-field-config-wrapper").hide()),f.config.fields[e]&&(i=f.config.fields[e],delete i.ID),c(h,g,i)}),a(document).on("click",".layout-form-field .icon-edit",function(){var b=a(this),c=b.parent(),d=a("#"+c.data("config")+"_type").val();a(".caldera-editor-field-config-wrapper").hide(),c.hasClass("field-edit-open")?c.removeClass("field-edit-open"):(a(".layout-form-field").removeClass("field-edit-open"),c.addClass("field-edit-open"),a("#"+c.data("config")).show()),a(document).trigger("show."+c.data("config")),a(document).trigger("show.fieldedit"),"radio"!==d&&"checkbox"!==d&&"dropdown"!==d&&"toggle_switch"!==d||a("#"+c.data("config")+"_auto").trigger("change")}),a("body").on("click",".layout-modal-edit-closer,.layout-modal-save-action",function(b){b.preventDefault();var c=a(this),d=a(".layout-form-field.edit-open"),e=c.closest(".layout-modal-container");settings=e.find(".settings-panel").first(),a(".edit-open").removeClass("edit-open"),settings.appendTo(d.find(".settings-wrapper")).hide(),e.hide()}),a(".layout-editor-body").on("change",".layout-core-pod-query",function(){a(this).parent().find(".settings-panel-row").remove(),a(".edit-open").find(".drag-handle .set-pod").html(" - "+a(this).val())}),a(".layout-editor-body").on("click",".remove-where",function(){a(this).closest(".settings-panel-row").remove()}),a(".layout-editor-body").on("click",".use-pod-container",function(){var b=a(this),c=b.prev(),d=c.val();if(d.length){a(".edit-open").find(".drag-handle .set-pod").html(" - "+c.val()),b.parent().parent().find(".spinner").css("display","inline-block");var e={action:"pq_loadpod",pod_reference:{pod:d}};a.post(ajaxurl,e,function(c){b.parent().find(".spinner").css("display","none");var d=a("#where-line-tmpl").html(),e="",f=b.closest(".settings-panel").data("container");for(var g in c)e+='<option value="'+c[g]+'">'+c[g]+"</option>";d=d.replace(/{{fields}}/g,e).replace(/{{container_id}}/g,f),b.parent().append(d)})}}),a(".caldera-editor-header").on("click",".column-sort .icon-edit",function(a){}),a(".layout-editor-body").on("tray_loaded",".layout-template-tray",function(){d()}),a(".caldera-editor-header").on("click",".caldera-editor-header-nav a",function(b){b.preventDefault();var c=a(this);a(".caldera-editor-header-nav li").removeClass("active"),a(".caldera-editor-body").hide(),a(c.attr("href")).show(),c.parent().addClass("active"),rebind_field_bindings()}),a("body").on("change",".required",function(){check_required_bindings(this)}),a("body").on("submit",".caldera-forms-options-form",function(b){var c=a(".required.has-error");c.length&&b.preventDefault()}),a(".caldera-editor-body").on("click",".add-toggle-option",function(b){var c=a(this);if(c.data("bulk"))return a(c.data("bulk")).toggle(),void a(c.data("bulk")).find("textarea").focus();var d=c.closest(".caldera-editor-field-config-wrapper"),e=d.find(".toggle-options"),f=a("#field-option-row-tmpl").html(),g=Handlebars.compile(f),h="opt"+parseInt(1048576*(Math.random()+1)),i={_name:"config[fields]["+d.prop("id")+"][config]",option:{}};if(c.data("options")){for(var j=a(c.data("options")),k=j.val().split("\n"),l=!1,m=0;m<k.length;m++){var n=k[m],o=n,p=o.split("|");p.length>1&&(o=p[0],n=p[1],l=!0),i.option["opt"+parseInt(1048576*(Math.random()+m))]={value:o,label:n,default:!1}}a(c.data("options")).parent().hide(),j.val(""),!0===l?d.find(".toggle_show_values").prop("checked",!0):d.find(".toggle_show_values").prop("checked",!1),e.empty()}else i.option[h]={value:"",label:"",default:!1};a(".preset_options").val(""),e.append(g(i)),d.find(".toggle_show_values").trigger("change"),a(".toggle-options").sortable({handle:".dashicons-sort"}),k||e.find(".toggle_label_field").last().focus()}),a(".caldera-editor-body").on("change",".preset_options",function(b){var c=a(this),d=c.val(),e=a(c.data("bulk"));preset_options&&preset_options[d]&&preset_options[d].data&&("object"==typeof preset_options[d].data&&preset_options[d].data.length&&(preset_options[d].data=preset_options[d].data.join("\n")),e.val(preset_options[d].data))}),a(".caldera-editor-body").on("click",".toggle-remove-option",function(b){var c=a(this).closest(".caldera-editor-field-config-wrapper").find(".field-config").first();a(this).parent().remove(),c.trigger("change"),a(document).trigger("option.remove")}),a(".caldera-editor-body").on("click",".page-toggle",function(b){var c=a(this),d=c.parent(),e=d.find(".button");e.removeClass("button-primary"),a(".layout-grid-panel").hide().removeClass("page-active"),a("#"+c.data("page")).show().addClass("page-active"),c.addClass("button-primary"),e.each(function(b,c){a(c).html(d.data("title")+" "+(b+1))}),1===e.length&&d.hide()}),a(".caldera-editor-body").on("blur toggle.values",".toggle_label_field",function(b){var c=a(this),d=c.prev();d.val().length||d.val(c.val())}),a(document).on("change focusout",".toggle_value_field",function(){a(document).trigger("show.fieldedit")}),a(document).on("show.fieldedit option.remove",function(b){a(".toggle_value_field.has-error").removeClass("has-error");for(var c=a("#"+a(".layout-form-field.field-edit-open").data("config")),d=c.find(".toggle_value_field"),e=c.find(".notice"),f=0,g=0;g<d.length;g++){for(var h=(d[g].value,0),i=0;i<d.length;i++)d[g]!==d[i]&&d[g].value===d[i].value&&(a(d[i]).addClass("has-error"),h++);h>0&&(a(d[g]).addClass("has-error"),f++)}f>0?(e.slideDown(),b.preventDefault()):e.slideUp()});var h=!1;focus_initial_field=function(b){var c=a(".layout-grid-panel .icon-edit").first();c.length?c.trigger("click"):(a(".layout-column.column-container").first().trigger("mouseover"),h=setInterval(e,500)),a(document).off("load.page",focus_initial_field)},a(document).on("load.page",focus_initial_field),cf_clear_puler=function(){h&&(clearTimeout(h),a(document).off("mouseover",".layout-new-form-field, .column-fieldinsert",cf_clear_puler)),a(".layout-new-form-field, .column-fieldinsert").fadeIn()},a(document).on("mouseover",".layout-new-form-field, .column-fieldinsert",cf_clear_puler),rebuild_field_binding(),a(document).trigger("load.page"),a("body").on("click",".caldera-processor-nav a",function(b){b.preventDefault();var c=a(this);a(".caldera-processor-nav").removeClass("active"),a(".caldera-editor-processor-config-wrapper").hide(),a(c.attr("href")).show(),c.parent().addClass("active")}),a("body").on("click",".add-new-processor",function(b){var c=a(this),d=Handlebars.compile(a("#processor-wrapper-tmpl").html());wrap=a(".active-processors-list"),process_conf=a(".caldera-editor-processor-config"),processid=Math.round(1e8*Math.random()),new_templ=Handlebars.compile(a("#processor-line-tmpl").html()),new_proc={id:"fp_"+processid,type:c.data("type")},wrap.append(new_templ(new_proc)),process_conf.append(d(new_proc)),a("#form_processor_baldrickModalCloser").trigger("click"),a(".caldera-processor-nav a").last().trigger("click"),a("#fp_"+processid+"_type").val(c.data("type")).trigger("change"),f(),baldrickTriggers()}),a("body").on("click",".delete-processor",function(b){var c=a(this),d=c.closest(".caldera-editor-processor-config-wrapper");d.data("type"),confirm(c.data("confirm"))&&(a("."+d.prop("id")).remove(),d.remove(),a(".caldera-processor-nav a").first().trigger("click"),rebuild_field_binding())}),a("body").on("change",".caldera-select-processor-type",function(b){var c=a(this),d=c.closest(".caldera-editor-processor-config-wrapper"),e=c.find('option[value="'+c.val()+'"]').text(),f=d.find(".caldera-editor-processor-title"),h=a(".caldera-processor-nav.active a");""===e&&(e=f.data("title")),f.html(e),h.html(e+' <span class="processor-line-number"></span>').parent().addClass("processor_type_"+c.val()),g(this),rebuild_field_binding()}),a(document).on("click","#cf-shortcode-preview",function(){a(this).focus().select()}),a(document).on("change",".cf-email-preview-toggle",function(){var b=a(this),c=a(".caldera-header-email-preview-button");b.is(":checked")?c.show().attr("aria-hidden","false").css("visibility","visible"):c.hide().attr("aria-hidden","true").css("visibility","hidden")}),rebuild_field_binding(),a(".caldera-select-processor-type").each(function(a,b){g(b)}),f()}),Handlebars.registerHelper("_field",function(a){var b=this,c="",d="",e="",f=this[a.hash.slug]?' data-default="'+this[a.hash.slug]+'"':"";a.hash.required&&(c=" required"),a.hash.exclude&&(e='data-exclude="'+a.hash.exclude+'"'),a.hash.array&&(d="[]","true"!==a.hash.array&&(f='value="'+a.hash.array+'"')),out="<select "+(a.hash.type?'data-type="'+a.hash.type+'"':"")+f+" "+e+' name="'+this._name+"["+a.hash.slug+"]"+d+'" id="'+this._id+"_"+a.hash.slug+'" class="block-input field-config caldera-field-bind'+c+'">',this[a.hash.slug]?out+='<option class="bound-field" value="'+this[a.hash.slug]+'" class="bound-field"></option>':a.hash.required||(out+='<option value=""></option>');for(var g in current_form_fields){var h="";a.hash.type&&current_form_fields[g].type!==a.hash.type||(b[a.hash.slug]&&b[a.hash.slug]===g&&(h=' selected="selected"'),out+='<option value="'+g+'"'+h+">"+current_form_fields[g].label+" ["+current_form_fields[g].slug+"]</option>")}return out+="</select>",a.hash.required&&(out+='<input class="field-config" name="'+this._name+'[_required_bounds][]" type="hidden" value="'+a.hash.slug+'">'),out}),Handlebars.registerHelper("console",function(a,b){console.log(this)});
1
+ function new_conditional_group(a){var b=a.trigger.data("id"),c="cl"+Math.round(18746582734*Math.random());return{group:[{id:"rw"+Math.round(98347598345*Math.random()),type:a.trigger.data("type"),lines:[{id:c}]}],id:b}}function new_conditional_line(a){var b=a.trigger.data("id"),c=a.trigger.data("group"),d=a.trigger.data("type"),e="cl"+Math.round(18746582734*Math.random());return{id:b,type:d,lineid:e,rowid:c,name:"config["+d+"]["+b+"][conditions][group]["+c+"]["+e+"]"}}function build_conditions_config(a){var b=JSON.parse(a.trigger.val());return b.id=a.trigger.data("id"),b}function pre_compile_templates(){for(var a=jQuery(".cf-editor-template"),b=0;b<a.length;b++)compiled_templates[a[b].id]=Handlebars.compile(a[b].innerHTML)}function get_compiled_template(a){return"object"!=typeof compiled_templates&&pre_compile_templates(),compiled_templates[a+"_tmpl"]?compiled_templates[a+"_tmpl"]:compiled_templates.noconfig_field_templ}function setup_field_type(a){return{id:a.trigger.prop("id")}}function check_required_bindings(a){var b,c=(jQuery(".caldera-header-save-button"),jQuery(".layout-form-field")),d=jQuery(".caldera-processor-nav"),e=!0;b=a?jQuery(a):jQuery(".caldera-config-field .required"),b.removeClass("has-error"),c.removeClass("has-error"),d.removeClass("has-error"),jQuery(".error-tag").remove(),required_errors={},b.each(function(a,b){var c=jQuery(b),d=c.closest(".caldera-config-editor-panel");if(b.value.length){if(c.hasClass("field-slug"))for(var f=jQuery(".field-slug").not(c),g=0;g<f.length;g++)if(f[g].value===b.value){var c=jQuery(f[g]);required_errors[d.prop("id")]||(required_errors[d.prop("id")]=0);var h=c.closest(".caldera-editor-field-config-wrapper"),i=c.closest(".caldera-editor-processor-config-wrapper");h.length&&jQuery('.layout-form-field[data-config="'+h.prop("id")+'"]').addClass("has-error"),i.length&&jQuery("."+i.prop("id")).addClass("has-error"),required_errors[d.prop("id")]+=1,c.addClass("has-error"),e=!1;break}if(c.hasClass("toggle_value_field"))for(var j=c.closest(".caldera-config-group").find(".toggle_value_field").not(c),g=0;g<j.length;g++)if(j[g].value===b.value){var c=jQuery(j[g]);required_errors[d.prop("id")]||(required_errors[d.prop("id")]=0);var h=c.closest(".caldera-editor-field-config-wrapper"),i=c.closest(".caldera-editor-processor-config-wrapper");h.length&&jQuery('.layout-form-field[data-config="'+h.prop("id")+'"]').addClass("has-error"),i.length&&jQuery("."+i.prop("id")).addClass("has-error"),required_errors[d.prop("id")]+=1,c.addClass("has-error"),e=!1;break}}else{required_errors[d.prop("id")]||(required_errors[d.prop("id")]=0);var h=c.closest(".caldera-editor-field-config-wrapper"),i=c.closest(".caldera-editor-processor-config-wrapper");h.length&&jQuery('.layout-form-field[data-config="'+h.prop("id")+'"]').addClass("has-error"),i.length&&jQuery("."+i.prop("id")).addClass("has-error"),required_errors[d.prop("id")]+=1,c.addClass("has-error"),e=!1}});for(var f in required_errors)jQuery(".caldera-forms-options-form").find('a[href="#'+f+'"]').append('<span class="error-tag">'+required_errors[f]+"</span>");return jQuery(".caldera-conditional-field-set").trigger("change"),e}function new_conditional_group(a){var b=a.trigger.data("id"),c="cl"+Math.round(18746582734*Math.random());return{group:[{id:"rw"+Math.round(98347598345*Math.random()),type:a.trigger.data("type"),lines:[{id:c}]}],id:b}}function new_conditional_line(a){var b=a.trigger.data("id"),c=a.trigger.data("group"),d=a.trigger.data("type"),e="cl"+Math.round(18746582734*Math.random());return{id:b,type:d,lineid:e,rowid:c,name:"config["+d+"]["+b+"][conditions][group]["+c+"]["+e+"]"}}function build_conditions_config(a){var b=JSON.parse(a.trigger.val());return b.id=a.trigger.data("id"),b}function setup_field_type(a){return{id:a.trigger.prop("id")}}function check_required_bindings(a){var b,c=(jQuery(".caldera-header-save-button"),jQuery(".layout-form-field")),d=jQuery(".caldera-processor-nav"),e=!0;b=a?jQuery(a):jQuery(".caldera-config-field .required"),b.removeClass("has-error"),c.removeClass("has-error"),d.removeClass("has-error"),jQuery(".error-tag").remove(),required_errors={},b.each(function(a,b){var c=jQuery(b),d=c.closest(".caldera-config-editor-panel");if(b.value.length){if(c.hasClass("field-slug"))for(var f=jQuery(".field-slug").not(c),g=0;g<f.length;g++)if(f[g].value===b.value){var c=jQuery(f[g]);required_errors[d.prop("id")]||(required_errors[d.prop("id")]=0);var h=c.closest(".caldera-editor-field-config-wrapper"),i=c.closest(".caldera-editor-processor-config-wrapper");h.length&&jQuery('.layout-form-field[data-config="'+h.prop("id")+'"]').addClass("has-error"),i.length&&jQuery("."+i.prop("id")).addClass("has-error"),required_errors[d.prop("id")]+=1,c.addClass("has-error"),e=!1;break}if(c.hasClass("toggle_value_field"))for(var j=c.closest(".caldera-config-group").find(".toggle_value_field").not(c),g=0;g<j.length;g++)if(j[g].value===b.value){var c=jQuery(j[g]);required_errors[d.prop("id")]||(required_errors[d.prop("id")]=0);var h=c.closest(".caldera-editor-field-config-wrapper"),i=c.closest(".caldera-editor-processor-config-wrapper");h.length&&jQuery('.layout-form-field[data-config="'+h.prop("id")+'"]').addClass("has-error"),i.length&&jQuery("."+i.prop("id")).addClass("has-error"),required_errors[d.prop("id")]+=1,c.addClass("has-error"),e=!1;break}}else{required_errors[d.prop("id")]||(required_errors[d.prop("id")]=0);var h=c.closest(".caldera-editor-field-config-wrapper"),i=c.closest(".caldera-editor-processor-config-wrapper");h.length&&jQuery('.layout-form-field[data-config="'+h.prop("id")+'"]').addClass("has-error"),i.length&&jQuery("."+i.prop("id")).addClass("has-error"),required_errors[d.prop("id")]+=1,c.addClass("has-error"),e=!1}});for(var f in required_errors)jQuery(".caldera-forms-options-form").find('a[href="#'+f+'"]').append('<span class="error-tag">'+required_errors[f]+"</span>");return jQuery(".caldera-conditional-field-set").trigger("change"),e}var cfAdminAJAX;cfAdminAJAX="object"==typeof CF_ADMIN?CF_ADMIN.adminAjax:ajaxurl,jQuery(document).ready(function(a){function b(b){var d=a(b),e=d.val(),f=d.closest(".caldera-editor-field-config-wrapper"),g=f.find(".caldera-config-field-setup"),h=get_compiled_template(e);if(config=f.find(".field_config_string").val(),current_type=d.data("type"),f.find(".caldera-config-group").show(),d.addClass("field-initialized"),config.length&&current_type===d.val()?config=JSON.parse(config):config=fieldtype_defaults[d.val()+"_cfg"],config||(config={}),config._id=d.data("field"),config._name="config[fields]["+d.data("field")+"][config]",h=a("<div>").html(h(config)),g.html(h.html()),"function"==typeof window[d.val()+"_init"]&&window[d.val()+"_init"](d.data("field"),g),fieldtype_defaults[d.val()+"_nosupport"]&&(fieldtype_defaults[d.val()+"_nosupport"].indexOf("hide_label")>=0&&f.find(".hide-label-field").hide().find(".field-config").prop("checked",!1),fieldtype_defaults[d.val()+"_nosupport"].indexOf("caption")>=0&&f.find(".caption-field").hide().find(".field-config").val(""),fieldtype_defaults[d.val()+"_nosupport"].indexOf("required")>=0&&f.find(".required-field").hide().find(".field-config").prop("checked",!1),fieldtype_defaults[d.val()+"_nosupport"].indexOf("custom_class")>=0&&f.find(".customclass-field").hide().find(".field-config").val(""),fieldtype_defaults[d.val()+"_nosupport"].indexOf("entry_list")>=0&&f.find(".entrylist-field").hide().find(".field-config").prop("checked",!1)),f.find(".toggle_show_values").trigger("change"),!a(".caldera-select-field-type").not(".field-initialized").length){if(core_form||(core_form=jQuery(".caldera-forms-options-form")),core_form.hasClass("builder-loaded"))c(d.data("field"));else{for(var i=a(".caldera-select-field-type.field-initialized"),j=0;j<i.length;j++)c(a(i[j]).data("field"));core_form.addClass("builder-loaded")}a(".caldera-header-save-button").prop("disabled",!1),rebuild_field_binding(),baldrickTriggers()}a(".color-field").length&&a(".color-field").wpColorPicker({change:function(b){var c=a(this);c.data("ev")&&clearTimeout(c.data("ev")),c.data("ev",setTimeout(function(){c.trigger("record")},200)),c.data("target")&&(a(c.data("target")).css(c.data("style"),c.val()),a(c.data("target")).val(c.val()))}})}function c(b){var c=a("#"+b),d=c.find(".caldera-select-field-type"),e=d.val(),f=a('.layout-form-field[data-config="'+b+'"]'),g=f.find(".field_preview"),h=(a("#preview-"+e+"_tmpl").html(),get_compiled_template("preview-"+e)),i={id:b},j=c.find(".field-config");j.each(function(c,d){for(var e=a(d),f=e.prop("name").split("["+b+"]")[1].substr(1),g=f.substr(0,f.length-1).split("]["),h=e.is(":checkbox,:radio")?e.filter(":checked").val():e.val(),j={},k=g.length-1;k>=0;k--)if(k===g.length-1)j[g[k]]=h;else{var l=j;j={},j[g[k]]=l}a.extend(!0,i,j)}),g.html(h(i)),f.removeClass("button"),a(".preview-field-config").prop("disabled",!0)}function d(b){var c,d=a(".caldera-editor-fields-panel"),e=(a(".caldera-editor-groups-panel"),a(".caldera-group-nav")),f=a('[data-group="'+b+'"]'),g=f.find(".caldera-config-group-name"),h=f.find(".caldera-config-group-slug"),i=f.find(".caldera-config-group-desc"),j=f.find(".caldera-config-group-admin"),k=a(".active-group-name"),l=a(".active-group-slug"),m=a(".active-group-desc"),n=a(".active-group-admin"),o=a(".caldera-editor-fields-list ul"),p=f.find(".caldera-config-group-repeat"),q=a(".repeat-config-button"),r=(a(".caldera-editor-group-settings"),a(".caldera-config-group-remove"));a(".new-group-input").remove(),a(".new-field-input").remove(),e.removeClass("active"),d.show(),o.hide(),o.removeClass("active").find("li.active").removeClass("active"),o.hide(),f.addClass("active"),c=a(".caldera-editor-fields-list ul.active li"),c.length?r.hide():r.show(),a(".caldera-editor-field-config-wrapper").hide(),f.show(),k.val(g.val()),l.val(h.val()),m.val(i.val()),"1"===j.val()?n.prop("checked",!0):n.prop("checked",!1),"1"===p.val()?q.addClass("field-edit-open"):q.removeClass("field-edit-open")}a(".caldera-header-save-button").baldrick({method:"POST",request:"admin.php?page=caldera-forms",before:function(b,c){if(c.preventDefault(),!check_required_bindings())return!1;a("#save_indicator").addClass("loading"),"undefined"!=typeof tinyMCE&&tinyMCE.triggerSave();var d=a(".caldera-forms-options-form").formJSON();return d.conditions&&(d.config.conditional_groups={conditions:d.conditions}),a(b).data("cf_edit_nonce",d.cf_edit_nonce),a(b).data("_wp_http_referer",d._wp_http_referer),a(b).data("sender","ajax"),a(b).data("config",JSON.stringify(d.config)),!0},callback:function(b){if(!1===b.data){var c=a(".updated_notice_box");c.stop().animate({top:0},200,function(){setTimeout(function(){c.stop().animate({top:-75},200)},2e3)})}},complete:function(b){a(".wrapper-instance-pane .field-config").prop("disabled",!1)}}),a("body").on("click",".toggle_processor_event input",function(b){var c=a(this),d=c.closest(".wrapper-instance-pane"),e=d.find(".caldera-config-processor-setup"),f=d.find(".caldera-config-processor-notice");c.is(":checked")?(c.parent().addClass("activated"),c.parent().find(".is_active").show().attr("aria-hidden",!1).css("visibility","visible"),c.parent().find(".not_active").hide().attr("aria-hidden",!0).css("visibility","hidden")):(c.parent().removeClass("activated"),c.parent().find(".is_active").hide().attr("aria-hidden",!0).css("visibility","hidden"),c.parent().find(".not_active").show().attr("aria-hidden",!1).css("visibility","visible")),d.find(".toggle_processor_event .activated").length?(e.slideDown(100),f.slideUp(100)):(e.slideUp(100),f.slideDown(100))}),a("body").on("click",".toggle_option_tab > a",function(b){b.preventDefault();var c=a(this),d=a(c.attr("href")),e=c.parent().find("a"),f=c.closest(".caldera-editor-config-wrapper").find(".wrapper-instance-pane");e.removeClass("button-primary"),f.hide(),d.show(),c.addClass("button-primary"),a(".caldera-conditionals-usetype").trigger("change")}),a(".caldera-editor-body").on("change",".caldera-select-field-type",function(a){b(this)}),a(".caldera-editor-body").on("click",".caldera-group-nav a",function(b){b.preventDefault(),d(a(this).attr("href").substr(1))}),a(".caldera-editor-body").on("click",".caldera-editor-fields-list a",function(b){b.preventDefault();var c=a(this),d=a(c.attr("href"));a(".new-group-input").remove(),a(".new-field-input").remove(),a(".caldera-editor-fields-list li.active").removeClass("active"),c.parent().addClass("active"),a(".caldera-editor-field-config-wrapper").hide(),d.show()}),a(".caldera-editor-body").on("click",".group-config-button",function(b){var c=a(this),d=a(".caldera-editor-group-settings"),e=c.closest(".caldera-editor-fields-panel"),f=a(".caldera-config-group-remove");e.find(".caldera-field-line").length?f.hide():f.show(),c.hasClass("field-edit-open")?(d.slideUp(100),c.removeClass("field-edit-open")):(d.slideDown(100),c.addClass("field-edit-open"))}),a(".caldera-editor-body").on("keydown",".field-config",function(b){a(this).is("textarea")||13===b.which&&b.preventDefault()}),a(".caldera-editor-body").on("change",".field-label",function(b){var c=a(this).closest(".caldera-editor-field-config-wrapper").prop("id");field_line=a('[data-field="'+c+'"]'),field_title=a("#"+c+" .caldera-editor-field-title, .layout-form-field.field-edit-open .layout_field_name"),slug=a("#"+c+" .field-slug"),field_line.find("a").html('<i class="icn-field"></i> '+this.value),field_title.text(this.value),"change"===b.type&&slug.trigger("change"),rebuild_field_binding()}),a(".caldera-editor-body").on("change",".active-group-name",function(b){b.preventDefault();var c=a(".caldera-group-nav.active"),d=(c.data("group"),c.find(".caldera-config-group-name")),e=c.find("span");"focusout"!==b.type||this.value.length||(this.value="Group "+(parseInt(c.index())+1)),d.val(this.value),e.text(this.value)}),a(".caldera-editor-body").on("change",".active-group-slug",function(b){b.preventDefault();var c=a(".caldera-group-nav.active"),d=(c.data("group"),c.find(".caldera-config-group-name").val()),e=c.find(".caldera-config-group-slug"),f=(c.find("span"),this.value.split(" ").join("_").split("-").join("_").replace(/[^a-z0-9_]/gi,"").toLowerCase());"focusout"!==b.type||this.value.length||(f=d.split(" ").join("_").split("-").join("_").replace(/[^a-z0-9_]/gi,"").toLowerCase()),e.val(f),this.value=f}),a(".caldera-editor-body").on("change",".active-group-desc",function(b){b.preventDefault();var c=a(".caldera-group-nav.active");c.data("group");c.find(".caldera-config-group-desc").val(this.value)}),a(".caldera-editor-body").on("change",".active-group-admin",function(b){b.preventDefault();var c=a(".caldera-group-nav.active"),d=(c.data("group"),c.find(".caldera-config-group-name").val(),c.find(".caldera-config-group-admin"));c.find("span"),this.value.split(" ").join("_").split("-").join("_").replace(/[^a-z0-9_]/gi,"").toLowerCase();a(this).prop("checked")?(d.val(1),c.addClass("is-admin")):(d.val(0),c.removeClass("is-admin"))}),a(".caldera-editor-body").on("click",".repeat-config-button",function(b){b.preventDefault();var c=a(".caldera-group-nav.active"),d=(c.data("group"),c.find("a .group-type")),e=c.find(".caldera-config-group-repeat"),f=a(this);f.hasClass("field-edit-open")?(e.val("0"),d.removeClass("icn-repeat").addClass("icn-folder"),f.removeClass("field-edit-open")):(e.val("1"),d.addClass("icn-repeat").removeClass("icn-folder"),f.addClass("field-edit-open"))}),a(".caldera-editor-body").on("click",".delete-field",function(){var b=a(this),c=b.closest(".caldera-editor-field-config-wrapper").prop("id");confirm(b.data("confirm"))&&(a("#"+c).remove(),a('option[value="'+c+'"]').remove(),a('[data-bind="'+c+'"]').remove(),delete current_form_fields[c],a('[data-config="'+c+'"]').slideUp(200,function(){a(this).remove(),rebuild_field_binding(),a(document).trigger("field.removed")}))}),a(".caldera-editor-body").on("click",".add-new-group,.add-field",function(){var b=a(this);if(a(".new-group-input").remove(),a(".new-field-input").remove(),b.hasClass("add-field")){a('<input type="text" class="new-field-input block-input">').appendTo(a(".caldera-editor-fields-list ul.active")).focus()}else{a('<input type="text" class="new-group-input block-input">').appendTo(a(".caldera-editor-groups-panel")).focus()}}),a(".caldera-editor-body").on("change keypress",".new-group-input",function(b){if("keypress"===b.type){if(13!==b.which)return;b.preventDefault()}var c,e,f=this.value,g=a(this),h=a(".caldera-editor-groups-panel ul"),i=a(".caldera-editor-fields-list");if(f.length){c=Handlebars.compile(a("#caldera_group_line_templ").html()),e={id:f.split(" ").join("_").split("-").join("_").replace(/[^a-z0-9_]/gi,"").toLowerCase(),name:f},h.append(c(e));a('<ul data-group="'+e.id+'">').hide().appendTo(i),g.remove(),d(e.id)}else g.remove()}),a(".caldera-editor-body").on("change keypress",".new-field-input",function(b){if("keypress"===b.type){if(13!==b.which)return;b.preventDefault()}var c,d,e,f=this.value,g=a(this),h=g.parent(),i=a(".caldera-editor-field-config"),j=a(".caldera-config-group-remove");if(f.length){j.hide(),c=Handlebars.compile(a("#caldera_field_line_templ").html()),d=Handlebars.compile(a("#caldera_field_config_wrapper_templ").html()),e={id:f.split(" ").join("_").split("-").join("_").replace(/[^a-z0-9_]/gi,"").toLowerCase(),label:f,slug:f.split(" ").join("_").split("-").join("_").replace(/[^a-z0-9_]/gi,"").toLowerCase(),group:a(".caldera-group-nav.active").data("group")};var k=a(c(e));k.appendTo(h),i.append(d(e)),k.find("a").trigger("click"),g.remove()}else g.remove()}),a(".caldera-editor-body").on("change",".field-slug",function(b){this.value.length?this.value=this.value.split(" ").join("_").split("-").join("_").replace(/[^a-z0-9_]/gi,"").toLowerCase():"change"===b.type&&(this.value=a(this).closest(".caldera-editor-field-config-wrapper").find(".field-label").val().split(" ").join("_").split("-").join("_").replace(/[^a-z0-9_]/gi,"").toLowerCase())}),a(".caldera-editor-body").on("click",".caldera-add-group",function(b){var c=a(this),d=c.data("group"),e=a("#"+d+"_panel_tmpl").html();c.parent().parent().append(e)}),a(".caldera-editor-body").on("click",".caldera-config-group-remove",function(b){var c=a(".active-group-slug").val();a('[data-group="'+c+'"]').hide(0,function(){a(this).remove();var b=a(".caldera-group-nav");b.length?b.first().find("a").trigger("click"):a(".caldera-editor-fields-panel").hide()})}),a("body").on("click",".set-current-field",function(b){b.preventDefault();var c=a(this);a("#"+c.data("field")+"_type").val(c.data("type")).trigger("change"),a("#"+c.data("field")+"_lable").focus(),a("#field_setup_baldrickModalCloser").trigger("click")}),a(".caldera-editor-body").on("change record",".field-config",function(b){var d=a(this),e=d.closest(".caldera-editor-field-config-wrapper");current_form_fields&&(d.prop("id")===e.prop("id")+"_lable"&&(current_form_fields[e.prop("id")].label=this.value),d.prop("id")===e.prop("id")+"_slug"&&(current_form_fields[e.prop("id")].slug=this.value),d.prop("id")===e.prop("id")+"_type"&&(current_form_fields[e.prop("id")].type=this.value),e.length&&c(e.prop("id")))}),a(".caldera-editor-body").on("focus",".caldera-field-bind",function(b){var c=a(this),d=this.value;if(b.type&&"focusin"===b.type)return c.removeClass("bound_field").addClass("reload-binding"),rebind_field_bindings(),void(this.value=d)}),a(".caldera-editor-body").on("change",".caldera-conditional-field-set",function(b){var c,d,e=a(this),f=e.parent().find(".compare-type"),g=e.data("condition"),h=e.data("id"),i="config["+g+"]["+h+"][conditions][group]["+e.data("row")+"]["+e.data("line")+"]",j=e.data("line"),k=a("#"+j+"_value"),l=k.find(".caldera-conditional-value-field").first(),m=[],n=this.value;if("{"!==n.substr(0,1)&&(c=a("#"+n),d=c.find(".field-button-type"),m=c.find(".caldera-config-group-toggle-options")),e.hasClass(".bind_init")&&e.addClass("bound_triggered"),l.length&&l.val().length&&k.data("value",l.val()),f.show(),m.length){var o=m.find(".toggle_option_row"),p='<select name="'+i+'[value]" class="caldera-processor-value-bind caldera-conditional-value-field" data-field="'+n+'" style="max-width: 220px; width: 220px;">';p+='<option value=""></option>',o.each(function(b,c){var d=a(c).find(".toggle_label_field"),e=d.data("option"),f="";k.data("value")&&(k.data("value").toString()!==e&&k.data("value").toString()!==a(c).find(".toggle_value_field").val()||(f=' selected="selected"')),p+='<option value="'+e+'"'+f+">"+d.val()+"</option>"}),p+="</select>"}else d&&"button"==d.val()?(f.val("is").hide(),p='<select name="'+i+'[value]" class="caldera-processor-value-bind caldera-conditional-value-field" data-field="'+n+'" style="max-width: 220px; width: 220px;">',p+='<option value="click" '+("click"===k.data("value")?'selected="selected"':"")+">Click</option>",p+='<option value="dblclick" '+("dblclick"===k.data("value")?'selected="selected"':"")+">Double Click</option>",p+="</select>"):p='<input name="'+i+'[value]" type="text" class="caldera-conditional-value-field magic-tag-enabled" value="'+(k.data("value")?k.data("value"):"")+'" style="max-width: 205px;">';k.html(p),init_magic_tags()}),a(".caldera-editor-body").on("change",".caldera-conditionals-usetype",function(b){var c=a(this);"show"===this.value||"hide"===this.value||"disable"===this.value||"use"===this.value||"not"===this.value?(a("#"+c.data("id")+"_condition_group_add").show(),a("#"+c.data("id")+"_conditional_wrap").show()):(a("#"+c.data("id")+"_condition_group_add").hide(),a("#"+c.data("id")+"_conditional_wrap").hide())}),a(".caldera-editor-body").on("click",".remove-conditional-line",function(b){b.preventDefault();var c=a(this),d=c.closest(".caldera-condition-line"),e=c.closest(".caldera-condition-group");d.remove(),e.find(".caldera-condition-line").length||e.remove()}),a(".caldera-group-nav").first().find("a").trigger("click"),a(".caldera-editor-body").on("change",".toggle_show_values",function(b){var c=a(this),d=c.closest(".caldera-config-group-toggle-options");values=d.find(".toggle_value_field"),lables=d.find(".toggle_label_field"),field_lables=d.find(".caldera-config-group-option-labels"),c.prop("checked")?(values.show().parent().show(),values.show().parent().parent().show(),lables.css("width",""),field_lables.show()):(values.hide().parent().hide(),lables.css("width",245),field_lables.hide()),lables.trigger("toggle.values"),init_magic_tags()}),a(".caldera-editor-body").on("change",".auto-populate-type",function(){a(this).closest(".wrapper-instance-pane").find(".auto-populate-options").trigger("change")}),a(".caldera-editor-body").on("change",".auto-populate-options",function(){var b=a(this),c=b.closest(".wrapper-instance-pane"),d=c.find(".caldera-config-group-toggle-options"),e=c.find(".caldera-config-group-auto-options"),f=e.find(".auto-populate-type");e.find(".auto-populate-type-panel").hide(),b.prop("checked")?(d.hide(),e.show()):(d.show(),e.hide()),e.find(".caldera-config-group-auto-"+f.val()).show()}),a("body").on("change",".pin-toggle-roles",function(){var b=a(this),c=a("#caldera-pin-rules");"1"===b.val()?c.show():c.hide()}),a("body").on("click",".magic-tag-init",function(b){a(this).prev().focus().trigger("init.magic")}),a("body").on("keyup focus select click init.magic",".magic-tag-enabled",function(b){init_magic_tags();var c=a(this),d=c.parent(),e=d.closest(".wrapper-instance-pane").find(".caldera-select-field-type").val()?d.closest(".wrapper-instance-pane").find(".caldera-select-field-type").val():"hidden",f=d.find(".magic-tags-autocomplete"),g=f.find("ul"),h=this.value,i=[],j="",k=this.selectionStart,l=this.selectionEnd;if(f.length&&f.data("focus"))return void b.preventDefault();if(c.data("tag",""),this.selectionEnd>this.selectionStart)j=this.value.substr(this.selectionStart,this.selectionEnd-this.selectionStart);else if(("select"===b.type||"keyup"===b.type)&&40!==b.which&&38!==b.which&&39!==b.which&&37!==b.which){for(k=this.selectionStart;k>0;k--){var m=h.substr(k-1,1);if(" "===m||"\n"===m||("%"===m||"}"===m)&&this.selectionStart===k)break}for(l=this.selectionStart;l<h.length;l++){var m=h.substr(l,1);if(" "===m||"\n"===m||("%"===m||"{"===m)&&this.selectionStart===l)break}j=h.substr(k,l-k)}if("focusout"!==b.type){"init"!==b.type&&j.length<3&&f.length&&f.remove(),f.length||(f=a('<div class="magic-tags-autocomplete"></div>'),g=a("<ul></ul>"),g.appendTo(f),f.insertAfter(c),f.on("mouseenter",function(){a(this).data("focus",!0)}),f.on("mouseleave",function(){a(this).data("focus",!1),setTimeout(function(){f.remove()},200),c.is(":focus")||c.trigger("focusout")})),g.empty();var n="system",o=!1;"hidden"===e||"dropdown"===e||"radio"===e||"toggle_switch"===e||"checkbox"===e?(o=!0,e="text",n="all"):"paragraph"!==e&&"html"!==e||(e="text"),c.data("type")&&(e=c.data("type")),e=e.split(","),e.push("vars");for(var p=0;p<e.length;p++)for(var q in system_values)if(void 0!==system_values[q].tags&&void 0!==system_values[q].tags[e[p]]){if(i=[q],"system"!==q&&"variable"!==q&&"field"!==q){var r=jQuery(".processor-"+q),s=c.closest(".caldera-editor-processor-config-wrapper"),t=s.prop("id");i=[];for(var u=0;u<r.length;u++)if(s.length||!0!==o){if(t===r[u].id)continue;jQuery("li."+r[u].id).index()<jQuery("li."+t).index()&&i.push(r[u].id)}else i.push(r[u].id)}for(var v=0;v<i.length;v++)if("all"===n||n===q||"variable"===q){var w=a('<li class="header">'+system_values[q].type+(v>0?" ["+(v+1)+"]":"")+"</li>"),x=0;w.appendTo(g);for(var y=0;y<system_values[q].tags[e[p]].length;y++)if(!c.data("parent")||"variable:"+c.data("parent")!==system_values[q].tags[e[p]][y]){var z=system_values[q].wrap[0]+system_values[q].tags[e[p]][y]+system_values[q].wrap[1];if(i[v]!==q&&i.length>1&&(z=system_values[q].wrap[0]+system_values[q].tags[e[p]][y]+":"+i[v]+system_values[q].wrap[1]),z.indexOf(j)>=0||"init"===b.type){x+=1;var A=z.replace(j,"<strong>"+j+"</strong>"),B=a('<li class="tag" data-tag="'+z+'">'+A+"</li>");B.on("click",function(){var b=a(this).data("tag");c.val(h.substr(0,k)+b+h.substr(l)).trigger("change").focus(),c[0].selectionStart=k+b.length-(b.indexOf("*")>0?2:0),c[0].selectionEnd=k+b.length-(b.indexOf("*")>0?1:0),l=k=c[0].selectionEnd,h+=b,c.trigger("init.magic")}),B.appendTo(g)}}0===x&&w.remove()}}}g.children().length||f.remove(),"focusout"===b.type&&setTimeout(function(){f.remove()},200)}),pre_compile_templates(),a(".caldera-select-field-type").not(".field-initialized").each(function(a,c){b(c)})});var rebuild_field_binding,rebind_field_bindings,current_form_fields={},required_errors={},add_new_grid_page,add_page_grid,init_magic_tags,core_form,compiled_templates={};init_magic_tags=function(){jQuery(".magic-tag-enabled").each(function(a,b){var c=jQuery(b);if(c.hasClass("magic-tag-init-bound")){var d=c.parent().find(".magic-tag-init");return void(c.is(":visible")?d.show():d.hide())}var e=jQuery('<span class=""></span>'),f=jQuery('<span style="position:relative;display:inline-block; width:100%;"></span>');c.is("input")&&e.css("borderBottom","none"),c.hasClass("caldera-conditional-value-field")&&f.width("auto"),c.wrap(f),e.insertAfter(c),c.addClass("magic-tag-init-bound"),c.is(":visible")?e.show():e.hide()})},rebuild_field_binding=function(){if(core_form||(core_form=jQuery(".caldera-forms-options-form")),core_form.hasClass("builder-loaded")){var a=jQuery(".caldera-editor-field-config-wrapper");system_values.field={tags:{text:[]},type:"Fields",wrap:["%","%"]};for(var b=0;b<a.length;b++){var c=a[b].id,d=jQuery("#"+c+"_lable").val(),e=jQuery("#"+c+"_slug").val(),f=jQuery("#"+c+"_type").val();void 0===system_values.field.tags[f]&&(system_values.field.tags[f]=[]),system_values.field.tags[f].push(e),"text"!==f&&system_values.field.tags.text.push(e),current_form_fields[c]={label:d,slug:e,type:f},jQuery("option.bound-field").trigger("change").each(function(a,b){var c=jQuery(b);0!==c.prop("value").indexOf("{")?c.text(jQuery("#"+c.prop("value")+"_lable").val()+" ["+jQuery("#"+c.prop("value")+"_lable").val()+"]"):c.text(c.prop("value").replace("{","").replace("}",""))}).removeClass("bound-field")}}},rebind_field_bindings=function(){var a,b,c=jQuery(".caldera-field-bind").not(".bound_field");if(c.length){c.addClass("bound_field");for(var d=0;d<c.length;d++){var e=jQuery(c[d]),f=e.val(),g=e.data("default"),h=e.data("exclude"),i=0,j=e.closest(".caldera-editor-processor-config-wrapper"),k=j.prop("id"),l="";if(g&&!e.hasClass("reload-binding")&&(f=g),e.is("select")){e.empty();var m=jQuery('<optgroup label="Fields">');for(var n in current_form_fields)e.data("type")&&e.data("type").split(",").indexOf(current_form_fields[n].type)<0||(e.data("id")!==n&&m.append('<option value="'+n+'"'+(f===n?'selected="selected"':"")+">"+current_form_fields[n].label+" ["+current_form_fields[n].slug+"]</option>"),i+=1);m.appendTo(e),0===i&&e.empty();for(var o in system_values)if(a=[],!(h&&h.split(",").indexOf(o)>=0)){if("system"!==o&&"variable"!==o)for(var p=jQuery(".processor-"+o),q=0;q<p.length;q++)k!==p[q].id&&(a.push(p[q].id),p.length>1&&(b=jQuery("li."+p[q].id+" .processor-line-number"))&&b.html("["+(q+1)+"]"));else a.push("__system__");var r=[];e.data("type")?(r=e.data("type").split(","),r.push("vars")):r=["text","vars"];for(var s=0;s<r.length;s++)if(system_values[o].tags&&system_values[o].tags[r[s]])for(var t=0;t<a.length;t++){jQuery("li."+a[t]).index()>jQuery("li."+k).index()&&"__system__"!==a[t]?e.closest(".caldera-editor-processors-panel-wrap").length&&(l=' disabled="disabled"'):l="";for(var m=jQuery('<optgroup label="'+system_values[o].type+("__system__"!==a[t]?" "+jQuery("li."+a[t]).find(".processor-line-number").html():"")+'"'+l+">"),u=0;u<system_values[o].tags[r[s]].length;u++){var v=system_values[o].tags[r[s]][u];"__system__"!==a[t]&&(v=v.replace(o,a[t])),m.append('<option value="{'+v+'}"'+(f==="{"+v+"}"?'selected="selected"':"")+l+">"+system_values[o].tags[r[s]][u]+"</option>"),i+=1}m.children().length&&m.appendTo(e)}}if(0===i){if(e.empty(),e.data("type")){e.append('<option value="">No '+e.data("type").split(",").join(" or ")+" in form</option>");var w=!0}}else e.prop("disabled",!1);e.hasClass("required")||void 0!==w||e.prepend('<option value=""></option>'),e.val(f)}}init_magic_tags(),jQuery(document).trigger("bound.fields"),jQuery(".caldera-header-save-button").prop("disabled",!1)}},jQuery(document).ready(function(a){function b(){var b=a(".layout-grid-panel"),c=0;b.each(function(b,d){var e=a(d),f=e.find(".layout-structure"),g=e.find(".row"),h=[];g.each(function(b,d){var e=a(d),f=e.children().not(".column-merge"),g=[];c+=1,f.each(function(b,d){span=a(d).attr("class").split("-"),g.push(span[2]);var e=a(d).find(".field-location");e.length&&e.each(function(d,e){a(e).val(c+":"+(b+1)).removeAttr("disabled")})}),h.push(g.join(":"))}),f.val(h.join("|"))})}function c(b,c,e){var f,g,h="fld_"+Math.round(1e7*Math.random()),i=h,j=a("#field_config_panels");b.prop("id","").prop("title",""),f=Handlebars.compile(a("#caldera_field_config_wrapper_templ").html()),g=a.extend({},{id:i,label:"",slug:""},e),g.slug="",j.append(f(g)),b.removeClass("button-small").removeClass("button").removeClass("button-primary").removeClass("ui-draggable").removeClass("layout-new-form-field").addClass("layout-form-field").attr("data-config",h).css({display:"",opacity:""}),b.find(".layout_field_name").remove(),b.find(".field-location").prop("name","config[layout_grid][fields]["+h+"]"),b.find(".settings-panel").show(),b.appendTo(c),d(),b.find(".icon-edit").trigger("click"),a("#"+h+"_lable").focus().select(),baldrickTriggers(),a(document).trigger("field.added"),e?a("#"+i+"_type").data("type",g.type).trigger("change"):a("#"+h).trigger("field.drop"),rebuild_field_binding()}function d(){a(".toggle-options").sortable({handle:".dashicons-sort"}),a("#grid-pages-panel").sortable({placeholder:"row-drop-helper",handle:".sort-handle",items:".first-row-level",axis:"y",stop:function(){b()}}),a(".layout-column").sortable({connectWith:".layout-column",appendTo:"#grid-pages-panel",helper:"clone",items:".layout-form-field",handle:".drag-handle",cursor:"move",opacity:.7,cursorAt:{left:100,top:15},start:function(a,b){b.helper.css({width:"200px",height:"35px",paddingTop:"20px"})},
2
+ stop:function(a,c){c.item.removeAttr("style"),b()}}),a("h3 .layout-new-form-field").draggable({helper:"clone",appendTo:"body"}),a(".page-toggle.button").droppable({accept:".layout-form-field",over:function(b,c){a(this).trigger("click"),a(".layout-column").sortable("refresh")}}),a(".layout-column").droppable({greedy:!0,activeClass:"ui-state-dropper",hoverClass:"ui-state-hoverable",accept:".layout-new-form-field",drop:function(b,d){c(d.draggable.clone(),a(this))}}),b()}function e(){if(h){var b=a(".column-fieldinsert");b.length?(b.stop().fadeToggle(700),a(".layout-new-form-field").stop().fadeToggle(700)):cf_clear_puler()}}function f(){a(".caldera-editor-processors-panel ul").sortable({update:function(){rebuild_field_binding()}})}function g(b){var c=a(b),d=a("#"+c.val()+"-tmpl").length?a("#"+c.val()+"-tmpl").html():"",e=c.closest(".caldera-editor-processor-config-wrapper"),f=e.find(".caldera-config-processor-setup"),g=Handlebars.compile(d),h=e.find(".processor_config_string").val(),i=c.data("type");h=h.length&&i===c.val()?JSON.parse(h):processor_defaults[c.val()+"_cfg"],h||(h={}),h._id=e.prop("id"),h._name="config[processors]["+e.prop("id")+"][config]",g=a("<div>").html(g(h)),f.html(g.html()),"function"==typeof window[c.val()+"_init"]&&window[c.val()+"_init"](e.prop("id"),f),e.find(".no-conditions").length&&e.find(".toggle_option_tab").remove(),rebuild_field_binding(),baldrickTriggers(),a(".wp-baldrick").baldrick({request:cfAdminAJAX,method:"POST",before:function(b){var c=a(b);c.data("addNode")&&!c.data("request")&&c.data("request","cf_get_default_setting")}})}add_new_grid_page=function(a){return{page_no:"pg_"+Math.round(1e7*Math.random())}},add_page_grid=function(b){var c=a(".page-toggle").length+1,e=a('<button type="button" data-name="Page '+c+'" data-page="'+b.rawData.page_no+'" class="page-toggle button">'+b.params.trigger.data("addtitle")+" "+c+"</button> "),f=a("#page-toggles");e.appendTo(f),f.show(),d(),e.trigger("click"),1===c&&f.hide(),a(document).trigger("add.page")},a(document).on("remove.page add.page load.page",function(b){var c=a(".page-toggle").length,d=a("#tab_pages");c<=1?d.hide():d.show()}),d(),a("#grid-pages-panel").on("click",".column-fieldinsert .dashicons-plus-alt",function(b){var d=a(this).closest(".column-container");c(a("#newfield-tool").clone().css("display",""),d)}),a("#grid-pages-panel").on("click",".column-split",function(b){var c=a(this).parent().parent(),e=c.attr("class").split("-"),f=a("<div>").insertAfter(c),g=Math.ceil(e[2]/2),h=Math.floor(e[2]/2);e[2]=g,c.attr("class",e.join("-")),e[2]=h,f.addClass(e.join("-")).append('<div class="layout-column column-container">'),a(this).remove(),d(),jQuery(".column-tools").remove(),jQuery(".column-merge").remove()}),a("#grid-pages-panel").on("click",".column-remove",function(c){var d=a(this).closest(".row"),e=d.find(".layout-form-field"),f=d.closest(".layout-grid-panel");if(e.length){if(!confirm(a("#row-remove-fields-message").text()))return;e.each(function(b,c){var d=a(c).data("config");a("#"+d).remove(),a('option[value="'+d+'"]').remove(),a('[data-bind="'+d+'"]').remove(),delete current_form_fields[d]})}d.slideUp(200,function(){if(a(this).remove(),b(),rebuild_field_binding(),!f.find(".row").length){f.remove();var c=a("#page-toggles .button-primary"),d=c.prev(),e=c.next();c.remove(),d.length?d.trigger("click"):e.trigger("click")}a(document).trigger("remove.page")}),jQuery(".column-tools").remove(),jQuery(".column-merge").remove()}),a(".caldera-config-editor-main-panel").on("click",".caldera-add-row",function(c){if(c.preventDefault(),!a(".page-active").length)return void a(".caldera-add-page").trigger("click");var e=a('<div style="display:none;" class="first-row-level row"><div class="col-xs-12"><div class="layout-column column-container"></div></div></div>');a(".page-active").append(e),e.slideDown(200),d(),b()}),a("#grid-pages-panel").on("click",".column-join",function(c){var d=a(this).parent().parent().parent(),e=d.prev(),f=e.attr("class").split("-"),g=d.attr("class").split("-");f[2]=parseFloat(f[2])+parseFloat(g[2]),d.find(".layout-column").contents().appendTo(e.find(".layout-column")),e.attr("class",f.join("-")),d.remove(),b(),jQuery(".column-tools").remove(),jQuery(".column-merge").remove()}),a("#grid-pages-panel").on("mouseenter",".row",function(c){var d=jQuery(this);jQuery(".column-tools,.column-merge").remove(),d.children().children().first().append('<div class="column-remove column-tools" data-placement="top" title="'+CF_ADMIN_TOOLTIPS.delete_row+'" ><i class="icon-remove"></i></div>'),d.children().children().last().append('<div class="column-sort column-tools" style="text-align:right;"><i class="dashicons dashicons-menu drag-handle sort-handle"></i></div>'),d.children().children().not(":first").prepend('<div class="column-merge"><div class="column-join column-tools"><i class="icon-join"></i></div></div>');var e=d.parent().parent().parent().width()/12-1;d.children().children().each(function(b,c){var d=a(c),e=d.width()/2-5;d.prepend('<div class="column-fieldinsert column-tools"><i class="dashicons dashicons-plus-alt" data-toggle="tooltip" data-placement="top" title="'+CF_ADMIN_TOOLTIPS.add_field_row+'"></i></div>'),d.parent().hasClass("col-xs-1")||(d.prepend('<div class="column-split column-tools" data-placement="top" title="'+CF_ADMIN_TOOLTIPS.split_row+'"><i class="dashicons dashicons-leftright"></i></div>'),d.find(".column-split").css("left",e))}),jQuery(".column-merge").draggable({axis:"x",helper:"clone",appendTo:d,grid:[e,0],drag:function(c,d){a(this).addClass("dragging"),a(".column-tools").remove(),a(".column-split").remove();var e=a(this).parent().parent(),f=d.helper,g=d.originalPosition.left>f.position().left?"left":"right",h=e.prev(),i=Math.round(e.parent().width()/12-10),j=Math.abs(d.originalPosition.left-f.position().left);if(e.parent().addClass("sizing"),j>=i){var k=h.attr("class").split("-"),l=e.attr("class").split("-");k[2]=parseFloat(k[2]),l[2]=parseFloat(l[2]),"left"===g?(k[2]--,l[2]++,k[2]>0&&k[2]<k[2]+l[2]?(h.attr("class",k.join("-")),e.attr("class",l.join("-")),d.originalPosition.left=f.position().left):a(this).draggable("option","disabled",!0)):(k[2]++,l[2]--,l[2]>0&&l[2]<l[2]+l[2]?(h.attr("class",k.join("-")),e.attr("class",l.join("-")),d.originalPosition.left=f.position().left):a(this).draggable("option","disabled",!0)),b()}},stop:function(){a(this).removeClass("dragging").parent().parent().parent().removeClass("sizing")}})}),a("#grid-pages-panel").on("mouseleave",".row",function(a){jQuery(".column-tools").remove(),jQuery(".column-merge").remove()}),a("#grid-pages-panel").on("click",".layout-form-field .icon-remove",function(){var b=a(this),c=b.parent(),d=a("#"+c.data("config"));c.slideUp(100,function(){a(this).remove()}),d.slideUp(100,function(){a(this).remove()})}),a(document).on("click",".layout-form-field .dashicons-admin-page",function(){var b=a(this),d=b.parent(),e=d.data("config"),f=a("#"+e).formJSON(),g=b.closest(".column-container"),h=d.clone().css("display",""),i={};d.hasClass("field-edit-open")&&(d.removeClass("field-edit-open"),h.removeClass("field-edit-open"),a(".caldera-editor-field-config-wrapper").hide()),f.config.fields[e]&&(i=f.config.fields[e],delete i.ID),c(h,g,i)}),a(document).on("click",".layout-form-field .icon-edit",function(){var b=a(this),c=b.parent(),d=a("#"+c.data("config")+"_type").val();a(".caldera-editor-field-config-wrapper").hide(),c.hasClass("field-edit-open")?c.removeClass("field-edit-open"):(a(".layout-form-field").removeClass("field-edit-open"),c.addClass("field-edit-open"),a("#"+c.data("config")).show()),a(document).trigger("show."+c.data("config")),a(document).trigger("show.fieldedit"),"radio"!==d&&"checkbox"!==d&&"dropdown"!==d&&"toggle_switch"!==d||a("#"+c.data("config")+"_auto").trigger("change")}),a("body").on("click",".layout-modal-edit-closer,.layout-modal-save-action",function(b){b.preventDefault();var c=a(this),d=a(".layout-form-field.edit-open"),e=c.closest(".layout-modal-container");settings=e.find(".settings-panel").first(),a(".edit-open").removeClass("edit-open"),settings.appendTo(d.find(".settings-wrapper")).hide(),e.hide()}),a(".layout-editor-body").on("change",".layout-core-pod-query",function(){a(this).parent().find(".settings-panel-row").remove(),a(".edit-open").find(".drag-handle .set-pod").html(" - "+a(this).val())}),a(".layout-editor-body").on("click",".remove-where",function(){a(this).closest(".settings-panel-row").remove()}),a(".layout-editor-body").on("click",".use-pod-container",function(){var b=a(this),c=b.prev(),d=c.val();if(d.length){a(".edit-open").find(".drag-handle .set-pod").html(" - "+c.val()),b.parent().parent().find(".spinner").css("display","inline-block");var e={action:"pq_loadpod",pod_reference:{pod:d}};a.post(cfAdminAJAX,e,function(c){b.parent().find(".spinner").css("display","none");var d=a("#where-line-tmpl").html(),e="",f=b.closest(".settings-panel").data("container");for(var g in c)e+='<option value="'+c[g]+'">'+c[g]+"</option>";d=d.replace(/{{fields}}/g,e).replace(/{{container_id}}/g,f),b.parent().append(d)})}}),a(".caldera-editor-header").on("click",".column-sort .icon-edit",function(a){}),a(".layout-editor-body").on("tray_loaded",".layout-template-tray",function(){d()}),a(".caldera-editor-header").on("click",".caldera-editor-header-nav a",function(b){b.preventDefault();var c=a(this);a(".caldera-editor-header-nav li").removeClass("active"),a(".caldera-editor-body").hide(),a(c.attr("href")).show(),c.parent().addClass("active"),rebind_field_bindings()}),a("body").on("change",".required",function(){check_required_bindings(this)}),a("body").on("submit",".caldera-forms-options-form",function(b){a(".required.has-error").length&&b.preventDefault()}),a(".caldera-editor-body").on("click",".add-toggle-option",function(b){var c=a(this);if(c.data("bulk"))return a(c.data("bulk")).toggle(),void a(c.data("bulk")).find("textarea").focus();var d=c.closest(".caldera-editor-field-config-wrapper"),e=d.find(".toggle-options"),f=a("#field-option-row-tmpl").html(),g=Handlebars.compile(f),h="opt"+parseInt(1048576*(Math.random()+1)),i={_name:"config[fields]["+d.prop("id")+"][config]",option:{}};if(c.data("options")){for(var j=a(c.data("options")),k=j.val().split("\n"),l=!1,m=0;m<k.length;m++){var n=k[m],o=n,p=o.split("|");p.length>1&&(o=p[0],n=p[1],l=!0),i.option["opt"+parseInt(1048576*(Math.random()+m))]={value:o,label:n,default:!1}}a(c.data("options")).parent().hide(),j.val(""),!0===l?d.find(".toggle_show_values").prop("checked",!0):d.find(".toggle_show_values").prop("checked",!1),e.empty()}else i.option[h]={value:"",label:"",default:!1};a(".preset_options").val(""),e.append(g(i)),d.find(".toggle_show_values").trigger("change"),a(".toggle-options").sortable({handle:".dashicons-sort"}),k||e.find(".toggle_label_field").last().focus()}),a(".caldera-editor-body").on("change",".preset_options",function(b){var c=a(this),d=c.val(),e=a(c.data("bulk"));preset_options&&preset_options[d]&&preset_options[d].data&&("object"==typeof preset_options[d].data&&preset_options[d].data.length&&(preset_options[d].data=preset_options[d].data.join("\n")),e.val(preset_options[d].data))}),a(".caldera-editor-body").on("click",".toggle-remove-option",function(b){var c=a(this).closest(".caldera-editor-field-config-wrapper").find(".field-config").first();a(this).parent().remove(),c.trigger("change"),a(document).trigger("option.remove")}),a(".caldera-editor-body").on("click",".page-toggle",function(b){var c=a(this),d=c.parent(),e=d.find(".button");e.removeClass("button-primary"),a(".layout-grid-panel").hide().removeClass("page-active"),a("#"+c.data("page")).show().addClass("page-active"),c.addClass("button-primary"),e.each(function(b,c){a(c).html(d.data("title")+" "+(b+1))}),1===e.length&&d.hide()}),a(".caldera-editor-body").on("blur toggle.values",".toggle_label_field",function(b){var c=a(this),d=c.prev();d.val().length||d.val(c.val())}),a(document).on("change focusout",".toggle_value_field",function(){a(document).trigger("show.fieldedit")}),a(document).on("show.fieldedit option.remove",function(b){a(".toggle_value_field.has-error").removeClass("has-error");for(var c=a("#"+a(".layout-form-field.field-edit-open").data("config")),d=c.find(".toggle_value_field"),e=c.find(".notice"),f=0,g=0;g<d.length;g++){for(var h=(d[g].value,0),i=0;i<d.length;i++)d[g]!==d[i]&&d[g].value===d[i].value&&(a(d[i]).addClass("has-error"),h++);h>0&&(a(d[g]).addClass("has-error"),f++)}f>0?(e.slideDown(),b.preventDefault()):e.slideUp()});var h=!1;focus_initial_field=function(b){var c=a(".layout-grid-panel .icon-edit").first();c.length?c.trigger("click"):(a(".layout-column.column-container").first().trigger("mouseover"),h=setInterval(e,500)),a(document).off("load.page",focus_initial_field)},a(document).on("load.page",focus_initial_field),cf_clear_puler=function(){h&&(clearTimeout(h),a(document).off("mouseover",".layout-new-form-field, .column-fieldinsert",cf_clear_puler)),a(".layout-new-form-field, .column-fieldinsert").fadeIn()},a(document).on("mouseover",".layout-new-form-field, .column-fieldinsert",cf_clear_puler),rebuild_field_binding(),a(document).trigger("load.page"),a("body").on("click",".caldera-processor-nav a",function(b){b.preventDefault();var c=a(this);a(".caldera-processor-nav").removeClass("active"),a(".caldera-editor-processor-config-wrapper").hide(),a(c.attr("href")).show(),c.parent().addClass("active")}),a("body").on("click",".add-new-processor",function(b){var c=a(this),d=Handlebars.compile(a("#processor-wrapper-tmpl").html());wrap=a(".active-processors-list"),process_conf=a(".caldera-editor-processor-config"),processid=Math.round(1e8*Math.random()),new_templ=Handlebars.compile(a("#processor-line-tmpl").html()),new_proc={id:"fp_"+processid,type:c.data("type")},wrap.append(new_templ(new_proc)),process_conf.append(d(new_proc)),a("#form_processor_baldrickModalCloser").trigger("click"),a(".caldera-processor-nav a").last().trigger("click"),a("#fp_"+processid+"_type").val(c.data("type")).trigger("change"),f(),baldrickTriggers()}),a("body").on("click",".delete-processor",function(b){var c=a(this),d=c.closest(".caldera-editor-processor-config-wrapper");d.data("type");confirm(c.data("confirm"))&&(a("."+d.prop("id")).remove(),d.remove(),a(".caldera-processor-nav a").first().trigger("click"),rebuild_field_binding())}),a("body").on("change",".caldera-select-processor-type",function(b){var c=a(this),d=c.closest(".caldera-editor-processor-config-wrapper"),e=c.find('option[value="'+c.val()+'"]').text(),f=d.find(".caldera-editor-processor-title"),h=a(".caldera-processor-nav.active a");""===e&&(e=f.data("title")),f.html(e),h.html(e+' <span class="processor-line-number"></span>').parent().addClass("processor_type_"+c.val()),g(this),rebuild_field_binding()}),a(document).on("click","#cf-shortcode-preview",function(){a(this).focus().select()}),a(document).on("change",".cf-email-preview-toggle",function(){var b=a(this),c=a(".caldera-header-email-preview-button");b.is(":checked")?c.show().attr("aria-hidden","false").css("visibility","visible"):c.hide().attr("aria-hidden","true").css("visibility","hidden")}),rebuild_field_binding(),a(".caldera-select-processor-type").each(function(a,b){g(b)}),f()}),Handlebars.registerHelper("_field",function(a){var b=this,c="",d="",e="",f=this[a.hash.slug]?' data-default="'+this[a.hash.slug]+'"':"";a.hash.required&&(c=" required"),a.hash.exclude&&(e='data-exclude="'+a.hash.exclude+'"'),a.hash.array&&(d="[]","true"!==a.hash.array&&(f='value="'+a.hash.array+'"')),out="<select "+(a.hash.type?'data-type="'+a.hash.type+'"':"")+f+" "+e+' name="'+this._name+"["+a.hash.slug+"]"+d+'" id="'+this._id+"_"+a.hash.slug+'" class="block-input field-config caldera-field-bind'+c+'">',this[a.hash.slug]?out+='<option class="bound-field" value="'+this[a.hash.slug]+'" class="bound-field"></option>':a.hash.required||(out+='<option value=""></option>');for(var g in current_form_fields){var h="";a.hash.type&&current_form_fields[g].type!==a.hash.type||(b[a.hash.slug]&&b[a.hash.slug]===g&&(h=' selected="selected"'),out+='<option value="'+g+'"'+h+">"+current_form_fields[g].label+" ["+current_form_fields[g].slug+"]</option>")}return out+="</select>",a.hash.required&&(out+='<input class="field-config" name="'+this._name+'[_required_bounds][]" type="hidden" value="'+a.hash.slug+'">'),out}),Handlebars.registerHelper("console",function(a,b){console.log(this)}),function(a){"use strict";var b=function(a,b){this.init("tooltip",a,b)};b.prototype={constructor:b,init:function(b,c,d){var e,f;this.type=b,this.$element=a(c),this.options=this.getOptions(d),this.enabled=!0,"click"==this.options.trigger?this.$element.on("click."+this.type,this.options.selector,a.proxy(this.toggle,this)):"manual"!=this.options.trigger&&(e="hover"==this.options.trigger?"mouseenter":"focus",f="hover"==this.options.trigger?"mouseleave":"blur",this.$element.on(e+"."+this.type,this.options.selector,a.proxy(this.enter,this)),this.$element.on(f+"."+this.type,this.options.selector,a.proxy(this.leave,this))),this.options.selector?this._options=a.extend({},this.options,{trigger:"manual",selector:""}):this.fixTitle()},getOptions:function(b){return b=a.extend({},a.fn[this.type].defaults,b,this.$element.data()),b.delay&&"number"==typeof b.delay&&(b.delay={show:b.delay,hide:b.delay}),b},enter:function(b){var c=a(b.currentTarget)[this.type](this._options).data(this.type);return c.options.delay&&c.options.delay.show?(clearTimeout(this.timeout),c.hoverState="in",void(this.timeout=setTimeout(function(){"in"==c.hoverState&&c.show()},c.options.delay.show))):c.show()},leave:function(b){var c=a(b.currentTarget)[this.type](this._options).data(this.type);return this.timeout&&clearTimeout(this.timeout),c.options.delay&&c.options.delay.hide?(c.hoverState="out",void(this.timeout=setTimeout(function(){"out"==c.hoverState&&c.hide()},c.options.delay.hide))):c.hide()},show:function(){var a,b,c,d,e,f,g;if(this.hasContent()&&this.enabled){switch(a=this.tip(),this.setContent(),this.options.animation&&a.addClass("fade"),f="function"==typeof this.options.placement?this.options.placement.call(this,a[0],this.$element[0]):this.options.placement,b=/in/.test(f),a.detach().css({top:0,left:0,display:"block"}).insertAfter(this.$element),c=this.getPosition(b),d=a[0].offsetWidth,e=a[0].offsetHeight,b?f.split(" ")[1]:f){case"bottom":g={top:c.top+c.height,left:c.left+c.width/2-d/2};break;case"top":g={top:c.top-e,left:c.left+c.width/2-d/2};break;case"left":g={top:c.top+c.height/2-e/2,left:c.left-d};break;case"right":g={top:c.top+c.height/2-e/2,left:c.left+c.width}}a.offset(g).addClass(f).addClass("in")}},setContent:function(){var a=this.tip(),b=this.getTitle();a.find(".tooltip-inner")[this.options.html?"html":"text"](b),a.removeClass("fade in top bottom left right")},hide:function(){var b=this.tip();return b.removeClass("in"),a.support.transition&&this.$tip.hasClass("fade")?function(){var c=setTimeout(function(){b.off(a.support.transition.end).detach()},500);b.one(a.support.transition.end,function(){clearTimeout(c),b.detach()})}():b.detach(),this},fixTitle:function(){var a=this.$element;(a.attr("title")||"string"!=typeof a.attr("data-original-title"))&&a.attr("data-original-title",a.attr("title")||"").attr("title","")},hasContent:function(){return this.getTitle()},getPosition:function(b){return a.extend({},b?{top:0,left:0}:this.$element.offset(),{width:this.$element[0].offsetWidth,height:this.$element[0].offsetHeight})},getTitle:function(){var a=this.$element,b=this.options;return a.attr("data-original-title")||("function"==typeof b.title?b.title.call(a[0]):b.title)},tip:function(){return this.$tip=this.$tip||a(this.options.template)},validate:function(){this.$element[0].parentNode||(this.hide(),this.$element=null,this.options=null)},enable:function(){this.enabled=!0},disable:function(){this.enabled=!1},toggleEnabled:function(){this.enabled=!this.enabled},toggle:function(b){var c=a(b.currentTarget)[this.type](this._options).data(this.type);c[c.tip().hasClass("in")?"hide":"show"]()},destroy:function(){this.hide().$element.off("."+this.type).removeData(this.type)}};var c=a.fn.tooltip;a.fn.tooltip=function(c){return this.each(function(){var d=a(this),e=d.data("tooltip"),f="object"==typeof c&&c;e||d.data("tooltip",e=new b(this,f)),"string"==typeof c&&e[c]()})},a.fn.tooltip.Constructor=b,a.fn.tooltip.defaults={animation:!0,placement:"top",selector:!1,template:'<div class="tooltip"><div class="tooltip-arrow"></div><div class="tooltip-inner"></div></div>',trigger:"hover",title:"",delay:0,html:!1},a.fn.tooltip.noConflict=function(){return a.fn.tooltip=c,this}}(window.jQuery),jQuery(document).ready(function(a){function b(b){var d=a(b),e=d.closest(".caldera-editor-field-config-wrapper"),f=e.find(".caldera-config-field-setup"),g=compiled_templates[d.val()+"_tmpl"]?compiled_templates[d.val()+"_tmpl"]:compiled_templates.noconfig_field_templ,h=e.find(".field_config_string").val(),i=d.data("type");if(e.find(".caldera-config-group").show(),d.addClass("field-initialized"),h=h.length&&i===d.val()?JSON.parse(h):fieldtype_defaults[d.val()+"_cfg"],h||(h={}),h._id=d.data("field"),h._name="config[fields]["+d.data("field")+"][config]",g=a("<div>").html(g(h)),f.html(g.html()),"function"==typeof window[d.val()+"_init"]&&window[d.val()+"_init"](d.data("field"),f),fieldtype_defaults[d.val()+"_nosupport"]&&(fieldtype_defaults[d.val()+"_nosupport"].indexOf("hide_label")>=0&&e.find(".hide-label-field").hide().find(".field-config").prop("checked",!1),fieldtype_defaults[d.val()+"_nosupport"].indexOf("caption")>=0&&e.find(".caption-field").hide().find(".field-config").val(""),fieldtype_defaults[d.val()+"_nosupport"].indexOf("required")>=0&&e.find(".required-field").hide().find(".field-config").prop("checked",!1),fieldtype_defaults[d.val()+"_nosupport"].indexOf("custom_class")>=0&&e.find(".customclass-field").hide().find(".field-config").val(""),fieldtype_defaults[d.val()+"_nosupport"].indexOf("entry_list")>=0&&e.find(".entrylist-field").hide().find(".field-config").prop("checked",!1)),e.find(".toggle_show_values").trigger("change"),!a(".caldera-select-field-type").not(".field-initialized").length){if(core_form||(core_form=jQuery(".caldera-forms-options-form")),core_form.hasClass("builder-loaded"))c(d.data("field"));else{for(var j=a(".caldera-select-field-type.field-initialized"),k=0;k<j.length;k++)c(a(j[k]).data("field"));core_form.addClass("builder-loaded")}a(".caldera-header-save-button").prop("disabled",!1),rebuild_field_binding(),baldrickTriggers()}a(".color-field").length&&a(".color-field").wpColorPicker({change:function(b){var c=a(this);c.data("ev")&&clearTimeout(c.data("ev")),c.data("ev",setTimeout(function(){c.trigger("record")},200)),c.data("target")&&(a(c.data("target")).css(c.data("style"),c.val()),a(c.data("target")).val(c.val()))}})}function c(b){var c=a("#"+b),d=c.find(".caldera-select-field-type"),e=a('.layout-form-field[data-config="'+b+'"]'),f=e.find(".field_preview"),g=(a("#preview-"+d.val()+"_tmpl").html(),compiled_templates["preview-"+d.val()+"_tmpl"]),h={id:b};c.find(".field-config").each(function(c,d){for(var e=a(d),f=e.prop("name").split("["+b+"]")[1].substr(1),g=f.substr(0,f.length-1).split("]["),i=e.is(":checkbox,:radio")?e.filter(":checked").val():e.val(),j={},k=g.length-1;k>=0;k--)if(k===g.length-1)j[g[k]]=i;else{var l=j;j={},j[g[k]]=l}a.extend(!0,h,j)}),f.html(g(h)),e.removeClass("button"),a(".preview-field-config").prop("disabled",!0)}function d(b){var c,d=a(".caldera-editor-fields-panel"),e=(a(".caldera-editor-groups-panel"),a(".caldera-group-nav")),f=a('[data-group="'+b+'"]'),g=f.find(".caldera-config-group-name"),h=f.find(".caldera-config-group-slug"),i=f.find(".caldera-config-group-desc"),j=f.find(".caldera-config-group-admin"),k=a(".active-group-name"),l=a(".active-group-slug"),m=a(".active-group-desc"),n=a(".active-group-admin"),o=a(".caldera-editor-fields-list ul"),p=f.find(".caldera-config-group-repeat"),q=a(".repeat-config-button"),r=(a(".caldera-editor-group-settings"),a(".caldera-config-group-remove"));a(".new-group-input").remove(),a(".new-field-input").remove(),e.removeClass("active"),d.show(),o.hide(),o.removeClass("active").find("li.active").removeClass("active"),o.hide(),f.addClass("active"),c=a(".caldera-editor-fields-list ul.active li"),c.length?r.hide():r.show(),a(".caldera-editor-field-config-wrapper").hide(),f.show(),k.val(g.val()),l.val(h.val()),m.val(i.val()),"1"===j.val()?n.prop("checked",!0):n.prop("checked",!1),"1"===p.val()?q.addClass("field-edit-open"):q.removeClass("field-edit-open")}a(".caldera-header-save-button").baldrick({method:"POST",request:"admin.php?page=caldera-forms",before:function(b,c){if(c.preventDefault(),!check_required_bindings())return!1;a("#save_indicator").addClass("loading"),"undefined"!=typeof tinyMCE&&tinyMCE.triggerSave();var d=a(".caldera-forms-options-form").formJSON();return d.conditions&&(d.config.conditional_groups={conditions:d.conditions}),a(b).data("cf_edit_nonce",d.cf_edit_nonce),a(b).data("_wp_http_referer",d._wp_http_referer),a(b).data("sender","ajax"),a(b).data("config",JSON.stringify(d.config)),!0},callback:function(b){if(!1===b.data){var c=a(".updated_notice_box");c.stop().animate({top:0},200,function(){setTimeout(function(){c.stop().animate({top:-75},200)},2e3)})}},complete:function(b){a(".wrapper-instance-pane .field-config").prop("disabled",!1)}}),a("body").on("click",".toggle_processor_event input",function(b){var c=a(this),d=c.closest(".wrapper-instance-pane"),e=d.find(".caldera-config-processor-setup"),f=d.find(".caldera-config-processor-notice");c.is(":checked")?(c.parent().addClass("activated"),c.parent().find(".is_active").show().attr("aria-hidden",!1).css("visibility","visible"),c.parent().find(".not_active").hide().attr("aria-hidden",!0).css("visibility","hidden")):(c.parent().removeClass("activated"),c.parent().find(".is_active").hide().attr("aria-hidden",!0).css("visibility","hidden"),c.parent().find(".not_active").show().attr("aria-hidden",!1).css("visibility","visible")),d.find(".toggle_processor_event .activated").length?(e.slideDown(100),f.slideUp(100)):(e.slideUp(100),f.slideDown(100))}),a("body").on("click",".toggle_option_tab > a",function(b){b.preventDefault();var c=a(this),d=a(c.attr("href")),e=c.parent().find("a"),f=c.closest(".caldera-editor-config-wrapper").find(".wrapper-instance-pane");e.removeClass("button-primary"),f.hide(),d.show(),c.addClass("button-primary"),a(".caldera-conditionals-usetype").trigger("change")}),a(".caldera-editor-body").on("change",".caldera-select-field-type",function(a){b(this)}),a(".caldera-editor-body").on("click",".caldera-group-nav a",function(b){b.preventDefault(),d(a(this).attr("href").substr(1))}),a(".caldera-editor-body").on("click",".caldera-editor-fields-list a",function(b){b.preventDefault();var c=a(this),d=a(c.attr("href"));a(".new-group-input").remove(),a(".new-field-input").remove(),a(".caldera-editor-fields-list li.active").removeClass("active"),c.parent().addClass("active"),a(".caldera-editor-field-config-wrapper").hide(),d.show()}),a(".caldera-editor-body").on("click",".group-config-button",function(b){var c=a(this),d=a(".caldera-editor-group-settings"),e=c.closest(".caldera-editor-fields-panel"),f=a(".caldera-config-group-remove");e.find(".caldera-field-line").length?f.hide():f.show(),c.hasClass("field-edit-open")?(d.slideUp(100),c.removeClass("field-edit-open")):(d.slideDown(100),c.addClass("field-edit-open"))}),a(".caldera-editor-body").on("keydown",".field-config",function(b){a(this).is("textarea")||13===b.which&&b.preventDefault()}),a(".caldera-editor-body").on("change",".field-label",function(b){var c=a(this).closest(".caldera-editor-field-config-wrapper").prop("id");field_line=a('[data-field="'+c+'"]'),field_title=a("#"+c+" .caldera-editor-field-title, .layout-form-field.field-edit-open .layout_field_name"),slug=a("#"+c+" .field-slug"),field_line.find("a").html('<i class="icn-field"></i> '+this.value),field_title.text(this.value),"change"===b.type&&slug.trigger("change"),rebuild_field_binding()}),a(".caldera-editor-body").on("change",".active-group-name",function(b){b.preventDefault();var c=a(".caldera-group-nav.active"),d=(c.data("group"),c.find(".caldera-config-group-name")),e=c.find("span");"focusout"!==b.type||this.value.length||(this.value="Group "+(parseInt(c.index())+1)),d.val(this.value),e.text(this.value)}),a(".caldera-editor-body").on("change",".active-group-slug",function(b){b.preventDefault();var c=a(".caldera-group-nav.active"),d=(c.data("group"),c.find(".caldera-config-group-name").val()),e=c.find(".caldera-config-group-slug"),f=(c.find("span"),this.value.split(" ").join("_").split("-").join("_").replace(/[^a-z0-9_]/gi,"").toLowerCase());"focusout"!==b.type||this.value.length||(f=d.split(" ").join("_").split("-").join("_").replace(/[^a-z0-9_]/gi,"").toLowerCase()),e.val(f),this.value=f}),a(".caldera-editor-body").on("change",".active-group-desc",function(b){b.preventDefault();var c=a(".caldera-group-nav.active");(c.data("group"),c.find(".caldera-config-group-desc")).val(this.value)}),a(".caldera-editor-body").on("change",".active-group-admin",function(b){b.preventDefault();var c=a(".caldera-group-nav.active"),d=(c.data("group"),c.find(".caldera-config-group-name").val(),c.find(".caldera-config-group-admin"));c.find("span"),this.value.split(" ").join("_").split("-").join("_").replace(/[^a-z0-9_]/gi,"").toLowerCase(),a(this).prop("checked")?(d.val(1),c.addClass("is-admin")):(d.val(0),c.removeClass("is-admin"))}),a(".caldera-editor-body").on("click",".repeat-config-button",function(b){b.preventDefault();var c=a(".caldera-group-nav.active"),d=(c.data("group"),c.find("a .group-type")),e=c.find(".caldera-config-group-repeat"),f=a(this);f.hasClass("field-edit-open")?(e.val("0"),d.removeClass("icn-repeat").addClass("icn-folder"),f.removeClass("field-edit-open")):(e.val("1"),d.addClass("icn-repeat").removeClass("icn-folder"),f.addClass("field-edit-open"))}),a(".caldera-editor-body").on("click",".delete-field",function(){var b=a(this),c=b.closest(".caldera-editor-field-config-wrapper").prop("id");confirm(b.data("confirm"))&&(a("#"+c).remove(),a('option[value="'+c+'"]').remove(),a('[data-bind="'+c+'"]').remove(),delete current_form_fields[c],a('[data-config="'+c+'"]').slideUp(200,function(){a(this).remove(),rebuild_field_binding(),a(document).trigger("field.removed")}))}),a(".caldera-editor-body").on("click",".add-new-group,.add-field",function(){var b=a(this);if(a(".new-group-input").remove(),a(".new-field-input").remove(),b.hasClass("add-field")){a('<input type="text" class="new-field-input block-input">').appendTo(a(".caldera-editor-fields-list ul.active")).focus()}else{a('<input type="text" class="new-group-input block-input">').appendTo(a(".caldera-editor-groups-panel")).focus()}}),a(".caldera-editor-body").on("change keypress",".new-group-input",function(b){if("keypress"===b.type){if(13!==b.which)return;b.preventDefault()}var c,e,f=this.value,g=a(this),h=a(".caldera-editor-groups-panel ul"),i=a(".caldera-editor-fields-list");if(f.length){c=Handlebars.compile(a("#caldera_group_line_templ").html()),e={id:f.split(" ").join("_").split("-").join("_").replace(/[^a-z0-9_]/gi,"").toLowerCase(),name:f},h.append(c(e));a('<ul data-group="'+e.id+'">').hide().appendTo(i),g.remove(),d(e.id)}else g.remove()}),a(".caldera-editor-body").on("change keypress",".new-field-input",function(b){if("keypress"===b.type){if(13!==b.which)return;b.preventDefault()}var c,d,e,f=this.value,g=a(this),h=g.parent(),i=a(".caldera-editor-field-config"),j=a(".caldera-config-group-remove");if(f.length){j.hide(),c=Handlebars.compile(a("#caldera_field_line_templ").html()),d=Handlebars.compile(a("#caldera_field_config_wrapper_templ").html()),e={id:f.split(" ").join("_").split("-").join("_").replace(/[^a-z0-9_]/gi,"").toLowerCase(),label:f,slug:f.split(" ").join("_").split("-").join("_").replace(/[^a-z0-9_]/gi,"").toLowerCase(),group:a(".caldera-group-nav.active").data("group")};var k=a(c(e));k.appendTo(h),i.append(d(e)),k.find("a").trigger("click"),g.remove()
3
+ }else g.remove()}),a(".caldera-editor-body").on("change",".field-slug",function(b){this.value.length?this.value=this.value.split(" ").join("_").split("-").join("_").replace(/[^a-z0-9_]/gi,"").toLowerCase():"change"===b.type&&(this.value=a(this).closest(".caldera-editor-field-config-wrapper").find(".field-label").val().split(" ").join("_").split("-").join("_").replace(/[^a-z0-9_]/gi,"").toLowerCase())}),a(".caldera-editor-body").on("click",".caldera-add-group",function(b){var c=a(this),d=c.data("group"),e=a("#"+d+"_panel_tmpl").html();c.parent().parent().append(e)}),a(".caldera-editor-body").on("click",".caldera-config-group-remove",function(b){var c=a(".active-group-slug").val();a('[data-group="'+c+'"]').hide(0,function(){a(this).remove();var b=a(".caldera-group-nav");b.length?b.first().find("a").trigger("click"):a(".caldera-editor-fields-panel").hide()})}),a("body").on("click",".set-current-field",function(b){b.preventDefault();var c=a(this);a("#"+c.data("field")+"_type").val(c.data("type")).trigger("change"),a("#"+c.data("field")+"_lable").focus(),a("#field_setup_baldrickModalCloser").trigger("click")}),a(".caldera-editor-body").on("change record",".field-config",function(b){var d=a(this),e=d.closest(".caldera-editor-field-config-wrapper");current_form_fields&&(d.prop("id")===e.prop("id")+"_lable"&&(current_form_fields[e.prop("id")].label=this.value),d.prop("id")===e.prop("id")+"_slug"&&(current_form_fields[e.prop("id")].slug=this.value),d.prop("id")===e.prop("id")+"_type"&&(current_form_fields[e.prop("id")].type=this.value),e.length&&c(e.prop("id")))}),a(".caldera-editor-body").on("focus",".caldera-field-bind",function(b){var c=a(this),d=this.value;if(b.type&&"focusin"===b.type)return c.removeClass("bound_field").addClass("reload-binding"),rebind_field_bindings(),void(this.value=d)}),a(".caldera-editor-body").on("change",".caldera-conditional-field-set",function(b){var c,d,e=a(this),f=e.parent().find(".compare-type"),g=e.data("condition"),h=e.data("id"),i="config["+g+"]["+h+"][conditions][group]["+e.data("row")+"]["+e.data("line")+"]",j=e.data("line"),k=a("#"+j+"_value"),l=k.find(".caldera-conditional-value-field").first(),m=[],n=this.value;if("{"!==n.substr(0,1)&&(c=a("#"+n),d=c.find(".field-button-type"),m=c.find(".caldera-config-group-toggle-options")),e.hasClass(".bind_init")&&e.addClass("bound_triggered"),l.length&&l.val().length&&k.data("value",l.val()),f.show(),m.length){var o=m.find(".toggle_option_row"),p='<select name="'+i+'[value]" class="caldera-processor-value-bind caldera-conditional-value-field" data-field="'+n+'" style="max-width: 220px; width: 220px;">';p+='<option value=""></option>',o.each(function(b,c){var d=a(c).find(".toggle_label_field"),e=d.data("option"),f="";k.data("value")&&(k.data("value").toString()!==e&&k.data("value").toString()!==a(c).find(".toggle_value_field").val()||(f=' selected="selected"')),p+='<option value="'+e+'"'+f+">"+d.val()+"</option>"}),p+="</select>"}else d&&"button"==d.val()?(f.val("is").hide(),p='<select name="'+i+'[value]" class="caldera-processor-value-bind caldera-conditional-value-field" data-field="'+n+'" style="max-width: 220px; width: 220px;">',p+='<option value="click" '+("click"===k.data("value")?'selected="selected"':"")+">Click</option>",p+='<option value="dblclick" '+("dblclick"===k.data("value")?'selected="selected"':"")+">Double Click</option>",p+="</select>"):p='<input name="'+i+'[value]" type="text" class="caldera-conditional-value-field magic-tag-enabled" value="'+(k.data("value")?k.data("value"):"")+'" style="max-width: 205px;">';k.html(p),init_magic_tags()}),a(".caldera-editor-body").on("change",".caldera-conditionals-usetype",function(b){var c=a(this);"show"===this.value||"hide"===this.value||"disable"===this.value||"use"===this.value||"not"===this.value?(a("#"+c.data("id")+"_condition_group_add").show(),a("#"+c.data("id")+"_conditional_wrap").show()):(a("#"+c.data("id")+"_condition_group_add").hide(),a("#"+c.data("id")+"_conditional_wrap").hide())}),a(".caldera-editor-body").on("click",".remove-conditional-line",function(b){b.preventDefault();var c=a(this),d=c.closest(".caldera-condition-line"),e=c.closest(".caldera-condition-group");d.remove(),e.find(".caldera-condition-line").length||e.remove()}),a(".caldera-group-nav").first().find("a").trigger("click"),a(".caldera-editor-body").on("change",".toggle_show_values",function(b){var c=a(this),d=c.closest(".caldera-config-group-toggle-options");values=d.find(".toggle_value_field"),lables=d.find(".toggle_label_field"),field_lables=d.find(".caldera-config-group-option-labels"),c.prop("checked")?(values.show().parent().show(),values.show().parent().parent().show(),lables.css("width",""),field_lables.show()):(values.hide().parent().hide(),lables.css("width",245),field_lables.hide()),lables.trigger("toggle.values"),init_magic_tags()}),a(".caldera-editor-body").on("change",".auto-populate-type",function(){a(this).closest(".wrapper-instance-pane").find(".auto-populate-options").trigger("change")}),a(".caldera-editor-body").on("change",".auto-populate-options",function(){var b=a(this),c=b.closest(".wrapper-instance-pane"),d=c.find(".caldera-config-group-toggle-options"),e=c.find(".caldera-config-group-auto-options"),f=e.find(".auto-populate-type");e.find(".auto-populate-type-panel").hide(),b.prop("checked")?(d.hide(),e.show()):(d.show(),e.hide()),e.find(".caldera-config-group-auto-"+f.val()).show()}),a("body").on("change",".pin-toggle-roles",function(){var b=a(this),c=a("#caldera-pin-rules");"1"===b.val()?c.show():c.hide()}),a("body").on("click",".magic-tag-init",function(b){a(this).prev().focus().trigger("init.magic")}),a("body").on("keyup focus select click init.magic",".magic-tag-enabled",function(b){init_magic_tags();var c=a(this),d=c.parent(),e=d.closest(".wrapper-instance-pane").find(".caldera-select-field-type").val()?d.closest(".wrapper-instance-pane").find(".caldera-select-field-type").val():"hidden",f=d.find(".magic-tags-autocomplete"),g=f.find("ul"),h=this.value,i=[],j="",k=this.selectionStart,l=this.selectionEnd;if(f.length&&f.data("focus"))return void b.preventDefault();if(c.data("tag",""),this.selectionEnd>this.selectionStart)j=this.value.substr(this.selectionStart,this.selectionEnd-this.selectionStart);else if(("select"===b.type||"keyup"===b.type)&&40!==b.which&&38!==b.which&&39!==b.which&&37!==b.which){for(k=this.selectionStart;k>0;k--){var m=h.substr(k-1,1);if(" "===m||"\n"===m||("%"===m||"}"===m)&&this.selectionStart===k)break}for(l=this.selectionStart;l<h.length;l++){var m=h.substr(l,1);if(" "===m||"\n"===m||("%"===m||"{"===m)&&this.selectionStart===l)break}j=h.substr(k,l-k)}if("focusout"!==b.type){"init"!==b.type&&j.length<3&&f.length&&f.remove(),f.length||(f=a('<div class="magic-tags-autocomplete"></div>'),g=a("<ul></ul>"),g.appendTo(f),f.insertAfter(c),f.on("mouseenter",function(){a(this).data("focus",!0)}),f.on("mouseleave",function(){a(this).data("focus",!1),setTimeout(function(){f.remove()},200),c.is(":focus")||c.trigger("focusout")})),g.empty();var n="system",o=!1;"hidden"===e||"dropdown"===e||"radio"===e||"toggle_switch"===e||"checkbox"===e?(o=!0,e="text",n="all"):"paragraph"!==e&&"html"!==e||(e="text"),c.data("type")&&(e=c.data("type")),e=e.split(","),e.push("vars");for(var p=0;p<e.length;p++)for(var q in system_values)if(void 0!==system_values[q].tags&&void 0!==system_values[q].tags[e[p]]){if(i=[q],"system"!==q&&"variable"!==q&&"field"!==q){var r=jQuery(".processor-"+q),s=c.closest(".caldera-editor-processor-config-wrapper"),t=s.prop("id");i=[];for(var u=0;u<r.length;u++)if(s.length||!0!==o){if(t===r[u].id)continue;jQuery("li."+r[u].id).index()<jQuery("li."+t).index()&&i.push(r[u].id)}else i.push(r[u].id)}for(var v=0;v<i.length;v++)if("all"===n||n===q||"variable"===q){var w=a('<li class="header">'+system_values[q].type+(v>0?" ["+(v+1)+"]":"")+"</li>"),x=0;w.appendTo(g);for(var y=0;y<system_values[q].tags[e[p]].length;y++)if(!c.data("parent")||"variable:"+c.data("parent")!==system_values[q].tags[e[p]][y]){var z=system_values[q].wrap[0]+system_values[q].tags[e[p]][y]+system_values[q].wrap[1];if(i[v]!==q&&i.length>1&&(z=system_values[q].wrap[0]+system_values[q].tags[e[p]][y]+":"+i[v]+system_values[q].wrap[1]),z.indexOf(j)>=0||"init"===b.type){x+=1;var A=z.replace(j,"<strong>"+j+"</strong>"),B=a('<li class="tag" data-tag="'+z+'">'+A+"</li>");B.on("click",function(){var b=a(this).data("tag");c.val(h.substr(0,k)+b+h.substr(l)).trigger("change").focus(),c[0].selectionStart=k+b.length-(b.indexOf("*")>0?2:0),c[0].selectionEnd=k+b.length-(b.indexOf("*")>0?1:0),l=k=c[0].selectionEnd,h+=b,c.trigger("init.magic")}),B.appendTo(g)}}0===x&&w.remove()}}}g.children().length||f.remove(),"focusout"===b.type&&setTimeout(function(){f.remove()},200)});for(var e=a(".cf-editor-template"),f=0;f<e.length;f++)compiled_templates[e[f].id]=Handlebars.compile(e[f].innerHTML);a(".caldera-select-field-type").not(".field-initialized").each(function(a,c){b(c)})});var rebuild_field_binding,rebind_field_bindings,current_form_fields={},required_errors={},add_new_grid_page,add_page_grid,init_magic_tags,core_form,compiled_templates={};init_magic_tags=function(){jQuery(".magic-tag-enabled").each(function(a,b){var c=jQuery(b);if(c.hasClass("magic-tag-init-bound")){var d=c.parent().find(".magic-tag-init");return void(c.is(":visible")?d.show():d.hide())}var e=jQuery('<span class=""></span>'),f=jQuery('<span style="position:relative;display:inline-block; width:100%;"></span>');c.is("input")&&e.css("borderBottom","none"),c.hasClass("caldera-conditional-value-field")&&f.width("auto"),c.wrap(f),e.insertAfter(c),c.addClass("magic-tag-init-bound"),c.is(":visible")?e.show():e.hide()})},rebuild_field_binding=function(){if(core_form||(core_form=jQuery(".caldera-forms-options-form")),core_form.hasClass("builder-loaded")){var a=jQuery(".caldera-editor-field-config-wrapper");system_values.field={tags:{text:[]},type:"Fields",wrap:["%","%"]};for(var b=0;b<a.length;b++){var c=a[b].id,d=jQuery("#"+c+"_lable").val(),e=jQuery("#"+c+"_slug").val(),f=jQuery("#"+c+"_type").val();void 0===system_values.field.tags[f]&&(system_values.field.tags[f]=[]),system_values.field.tags[f].push(e),"text"!==f&&system_values.field.tags.text.push(e),current_form_fields[c]={label:d,slug:e,type:f},jQuery("option.bound-field").trigger("change").each(function(a,b){var c=jQuery(b);0!==c.prop("value").indexOf("{")?c.text(jQuery("#"+c.prop("value")+"_lable").val()+" ["+jQuery("#"+c.prop("value")+"_lable").val()+"]"):c.text(c.prop("value").replace("{","").replace("}",""))}).removeClass("bound-field")}}},rebind_field_bindings=function(){var a,b,c=jQuery(".caldera-field-bind").not(".bound_field");if(c.length){c.addClass("bound_field");for(var d=0;d<c.length;d++){var e=jQuery(c[d]),f=e.val(),g=e.data("default"),h=e.data("exclude"),i=0,j=e.closest(".caldera-editor-processor-config-wrapper"),k=j.prop("id"),l="";if(g&&!e.hasClass("reload-binding")&&(f=g),e.is("select")){e.empty();var m=jQuery('<optgroup label="Fields">');for(var n in current_form_fields)e.data("type")&&e.data("type").split(",").indexOf(current_form_fields[n].type)<0||(e.data("id")!==n&&m.append('<option value="'+n+'"'+(f===n?'selected="selected"':"")+">"+current_form_fields[n].label+" ["+current_form_fields[n].slug+"]</option>"),i+=1);m.appendTo(e),0===i&&e.empty();for(var o in system_values)if(a=[],!(h&&h.split(",").indexOf(o)>=0)){if("system"!==o&&"variable"!==o)for(var p=jQuery(".processor-"+o),q=0;q<p.length;q++)k!==p[q].id&&(a.push(p[q].id),p.length>1&&(b=jQuery("li."+p[q].id+" .processor-line-number"))&&b.html("["+(q+1)+"]"));else a.push("__system__");var r=[];e.data("type")?(r=e.data("type").split(","),r.push("vars")):r=["text","vars"];for(var s=0;s<r.length;s++)if(system_values[o].tags&&system_values[o].tags[r[s]])for(var t=0;t<a.length;t++){jQuery("li."+a[t]).index()>jQuery("li."+k).index()&&"__system__"!==a[t]?e.closest(".caldera-editor-processors-panel-wrap").length&&(l=' disabled="disabled"'):l="";for(var m=jQuery('<optgroup label="'+system_values[o].type+("__system__"!==a[t]?" "+jQuery("li."+a[t]).find(".processor-line-number").html():"")+'"'+l+">"),u=0;u<system_values[o].tags[r[s]].length;u++){var v=system_values[o].tags[r[s]][u];"__system__"!==a[t]&&(v=v.replace(o,a[t])),m.append('<option value="{'+v+'}"'+(f==="{"+v+"}"?'selected="selected"':"")+l+">"+system_values[o].tags[r[s]][u]+"</option>"),i+=1}m.children().length&&m.appendTo(e)}}if(0===i){if(e.empty(),e.data("type")){e.append('<option value="">No '+e.data("type").split(",").join(" or ")+" in form</option>");var w=!0}}else e.prop("disabled",!1);e.hasClass("required")||void 0!==w||e.prepend('<option value=""></option>'),e.val(f)}}init_magic_tags(),jQuery(document).trigger("bound.fields"),jQuery(".caldera-header-save-button").prop("disabled",!1)}},jQuery(document).ready(function(a){function b(){var b=a(".layout-grid-panel"),c=0;b.each(function(b,d){var e=a(d),f=e.find(".layout-structure"),g=e.find(".row"),h=[];g.each(function(b,d){var e=a(d),f=e.children().not(".column-merge"),g=[];c+=1,f.each(function(b,d){span=a(d).attr("class").split("-"),g.push(span[2]);var e=a(d).find(".field-location");e.length&&e.each(function(d,e){a(e).val(c+":"+(b+1)).removeAttr("disabled")})}),h.push(g.join(":"))}),f.val(h.join("|"))})}function c(b,c,e){var f,g,h="fld_"+Math.round(1e7*Math.random()),i=h,j=a("#field_config_panels");b.prop("id","").prop("title",""),f=Handlebars.compile(a("#caldera_field_config_wrapper_templ").html()),g=a.extend({},{id:i,label:"",slug:""},e),g.slug="",j.append(f(g)),b.removeClass("button-small").removeClass("button").removeClass("button-primary").removeClass("ui-draggable").removeClass("layout-new-form-field").addClass("layout-form-field").attr("data-config",h).css({display:"",opacity:""}),b.find(".layout_field_name").remove(),b.find(".field-location").prop("name","config[layout_grid][fields]["+h+"]"),b.find(".settings-panel").show(),b.appendTo(c),d(),b.find(".icon-edit").trigger("click"),a("#"+h+"_lable").focus().select(),baldrickTriggers(),a(document).trigger("field.added"),e?a("#"+i+"_type").data("type",g.type).trigger("change"):a("#"+h).trigger("field.drop"),rebuild_field_binding()}function d(){a(".toggle-options").sortable({handle:".dashicons-sort"}),a("#grid-pages-panel").sortable({placeholder:"row-drop-helper",handle:".sort-handle",items:".first-row-level",axis:"y",stop:function(){b()}}),a(".layout-column").sortable({connectWith:".layout-column",appendTo:"#grid-pages-panel",helper:"clone",items:".layout-form-field",handle:".drag-handle",cursor:"move",opacity:.7,cursorAt:{left:100,top:15},start:function(a,b){b.helper.css({width:"200px",height:"35px",paddingTop:"20px"})},stop:function(a,c){c.item.removeAttr("style"),b()}}),a("h3 .layout-new-form-field").draggable({helper:"clone",appendTo:"body"}),a(".page-toggle.button").droppable({accept:".layout-form-field",over:function(b,c){a(this).trigger("click"),a(".layout-column").sortable("refresh")}}),a(".layout-column").droppable({greedy:!0,activeClass:"ui-state-dropper",hoverClass:"ui-state-hoverable",accept:".layout-new-form-field",drop:function(b,d){c(d.draggable.clone(),a(this))}}),b()}function e(){if(h){var b=a(".column-fieldinsert");b.length?(b.stop().fadeToggle(700),a(".layout-new-form-field").stop().fadeToggle(700)):cf_clear_puler()}}function f(){a(".caldera-editor-processors-panel ul").sortable({update:function(){rebuild_field_binding()}})}function g(b){var c=a(b),d=a("#"+c.val()+"-tmpl").length?a("#"+c.val()+"-tmpl").html():"",e=c.closest(".caldera-editor-processor-config-wrapper"),f=e.find(".caldera-config-processor-setup"),g=Handlebars.compile(d),h=e.find(".processor_config_string").val(),i=c.data("type");h=h.length&&i===c.val()?JSON.parse(h):processor_defaults[c.val()+"_cfg"],h||(h={}),h._id=e.prop("id"),h._name="config[processors]["+e.prop("id")+"][config]",g=a("<div>").html(g(h)),f.html(g.html()),"function"==typeof window[c.val()+"_init"]&&window[c.val()+"_init"](e.prop("id"),f),e.find(".no-conditions").length&&e.find(".toggle_option_tab").remove(),rebuild_field_binding(),baldrickTriggers(),a(".wp-baldrick").baldrick({request:ajaxurl,method:"POST",before:function(b){var c=a(b);c.data("addNode")&&!c.data("request")&&c.data("request","cf_get_default_setting")}})}add_new_grid_page=function(a){return{page_no:"pg_"+Math.round(1e7*Math.random())}},add_page_grid=function(b){var c=a(".page-toggle").length+1,e=a('<button type="button" data-name="Page '+c+'" data-page="'+b.rawData.page_no+'" class="page-toggle button">'+b.params.trigger.data("addtitle")+" "+c+"</button> "),f=a("#page-toggles");e.appendTo(f),f.show(),d(),e.trigger("click"),1===c&&f.hide(),a(document).trigger("add.page")},a(document).on("remove.page add.page load.page",function(b){var c=a(".page-toggle").length,d=a("#tab_pages");c<=1?d.hide():d.show()}),d(),a("#grid-pages-panel").on("click",".column-fieldinsert .dashicons-plus-alt",function(b){var d=a(this).closest(".column-container");c(a("#newfield-tool").clone().css("display",""),d)}),a("#grid-pages-panel").on("click",".column-split",function(b){var c=a(this).parent().parent(),e=c.attr("class").split("-"),f=a("<div>").insertAfter(c),g=Math.ceil(e[2]/2),h=Math.floor(e[2]/2);e[2]=g,c.attr("class",e.join("-")),e[2]=h,f.addClass(e.join("-")).append('<div class="layout-column column-container">'),a(this).remove(),d(),jQuery(".column-tools").remove(),jQuery(".column-merge").remove()}),a("#grid-pages-panel").on("click",".column-remove",function(c){var d=a(this).closest(".row"),e=d.find(".layout-form-field"),f=d.closest(".layout-grid-panel");if(e.length){if(!confirm(a("#row-remove-fields-message").text()))return;e.each(function(b,c){var d=a(c).data("config");a("#"+d).remove(),a('option[value="'+d+'"]').remove(),a('[data-bind="'+d+'"]').remove(),delete current_form_fields[d]})}d.slideUp(200,function(){if(a(this).remove(),b(),rebuild_field_binding(),!f.find(".row").length){f.remove();var c=a("#page-toggles .button-primary"),d=c.prev(),e=c.next();c.remove(),d.length?d.trigger("click"):e.trigger("click")}a(document).trigger("remove.page")}),jQuery(".column-tools").remove(),jQuery(".column-merge").remove()}),a(".caldera-config-editor-main-panel").on("click",".caldera-add-row",function(c){if(c.preventDefault(),!a(".page-active").length)return void a(".caldera-add-page").trigger("click");var e=a('<div style="display:none;" class="first-row-level row"><div class="col-xs-12"><div class="layout-column column-container"></div></div></div>');a(".page-active").append(e),e.slideDown(200),d(),b()}),a("#grid-pages-panel").on("click",".column-join",function(c){var d=a(this).parent().parent().parent(),e=d.prev(),f=e.attr("class").split("-"),g=d.attr("class").split("-");f[2]=parseFloat(f[2])+parseFloat(g[2]),d.find(".layout-column").contents().appendTo(e.find(".layout-column")),e.attr("class",f.join("-")),d.remove(),b(),jQuery(".column-tools").remove(),jQuery(".column-merge").remove()}),a("#grid-pages-panel").on("mouseenter",".row",function(c){var d=jQuery(this);jQuery(".column-tools,.column-merge").remove(),d.children().children().first().append('<div class="column-remove column-tools"><i class="icon-remove"></i></div>'),d.children().children().last().append('<div class="column-sort column-tools" style="text-align:right;"><i class="dashicons dashicons-menu drag-handle sort-handle"></i></div>'),d.children().children().not(":first").prepend('<div class="column-merge"><div class="column-join column-tools"><i class="icon-join"></i></div></div>');var e=d.parent().parent().parent().width()/12-1;d.children().children().each(function(b,c){var d=a(c),e=d.width()/2-5;d.prepend('<div class="column-fieldinsert column-tools"><i class="dashicons dashicons-plus-alt"></i></div>'),d.parent().hasClass("col-xs-1")||(d.prepend('<div class="column-split column-tools"><i class="dashicons dashicons-leftright"></i></div>'),d.find(".column-split").css("left",e))}),jQuery(".column-merge").draggable({axis:"x",helper:"clone",appendTo:d,grid:[e,0],drag:function(c,d){a(this).addClass("dragging"),a(".column-tools").remove(),a(".column-split").remove();var e=a(this).parent().parent(),f=d.helper,g=d.originalPosition.left>f.position().left?"left":"right",h=e.prev(),i=Math.round(e.parent().width()/12-10),j=Math.abs(d.originalPosition.left-f.position().left);if(e.parent().addClass("sizing"),j>=i){var k=h.attr("class").split("-"),l=e.attr("class").split("-");k[2]=parseFloat(k[2]),l[2]=parseFloat(l[2]),"left"===g?(k[2]--,l[2]++,k[2]>0&&k[2]<k[2]+l[2]?(h.attr("class",k.join("-")),e.attr("class",l.join("-")),d.originalPosition.left=f.position().left):a(this).draggable("option","disabled",!0)):(k[2]++,l[2]--,l[2]>0&&l[2]<l[2]+l[2]?(h.attr("class",k.join("-")),e.attr("class",l.join("-")),d.originalPosition.left=f.position().left):a(this).draggable("option","disabled",!0)),b()}},stop:function(){a(this).removeClass("dragging").parent().parent().parent().removeClass("sizing")}})}),a("#grid-pages-panel").on("mouseleave",".row",function(a){jQuery(".column-tools").remove(),jQuery(".column-merge").remove()}),a("#grid-pages-panel").on("click",".layout-form-field .icon-remove",function(){var b=a(this),c=b.parent(),d=a("#"+c.data("config"));c.slideUp(100,function(){a(this).remove()}),d.slideUp(100,function(){a(this).remove()})}),a(document).on("click",".layout-form-field .dashicons-admin-page",function(){var b=a(this),d=b.parent(),e=d.data("config"),f=a("#"+e).formJSON(),g=b.closest(".column-container"),h=d.clone().css("display",""),i={};d.hasClass("field-edit-open")&&(d.removeClass("field-edit-open"),h.removeClass("field-edit-open"),a(".caldera-editor-field-config-wrapper").hide()),f.config.fields[e]&&(i=f.config.fields[e],delete i.ID),c(h,g,i)}),a(document).on("click",".layout-form-field .icon-edit",function(){var b=a(this),c=b.parent(),d=a("#"+c.data("config")+"_type").val();a(".caldera-editor-field-config-wrapper").hide(),c.hasClass("field-edit-open")?c.removeClass("field-edit-open"):(a(".layout-form-field").removeClass("field-edit-open"),c.addClass("field-edit-open"),a("#"+c.data("config")).show()),a(document).trigger("show."+c.data("config")),a(document).trigger("show.fieldedit"),"radio"!==d&&"checkbox"!==d&&"dropdown"!==d&&"toggle_switch"!==d||a("#"+c.data("config")+"_auto").trigger("change")}),a("body").on("click",".layout-modal-edit-closer,.layout-modal-save-action",function(b){b.preventDefault();var c=a(this),d=a(".layout-form-field.edit-open"),e=c.closest(".layout-modal-container");settings=e.find(".settings-panel").first(),a(".edit-open").removeClass("edit-open"),settings.appendTo(d.find(".settings-wrapper")).hide(),e.hide()}),a(".layout-editor-body").on("change",".layout-core-pod-query",function(){a(this).parent().find(".settings-panel-row").remove(),a(".edit-open").find(".drag-handle .set-pod").html(" - "+a(this).val())}),a(".layout-editor-body").on("click",".remove-where",function(){a(this).closest(".settings-panel-row").remove()}),a(".layout-editor-body").on("click",".use-pod-container",function(){var b=a(this),c=b.prev(),d=c.val();if(d.length){a(".edit-open").find(".drag-handle .set-pod").html(" - "+c.val()),b.parent().parent().find(".spinner").css("display","inline-block");var e={action:"pq_loadpod",pod_reference:{pod:d}};a.post(ajaxurl,e,function(c){b.parent().find(".spinner").css("display","none");var d=a("#where-line-tmpl").html(),e="",f=b.closest(".settings-panel").data("container");for(var g in c)e+='<option value="'+c[g]+'">'+c[g]+"</option>";d=d.replace(/{{fields}}/g,e).replace(/{{container_id}}/g,f),b.parent().append(d)})}}),a(".caldera-editor-header").on("click",".column-sort .icon-edit",function(a){}),a(".layout-editor-body").on("tray_loaded",".layout-template-tray",function(){d()}),a(".caldera-editor-header").on("click",".caldera-editor-header-nav a",function(b){b.preventDefault();var c=a(this);a(".caldera-editor-header-nav li").removeClass("active"),a(".caldera-editor-body").hide(),a(c.attr("href")).show(),c.parent().addClass("active"),rebind_field_bindings()}),a("body").on("change",".required",function(){check_required_bindings(this)}),a("body").on("submit",".caldera-forms-options-form",function(b){a(".required.has-error").length&&b.preventDefault()}),a(".caldera-editor-body").on("click",".add-toggle-option",function(b){var c=a(this);if(c.data("bulk"))return a(c.data("bulk")).toggle(),void a(c.data("bulk")).find("textarea").focus();var d=c.closest(".caldera-editor-field-config-wrapper"),e=d.find(".toggle-options"),f=a("#field-option-row-tmpl").html(),g=Handlebars.compile(f),h="opt"+parseInt(1048576*(Math.random()+1)),i={_name:"config[fields]["+d.prop("id")+"][config]",option:{}};if(c.data("options")){for(var j=a(c.data("options")),k=j.val().split("\n"),l=!1,m=0;m<k.length;m++){var n=k[m],o=n,p=o.split("|");p.length>1&&(o=p[0],n=p[1],l=!0),i.option["opt"+parseInt(1048576*(Math.random()+m))]={value:o,label:n,default:!1}}a(c.data("options")).parent().hide(),j.val(""),!0===l?d.find(".toggle_show_values").prop("checked",!0):d.find(".toggle_show_values").prop("checked",!1),e.empty()}else i.option[h]={value:"",label:"",default:!1};a(".preset_options").val(""),e.append(g(i)),d.find(".toggle_show_values").trigger("change"),a(".toggle-options").sortable({handle:".dashicons-sort"}),k||e.find(".toggle_label_field").last().focus()}),a(".caldera-editor-body").on("change",".preset_options",function(b){var c=a(this),d=c.val(),e=a(c.data("bulk"));preset_options&&preset_options[d]&&preset_options[d].data&&("object"==typeof preset_options[d].data&&preset_options[d].data.length&&(preset_options[d].data=preset_options[d].data.join("\n")),e.val(preset_options[d].data))}),a(".caldera-editor-body").on("click",".toggle-remove-option",function(b){var c=a(this).closest(".caldera-editor-field-config-wrapper").find(".field-config").first();a(this).parent().remove(),c.trigger("change"),a(document).trigger("option.remove")}),a(".caldera-editor-body").on("click",".page-toggle",function(b){var c=a(this),d=c.parent(),e=d.find(".button");e.removeClass("button-primary"),a(".layout-grid-panel").hide().removeClass("page-active"),a("#"+c.data("page")).show().addClass("page-active"),c.addClass("button-primary"),e.each(function(b,c){a(c).html(d.data("title")+" "+(b+1))}),1===e.length&&d.hide()}),a(".caldera-editor-body").on("blur toggle.values",".toggle_label_field",function(b){var c=a(this),d=c.prev();d.val().length||d.val(c.val())}),a(document).on("change focusout",".toggle_value_field",function(){a(document).trigger("show.fieldedit")}),a(document).on("show.fieldedit option.remove",function(b){a(".toggle_value_field.has-error").removeClass("has-error");for(var c=a("#"+a(".layout-form-field.field-edit-open").data("config")),d=c.find(".toggle_value_field"),e=c.find(".notice"),f=0,g=0;g<d.length;g++){for(var h=(d[g].value,0),i=0;i<d.length;i++)d[g]!==d[i]&&d[g].value===d[i].value&&(a(d[i]).addClass("has-error"),h++);h>0&&(a(d[g]).addClass("has-error"),f++)}f>0?(e.slideDown(),b.preventDefault()):e.slideUp()});var h=!1;focus_initial_field=function(b){var c=a(".layout-grid-panel .icon-edit").first();c.length?c.trigger("click"):(a(".layout-column.column-container").first().trigger("mouseover"),h=setInterval(e,500)),a(document).off("load.page",focus_initial_field)},a(document).on("load.page",focus_initial_field),cf_clear_puler=function(){h&&(clearTimeout(h),a(document).off("mouseover",".layout-new-form-field, .column-fieldinsert",cf_clear_puler)),a(".layout-new-form-field, .column-fieldinsert").fadeIn()},a(document).on("mouseover",".layout-new-form-field, .column-fieldinsert",cf_clear_puler),rebuild_field_binding(),a(document).trigger("load.page"),a("body").on("click",".caldera-processor-nav a",function(b){b.preventDefault();var c=a(this);a(".caldera-processor-nav").removeClass("active"),a(".caldera-editor-processor-config-wrapper").hide(),a(c.attr("href")).show(),c.parent().addClass("active")}),a("body").on("click",".add-new-processor",function(b){var c=a(this),d=Handlebars.compile(a("#processor-wrapper-tmpl").html());wrap=a(".active-processors-list"),process_conf=a(".caldera-editor-processor-config"),processid=Math.round(1e8*Math.random()),new_templ=Handlebars.compile(a("#processor-line-tmpl").html()),new_proc={id:"fp_"+processid,type:c.data("type")},wrap.append(new_templ(new_proc)),process_conf.append(d(new_proc)),a("#form_processor_baldrickModalCloser").trigger("click"),a(".caldera-processor-nav a").last().trigger("click"),a("#fp_"+processid+"_type").val(c.data("type")).trigger("change"),f(),baldrickTriggers()}),a("body").on("click",".delete-processor",function(b){var c=a(this),d=c.closest(".caldera-editor-processor-config-wrapper");d.data("type"),confirm(c.data("confirm"))&&(a("."+d.prop("id")).remove(),d.remove(),a(".caldera-processor-nav a").first().trigger("click"),rebuild_field_binding())}),a("body").on("change",".caldera-select-processor-type",function(b){var c=a(this),d=c.closest(".caldera-editor-processor-config-wrapper"),e=c.find('option[value="'+c.val()+'"]').text(),f=d.find(".caldera-editor-processor-title"),h=a(".caldera-processor-nav.active a");""===e&&(e=f.data("title")),f.html(e),h.html(e+' <span class="processor-line-number"></span>').parent().addClass("processor_type_"+c.val()),g(this),rebuild_field_binding()}),a(document).on("click","#cf-shortcode-preview",function(){a(this).focus().select()}),a(document).on("change",".cf-email-preview-toggle",function(){var b=a(this),c=a(".caldera-header-email-preview-button");b.is(":checked")?c.show().attr("aria-hidden","false").css("visibility","visible"):c.hide().attr("aria-hidden","true").css("visibility","hidden")}),rebuild_field_binding(),a(".caldera-select-processor-type").each(function(a,b){g(b)}),f()}),Handlebars.registerHelper("_field",function(a){var b=this,c="",d="",e="",f=this[a.hash.slug]?' data-default="'+this[a.hash.slug]+'"':"";a.hash.required&&(c=" required"),a.hash.exclude&&(e='data-exclude="'+a.hash.exclude+'"'),a.hash.array&&(d="[]","true"!==a.hash.array&&(f='value="'+a.hash.array+'"')),out="<select "+(a.hash.type?'data-type="'+a.hash.type+'"':"")+f+" "+e+' name="'+this._name+"["+a.hash.slug+"]"+d+'" id="'+this._id+"_"+a.hash.slug+'" class="block-input field-config caldera-field-bind'+c+'">',this[a.hash.slug]?out+='<option class="bound-field" value="'+this[a.hash.slug]+'" class="bound-field"></option>':a.hash.required||(out+='<option value=""></option>');for(var g in current_form_fields){var h="";a.hash.type&&current_form_fields[g].type!==a.hash.type||(b[a.hash.slug]&&b[a.hash.slug]===g&&(h=' selected="selected"'),out+='<option value="'+g+'"'+h+">"+current_form_fields[g].label+" ["+current_form_fields[g].slug+"]</option>")}return out+="</select>",a.hash.required&&(out+='<input class="field-config" name="'+this._name+'[_required_bounds][]" type="hidden" value="'+a.hash.slug+'">'),out}),Handlebars.registerHelper("console",function(a,b){console.log(this)});
assets/build/js/field-config.min.js CHANGED
@@ -1 +1 @@
1
- function Caldera_Forms_Field_Config(a,b,c){function d(a,b,c,d){var g=b.parent().parent();return g.removeClass("has-error"),g.find(".help-block").remove(),a?(g.removeClass("has-error"),f(),!0):(g.addClass("has-error").append('<span id="cf-error-'+b.attr("id")+'" class="help-block '+d+'">'+c+"</span>"),b.prop("required")&&e(),b.addClass("parsely-error"),!1)}function e(){i.prop("disabled",!0).attr("aria-disabled",!0)}function f(){i.prop("disabled",!1).attr("aria-disabled",!1)}var g=this,h={},i=b.find(":submit, .cf-page-btn-next");this.init=function(){c.each(a,function(a,b){h[b.id]=g[b.type](b)})},this.button=function(a){var b=a.id;c(document).on("click dblclick","#"+b,function(a){c("#"+b+"_btn").val(a.type).trigger("change")})},this.html=function(a){function b(){for(var b=c(document.getElementById(a.tmplId)).html(),d=c(document.getElementById(a.contentId)),e=a.binds,f=0;f<e.length;f++){for(var g=c('[data-field="'+e[f]+'"]'),h=[],i=0;i<g.length;i++)if(!c(g[i]).is(":radio,:checkbox")||c(g[i]).prop("checked"))if(c(g[i]).is("input:file")){var j=g[i].value.split("\\");h.push(j[j.length-1])}else g[i].value&&h.push(g[i].value);b=b.replace(new RegExp("{{"+e[f]+"}}","g"),h.join(", "))}d.html(b).trigger("change")}0!=a.sync&&(c.each(a.bindFields,function(a,d){c(document.getElementById(d)).on("change keyup",b)}),b())},this.summary=this.html;var j={};this.range_slider=function(a){function b(){"object"!=j[a.id]&&(j[a.id]={value:a.default,init:{}});var b={onSlide:function(b,d){j[a.id].value=d,d=d.toFixed(a.value),c("#"+a.id+"_value").html(d)},onInit:function(){this.value=j[a.id].value,d.parent().find(".rangeslider").css("backgroundColor",a.trackcolor),d.parent().find(".rangeslider__fill").css("backgroundColor",a.color),d.parent().find(".rangeslider__handle").css("backgroundColor",a.handle).css("borderColor",a.handleborder)},polyfill:!1};d.rangeslider(b),j[a.id].init=b}var d=c(document.getElementById(a.id));d.on("change",function(){c("#"+a.id+"_value").html(this.value)}).css("width","100%"),c(document).on("cf.pagenav cf.add cf.disable cf.modal",function(){var b=document.getElementById(a.id);if(null!=b){var d=c(b);d.rangeslider("destroy"),d.rangeslider(j[a.id].init)}}),b()},this.star_rating=function(a){var b=a.options.score,d=c(document.getElementById(a.starFieldId)),e=(c(document.getElementById(a.id)),function(){var c=a.options;c.click=function(){b=d.raty("score"),d.trigger("change")},d.raty(c),d.raty("score",b)});e();var f=!1;jQuery(document).on("cf.add",function(){!1===f&&(f=!0,d.length&&(d.raty("destroy"),e()),setTimeout(function(){f=!1},500))})},this.toggle_switch=function(a){c(document).on("reset","#"+a.id,function(b){c.each(a.options,function(b,d){c(document.getElemenetById(d)).removeClass(a.selectedClassName).addClass(a.defaultClassName)}),c(document.getElementById(a.id)).prop("checked","")})},this.phone_better=function(a){var b=c(document.getElementById(a.id)),e=function(){var b=document.getElementById("cf-error-"+a.id);null!=b&&b.remove()},f=function(){e();var f;b.intlTelInput("isValidNumber");c.trim(b.val())&&(f=!!b.intlTelInput("isValidNumber"));var g,h=b.intlTelInput("getValidationError");0==h?(f=!0,g=""):g="undefined"!=a.messages[h]?a.messages[h]:a.messages.generic,d(f,b,g,"help-block-phone_better")};b.intlTelInput(a.options),b.on("keyup change",e),b.blur(function(){e(),f()}),b.on("change",f)},this.wysiwyg=function(a){var b=document.getElementById(a.id);if(null!=b){var d=c(b);d.trumbowyg(a.options);var e=d.parent().find(".trumbowyg-editor");e.html(d.html()),e.bind("input propertychange",function(){d.html(e.html())})}},this.credit_card_number=function(a){function b(){e();var b=c(document.getElementById(a.cvc)),d=c(document.getElementById(a.exp));b.blur(function(){g.creditCardUtil.validateCVC(h,b),g.creditCardUtil.validateExp(d)})}function f(b){var d={0:"amex",1:"discover",2:"visa",3:"discover",4:"mastercard"},e="credit-card.svg";c.each(d,function(a,c){if(0===b.indexOf(c))return e="cc-"+c+".svg",!1}),h.css("background",'url("'+a.imgPath+e+'")')}var h=c(document.getElementById(a.id));0==a.exp&&0==a.cvc||b(),h.length&&(h.payment("formatCardNumber"),h.blur(function(){var b=h.val(),e=c.payment.validateCardNumber(b),g=c.payment.cardType(b);d(e,h,a.invalid,"help-block-credit_card_number help-block-credit_card"),e&&f(g)}))},this.credit_card_exp=function(a){var b=c(document.getElementById(a.id));b.length&&(b.payment("formatCardExpiry"),b.blur(function(){var c=g.creditCardUtil.validateExp(b);d(c,b,a.invalid,"help-block-credit_card_exp help-block-credit_card")}))},this.credit_card_cvc=function(a){var b=c(document.getElementById(a.id));if(b.length&&(b.payment("formatCardCVC"),!1!==a.ccField)){var e=c(document.getElementById(a.ccField));b.blur(function(){var c=g.creditCardUtil.validateExp(e,b);d(c,b,a.invalid,"help-block-credit_card_cvc help-block-credit_card")})}},this.creditCardUtil={validateCVC:function(a,b){var d=b.val(),e=c.payment.validateCardNumber(a.val()),f=!1;if(e){var g=c.payment.cardType(a.val());f=c.payment.validateCardCVC(d,g)}return f},validateExp:function(a){var b=a.val().split("/");return c.payment.validateCardExpiry(b[0].trim(),b[1].trim())}},this.color_picker=function(a){c(document.getElementById(a.id)).miniColors(a.settings)}}
1
+ function Caldera_Forms_Field_Config(a,b,c){function d(a,b,c,d){var g=b.parent().parent();return g.removeClass("has-error"),g.find(".help-block").remove(),a?(g.removeClass("has-error"),f(),!0):(g.addClass("has-error").append('<span id="cf-error-'+b.attr("id")+'" class="help-block '+d+'">'+c+"</span>"),b.prop("required")&&e(),b.addClass("parsely-error"),!1)}function e(){i.prop("disabled",!0).attr("aria-disabled",!0)}function f(){i.prop("disabled",!1).attr("aria-disabled",!1)}var g=this,h={},i=b.find(":submit, .cf-page-btn-next");this.init=function(){c.each(a,function(a,b){h[b.id]=g[b.type](b)})},this.button=function(a){var b=a.id;c(document).on("click dblclick","#"+b,function(a){c("#"+b+"_btn").val(a.type).trigger("change")})},this.html=function(a){function b(){void 0==e[a.tmplId]&&(e[a.tmplId]=c(document.getElementById(a.tmplId)).html());for(var b=e[a.tmplId],d=c(document.getElementById(a.contentId)),g=0;g<f.length;g++){for(var h=c('[data-field="'+f[g]+'"]'),i=[],j=0;j<h.length;j++)if(!c(h[j]).is(":radio,:checkbox")||c(h[j]).prop("checked"))if(c(h[j]).is("input:file")){var k=h[j].value.split("\\");i.push(k[k.length-1])}else h[j].value&&i.push(h[j].value);b=b.replace(new RegExp("{{"+f[g]+"}}","g"),i.join(", "))}d.html(b).trigger("change")}function d(){c.each(a.bindFields,function(a,d){c(document.getElementById(d)).on("click keyup",b)})}if(0!=a.sync){var e={},f=a.binds;c(document).on("cf.pagenav cf.add cf.disable",function(){d()}),d(),b()}},this.summary=this.html;var j={};this.range_slider=function(a){var b=c(document.getElementById(a.id));b.on("change",function(){c("#"+a.id+"_value").html(this.value)}).css("width","100%"),c(document).on("cf.pagenav cf.add cf.disable cf.modal",function(){var b=document.getElementById(a.id);if(null!=b){var d=c(b),e=d.val();d.rangeslider("destroy"),d.rangeslider(j[a.id].init),d.val(e).change()}}),function(){"object"!=j[a.id]&&(j[a.id]={value:a.default,init:{}});var d={onSlide:function(b,d){j[a.id].value=d,d=d.toFixed(a.value),c("#"+a.id+"_value").html(d)},onInit:function(){this.value=j[a.id].value,b.parent().find(".rangeslider").css("backgroundColor",a.trackcolor),b.parent().find(".rangeslider__fill").css("backgroundColor",a.color),b.parent().find(".rangeslider__handle").css("backgroundColor",a.handle).css("borderColor",a.handleborder)},polyfill:!1};b.rangeslider(d),j[a.id].init=d}()},this.star_rating=function(a){var b=a.options.score,d=c(document.getElementById(a.starFieldId)),e=(c(document.getElementById(a.id)),function(){var c=a.options;c.click=function(){b=d.raty("score"),d.trigger("change")},d.raty(c),d.raty("score",b)});e();var f=!1;jQuery(document).on("cf.add",function(){!1===f&&(f=!0,d.length&&(d.raty("destroy"),e()),setTimeout(function(){f=!1},500))})},this.toggle_switch=function(a){c(document).on("reset","#"+a.id,function(b){c.each(a.options,function(b,d){c(document.getElemenetById(d)).removeClass(a.selectedClassName).addClass(a.defaultClassName)}),c(document.getElementById(a.id)).prop("checked","")})},this.phone_better=function(a){var e=c(document.getElementById(a.id)),f=function(){var b=document.getElementById("cf-error-"+a.id);null!=b&&b.remove()},g=function(){f();var b;c.trim(e.val())&&(b=!!e.intlTelInput("isValidNumber"));var g,h=e.intlTelInput("getValidationError");return 0==h?(b=!0,g=""):g="undefined"!=a.messages[h]?a.messages[h]:a.messages.generic,d(b,e,g,"help-block-phone_better"),b};e.intlTelInput(a.options),e.on("keyup change",f),e.blur(function(){f(),g()}),e.on("change",g),b.on("submit",function(){g()})},this.wysiwyg=function(a){var b=document.getElementById(a.id);if(null!=b){var d=c(b);d.trumbowyg(a.options);var e=d.parent().find(".trumbowyg-editor");e.html(d.html()),e.bind("input propertychange",function(){d.html(e.html())})}},this.credit_card_number=function(a){function b(b){var d={0:"amex",1:"discover",2:"visa",3:"discover",4:"mastercard"},e="credit-card.svg";c.each(d,function(a,c){if(0===b.indexOf(c))return e="cc-"+c+".svg",!1}),f.css("background",'url("'+a.imgPath+e+'")')}var f=c(document.getElementById(a.id));0==a.exp&&0==a.cvc||function(){e();var b=c(document.getElementById(a.cvc)),d=c(document.getElementById(a.exp));b.blur(function(){b.val()&&g.creditCardUtil.validateCVC(f,b),d.val()&&g.creditCardUtil.validateExp(d)})}(),f.length&&(f.payment("formatCardNumber"),f.blur(function(){var e=f.val(),g=c.payment.validateCardNumber(e),h=c.payment.cardType(e);d(g,f,a.invalid,"help-block-credit_card_number help-block-credit_card"),g&&b(h)}))},this.credit_card_exp=function(a){var b=c(document.getElementById(a.id));b.length&&(b.payment("formatCardExpiry"),b.blur(function(){d(g.creditCardUtil.validateExp(b),b,a.invalid,"help-block-credit_card_exp help-block-credit_card")}))},this.credit_card_cvc=function(a){var b=c(document.getElementById(a.id));if(b.length&&(b.payment("formatCardCVC"),!1!==a.ccField)){var e=c(document.getElementById(a.ccField));b.blur(function(){d(g.creditCardUtil.validateExp(e,b),b,a.invalid,"help-block-credit_card_cvc help-block-credit_card")})}},this.creditCardUtil={validateCVC:function(a,b){var d=b.val(),e=c.payment.validateCardNumber(a.val()),f=!1;if(e){var g=c.payment.cardType(a.val());f=c.payment.validateCardCVC(d,g)}return f},validateExp:function(a){var b=a.val().split("/");if(b&&2==b.length)return c.payment.validateCardExpiry(b[0].trim(),b[1].trim())}},this.color_picker=function(a){c(document.getElementById(a.id)).miniColors(a.settings),c(document).on("cf.pagenav cf.add cf.disable cf.modal",function(){c(document.getElementById(a.id)).miniColors(a.settings)})}}
assets/build/js/fields.min.js CHANGED
@@ -1,4 +1,4 @@
1
- function color_picker_init(){jQuery(".minicolor-picker").miniColors()}function toggle_button_init(a,b){var c=jQuery(b),d=c.find(".cf-toggle-group-radio:checked");d.length&&jQuery("#"+d.data("ref")).trigger("click")}jQuery&&function(a){a.extend(a.fn,{miniColors:function(b,c){var d=function(b,c,d){var e=s(b.val());e||(e="ffffff");var f=x(e),h=a('<span class="input-group-addon" style="background-color: #'+e+'" href="#"></span>');h.insertAfter(b),b.addClass("miniColors").data("original-maxlength",b.attr("maxlength")||null).data("original-autocomplete",b.attr("autocomplete")||null).data("letterCase",c.letterCase?c.letterCase:"uppercase").data("trigger",h).data("hsb",f).data("change",c.change?c.change:null).data("close",c.close?c.close:null).data("open",c.open?c.open:null).attr("maxlength",7).attr("autocomplete","off").val("#"+o(e,c.letterCase)).trigger("change"),c.readonly&&b.prop("readonly",!0),c.disabled&&g(b),h.on("click.miniColors",function(a){a.preventDefault(),""===b.val()&&b.val("#").trigger("change"),i(b)}),b.on("focus.miniColors",function(a){""===b.val()&&b.val("#").trigger("change"),i(b)}),b.on("blur.miniColors",function(a){var c=s(y(b.data("hsb")));b.val(c?"#"+o(c,b.data("letterCase")):"").trigger("change")}),b.on("keydown.miniColors",function(a){9===a.keyCode&&j(b)}),b.on("keyup.miniColors",function(a){n(b)}),b.on("paste.miniColors",function(a){setTimeout(function(){n(b)},5)})},e=function(b){j(),b=a(b),b.data("trigger").remove(),b.attr("autocomplete",b.data("original-autocomplete")).attr("maxlength",b.data("original-maxlength")).removeData().removeClass("miniColors").off(".miniColors"),a(document).off(".miniColors")},f=function(a){a.prop("disabled",!1).data("trigger").css("opacity",1)},g=function(a){j(a),a.prop("disabled",!0).data("trigger").css("opacity",.5)},i=function(b){if(b.prop("disabled"))return!1;j();var c=a('<div class="miniColors-selector"></div>');c.append('<div class="miniColors-colors" style="background-color: #FFF;"><div class="miniColors-colorPicker"><div class="miniColors-colorPicker-inner"></div></div>').append('<div class="miniColors-hues"><div class="miniColors-huePicker"></div></div>').css("display","none").addClass(b.attr("class")).removeClass("form-control");var d=b.data("hsb");c.find(".miniColors-colors").css("backgroundColor","#"+y({h:d.h,s:100,b:100}));var e=b.data("colorPosition");e||(e=p(d)),c.find(".miniColors-colorPicker").css("top",e.y+"px").css("left",e.x+"px");var f=b.data("huePosition");f||(f=q(d)),c.find(".miniColors-huePicker").css("top",f.y+"px"),b.data("selector",c).data("huePicker",c.find(".miniColors-huePicker")).data("colorPicker",c.find(".miniColors-colorPicker")).data("mousebutton",0),a("BODY").append(c);var g=b.data("trigger"),h=!b.is(":visible"),i=h?g.offset().top+g.outerHeight():b.offset().top+b.outerHeight(),m=h?g.offset().left:b.offset().left,n=c.outerWidth(),o=c.outerHeight(),r=g.outerWidth(),s=g.outerHeight(),u=a(window).height(),v=a(window).width(),w=a(window).scrollTop(),x=a(window).scrollLeft();i+o>u+w&&(i=i-o-s),m+n>v+x&&(m=m-n+r),c.css({top:i,left:m}).fadeIn(100),c.on("selectstart",function(){return!1}),(!a.browser.msie||a.browser.msie&&a.browser.version>=9)&&a(window).on("resize.miniColors",function(a){j(b)}),a(document).on("mousedown.miniColors touchstart.miniColors",function(c){b.data("mousebutton",1);var d=a(c.target).parents().andSelf();return d.hasClass("miniColors-colors")&&(c.preventDefault(),b.data("moving","colors"),k(b,c)),d.hasClass("miniColors-hues")&&(c.preventDefault(),b.data("moving","hues"),l(b,c)),d.hasClass("miniColors-selector")?void c.preventDefault():void(d.hasClass("miniColors")||j(b))}),a(document).on("mouseup.miniColors touchend.miniColors",function(a){a.preventDefault(),b.data("mousebutton",0).removeData("moving")}).on("mousemove.miniColors touchmove.miniColors",function(a){a.preventDefault(),1===b.data("mousebutton")&&("colors"===b.data("moving")&&k(b,a),"hues"===b.data("moving")&&l(b,a))}),b.data("open")&&b.data("open").call(b.get(0),"#"+y(d),t(d))},j=function(b){b||(b=a(".miniColors")),b.each(function(){var c=a(this).data("selector");a(this).removeData("selector"),a(c).fadeOut(100,function(){if(b.data("close")){var c=b.data("hsb"),d=y(c);b.data("close").call(b.get(0),"#"+d,t(c))}a(this).remove()})}),a(document).off(".miniColors")},k=function(a,b){var c=a.data("colorPicker");c.hide();var d={x:b.pageX,y:b.pageY};b.originalEvent.changedTouches&&(d.x=b.originalEvent.changedTouches[0].pageX,d.y=b.originalEvent.changedTouches[0].pageY),d.x=d.x-a.data("selector").find(".miniColors-colors").offset().left-5,d.y=d.y-a.data("selector").find(".miniColors-colors").offset().top-5,d.x<=-5&&(d.x=-5),d.x>=144&&(d.x=144),d.y<=-5&&(d.y=-5),d.y>=144&&(d.y=144),a.data("colorPosition",d),c.css("left",d.x).css("top",d.y).show();var e=Math.round(.67*(d.x+5));e<0&&(e=0),e>100&&(e=100);var f=100-Math.round(.67*(d.y+5));f<0&&(f=0),f>100&&(f=100);var g=a.data("hsb");g.s=e,g.b=f,m(a,g,!0)},l=function(a,b){var c=a.data("huePicker");c.hide();var d={y:b.pageY};b.originalEvent.changedTouches&&(d.y=b.originalEvent.changedTouches[0].pageY),d.y=d.y-a.data("selector").find(".miniColors-colors").offset().top-1,d.y<=-1&&(d.y=-1),d.y>=149&&(d.y=149),a.data("huePosition",d),c.css("top",d.y).show();var e=Math.round(2.4*(150-d.y-1));e<0&&(e=0),e>360&&(e=360);var f=a.data("hsb");f.h=e,m(a,f,!0)},m=function(a,b,c){a.data("hsb",b);var d=y(b);if(c&&a.val("#"+o(d,a.data("letterCase"))).trigger("change"),a.data("trigger").css("backgroundColor","#"+d),a.data("selector")&&a.data("selector").find(".miniColors-colors").css("backgroundColor","#"+y({h:b.h,s:100,b:100})),a.data("change")){if(d===a.data("lastChange"))return;a.data("change").call(a.get(0),"#"+d,t(b)),a.data("lastChange",d)}},n=function(b){b.val("#"+r(b.val())).trigger("change");var c=s(b.val());if(!c)return!1;var d=x(c),e=b.data("hsb");if(d.h===e.h&&d.s===e.s&&d.b===e.b)return!0;var f=p(d),g=a(b.data("colorPicker"));g.css("top",f.y+"px").css("left",f.x+"px"),b.data("colorPosition",f);var h=q(d),i=a(b.data("huePicker"));return i.css("top",h.y+"px"),b.data("huePosition",h),m(b,d),!0},o=function(a,b){return"lowercase"===b?a.toLowerCase():"uppercase"===b?a.toUpperCase():a},p=function(a){var b=Math.ceil(a.s/.67);b<0&&(b=0),b>150&&(b=150);var c=150-Math.ceil(a.b/.67);return c<0&&(c=0),c>150&&(c=150),{x:b-5,y:c-5}},q=function(a){var b=150-a.h/2.4;return b<0&&(h=0),b>150&&(h=150),{y:b-1}},r=function(a){return a.replace(/[^A-F0-9]/gi,"")},s=function(a){return(a=r(a))?(3===a.length&&(a=a[0]+a[0]+a[1]+a[1]+a[2]+a[2]),6===a.length?a:null):null},t=function(a){var b={},c=Math.round(a.h),d=Math.round(255*a.s/100),e=Math.round(255*a.b/100);if(0===d)b.r=b.g=b.b=e;else{var f=e,g=(255-d)*e/255,h=(f-g)*(c%60)/60;360===c&&(c=0),c<60?(b.r=f,b.b=g,b.g=g+h):c<120?(b.g=f,b.b=g,b.r=f-h):c<180?(b.g=f,b.r=g,b.b=g+h):c<240?(b.b=f,b.r=g,b.g=f-h):c<300?(b.b=f,b.g=g,b.r=g+h):c<360?(b.r=f,b.g=g,b.b=f-h):(b.r=0,b.g=0,b.b=0)}return{r:Math.round(b.r),g:Math.round(b.g),b:Math.round(b.b)}},u=function(b){var c=[b.r.toString(16),b.g.toString(16),b.b.toString(16)];return a.each(c,function(a,b){1===b.length&&(c[a]="0"+b)}),c.join("")},v=function(a){return a=parseInt(a.indexOf("#")>-1?a.substring(1):a,16),{r:a>>16,g:(65280&a)>>8,b:255&a}},w=function(a){var b={h:0,s:0,b:0},c=Math.min(a.r,a.g,a.b),d=Math.max(a.r,a.g,a.b),e=d-c;return b.b=d,b.s=0!==d?255*e/d:0,0!==b.s?a.r===d?b.h=(a.g-a.b)/e:a.g===d?b.h=2+(a.b-a.r)/e:b.h=4+(a.r-a.g)/e:b.h=-1,b.h*=60,b.h<0&&(b.h+=360),b.s*=100/255,b.b*=100/255,b},x=function(a){var b=w(v(a));return 0===b.s&&(b.h=360),b},y=function(a){return u(t(a))};switch(b){case"readonly":return a(this).each(function(){a(this).hasClass("miniColors")&&a(this).prop("readonly",c)}),a(this);case"disabled":return a(this).each(function(){a(this).hasClass("miniColors")&&(c?g(a(this)):f(a(this)))}),a(this);case"value":if(void 0===c){if(!a(this).hasClass("miniColors"))return;var z=a(this),A=s(z.val());return A?"#"+o(A,z.data("letterCase")):null}return a(this).each(function(){a(this).hasClass("miniColors")&&(a(this).val(c).trigger("change"),n(a(this)))}),a(this);case"destroy":return a(this).each(function(){a(this).hasClass("miniColors")&&e(a(this))}),a(this);default:return b||(b={}),a(this).each(function(){"input"===a(this)[0].tagName.toLowerCase()&&(a(this).data("trigger")||d(a(this),b,c))}),a(this)}}})}(jQuery),document.addEventListener("load",color_picker_init,!1),jQuery(document).ajaxComplete(function(){color_picker_init()}),function(a,b){function c(){return new Date(Date.UTC.apply(Date,arguments))}function d(){var a=new Date;return c(a.getFullYear(),a.getMonth(),a.getDate())}function e(a){return function(){return this[a].apply(this,arguments)}}function f(b,c){function d(a,b){return b.toLowerCase()}var e,f=a(b).data(),g={},h=new RegExp("^"+c.toLowerCase()+"([A-Z])");c=new RegExp("^"+c.toLowerCase());for(var i in f)c.test(i)&&(e=i.replace(h,d),g[e]=f[i]);return g}function g(b){var c={};if(o[b]||(b=b.split("-")[0],o[b])){var d=o[b];return a.each(n,function(a,b){b in d&&(c[b]=d[b])}),c}}var h=a(window),i=function(){var b={get:function(a){return this.slice(a)[0]},contains:function(a){for(var b=a&&a.valueOf(),c=0,d=this.length;c<d;c++)if(this[c].valueOf()===b)return c;return-1},remove:function(a){this.splice(a,1)},replace:function(b){b&&(a.isArray(b)||(b=[b]),this.clear(),this.push.apply(this,b))},clear:function(){this.splice(0)},copy:function(){var a=new i;return a.replace(this),a}};return function(){var c=[];return c.push.apply(c,arguments),a.extend(c,b),c}}(),j=function(b,c){this.dates=new i,this.viewDate=d(),this.focusDate=null,this._process_options(c),this.element=a(b),this.isInline=!1,this.isInput=this.element.is("input"),this.component=!!this.element.is(".date")&&this.element.find(".add-on, .input-group-addon, .btn"),this.hasInput=this.component&&this.element.find("input").length,this.component&&0===this.component.length&&(this.component=!1),this.picker=a(p.template),this._buildEvents(),this._attachEvents(),this.isInline?this.picker.addClass("cfdatepicker-inline").appendTo(this.element):this.picker.addClass("cfdatepicker-dropdown dropdown-menu"),this.o.rtl&&this.picker.addClass("cfdatepicker-rtl"),this.viewMode=this.o.startView,this.o.calendarWeeks&&this.picker.find("tfoot th.today").attr("colspan",function(a,b){return parseInt(b)+1}),this._allow_update=!1,this.setStartDate(this._o.startDate),this.setEndDate(this._o.endDate),this.setDaysOfWeekDisabled(this.o.daysOfWeekDisabled),this.fillDow(),this.fillMonths(),this._allow_update=!0,this.update(),this.showMode(),this.isInline&&this.show()};j.prototype={constructor:j,_process_options:function(b){this._o=a.extend({},this._o,b);var c=this.o=a.extend({},this._o),d=c.language;switch(o[d]||(d=d.split("-")[0],o[d]||(d=m.language)),c.language=d,c.startView){case 2:case"decade":c.startView=2;break;case 1:case"year":c.startView=1;break;default:c.startView=0}switch(c.minViewMode){case 1:case"months":c.minViewMode=1;break;case 2:case"years":c.minViewMode=2;break;default:c.minViewMode=0}c.startView=Math.max(c.startView,c.minViewMode),c.multidate!==!0&&(c.multidate=Number(c.multidate)||!1,c.multidate!==!1?c.multidate=Math.max(0,c.multidate):c.multidate=1),c.multidateSeparator=String(c.multidateSeparator),c.weekStart%=7,c.weekEnd=(c.weekStart+6)%7;var e=p.parseFormat(c.format);c.startDate!==-(1/0)&&(c.startDate?c.startDate instanceof Date?c.startDate=this._local_to_utc(this._zero_time(c.startDate)):c.startDate=p.parseDate(c.startDate,e,c.language):c.startDate=-(1/0)),c.endDate!==1/0&&(c.endDate?c.endDate instanceof Date?c.endDate=this._local_to_utc(this._zero_time(c.endDate)):c.endDate=p.parseDate(c.endDate,e,c.language):c.endDate=1/0),c.daysOfWeekDisabled=c.daysOfWeekDisabled||[],a.isArray(c.daysOfWeekDisabled)||(c.daysOfWeekDisabled=c.daysOfWeekDisabled.split(/[,\s]*/)),c.daysOfWeekDisabled=a.map(c.daysOfWeekDisabled,function(a){return parseInt(a,10)});var f=String(c.orientation).toLowerCase().split(/\s+/g),g=c.orientation.toLowerCase();if(f=a.grep(f,function(a){return/^auto|left|right|top|bottom$/.test(a)}),c.orientation={x:"auto",y:"auto"},g&&"auto"!==g)if(1===f.length)switch(f[0]){case"top":case"bottom":c.orientation.y=f[0];break;case"left":case"right":c.orientation.x=f[0]}else g=a.grep(f,function(a){return/^left|right$/.test(a)}),c.orientation.x=g[0]||"auto",g=a.grep(f,function(a){return/^top|bottom$/.test(a)}),c.orientation.y=g[0]||"auto";else;},_events:[],_secondaryEvents:[],_applyEvents:function(a){for(var c,d,e,f=0;f<a.length;f++)c=a[f][0],2===a[f].length?(d=b,e=a[f][1]):3===a[f].length&&(d=a[f][1],e=a[f][2]),c.on(e,d)},_unapplyEvents:function(a){for(var c,d,e,f=0;f<a.length;f++)c=a[f][0],2===a[f].length?(e=b,d=a[f][1]):3===a[f].length&&(e=a[f][1],d=a[f][2]),c.off(d,e)},_buildEvents:function(){this.isInput?this._events=[[this.element,{focus:a.proxy(this.show,this),keyup:a.proxy(function(b){a.inArray(b.keyCode,[27,37,39,38,40,32,13,9])===-1&&this.update()},this),keydown:a.proxy(this.keydown,this)}]]:this.component&&this.hasInput?this._events=[[this.element.find("input"),{focus:a.proxy(this.show,this),keyup:a.proxy(function(b){a.inArray(b.keyCode,[27,37,39,38,40,32,13,9])===-1&&this.update()},this),keydown:a.proxy(this.keydown,this)}],[this.component,{click:a.proxy(this.show,this)}]]:this.element.is("div")?this.isInline=!0:this._events=[[this.element,{click:a.proxy(this.show,this)}]],this._events.push([this.element,"*",{blur:a.proxy(function(a){this._focused_from=a.target},this)}],[this.element,{blur:a.proxy(function(a){this._focused_from=a.target},this)}]),this._secondaryEvents=[[this.picker,{click:a.proxy(this.click,this)}],[a(window),{resize:a.proxy(this.place,this)}],[a(document),{"mousedown touchstart":a.proxy(function(a){this.element.is(a.target)||this.element.find(a.target).length||this.picker.is(a.target)||this.picker.find(a.target).length||this.hide()},this)}]]},_attachEvents:function(){this._detachEvents(),this._applyEvents(this._events)},_detachEvents:function(){this._unapplyEvents(this._events)},_attachSecondaryEvents:function(){this._detachSecondaryEvents(),this._applyEvents(this._secondaryEvents)},_detachSecondaryEvents:function(){this._unapplyEvents(this._secondaryEvents)},_trigger:function(b,c){var d=c||this.dates.get(-1),e=this._utc_to_local(d);this.element.trigger({type:b,date:e,dates:a.map(this.dates,this._utc_to_local),format:a.proxy(function(a,b){0===arguments.length?(a=this.dates.length-1,b=this.o.format):"string"==typeof a&&(b=a,a=this.dates.length-1),b=b||this.o.format;var c=this.dates.get(a);return p.formatDate(c,b,this.o.language)},this)})},show:function(){this.isInline||this.picker.appendTo("body"),this.picker.show(),this.place(),this._attachSecondaryEvents(),this._trigger("show")},hide:function(){this.isInline||this.picker.is(":visible")&&(this.focusDate=null,this.picker.hide().detach(),this._detachSecondaryEvents(),this.viewMode=this.o.startView,this.showMode(),this.o.forceParse&&(this.isInput&&this.element.val()||this.hasInput&&this.element.find("input").val())&&this.setValue(),this._trigger("hide"))},remove:function(){this.hide(),this._detachEvents(),this._detachSecondaryEvents(),this.picker.remove(),delete this.element.data().cfdatepicker,this.isInput||delete this.element.data().date},_utc_to_local:function(a){return a&&new Date(a.getTime()+6e4*a.getTimezoneOffset())},_local_to_utc:function(a){return a&&new Date(a.getTime()-6e4*a.getTimezoneOffset())},_zero_time:function(a){return a&&new Date(a.getFullYear(),a.getMonth(),a.getDate())},_zero_utc_time:function(a){return a&&new Date(Date.UTC(a.getUTCFullYear(),a.getUTCMonth(),a.getUTCDate()))},getDates:function(){return a.map(this.dates,this._utc_to_local)},getUTCDates:function(){return a.map(this.dates,function(a){return new Date(a)})},getDate:function(){return this._utc_to_local(this.getUTCDate())},getUTCDate:function(){return new Date(this.dates.get(-1))},setDates:function(){var b=a.isArray(arguments[0])?arguments[0]:arguments;this.update.apply(this,b),this._trigger("changeDate"),this.setValue()},setUTCDates:function(){var b=a.isArray(arguments[0])?arguments[0]:arguments;this.update.apply(this,a.map(b,this._utc_to_local)),this._trigger("changeDate"),this.setValue()},setDate:e("setDates"),setUTCDate:e("setUTCDates"),setValue:function(){var a=this.getFormattedDate();this.isInput?this.element.val(a).change():this.component&&this.element.find("input").val(a).change()},getFormattedDate:function(c){c===b&&(c=this.o.format);var d=this.o.language;return a.map(this.dates,function(a){return p.formatDate(a,c,d)}).join(this.o.multidateSeparator)},setStartDate:function(a){this._process_options({startDate:a}),this.update(),this.updateNavArrows()},setEndDate:function(a){this._process_options({endDate:a}),this.update(),this.updateNavArrows()},setDaysOfWeekDisabled:function(a){this._process_options({daysOfWeekDisabled:a}),this.update(),this.updateNavArrows()},place:function(){if(!this.isInline){var b,c=this.picker.outerWidth(),d=this.picker.outerHeight(),e=10,f=h.width(),g=h.height(),i=h.scrollTop(),j=jQuery(this.element).data("form-id"),k=document.getElementById("modal-"+j+"-content");b=null!==k?1e4:parseInt(this.element.parents().filter(function(){return"auto"!==a(this).css("z-index")}).first().css("z-index"))+10;var l=this.component?this.component.parent().offset():this.element.offset(),m=this.component?this.component.outerHeight(!0):this.element.outerHeight(!1),n=this.component?this.component.outerWidth(!0):this.element.outerWidth(!1),o=l.left,p=l.top;this.picker.removeClass("cfdatepicker-orient-top cfdatepicker-orient-bottom cfdatepicker-orient-right cfdatepicker-orient-left"),"auto"!==this.o.orientation.x?(this.picker.addClass("cfdatepicker-orient-"+this.o.orientation.x),"right"===this.o.orientation.x&&(o-=c-n)):(this.picker.addClass("cfdatepicker-orient-left"),l.left<0?o-=l.left-e:l.left+c>f&&(o=f-c-e));var q,r,s=this.o.orientation.y;"auto"===s&&(q=-i+l.top-d,r=i+g-(l.top+m+d),s=Math.max(q,r)===r?"top":"bottom"),this.picker.addClass("cfdatepicker-orient-"+s),"top"===s?p+=m:p-=d+parseInt(this.picker.css("padding-top")),this.picker.css({top:p,left:o,zIndex:b})}},_allow_update:!0,update:function(){if(this._allow_update){var b=this.dates.copy(),c=[],d=!1;arguments.length?(a.each(arguments,a.proxy(function(a,b){b instanceof Date&&(b=this._local_to_utc(b)),c.push(b)},this)),d=!0):(c=this.isInput?this.element.val():this.element.data("date")||this.element.find("input").val(),c=c&&this.o.multidate?c.split(this.o.multidateSeparator):[c],delete this.element.data().date),c=a.map(c,a.proxy(function(a){return p.parseDate(a,this.o.format,this.o.language)},this)),c=a.grep(c,a.proxy(function(a){return a<this.o.startDate||a>this.o.endDate||!a},this),!0),this.dates.replace(c),this.dates.length?this.viewDate=new Date(this.dates.get(-1)):this.viewDate<this.o.startDate?this.viewDate=new Date(this.o.startDate):this.viewDate>this.o.endDate&&(this.viewDate=new Date(this.o.endDate)),d?this.setValue():c.length&&String(b)!==String(this.dates)&&this._trigger("changeDate"),!this.dates.length&&b.length&&this._trigger("clearDate"),this.fill()}},fillDow:function(){var a=this.o.weekStart,b="<tr>";if(this.o.calendarWeeks){var c='<th class="cw">&nbsp;</th>';b+=c,this.picker.find(".cfdatepicker-days thead tr:first-child").prepend(c)}for(;a<this.o.weekStart+7;)b+='<th class="dow">'+o[this.o.language].daysMin[a++%7]+"</th>";b+="</tr>",this.picker.find(".cfdatepicker-days thead").append(b)},fillMonths:function(){for(var a="",b=0;b<12;)a+='<span class="month">'+o[this.o.language].monthsShort[b++]+"</span>";this.picker.find(".cfdatepicker-months td").html(a)},setRange:function(b){b&&b.length?this.range=a.map(b,function(a){return a.valueOf()}):delete this.range,this.fill()},getClassNames:function(b){var c=[],d=this.viewDate.getUTCFullYear(),e=this.viewDate.getUTCMonth(),f=new Date;return b.getUTCFullYear()<d||b.getUTCFullYear()===d&&b.getUTCMonth()<e?c.push("old"):(b.getUTCFullYear()>d||b.getUTCFullYear()===d&&b.getUTCMonth()>e)&&c.push("new"),this.focusDate&&b.valueOf()===this.focusDate.valueOf()&&c.push("focused"),this.o.todayHighlight&&b.getUTCFullYear()===f.getFullYear()&&b.getUTCMonth()===f.getMonth()&&b.getUTCDate()===f.getDate()&&c.push("today"),this.dates.contains(b)!==-1&&c.push("active"),(b.valueOf()<this.o.startDate||b.valueOf()>this.o.endDate||a.inArray(b.getUTCDay(),this.o.daysOfWeekDisabled)!==-1)&&c.push("disabled"),this.range&&(b>this.range[0]&&b<this.range[this.range.length-1]&&c.push("range"),a.inArray(b.valueOf(),this.range)!==-1&&c.push("selected")),c},fill:function(){var d,e=new Date(this.viewDate),f=e.getUTCFullYear(),g=e.getUTCMonth(),h=this.o.startDate!==-(1/0)?this.o.startDate.getUTCFullYear():-(1/0),i=this.o.startDate!==-(1/0)?this.o.startDate.getUTCMonth():-(1/0),j=this.o.endDate!==1/0?this.o.endDate.getUTCFullYear():1/0,k=this.o.endDate!==1/0?this.o.endDate.getUTCMonth():1/0,l=o[this.o.language].today||o.en.today||"",m=o[this.o.language].clear||o.en.clear||"";this.picker.find(".cfdatepicker-days thead th.cfdatepicker-switch").text(o[this.o.language].months[g]+" "+f),this.picker.find("tfoot th.today").text(l).toggle(this.o.todayBtn!==!1),this.picker.find("tfoot th.clear").text(m).toggle(this.o.clearBtn!==!1),this.updateNavArrows(),this.fillMonths();var n=c(f,g-1,28),q=p.getDaysInMonth(n.getUTCFullYear(),n.getUTCMonth());n.setUTCDate(q),n.setUTCDate(q-(n.getUTCDay()-this.o.weekStart+7)%7);var r=new Date(n);r.setUTCDate(r.getUTCDate()+42),r=r.valueOf();for(var s,t=[];n.valueOf()<r;){if(n.getUTCDay()===this.o.weekStart&&(t.push("<tr>"),this.o.calendarWeeks)){var u=new Date(+n+(this.o.weekStart-n.getUTCDay()-7)%7*864e5),v=new Date(Number(u)+(11-u.getUTCDay())%7*864e5),w=new Date(Number(w=c(v.getUTCFullYear(),0,1))+(11-w.getUTCDay())%7*864e5),x=(v-w)/864e5/7+1;t.push('<td class="cw">'+x+"</td>")}if(s=this.getClassNames(n),s.push("day"),this.o.beforeShowDay!==a.noop){var y=this.o.beforeShowDay(this._utc_to_local(n));y===b?y={}:"boolean"==typeof y?y={enabled:y}:"string"==typeof y&&(y={classes:y}),y.enabled===!1&&s.push("disabled"),y.classes&&(s=s.concat(y.classes.split(/\s+/))),y.tooltip&&(d=y.tooltip)}s=a.unique(s),t.push('<td class="'+s.join(" ")+'"'+(d?' title="'+d+'"':"")+">"+n.getUTCDate()+"</td>"),n.getUTCDay()===this.o.weekEnd&&t.push("</tr>"),n.setUTCDate(n.getUTCDate()+1)}this.picker.find(".cfdatepicker-days tbody").empty().append(t.join(""));var z=this.picker.find(".cfdatepicker-months").find("th:eq(1)").text(f).end().find("span").removeClass("active");a.each(this.dates,function(a,b){b.getUTCFullYear()===f&&z.eq(b.getUTCMonth()).addClass("active")}),(f<h||f>j)&&z.addClass("disabled"),f===h&&z.slice(0,i).addClass("disabled"),f===j&&z.slice(k+1).addClass("disabled"),t="",f=10*parseInt(f/10,10);var A=this.picker.find(".cfdatepicker-years").find("th:eq(1)").text(f+"-"+(f+9)).end().find("td");f-=1;for(var B,C=a.map(this.dates,function(a){return a.getUTCFullYear()}),D=-1;D<11;D++)B=["year"],D===-1?B.push("old"):10===D&&B.push("new"),a.inArray(f,C)!==-1&&B.push("active"),(f<h||f>j)&&B.push("disabled"),t+='<span class="'+B.join(" ")+'">'+f+"</span>",f+=1;A.html(t)},updateNavArrows:function(){if(this._allow_update){var a=new Date(this.viewDate),b=a.getUTCFullYear(),c=a.getUTCMonth();switch(this.viewMode){case 0:this.o.startDate!==-(1/0)&&b<=this.o.startDate.getUTCFullYear()&&c<=this.o.startDate.getUTCMonth()?this.picker.find(".prev").css({visibility:"hidden"}):this.picker.find(".prev").css({visibility:"visible"}),this.o.endDate!==1/0&&b>=this.o.endDate.getUTCFullYear()&&c>=this.o.endDate.getUTCMonth()?this.picker.find(".next").css({visibility:"hidden"}):this.picker.find(".next").css({visibility:"visible"});break;case 1:case 2:this.o.startDate!==-(1/0)&&b<=this.o.startDate.getUTCFullYear()?this.picker.find(".prev").css({visibility:"hidden"}):this.picker.find(".prev").css({visibility:"visible"}),this.o.endDate!==1/0&&b>=this.o.endDate.getUTCFullYear()?this.picker.find(".next").css({visibility:"hidden"}):this.picker.find(".next").css({visibility:"visible"})}}},click:function(b){b.preventDefault();var d,e,f,g=a(b.target).closest("span, td, th");if(1===g.length)switch(g[0].nodeName.toLowerCase()){case"th":switch(g[0].className){case"cfdatepicker-switch":this.showMode(1);break;case"prev":case"next":var h=p.modes[this.viewMode].navStep*("prev"===g[0].className?-1:1);switch(this.viewMode){case 0:this.viewDate=this.moveMonth(this.viewDate,h),this._trigger("changeMonth",this.viewDate);break;case 1:case 2:this.viewDate=this.moveYear(this.viewDate,h),1===this.viewMode&&this._trigger("changeYear",this.viewDate)}this.fill();break;case"today":var i=new Date;i=c(i.getFullYear(),i.getMonth(),i.getDate(),0,0,0),this.showMode(-2);var j="linked"===this.o.todayBtn?null:"view";this._setDate(i,j);break;case"clear":var k;this.isInput?k=this.element:this.component&&(k=this.element.find("input")),k&&k.val("").change(),this.update(),this._trigger("changeDate"),this.o.autoclose&&this.hide()}break;case"span":g.is(".disabled")||(this.viewDate.setUTCDate(1),g.is(".month")?(f=1,e=g.parent().find("span").index(g),d=this.viewDate.getUTCFullYear(),this.viewDate.setUTCMonth(e),this._trigger("changeMonth",this.viewDate),1===this.o.minViewMode&&this._setDate(c(d,e,f))):(f=1,e=0,d=parseInt(g.text(),10)||0,this.viewDate.setUTCFullYear(d),this._trigger("changeYear",this.viewDate),2===this.o.minViewMode&&this._setDate(c(d,e,f))),this.showMode(-1),this.fill());break;case"td":g.is(".day")&&!g.is(".disabled")&&(f=parseInt(g.text(),10)||1,d=this.viewDate.getUTCFullYear(),e=this.viewDate.getUTCMonth(),g.is(".old")?0===e?(e=11,d-=1):e-=1:g.is(".new")&&(11===e?(e=0,d+=1):e+=1),this._setDate(c(d,e,f)))}this.picker.is(":visible")&&this._focused_from&&a(this._focused_from).focus(),delete this._focused_from},_toggle_multidate:function(a){var b=this.dates.contains(a);if(a?b!==-1?this.dates.remove(b):this.dates.push(a):this.dates.clear(),"number"==typeof this.o.multidate)for(;this.dates.length>this.o.multidate;)this.dates.remove(0)},_setDate:function(a,b){b&&"date"!==b||this._toggle_multidate(a&&new Date(a)),b&&"view"!==b||(this.viewDate=a&&new Date(a)),this.fill(),this.setValue(),this._trigger("changeDate");var c;this.isInput?c=this.element:this.component&&(c=this.element.find("input")),c&&c.change(),!this.o.autoclose||b&&"date"!==b||this.hide()},moveMonth:function(a,c){if(!a)return b;if(!c)return a;var d,e,f=new Date(a.valueOf()),g=f.getUTCDate(),h=f.getUTCMonth(),i=Math.abs(c);if(c=c>0?1:-1,1===i)e=c===-1?function(){return f.getUTCMonth()===h}:function(){return f.getUTCMonth()!==d},d=h+c,f.setUTCMonth(d),(d<0||d>11)&&(d=(d+12)%12);else{for(var j=0;j<i;j++)f=this.moveMonth(f,c);d=f.getUTCMonth(),f.setUTCDate(g),e=function(){return d!==f.getUTCMonth()}}for(;e();)f.setUTCDate(--g),f.setUTCMonth(d);return f},moveYear:function(a,b){return this.moveMonth(a,12*b)},dateWithinRange:function(a){return a>=this.o.startDate&&a<=this.o.endDate},keydown:function(a){if(this.picker.is(":not(:visible)"))return void(27===a.keyCode&&this.show());var b,c,e,f=!1,g=this.focusDate||this.viewDate;switch(a.keyCode){case 27:this.focusDate?(this.focusDate=null,this.viewDate=this.dates.get(-1)||this.viewDate,this.fill()):this.hide(),a.preventDefault();break;case 37:case 39:if(!this.o.keyboardNavigation)break;b=37===a.keyCode?-1:1,a.ctrlKey?(c=this.moveYear(this.dates.get(-1)||d(),b),e=this.moveYear(g,b),this._trigger("changeYear",this.viewDate)):a.shiftKey?(c=this.moveMonth(this.dates.get(-1)||d(),b),e=this.moveMonth(g,b),this._trigger("changeMonth",this.viewDate)):(c=new Date(this.dates.get(-1)||d()),c.setUTCDate(c.getUTCDate()+b),e=new Date(g),e.setUTCDate(g.getUTCDate()+b)),this.dateWithinRange(c)&&(this.focusDate=this.viewDate=e,this.setValue(),this.fill(),a.preventDefault());break;case 38:case 40:if(!this.o.keyboardNavigation)break;b=38===a.keyCode?-1:1,a.ctrlKey?(c=this.moveYear(this.dates.get(-1)||d(),b),e=this.moveYear(g,b),this._trigger("changeYear",this.viewDate)):a.shiftKey?(c=this.moveMonth(this.dates.get(-1)||d(),b),e=this.moveMonth(g,b),this._trigger("changeMonth",this.viewDate)):(c=new Date(this.dates.get(-1)||d()),c.setUTCDate(c.getUTCDate()+7*b),e=new Date(g),e.setUTCDate(g.getUTCDate()+7*b)),this.dateWithinRange(c)&&(this.focusDate=this.viewDate=e,this.setValue(),this.fill(),a.preventDefault());break;case 32:break;case 13:g=this.focusDate||this.dates.get(-1)||this.viewDate,this._toggle_multidate(g),f=!0,this.focusDate=null,this.viewDate=this.dates.get(-1)||this.viewDate,this.setValue(),this.fill(),this.picker.is(":visible")&&(a.preventDefault(),this.o.autoclose&&this.hide());break;case 9:this.focusDate=null,this.viewDate=this.dates.get(-1)||this.viewDate,this.fill(),this.hide()}if(f){this.dates.length?this._trigger("changeDate"):this._trigger("clearDate");var h;this.isInput?h=this.element:this.component&&(h=this.element.find("input")),h&&h.change()}},showMode:function(a){a&&(this.viewMode=Math.max(this.o.minViewMode,Math.min(2,this.viewMode+a))),this.picker.find(">div").hide().filter(".cfdatepicker-"+p.modes[this.viewMode].clsName).css("display","block"),this.updateNavArrows()}};var k=function(b,c){this.element=a(b),this.inputs=a.map(c.inputs,function(a){return a.jquery?a[0]:a}),delete c.inputs,a(this.inputs).cfdatepicker(c).bind("changeDate",a.proxy(this.dateUpdated,this)),this.pickers=a.map(this.inputs,function(b){return a(b).data("cfdatepicker")}),this.updateDates()};k.prototype={updateDates:function(){this.dates=a.map(this.pickers,function(a){return a.getUTCDate()}),this.updateRanges()},updateRanges:function(){var b=a.map(this.dates,function(a){return a.valueOf()});a.each(this.pickers,function(a,c){c.setRange(b)})},dateUpdated:function(b){if(!this.updating){this.updating=!0;var c=a(b.target).data("cfdatepicker"),d=c.getUTCDate(),e=a.inArray(b.target,this.inputs),f=this.inputs.length;if(e!==-1){if(a.each(this.pickers,function(a,b){b.getUTCDate()||b.setUTCDate(d)}),d<this.dates[e])for(;e>=0&&d<this.dates[e];)this.pickers[e--].setUTCDate(d);else if(d>this.dates[e])for(;e<f&&d>this.dates[e];)this.pickers[e++].setUTCDate(d);this.updateDates(),delete this.updating}}},remove:function(){a.map(this.pickers,function(a){a.remove()}),delete this.element.data().cfdatepicker}};var l=a.fn.cfdatepicker;a.fn.cfdatepicker=function(c){var d=Array.apply(null,arguments);d.shift();var e;return this.each(function(){var h=a(this),i=h.data("cfdatepicker"),l="object"==typeof c&&c;if(!i){var n=f(this,"date"),o=a.extend({},m,n,l),p=g(o.language),q=a.extend({},m,p,n,l);if(h.is(".input-daterange")||q.inputs){var r={inputs:q.inputs||h.find("input").toArray()};h.data("cfdatepicker",i=new k(this,a.extend(q,r)))}else h.data("cfdatepicker",i=new j(this,q))}if("string"==typeof c&&"function"==typeof i[c]&&(e=i[c].apply(i,d),e!==b))return!1}),e!==b?e:this};var m=a.fn.cfdatepicker.defaults={autoclose:!1,beforeShowDay:a.noop,calendarWeeks:!1,clearBtn:!1,daysOfWeekDisabled:[],endDate:1/0,forceParse:!0,format:"mm/dd/yyyy",keyboardNavigation:!0,language:"en",minViewMode:0,multidate:!1,multidateSeparator:",",orientation:"auto",rtl:!1,startDate:-(1/0),startView:0,todayBtn:!1,todayHighlight:!1,weekStart:0},n=a.fn.cfdatepicker.locale_opts=["format","rtl","weekStart"];a.fn.cfdatepicker.Constructor=j;var o=a.fn.cfdatepicker.dates={en:{days:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday","Sunday"],daysShort:["Sun","Mon","Tue","Wed","Thu","Fri","Sat","Sun"],daysMin:["Su","Mo","Tu","We","Th","Fr","Sa","Su"],months:["January","February","March","April","May","June","July","August","September","October","November","December"],monthsShort:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],today:"Today",clear:"Clear"}},p={modes:[{clsName:"days",navFnc:"Month",navStep:1},{clsName:"months",navFnc:"FullYear",navStep:1},{clsName:"years",navFnc:"FullYear",navStep:10}],isLeapYear:function(a){return a%4===0&&a%100!==0||a%400===0},getDaysInMonth:function(a,b){return[31,p.isLeapYear(a)?29:28,31,30,31,30,31,31,30,31,30,31][b]},validParts:/dd?|DD?|mm?|MM?|yy(?:yy)?/g,nonpunctuation:/[^ -\/:-@\[\u3400-\u9fff-`{-~\t\n\r]+/g,
2
- parseFormat:function(a){var b=a.replace(this.validParts,"\0").split("\0"),c=a.match(this.validParts);if(!b||!b.length||!c||0===c.length)throw new Error("Invalid date format.");return{separators:b,parts:c}},parseDate:function(d,e,f){function g(){var a=this.slice(0,m[k].length),b=m[k].slice(0,a.length);return a===b}if(!d)return b;if(d instanceof Date)return d;"string"==typeof e&&(e=p.parseFormat(e));var h,i,k,l=/([\-+]\d+)([dmwy])/,m=d.match(/([\-+]\d+)([dmwy])/g);if(/^[\-+]\d+[dmwy]([\s,]+[\-+]\d+[dmwy])*$/.test(d)){for(d=new Date,k=0;k<m.length;k++)switch(h=l.exec(m[k]),i=parseInt(h[1]),h[2]){case"d":d.setUTCDate(d.getUTCDate()+i);break;case"m":d=j.prototype.moveMonth.call(j.prototype,d,i);break;case"w":d.setUTCDate(d.getUTCDate()+7*i);break;case"y":d=j.prototype.moveYear.call(j.prototype,d,i)}return c(d.getUTCFullYear(),d.getUTCMonth(),d.getUTCDate(),0,0,0)}m=d&&d.match(this.nonpunctuation)||[],d=new Date;var n,q,r={},s=["yyyy","yy","M","MM","m","mm","d","dd"],t={yyyy:function(a,b){return a.setUTCFullYear(b)},yy:function(a,b){return a.setUTCFullYear(2e3+b)},m:function(a,b){if(isNaN(a))return a;for(b-=1;b<0;)b+=12;for(b%=12,a.setUTCMonth(b);a.getUTCMonth()!==b;)a.setUTCDate(a.getUTCDate()-1);return a},d:function(a,b){return a.setUTCDate(b)}};t.M=t.MM=t.mm=t.m,t.dd=t.d,d=c(d.getFullYear(),d.getMonth(),d.getDate(),0,0,0);var u=e.parts.slice();if(m.length!==u.length&&(u=a(u).filter(function(b,c){return a.inArray(c,s)!==-1}).toArray()),m.length===u.length){var v;for(k=0,v=u.length;k<v;k++){if(n=parseInt(m[k],10),h=u[k],isNaN(n))switch(h){case"MM":q=a(o[f].months).filter(g),n=a.inArray(q[0],o[f].months)+1;break;case"M":q=a(o[f].monthsShort).filter(g),n=a.inArray(q[0],o[f].monthsShort)+1}r[h]=n}var w,x;for(k=0;k<s.length;k++)x=s[k],x in r&&!isNaN(r[x])&&(w=new Date(d),t[x](w,r[x]),isNaN(w)||(d=w))}return d},formatDate:function(b,c,d){if(!b)return"";"string"==typeof c&&(c=p.parseFormat(c));var e={d:b.getUTCDate(),D:o[d].daysShort[b.getUTCDay()],DD:o[d].days[b.getUTCDay()],m:b.getUTCMonth()+1,M:o[d].monthsShort[b.getUTCMonth()],MM:o[d].months[b.getUTCMonth()],yy:b.getUTCFullYear().toString().substring(2),yyyy:b.getUTCFullYear()};e.dd=(e.d<10?"0":"")+e.d,e.mm=(e.m<10?"0":"")+e.m,b=[];for(var f=a.extend([],c.separators),g=0,h=c.parts.length;g<=h;g++)f.length&&b.push(f.shift()),b.push(e[c.parts[g]]);return b.join("")},headTemplate:'<thead><tr><th class="prev">&laquo;</th><th colspan="5" class="cfdatepicker-switch"></th><th class="next">&raquo;</th></tr></thead>',contTemplate:'<tbody><tr><td colspan="7"></td></tr></tbody>',footTemplate:'<tfoot><tr><th colspan="7" class="today"></th></tr><tr><th colspan="7" class="clear"></th></tr></tfoot>'};p.template='<div class="cfdatepicker"><div class="cfdatepicker-days"><table class=" table-condensed">'+p.headTemplate+"<tbody></tbody>"+p.footTemplate+'</table></div><div class="cfdatepicker-months"><table class="table-condensed">'+p.headTemplate+p.contTemplate+p.footTemplate+'</table></div><div class="cfdatepicker-years"><table class="table-condensed">'+p.headTemplate+p.contTemplate+p.footTemplate+"</table></div></div>",a.fn.cfdatepicker.DPGlobal=p,a.fn.cfdatepicker.noConflict=function(){return a.fn.cfdatepicker=l,this},a(document).on("focus.cfdatepicker.data-api click.cfdatepicker.data-api",'[data-provide="cfdatepicker"]',function(b){var c=a(this);c.data("cfdatepicker")||(b.preventDefault(),c.cfdatepicker("show").on("show",function(){a(this).trigger("blur")}).on("hide",function(){a(this).attr("disabled",!1)}))})}(window.jQuery),!function(a){function b(a){var b=document.createElement("input"),c="on"+a,d=c in b;return d||(b.setAttribute(c,"return;"),d="function"==typeof b[c]),b=null,d}function c(a){var b="text"==a||"tel"==a;if(!b){var c=document.createElement("input");c.setAttribute("type",a),b="text"===c.type,c=null}return b}function d(b,c,e){var f=e.aliases[b];return!!f&&(f.alias&&d(f.alias,void 0,e),a.extend(!0,e,f),a.extend(!0,e,c),!0)}function e(b,c){function d(a){function c(a,b,c,d){this.matches=[],this.isGroup=a||!1,this.isOptional=b||!1,this.isQuantifier=c||!1,this.isAlternator=d||!1,this.quantifier={min:1,max:1}}function d(a,c,d){var e=b.definitions[c],f=0==a.matches.length;if(d=void 0!=d?d:a.matches.length,e&&!l){for(var g=e.prevalidator,h=g?g.length:0,i=1;i<e.cardinality;i++){var j=h>=i?g[i-1]:[],k=j.validator,m=j.cardinality;a.matches.splice(d++,0,{fn:k?"string"==typeof k?new RegExp(k):new function(){this.test=k}:new RegExp("."),cardinality:m?m:1,optionality:a.isOptional,newBlockMarker:f,casing:e.casing,def:e.definitionSymbol||c,placeholder:e.placeholder,mask:c})}a.matches.splice(d++,0,{fn:e.validator?"string"==typeof e.validator?new RegExp(e.validator):new function(){this.test=e.validator}:new RegExp("."),cardinality:e.cardinality,optionality:a.isOptional,newBlockMarker:f,casing:e.casing,def:e.definitionSymbol||c,placeholder:e.placeholder,mask:c})}else a.matches.splice(d++,0,{fn:null,cardinality:0,optionality:a.isOptional,newBlockMarker:f,casing:null,def:c,placeholder:void 0,mask:c}),l=!1}for(var e,f,g,h,i,j,k=/(?:[?*+]|\{[0-9\+\*]+(?:,[0-9\+\*]*)?\})\??|[^.?*+^${[]()|\\]+|./g,l=!1,m=new c,n=[],o=[];e=k.exec(a);)switch(f=e[0],f.charAt(0)){case b.optionalmarker.end:case b.groupmarker.end:if(g=n.pop(),n.length>0){if(h=n[n.length-1],h.matches.push(g),h.isAlternator){i=n.pop();for(var p=0;p<i.matches.length;p++)i.matches[p].isGroup=!1;n.length>0?(h=n[n.length-1],h.matches.push(i)):m.matches.push(i)}}else m.matches.push(g);break;case b.optionalmarker.start:n.push(new c(!1,!0));break;case b.groupmarker.start:n.push(new c(!0));break;case b.quantifiermarker.start:var q=new c(!1,!1,!0);f=f.replace(/[{}]/g,"");var r=f.split(","),s=isNaN(r[0])?r[0]:parseInt(r[0]),t=1==r.length?s:isNaN(r[1])?r[1]:parseInt(r[1]);if(("*"==t||"+"==t)&&(s="*"==t?0:1),q.quantifier={min:s,max:t},n.length>0){var u=n[n.length-1].matches;if(e=u.pop(),!e.isGroup){var v=new c(!0);v.matches.push(e),e=v}u.push(e),u.push(q)}else{if(e=m.matches.pop(),!e.isGroup){var v=new c(!0);v.matches.push(e),e=v}m.matches.push(e),m.matches.push(q)}break;case b.escapeChar:l=!0;break;case b.alternatormarker:n.length>0?(h=n[n.length-1],j=h.matches.pop()):j=m.matches.pop(),j.isAlternator?n.push(j):(i=new c(!1,!1,!1,!0),i.matches.push(j),n.push(i));break;default:if(n.length>0){if(h=n[n.length-1],h.matches.length>0&&(j=h.matches[h.matches.length-1],j.isGroup&&(j.isGroup=!1,d(j,b.groupmarker.start,0),d(j,b.groupmarker.end))),d(h,f),h.isAlternator){i=n.pop();for(var p=0;p<i.matches.length;p++)i.matches[p].isGroup=!1;n.length>0?(h=n[n.length-1],h.matches.push(i)):m.matches.push(i)}}else m.matches.length>0&&(j=m.matches[m.matches.length-1],j.isGroup&&(j.isGroup=!1,d(j,b.groupmarker.start,0),d(j,b.groupmarker.end))),d(m,f)}return m.matches.length>0&&(j=m.matches[m.matches.length-1],j.isGroup&&(j.isGroup=!1,d(j,b.groupmarker.start,0),d(j,b.groupmarker.end)),o.push(m)),o}function e(c,e){if(b.numericInput&&b.multi!==!0){c=c.split("").reverse();for(var f=0;f<c.length;f++)c[f]==b.optionalmarker.start?c[f]=b.optionalmarker.end:c[f]==b.optionalmarker.end?c[f]=b.optionalmarker.start:c[f]==b.groupmarker.start?c[f]=b.groupmarker.end:c[f]==b.groupmarker.end&&(c[f]=b.groupmarker.start);c=c.join("")}if(void 0!=c&&""!=c){if(1==c.length&&0==b.greedy&&0!=b.repeat&&(b.placeholder=""),b.repeat>0||"*"==b.repeat||"+"==b.repeat){var g="*"==b.repeat?0:"+"==b.repeat?1:b.repeat;c=b.groupmarker.start+c+b.groupmarker.end+b.quantifiermarker.start+g+","+b.repeat+b.quantifiermarker.end}return void 0==a.inputmask.masksCache[c]&&(a.inputmask.masksCache[c]={mask:c,maskToken:d(c),validPositions:{},_buffer:void 0,buffer:void 0,tests:{},metadata:e}),a.extend(!0,{},a.inputmask.masksCache[c])}}var f=void 0;if(a.isFunction(b.mask)&&(b.mask=b.mask.call(this,b)),a.isArray(b.mask))if(c)f=[],a.each(b.mask,function(b,c){f.push(void 0==c.mask||a.isFunction(c.mask)?e(c.toString(),c):e(c.mask.toString(),c))});else{b.keepStatic=void 0==b.keepStatic||b.keepStatic;var g="(";a.each(b.mask,function(b,c){g.length>1&&(g+=")|("),g+=void 0==c.mask||a.isFunction(c.mask)?c.toString():c.mask.toString()}),g+=")",f=e(g,b.mask)}else b.mask&&(f=void 0==b.mask.mask||a.isFunction(b.mask.mask)?e(b.mask.toString(),b.mask):e(b.mask.mask.toString(),b.mask));return f}function f(d,e,f){function h(a,b,c){b=b||0;var d,e,f,g=[],h=0;do{if(a===!0&&o().validPositions[h]){var i=o().validPositions[h];e=i.match,d=i.locator.slice(),g.push(c===!0?i.input:I(h,e))}else{if(b>h){var j=w(h,d,h-1);f=j[0]}else f=t(h,d,h-1);e=f.match,d=f.locator.slice(),g.push(I(h,e))}h++}while((void 0==fa||fa>h-1)&&null!=e.fn||null==e.fn&&""!=e.def||b>=h);return g.pop(),g}function o(){return e}function p(a){var b=o();b.buffer=void 0,b.tests={},a!==!0&&(b._buffer=void 0,b.validPositions={},b.p=0)}function q(a){var b=o(),c=-1,d=b.validPositions;void 0==a&&(a=-1);var e=c,f=c;for(var g in d){var h=parseInt(g);(-1==a||null!=d[h].match.fn)&&(a>h&&(e=h),h>=a&&(f=h))}return c=a-e>1||a>f?e:f}function r(b,c,d){if(f.insertMode&&void 0!=o().validPositions[b]&&void 0==d){var e,g=a.extend(!0,{},o().validPositions),h=q();for(e=b;h>=e;e++)delete o().validPositions[e];o().validPositions[b]=c;var i,j=!0;for(e=b;h>=e;e++){var k=g[e];if(void 0!=k){var l=o().validPositions;i=!f.keepStatic&&(void 0!=l[e+1]&&w(e+1,l[e].locator.slice(),e).length>1||l[e]&&void 0!=l[e].alternation)?e+1:E(e),j=v(i,k.match.def)?j&&B(i,k.input,!0,!0)!==!1:null==k.match.fn}if(!j)break}if(!j)return o().validPositions=a.extend(!0,{},g),!1}else o().validPositions[b]=c;return!0}function s(a,b){var c,d=a;for(void 0!=o().validPositions[a]&&o().validPositions[a].input==f.radixPoint&&(b++,d++),c=d;b>c;c++)void 0==o().validPositions[c]||o().validPositions[c].input==f.radixPoint&&c!=q()||delete o().validPositions[c];for(c=b;c<=q();){var e=o().validPositions[c],g=o().validPositions[d];void 0!=e&&void 0==g?(v(d,e.match.def)&&B(d,e.input,!0)!==!1&&(delete o().validPositions[c],c++),d++):c++}var h=q();h>=a&&void 0!=o().validPositions[h]&&o().validPositions[h].input==f.radixPoint&&delete o().validPositions[h],p(!0)}function t(b,c,d){function e(b,c,d){for(var e=!1,f=b.locator[c].toString().split(","),g=0;g<f.length;g++)if(-1!=a.inArray(f[g],d)){e=!0;break}return e}for(var g,h=w(b,c,d),i=q(),j=o().validPositions[i]||w(0)[0],k=void 0!=j.alternation?j.locator[j.alternation].split(","):[],l=0;l<h.length&&(g=h[l],!(f.greedy||g.match&&(g.match.optionality===!1||g.match.newBlockMarker===!1)&&g.match.optionalQuantifier!==!0&&(void 0==j.alternation||void 0!=g.locator[j.alternation]&&e(g,j.alternation,k))));l++);return g}function u(a){return o().validPositions[a]?o().validPositions[a].match:w(a)[0].match}function v(a,b){for(var c=!1,d=w(a),e=0;e<d.length;e++)if(d[e].match&&d[e].match.def==b){c=!0;break}return c}function w(b,c,d){function e(c,d,g,i){function l(g,i,n){if(h>1e4)return alert("jquery.inputmask: There is probably an error in your mask definition or in the code. Create an issue on github with an example of the mask you are using. "+o().mask),!0;if(h==b&&void 0==g.matches)return j.push({match:g,locator:i.reverse()}),!0;if(void 0!=g.matches){if(g.isGroup&&n!==!0){if(g=l(c.matches[m+1],i))return!0}else if(g.isOptional){var p=g;if(g=e(g,d,i,n)){var q=j[j.length-1].match,r=0==a.inArray(q,p.matches);r&&(k=!0),h=b}}else if(g.isAlternator){var s,t=g,u=[],v=j.slice(),w=i.length,x=d.length>0?d.shift():-1;if(-1==x||"string"==typeof x){var y,z=h,A=d.slice();"string"==typeof x&&(y=x.split(","));for(var B=0;B<t.matches.length;B++){j=[],g=l(t.matches[B],[B].concat(i),n)||g,s=j.slice(),h=z,j=[];for(var C=0;C<A.length;C++)d[C]=A[C];for(var D=0;D<s.length;D++)for(var E=s[D],F=0;F<u.length;F++){var G=u[F];if(E.match.mask==G.match.mask&&("string"!=typeof x||-1!=a.inArray(E.locator[w].toString(),y))){s.splice(D,1),G.locator[w]=G.locator[w]+","+E.locator[w],G.alternation=w;break}}u=u.concat(s)}"string"==typeof x&&(u=a.map(u,function(b,c){if(isFinite(c)){var d,e=b.locator[w].toString().split(",");b.locator[w]=void 0,b.alternation=void 0;for(var f=0;f<e.length;f++)d=-1!=a.inArray(e[f],y),d&&(void 0!=b.locator[w]?(b.locator[w]+=",",b.alternation=w,b.locator[w]+=e[f]):b.locator[w]=parseInt(e[f]));if(void 0!=b.locator[w])return b}})),j=v.concat(u),k=!0}else g=l(t.matches[x],[x].concat(i),n);if(g)return!0}else if(g.isQuantifier&&n!==!0){var H=g;f.greedy=f.greedy&&isFinite(H.quantifier.max);for(var I=d.length>0&&n!==!0?d.shift():0;I<(isNaN(H.quantifier.max)?I+1:H.quantifier.max)&&b>=h;I++){var J=c.matches[a.inArray(H,c.matches)-1];if(g=l(J,[I].concat(i),!0)){var q=j[j.length-1].match;q.optionalQuantifier=I>H.quantifier.min-1;var r=0==a.inArray(q,J.matches);if(r){if(I>H.quantifier.min-1){k=!0,h=b;break}return!0}return!0}}}else if(g=e(g,d,i,n))return!0}else h++}for(var m=d.length>0?d.shift():0;m<c.matches.length;m++)if(c.matches[m].isQuantifier!==!0){var n=l(c.matches[m],[m].concat(g),i);if(n&&h==b)return n;if(h>b)break}}var g=o().maskToken,h=c?d:0,i=c||[0],j=[],k=!1;if(void 0==c){for(var l,m=b-1;void 0==(l=o().validPositions[m])&&m>-1;)m--;if(void 0!=l&&m>-1)h=m,i=l.locator.slice();else{for(m=b-1;void 0==(l=o().tests[m])&&m>-1;)m--;void 0!=l&&m>-1&&(h=m,i=l[0].locator.slice())}}for(var n=i.shift();n<g.length;n++){var p=e(g[n],i,[n]);if(p&&h==b||h>b)break}return(0==j.length||k)&&j.push({match:{fn:null,cardinality:0,optionality:!0,casing:null,def:""},locator:[]}),o().tests[b]=a.extend(!0,[],j),o().tests[b]}function x(){return void 0==o()._buffer&&(o()._buffer=h(!1,1)),o()._buffer}function y(){return void 0==o().buffer&&(o().buffer=h(!0,q(),!0)),o().buffer}function z(a,b){var c=y().slice();if(a===!0)p(),a=0,b=c.length;else for(var d=a;b>d;d++)delete o().validPositions[d],delete o().tests[d];for(var d=a;b>d;d++)c[d]!=f.skipOptionalPartCharacter&&B(d,c[d],!0,!0)}function A(a,b){switch(b.casing){case"upper":a=a.toUpperCase();break;case"lower":a=a.toLowerCase()}return a}function B(b,c,d,e){function g(b,c,d,e){var g=!1;return a.each(w(b),function(h,i){for(var j=i.match,k=c?1:0,l="",m=(y(),j.cardinality);m>k;m--)l+=G(b-(m-1));if(c&&(l+=c),g=null!=j.fn?j.fn.test(l,o(),b,d,f):(c==j.def||c==f.skipOptionalPartCharacter)&&""!=j.def&&{c:j.def,pos:b},g!==!1){var n=void 0!=g.c?g.c:c;n=n==f.skipOptionalPartCharacter&&null===j.fn?j.def:n;var t=b;if(void 0!=g.remove&&s(g.remove,g.remove+1),g.refreshFromBuffer){var u=g.refreshFromBuffer;if(d=!0,z(u===!0?u:u.start,u.end),void 0==g.pos&&void 0==g.c)return g.pos=q(),!1;if(t=void 0!=g.pos?g.pos:b,t!=b)return g=a.extend(g,B(t,n,!0)),!1}else if(g!==!0&&void 0!=g.pos&&g.pos!=b&&(t=g.pos,z(b,t),t!=b))return g=a.extend(g,B(t,n,!0)),!1;return(1==g||void 0!=g.pos||void 0!=g.c)&&(h>0&&p(!0),r(t,a.extend({},i,{input:A(n,j)}),e)||(g=!1),!1)}}),g}function h(b,c,d,e){var g,h,i=a.extend(!0,{},o().validPositions);for(g=q();g>=0;g--)if(o().validPositions[g]&&void 0!=o().validPositions[g].alternation){h=o().validPositions[g].alternation;break}if(void 0!=h)for(var j in o().validPositions)if(parseInt(j)>parseInt(g)&&void 0===o().validPositions[j].alternation){for(var k=o().validPositions[j],l=k.locator[h],m=o().validPositions[g].locator[h].split(","),n=0;n<m.length;n++)if(l<m[n]){for(var r,s,t=j-1;t>=0;t--)if(r=o().validPositions[t],void 0!=r){s=r.locator[h],r.locator[h]=m[n];break}if(l!=r.locator[h]){for(var u=y().slice(),v=j;v<q()+1;v++)delete o().validPositions[v],delete o().tests[v];p(!0),f.keepStatic=!f.keepStatic;for(var v=j;v<u.length;v++)u[v]!=f.skipOptionalPartCharacter&&B(q()+1,u[v],!1,!0);r.locator[h]=s;var w=B(b,c,d,e);if(f.keepStatic=!f.keepStatic,w)return w;p(),o().validPositions=a.extend(!0,{},i)}}break}return!1}d=d===!0;for(var i=y(),j=b-1;j>-1&&(!o().validPositions[j]||null!=o().validPositions[j].match.fn);j--)void 0==o().validPositions[j]&&(!C(j)||i[j]!=I(j))&&w(j).length>1&&g(j,i[j],!0);var k=b,l=!1;if(e&&k>=D()&&p(!0),k<D()&&(l=g(k,c,d,e),!d&&l===!1)){var m=o().validPositions[k];if(!m||null!=m.match.fn||m.match.def!=c&&c!=f.skipOptionalPartCharacter){if((f.insertMode||void 0==o().validPositions[E(k)])&&!C(k))for(var n=k+1,t=E(k);t>=n;n++)if(l=g(n,c,d,e),l!==!1){k=n;break}}else l={caret:E(k)}}return l===!1&&f.keepStatic&&R(i)&&(l=h(b,c,d,e)),l===!0&&(l={pos:k}),l}function C(a){var b=u(a);return null!=b.fn&&b.fn}function D(){var a;if(fa=ea.prop("maxLength"),-1==fa&&(fa=void 0),0==f.greedy){var b,c=q(),d=o().validPositions[c],e=void 0!=d?d.locator.slice():void 0;for(b=c+1;void 0==d||null!=d.match.fn||null==d.match.fn&&""!=d.match.def;b++)d=t(b,e,b-1),e=d.locator.slice();a=b}else a=y().length;return void 0==fa||fa>a?a:fa}function E(a){var b=D();if(a>=b)return b;for(var c=a;++c<b&&!C(c)&&(f.nojumps!==!0||f.nojumpsThreshold>c););return c}function F(a){var b=a;if(0>=b)return 0;for(;--b>0&&!C(b););return b}function G(a){return void 0==o().validPositions[a]?I(a):o().validPositions[a].input}function H(a,b,c){a._valueSet(b.join("")),void 0!=c&&O(a,c)}function I(b,c){c=c||u(b);var d=a.isFunction(c.placeholder)?c.placeholder.call(this,f):c.placeholder;return void 0!=d?d:null==c.fn?c.def:f.placeholder.charAt(b%f.placeholder.length)}function J(b,c,d,e,g){var h=void 0!=e?e.slice():L(b._valueGet()).split("");if(p(),c&&b._valueSet(""),a.each(h,function(c,e){if(g===!0){var f=q(),h=-1==f?c:E(f);-1==a.inArray(e,x().slice(f+1,h))&&Y.call(b,void 0,!0,e.charCodeAt(0),!1,d,d?c:o().p)}else Y.call(b,void 0,!0,e.charCodeAt(0),!1,d,d?c:o().p),d=d||c>0&&c>o().p}),c){var i=f.onKeyPress.call(this,void 0,y(),0,f);W(b,i),H(b,y(),a(b).is(":focus")?E(q(0)):void 0)}}function K(b){return a.inputmask.escapeRegex.call(this,b)}function L(a){return a.replace(new RegExp("("+K(x().join(""))+")*$"),"")}function M(b){if(b.data("_inputmask")&&!b.hasClass("hasDatepicker")){var c=[],d=o().validPositions;for(var e in d)d[e].match&&null!=d[e].match.fn&&c.push(d[e].input);var g=(ga?c.reverse():c).join(""),h=(ga?y().slice().reverse():y()).join("");return a.isFunction(f.onUnMask)&&(g=f.onUnMask.call(b,h,g,f)||g),g}return b[0]._valueGet()}function N(a){if(ga&&"number"==typeof a&&(!f.greedy||""!=f.placeholder)){var b=y().length;a=b-a}return a}function O(b,c,d){var e,g=b.jquery&&b.length>0?b[0]:b;if("number"!=typeof c){var h=a(g).data("_inputmask");return!a(g).is(":visible")&&h&&void 0!=h.caret?(c=h.caret.begin,d=h.caret.end):g.setSelectionRange?(c=g.selectionStart,d=g.selectionEnd):document.selection&&document.selection.createRange&&(e=document.selection.createRange(),c=0-e.duplicate().moveStart("character",-1e5),d=c+e.text.length),c=N(c),d=N(d),{begin:c,end:d}}c=N(c),d=N(d),d="number"==typeof d?d:c;var h=a(g).data("_inputmask")||{};h.caret={begin:c,end:d},a(g).data("_inputmask",h),a(g).is(":visible")&&(g.scrollLeft=g.scrollWidth,0==f.insertMode&&c==d&&d++,g.setSelectionRange?(g.selectionStart=c,g.selectionEnd=d):g.createTextRange&&(e=g.createTextRange(),e.collapse(!0),e.moveEnd("character",d),e.moveStart("character",c),e.select()))}function P(b){var c,d,e=y(),f=e.length,g=q(),h={},i=o().validPositions[g],j=void 0!=i?i.locator.slice():void 0;for(c=g+1;c<e.length;c++)d=t(c,j,c-1),j=d.locator.slice(),h[c]=a.extend(!0,{},d);var k=i&&void 0!=i.alternation?i.locator[i.alternation].split(","):[];for(c=f-1;c>g&&(d=h[c].match,(d.optionality||d.optionalQuantifier||i&&void 0!=i.alternation&&void 0!=h[c].locator[i.alternation]&&-1!=a.inArray(h[c].locator[i.alternation].toString(),k))&&e[c]==I(c,d));c--)f--;return b?{l:f,def:h[f]?h[f].match:void 0}:f}function Q(a){for(var b=y(),c=b.slice(),d=P(),e=c.length-1;e>d&&!C(e);e--);c.splice(d,e+1-d),H(a,c)}function R(b){if(a.isFunction(f.isComplete))return f.isComplete.call(ea,b,f);if("*"!=f.repeat){var c=!1,d=P(!0),e=F(d.l),g=q();if(g==e&&(void 0==d.def||d.def.newBlockMarker||d.def.optionalQuantifier)){c=!0;for(var h=0;e>=h;h++){var i=C(h);if(i&&(void 0==b[h]||b[h]==I(h))||!i&&b[h]!=I(h)){c=!1;break}}}return c}}function S(a,b){return ga?a-b>1||a-b==1&&f.insertMode:b-a>1||b-a==1&&f.insertMode}function T(b){var c=a._data(b).events;a.each(c,function(b,c){a.each(c,function(a,b){if("inputmask"==b.namespace&&"setvalue"!=b.type){var c=b.handler;b.handler=function(a){return this.readOnly||this.disabled?void a.preventDefault:c.apply(this,arguments)}}})})}function U(b){function c(b){if(void 0==a.valHooks[b]||1!=a.valHooks[b].inputmaskpatch){var c=a.valHooks[b]&&a.valHooks[b].get?a.valHooks[b].get:function(a){return a.value},d=a.valHooks[b]&&a.valHooks[b].set?a.valHooks[b].set:function(a,b){return a.value=b,a};a.valHooks[b]={get:function(b){var d=a(b);if(d.data("_inputmask")){if(d.data("_inputmask").opts.autoUnmask)return d.inputmask("unmaskedvalue");var e=c(b),f=d.data("_inputmask"),g=f.maskset,h=g._buffer;return h=h?h.join(""):"",e!=h?e:""}return c(b)},set:function(b,c){var e,f=a(b),g=f.data("_inputmask");return g?(e=d(b,a.isFunction(g.opts.onBeforeMask)?g.opts.onBeforeMask.call(oa,c,g.opts)||c:c),f.triggerHandler("setvalue.inputmask")):e=d(b,c),e},inputmaskpatch:!0}}}function d(){var b=a(this),c=a(this).data("_inputmask");return c?c.opts.autoUnmask?b.inputmask("unmaskedvalue"):g.call(this)!=x().join("")?g.call(this):"":g.call(this)}function e(b){var c=a(this).data("_inputmask");c?(h.call(this,a.isFunction(c.opts.onBeforeMask)?c.opts.onBeforeMask.call(oa,b,c.opts)||b:b),a(this).triggerHandler("setvalue.inputmask")):h.call(this,b)}function f(b){a(b).bind("mouseenter.inputmask",function(){var b=a(this),c=this,d=c._valueGet();""!=d&&d!=y().join("")&&b.trigger("setvalue")});var c=a._data(b).events,d=c.mouseover;if(d){for(var e=d[d.length-1],f=d.length-1;f>0;f--)d[f]=d[f-1];d[0]=e}}var g,h;b._valueGet||(Object.getOwnPropertyDescriptor&&Object.getOwnPropertyDescriptor(b,"value"),document.__lookupGetter__&&b.__lookupGetter__("value")?(g=b.__lookupGetter__("value"),h=b.__lookupSetter__("value"),b.__defineGetter__("value",d),b.__defineSetter__("value",e)):(g=function(){return b.value},h=function(a){b.value=a},c(b.type),f(b)),b._valueGet=function(){return ga?g.call(this).split("").reverse().join(""):g.call(this)},b._valueSet=function(a){h.call(this,ga?a.split("").reverse().join(""):a)})}function V(b,c,d){function e(){if(f.keepStatic){p(!0);var a,c=[];for(a=q();a>=0;a--)if(o().validPositions[a]){if(void 0!=o().validPositions[a].alternation)break;c.push(o().validPositions[a].input),delete o().validPositions[a]}if(a>0)for(;c.length>0;)o().p=E(q()),Y.call(b,void 0,!0,c.pop().charCodeAt(0),!1,!1,o().p)}}if((f.numericInput||ga)&&(c==a.inputmask.keyCode.BACKSPACE?c=a.inputmask.keyCode.DELETE:c==a.inputmask.keyCode.DELETE&&(c=a.inputmask.keyCode.BACKSPACE),ga)){var g=d.end;d.end=d.begin,d.begin=g}c==a.inputmask.keyCode.BACKSPACE&&d.end-d.begin<=1?d.begin=F(d.begin):c==a.inputmask.keyCode.DELETE&&d.begin==d.end&&d.end++,s(d.begin,d.end),e();var h=q(d.begin);h<d.begin?(-1==h&&p(),o().p=E(h)):o().p=d.begin}function W(a,b,c){if(b&&b.refreshFromBuffer){var d=b.refreshFromBuffer;z(d===!0?d:d.start,d.end),p(!0),void 0!=c&&(H(a,y()),O(a,b.caret||c.begin,b.caret||c.end))}}function X(c){ha=!1;var d=this,e=a(d),g=c.keyCode,h=O(d);g==a.inputmask.keyCode.BACKSPACE||g==a.inputmask.keyCode.DELETE||i&&127==g||c.ctrlKey&&88==g&&!b("cut")?(c.preventDefault(),88==g&&(da=y().join("")),V(d,g,h),H(d,y(),o().p),d._valueGet()==x().join("")&&e.trigger("cleared"),f.showTooltip&&e.prop("title",o().mask)):g==a.inputmask.keyCode.END||g==a.inputmask.keyCode.PAGE_DOWN?setTimeout(function(){var a=E(q());f.insertMode||a!=D()||c.shiftKey||a--,O(d,c.shiftKey?h.begin:a,a)},0):g==a.inputmask.keyCode.HOME&&!c.shiftKey||g==a.inputmask.keyCode.PAGE_UP?O(d,0,c.shiftKey?h.begin:0):g==a.inputmask.keyCode.ESCAPE||90==g&&c.ctrlKey?(J(d,!0,!1,da.split("")),e.click()):g!=a.inputmask.keyCode.INSERT||c.shiftKey||c.ctrlKey?0!=f.insertMode||c.shiftKey||(g==a.inputmask.keyCode.RIGHT?setTimeout(function(){var a=O(d);O(d,a.begin)},0):g==a.inputmask.keyCode.LEFT&&setTimeout(function(){var a=O(d);O(d,ga?a.begin+1:a.begin-1)},0)):(f.insertMode=!f.insertMode,O(d,f.insertMode||h.begin!=D()?h.begin:h.begin-1));var j=O(d),k=f.onKeyDown.call(this,c,y(),j.begin,f);W(d,k,j),ja=-1!=a.inArray(g,f.ignorables)}function Y(b,c,d,e,g,h){if(void 0==d&&ha)return!1;ha=!0;var i=this,j=a(i);b=b||window.event;var d=c?d:b.which||b.charCode||b.keyCode;if(!(c===!0||b.ctrlKey&&b.altKey)&&(b.ctrlKey||b.metaKey||ja))return!0;if(d){c!==!0&&46==d&&0==b.shiftKey&&","==f.radixPoint&&(d=44);var k,l=c?{begin:h,end:h}:O(i),m=String.fromCharCode(d),n=S(l.begin,l.end);n&&(o().undoPositions=a.extend(!0,{},o().validPositions),V(i,a.inputmask.keyCode.DELETE,l),f.insertMode||(f.insertMode=!f.insertMode,r(l.begin,g),f.insertMode=!f.insertMode),n=!f.multi),o().writeOutBuffer=!0;var q=ga&&!n?l.end:l.begin,s=B(q,m,g);if(s!==!1){if(s!==!0&&(q=void 0!=s.pos?s.pos:q,m=void 0!=s.c?s.c:m),p(!0),void 0!=s.caret)k=s.caret;else{var t=o().validPositions;k=!f.keepStatic&&(void 0!=t[q+1]&&w(q+1,t[q].locator.slice(),q).length>1||void 0!=t[q].alternation)?q+1:E(q)}o().p=k}if(e!==!1){var u=this;if(setTimeout(function(){f.onKeyValidation.call(u,s,f)},0),o().writeOutBuffer&&s!==!1){var v=y();H(i,v,c?void 0:f.numericInput?F(k):k),c!==!0&&setTimeout(function(){R(v)===!0&&j.trigger("complete"),ia=!0,j.trigger("input")},0)}else n&&(o().buffer=void 0,o().validPositions=o().undoPositions)}else n&&(o().buffer=void 0,o().validPositions=o().undoPositions);if(f.showTooltip&&j.prop("title",o().mask),b&&1!=c){b.preventDefault();var x=O(i),z=f.onKeyPress.call(this,b,y(),x.begin,f);W(i,z,x)}}}function Z(b){var c=a(this),d=this,e=b.keyCode,g=y(),h=O(d),i=f.onKeyUp.call(this,b,g,h.begin,f);W(d,i,h),e==a.inputmask.keyCode.TAB&&f.showMaskOnFocus&&(c.hasClass("focus-inputmask")&&0==d._valueGet().length?(p(),g=y(),H(d,g),O(d,0),da=y().join("")):(H(d,g),O(d,N(0),N(D()))))}function $(b){if(ia===!0&&"input"==b.type)return ia=!1,!0;var c=this,d=a(c),e=c._valueGet(),g=O(c);if("propertychange"==b.type&&c._valueGet().length<=D())return!0;"paste"==b.type&&(window.clipboardData&&window.clipboardData.getData?e=e.substr(0,g.begin)+window.clipboardData.getData("Text")+e.substr(g.end,e.length):b.originalEvent&&b.originalEvent.clipboardData&&b.originalEvent.clipboardData.getData&&(e=e.substr(0,g.begin)+b.originalEvent.clipboardData.getData("text/plain")+e.substr(g.end,e.length)));var h=a.isFunction(f.onBeforePaste)?f.onBeforePaste.call(c,e,f)||e:e;return J(c,!0,!1,ga?h.split("").reverse():h.split(""),!0),d.click(),R(y())===!0&&d.trigger("complete"),!1}function _(b){if(ia===!0&&"input"==b.type)return ia=!1,!0;var c=this,d=O(c),e=c._valueGet();e=e.replace(new RegExp("("+K(x().join(""))+")*"),""),d.begin>e.length&&(O(c,e.length),d=O(c)),y().length-e.length!=1||e.charAt(d.begin)==y()[d.begin]||e.charAt(d.begin+1)==y()[d.begin]||C(d.begin)||(b.keyCode=a.inputmask.keyCode.BACKSPACE,X.call(c,b)),b.preventDefault()}function aa(b){if(ia===!0&&"input"==b.type)return ia=!1,!0;var c=this,d=O(c),e=c._valueGet();O(c,d.begin-1);var g=a.Event("keypress");g.which=e.charCodeAt(d.begin-1),ha=!1,ja=!1,Y.call(c,g,void 0,void 0,!1);var h=o().p;H(c,y(),f.numericInput?F(h):h),b.preventDefault()}function ba(b){ia=!0;var c=this;return setTimeout(function(){O(c,O(c).begin-1);var d=a.Event("keypress");d.which=b.originalEvent.data.charCodeAt(0),ha=!1,ja=!1,Y.call(c,d,void 0,void 0,!1);var e=o().p;H(c,y(),f.numericInput?F(e):e)},0),!1}function ca(b){if(ea=a(b),ea.is(":input")&&c(ea.attr("type"))){if(ea.data("_inputmask",{maskset:e,opts:f,isRTL:!1}),f.showTooltip&&ea.prop("title",o().mask),("rtl"==b.dir||f.rightAlign)&&ea.css("text-align","right"),"rtl"==b.dir||f.numericInput){b.dir="ltr",ea.removeAttr("dir");var d=ea.data("_inputmask");d.isRTL=!0,ea.data("_inputmask",d),ga=!0}ea.unbind(".inputmask"),ea.removeClass("focus-inputmask"),ea.closest("form").bind("submit",function(){da!=y().join("")&&ea.change(),ea[0]._valueGet&&ea[0]._valueGet()==x().join("")&&ea[0]._valueSet(""),f.autoUnmask&&f.removeMaskOnSubmit&&ea.inputmask("remove")}).bind("reset",function(){setTimeout(function(){ea.trigger("setvalue")},0)}),ea.bind("mouseenter.inputmask",function(){var b=a(this),c=this;!b.hasClass("focus-inputmask")&&f.showMaskOnHover&&c._valueGet()!=y().join("")&&H(c,y())}).bind("blur.inputmask",function(){var b=a(this),c=this;if(b.data("_inputmask")){var d=c._valueGet(),e=y();b.removeClass("focus-inputmask"),da!=y().join("")&&b.change(),f.clearMaskOnLostFocus&&""!=d&&(d==x().join("")?c._valueSet(""):Q(c)),R(e)===!1&&(b.trigger("incomplete"),f.clearIncomplete&&(p(),f.clearMaskOnLostFocus?c._valueSet(""):(e=x().slice(),H(c,e))))}}).bind("focus.inputmask",function(){var b=a(this),c=this,d=c._valueGet();f.showMaskOnFocus&&!b.hasClass("focus-inputmask")&&(!f.showMaskOnHover||f.showMaskOnHover&&""==d)&&c._valueGet()!=y().join("")&&H(c,y(),E(q())),b.addClass("focus-inputmask"),da=y().join("")}).bind("mouseleave.inputmask",function(){var b=a(this),c=this;f.clearMaskOnLostFocus&&(b.hasClass("focus-inputmask")||c._valueGet()==b.attr("placeholder")||(c._valueGet()==x().join("")||""==c._valueGet()?c._valueSet(""):Q(c)))}).bind("click.inputmask",function(){var b=this;a(b).is(":focus")&&setTimeout(function(){var c=O(b);if(c.begin==c.end)if(f.radixFocus&&""!=f.radixPoint&&-1!=a.inArray(f.radixPoint,y())&&y().join("")==x().join(""))O(b,a.inArray(f.radixPoint,y()));else{var d=ga?N(c.begin):c.begin,e=E(q(d));e>d?O(b,C(d)?d:E(d)):O(b,e)}},0)}).bind("dblclick.inputmask",function(){var a=this;setTimeout(function(){O(a,0,E(q()))},0)}).bind(n+".inputmask dragdrop.inputmask drop.inputmask",$).bind("setvalue.inputmask",function(){var a=this;J(a,!0,!1,void 0,!0),da=y().join(""),(f.clearMaskOnLostFocus||f.clearIncomplete)&&a._valueGet()==x().join("")&&a._valueSet("")}).bind("cut.inputmask",function(b){ia=!0;var c=this,d=a(c),e=O(c);V(c,a.inputmask.keyCode.DELETE,e);var g=f.onKeyPress.call(this,b,y(),o().p,f);W(c,g,{begin:o().p,end:o().p}),c._valueGet()==x().join("")&&d.trigger("cleared"),f.showTooltip&&d.prop("title",o().mask)}).bind("complete.inputmask",f.oncomplete).bind("incomplete.inputmask",f.onincomplete).bind("cleared.inputmask",f.oncleared),ea.bind("keydown.inputmask",X).bind("keypress.inputmask",Y).bind("keyup.inputmask",Z).bind("compositionupdate.inputmask",ba),"paste"!==n||g||ea.bind("input.inputmask",aa),g&&ea.bind("input.inputmask",$),(j||l||k||m)&&("input"==n&&ea.unbind(n+".inputmask"),ea.bind("input.inputmask",_)),U(b);var h=a.isFunction(f.onBeforeMask)?f.onBeforeMask.call(b,b._valueGet(),f)||b._valueGet():b._valueGet();J(b,!0,!1,h.split(""),!0),da=y().join("");var i;try{i=document.activeElement}catch(a){}R(y())===!1&&f.clearIncomplete&&p(),f.clearMaskOnLostFocus?y().join("")==x().join("")?b._valueSet(""):Q(b):H(b,y()),i===b&&(ea.addClass("focus-inputmask"),O(b,E(q()))),T(b)}}var da,ea,fa,ga=!1,ha=!1,ia=!1,ja=!1;if(void 0!=d)switch(d.action){case"isComplete":return ea=a(d.el),e=ea.data("_inputmask").maskset,f=ea.data("_inputmask").opts,R(d.buffer);case"unmaskedvalue":return ea=d.$input,e=ea.data("_inputmask").maskset,f=ea.data("_inputmask").opts,ga=d.$input.data("_inputmask").isRTL,M(d.$input);case"mask":da=y().join(""),ca(d.el);break;case"format":ea=a({}),ea.data("_inputmask",{maskset:e,opts:f,isRTL:f.numericInput}),f.numericInput&&(ga=!0);var ka=(a.isFunction(f.onBeforeMask)?f.onBeforeMask.call(ea,d.value,f)||d.value:d.value).split("");return J(ea,!1,!1,ga?ka.reverse():ka,!0),f.onKeyPress.call(this,void 0,y(),0,f),d.metadata?{value:ga?y().slice().reverse().join(""):y().join(""),metadata:ea.inputmask("getmetadata")}:ga?y().slice().reverse().join(""):y().join("");case"isValid":ea=a({}),ea.data("_inputmask",{maskset:e,opts:f,isRTL:f.numericInput}),f.numericInput&&(ga=!0);var ka=d.value.split("");J(ea,!1,!0,ga?ka.reverse():ka);for(var la=y(),ma=P(),na=la.length-1;na>ma&&!C(na);na--);return la.splice(ma,na+1-ma),R(la)&&d.value==la.join("");case"getemptymask":return ea=a(d.el),e=ea.data("_inputmask").maskset,f=ea.data("_inputmask").opts,x();case"remove":var oa=d.el;ea=a(oa),e=ea.data("_inputmask").maskset,f=ea.data("_inputmask").opts,oa._valueSet(M(ea)),ea.unbind(".inputmask"),ea.removeClass("focus-inputmask"),ea.removeData("_inputmask");var pa;Object.getOwnPropertyDescriptor&&(pa=Object.getOwnPropertyDescriptor(oa,"value")),pa&&pa.get?oa._valueGet&&Object.defineProperty(oa,"value",{get:oa._valueGet,set:oa._valueSet}):document.__lookupGetter__&&oa.__lookupGetter__("value")&&oa._valueGet&&(oa.__defineGetter__("value",oa._valueGet),
3
- oa.__defineSetter__("value",oa._valueSet));try{delete oa._valueGet,delete oa._valueSet}catch(a){oa._valueGet=void 0,oa._valueSet=void 0}break;case"getmetadata":if(ea=a(d.el),e=ea.data("_inputmask").maskset,f=ea.data("_inputmask").opts,a.isArray(e.metadata)){for(var qa,ra=q(),sa=ra;sa>=0;sa--)if(o().validPositions[sa]&&void 0!=o().validPositions[sa].alternation){qa=o().validPositions[sa].alternation;break}return void 0!=qa?e.metadata[o().validPositions[ra].locator[qa]]:e.metadata[0]}return e.metadata}}if(void 0===a.fn.inputmask){var g="function"==typeof ScriptEngineMajorVersion?ScriptEngineMajorVersion():new Function("/*@cc_on return @_jscript_version; @*/")()>=10,h=navigator.userAgent,i=null!==h.match(new RegExp("iphone","i")),j=null!==h.match(new RegExp("android.*safari.*","i")),k=null!==h.match(new RegExp("android.*chrome.*","i")),l=null!==h.match(new RegExp("android.*firefox.*","i")),m=/Kindle/i.test(h)||/Silk/i.test(h)||/KFTT/i.test(h)||/KFOT/i.test(h)||/KFJWA/i.test(h)||/KFJWI/i.test(h)||/KFSOWI/i.test(h)||/KFTHWA/i.test(h)||/KFTHWI/i.test(h)||/KFAPWA/i.test(h)||/KFAPWI/i.test(h),n=b("paste")?"paste":b("input")?"input":"propertychange";a.inputmask={defaults:{placeholder:"_",optionalmarker:{start:"[",end:"]"},quantifiermarker:{start:"{",end:"}"},groupmarker:{start:"(",end:")"},alternatormarker:"|",escapeChar:"\\",mask:null,oncomplete:a.noop,onincomplete:a.noop,oncleared:a.noop,repeat:0,greedy:!0,autoUnmask:!1,removeMaskOnSubmit:!0,clearMaskOnLostFocus:!0,insertMode:!0,clearIncomplete:!1,aliases:{},alias:null,onKeyUp:a.noop,onKeyPress:a.noop,onKeyDown:a.noop,onBeforeMask:void 0,onBeforePaste:void 0,onUnMask:void 0,showMaskOnFocus:!0,showMaskOnHover:!0,onKeyValidation:a.noop,skipOptionalPartCharacter:" ",showTooltip:!1,numericInput:!1,rightAlign:!1,radixPoint:"",radixFocus:!1,nojumps:!1,nojumpsThreshold:0,keepStatic:void 0,definitions:{9:{validator:"[0-9]",cardinality:1,definitionSymbol:"*"},a:{validator:"[A-Za-zА-яЁёÀ-ÿµ]",cardinality:1,definitionSymbol:"*"},"*":{validator:"[0-9A-Za-zА-яЁёÀ-ÿµ]",cardinality:1}},ignorables:[8,9,13,19,27,33,34,35,36,37,38,39,40,45,46,93,112,113,114,115,116,117,118,119,120,121,122,123],isComplete:void 0},keyCode:{ALT:18,BACKSPACE:8,CAPS_LOCK:20,COMMA:188,COMMAND:91,COMMAND_LEFT:91,COMMAND_RIGHT:93,CONTROL:17,DELETE:46,DOWN:40,END:35,ENTER:13,ESCAPE:27,HOME:36,INSERT:45,LEFT:37,MENU:93,NUMPAD_ADD:107,NUMPAD_DECIMAL:110,NUMPAD_DIVIDE:111,NUMPAD_ENTER:108,NUMPAD_MULTIPLY:106,NUMPAD_SUBTRACT:109,PAGE_DOWN:34,PAGE_UP:33,PERIOD:190,RIGHT:39,SHIFT:16,SPACE:32,TAB:9,UP:38,WINDOWS:91},masksCache:{},escapeRegex:function(a){var b=["/",".","*","+","?","|","(",")","[","]","{","}","\\"];return a.replace(new RegExp("(\\"+b.join("|\\")+")","gim"),"\\$1")},format:function(b,c,g){var h=a.extend(!0,{},a.inputmask.defaults,c);return d(h.alias,c,h),f({action:"format",value:b,metadata:g},e(h),h)},isValid:function(b,c){var g=a.extend(!0,{},a.inputmask.defaults,c);return d(g.alias,c,g),f({action:"isValid",value:b},e(g),g)}},a.fn.inputmask=function(b,c,g,h,i){function j(b,c,e){var f=a(b);f.data("inputmask-alias")&&d(f.data("inputmask-alias"),{},c);for(var g in c){var h=f.data("inputmask-"+g.toLowerCase());void 0!=h&&("mask"==g&&0==h.indexOf("[")?(c[g]=h.replace(/[\s[\]]/g,"").split("','"),c[g][0]=c[g][0].replace("'",""),c[g][c[g].length-1]=c[g][c[g].length-1].replace("'","")):c[g]="boolean"==typeof h?h:h.toString(),e&&(e[g]=c[g]))}return c}g=g||f,h=h||"_inputmask";var k,l=a.extend(!0,{},a.inputmask.defaults,c);if("string"==typeof b)switch(b){case"mask":return d(l.alias,c,l),k=e(l,g!==f),void 0==k?this:this.each(function(){g({action:"mask",el:this},a.extend(!0,{},k),j(this,l))});case"unmaskedvalue":var m=a(this);return m.data(h)?g({action:"unmaskedvalue",$input:m}):m.val();case"remove":return this.each(function(){var b=a(this);b.data(h)&&g({action:"remove",el:this})});case"getemptymask":return this.data(h)?g({action:"getemptymask",el:this}):"";case"hasMaskedValue":return!!this.data(h)&&!this.data(h).opts.autoUnmask;case"isComplete":return!this.data(h)||g({action:"isComplete",buffer:this[0]._valueGet().split(""),el:this});case"getmetadata":return this.data(h)?g({action:"getmetadata",el:this}):void 0;case"_detectScope":return d(l.alias,c,l),void 0==i||d(i,c,l)||-1!=a.inArray(i,["mask","unmaskedvalue","remove","getemptymask","hasMaskedValue","isComplete","getmetadata","_detectScope"])||(l.mask=i),a.isFunction(l.mask)&&(l.mask=l.mask.call(this,l)),a.isArray(l.mask);default:return d(l.alias,c,l),d(b,c,l)||(l.mask=b),k=e(l,g!==f),void 0==k?this:this.each(function(){g({action:"mask",el:this},a.extend(!0,{},k),j(this,l))})}else{if("object"==typeof b)return l=a.extend(!0,{},a.inputmask.defaults,b),d(l.alias,b,l),k=e(l,g!==f),void 0==k?this:this.each(function(){g({action:"mask",el:this},a.extend(!0,{},k),j(this,l))});if(void 0==b)return this.each(function(){var b=a(this).attr("data-inputmask");if(b&&""!=b)try{b=b.replace(new RegExp("'","g"),'"');var e=a.parseJSON("{"+b+"}");a.extend(!0,e,c),l=a.extend(!0,{},a.inputmask.defaults,e),l=j(this,l),d(l.alias,e,l),l.alias=void 0,a(this).inputmask("mask",l,g)}catch(a){}if(a(this).attr("data-inputmask-mask")||a(this).attr("data-inputmask-alias")){l=a.extend(!0,{},a.inputmask.defaults,{});var f={};l=j(this,l,f),d(l.alias,f,l),l.alias=void 0,a(this).inputmask("mask",l,g)}})}}}return a.fn.inputmask}(jQuery),function(a){return a.extend(a.inputmask.defaults.definitions,{h:{validator:"[01][0-9]|2[0-3]",cardinality:2,prevalidator:[{validator:"[0-2]",cardinality:1}]},s:{validator:"[0-5][0-9]",cardinality:2,prevalidator:[{validator:"[0-5]",cardinality:1}]},d:{validator:"0[1-9]|[12][0-9]|3[01]",cardinality:2,prevalidator:[{validator:"[0-3]",cardinality:1}]},m:{validator:"0[1-9]|1[012]",cardinality:2,prevalidator:[{validator:"[01]",cardinality:1}]},y:{validator:"(19|20)\\d{2}",cardinality:4,prevalidator:[{validator:"[12]",cardinality:1},{validator:"(19|20)",cardinality:2},{validator:"(19|20)\\d",cardinality:3}]}}),a.extend(a.inputmask.defaults.aliases,{"dd/mm/yyyy":{mask:"1/2/y",placeholder:"dd/mm/yyyy",regex:{val1pre:new RegExp("[0-3]"),val1:new RegExp("0[1-9]|[12][0-9]|3[01]"),val2pre:function(b){var c=a.inputmask.escapeRegex.call(this,b);return new RegExp("((0[1-9]|[12][0-9]|3[01])"+c+"[01])")},val2:function(b){var c=a.inputmask.escapeRegex.call(this,b);return new RegExp("((0[1-9]|[12][0-9])"+c+"(0[1-9]|1[012]))|(30"+c+"(0[13-9]|1[012]))|(31"+c+"(0[13578]|1[02]))")}},leapday:"29/02/",separator:"/",yearrange:{minyear:1900,maxyear:2099},isInYearRange:function(a,b,c){if(isNaN(a))return!1;var d=parseInt(a.concat(b.toString().slice(a.length))),e=parseInt(a.concat(c.toString().slice(a.length)));return!isNaN(d)&&(d>=b&&c>=d)||!isNaN(e)&&(e>=b&&c>=e)},determinebaseyear:function(a,b,c){var d=(new Date).getFullYear();if(a>d)return a;if(d>b){for(var e=b.toString().slice(0,2),f=b.toString().slice(2,4);e+c>b;)e--;var g=e+f;return a>g?a:g}return d},onKeyUp:function(b){var c=a(this);if(b.ctrlKey&&b.keyCode==a.inputmask.keyCode.RIGHT){var d=new Date;c.val(d.getDate().toString()+(d.getMonth()+1).toString()+d.getFullYear().toString())}},definitions:{1:{validator:function(a,b,c,d,e){var f=e.regex.val1.test(a);return d||f||a.charAt(1)!=e.separator&&-1=="-./".indexOf(a.charAt(1))||!(f=e.regex.val1.test("0"+a.charAt(0)))?f:(b.buffer[c-1]="0",{refreshFromBuffer:{start:c-1,end:c},pos:c,c:a.charAt(0)})},cardinality:2,prevalidator:[{validator:function(a,b,c,d,e){isNaN(b.buffer[c+1])||(a+=b.buffer[c+1]);var f=1==a.length?e.regex.val1pre.test(a):e.regex.val1.test(a);return d||f||!(f=e.regex.val1.test("0"+a))?f:(b.buffer[c]="0",c++,{pos:c})},cardinality:1}]},2:{validator:function(a,b,c,d,e){var f=e.mask.indexOf("2")==e.mask.length-1?b.buffer.join("").substr(5,3):b.buffer.join("").substr(0,3);-1!=f.indexOf(e.placeholder[0])&&(f="01"+e.separator);var g=e.regex.val2(e.separator).test(f+a);if(!d&&!g&&(a.charAt(1)==e.separator||-1!="-./".indexOf(a.charAt(1)))&&(g=e.regex.val2(e.separator).test(f+"0"+a.charAt(0))))return b.buffer[c-1]="0",{refreshFromBuffer:{start:c-1,end:c},pos:c,c:a.charAt(0)};if(e.mask.indexOf("2")==e.mask.length-1&&g){var h=b.buffer.join("").substr(4,4)+a;if(h!=e.leapday)return!0;var i=parseInt(b.buffer.join("").substr(0,4),10);return i%4===0&&(i%100!==0||i%400===0)}return g},cardinality:2,prevalidator:[{validator:function(a,b,c,d,e){isNaN(b.buffer[c+1])||(a+=b.buffer[c+1]);var f=e.mask.indexOf("2")==e.mask.length-1?b.buffer.join("").substr(5,3):b.buffer.join("").substr(0,3);-1!=f.indexOf(e.placeholder[0])&&(f="01"+e.separator);var g=1==a.length?e.regex.val2pre(e.separator).test(f+a):e.regex.val2(e.separator).test(f+a);return d||g||!(g=e.regex.val2(e.separator).test(f+"0"+a))?g:(b.buffer[c]="0",c++,{pos:c})},cardinality:1}]},y:{validator:function(a,b,c,d,e){if(e.isInYearRange(a,e.yearrange.minyear,e.yearrange.maxyear)){var f=b.buffer.join("").substr(0,6);if(f!=e.leapday)return!0;var g=parseInt(a,10);return g%4===0&&(g%100!==0||g%400===0)}return!1},cardinality:4,prevalidator:[{validator:function(a,b,c,d,e){var f=e.isInYearRange(a,e.yearrange.minyear,e.yearrange.maxyear);if(!d&&!f){var g=e.determinebaseyear(e.yearrange.minyear,e.yearrange.maxyear,a+"0").toString().slice(0,1);if(f=e.isInYearRange(g+a,e.yearrange.minyear,e.yearrange.maxyear))return b.buffer[c++]=g.charAt(0),{pos:c};if(g=e.determinebaseyear(e.yearrange.minyear,e.yearrange.maxyear,a+"0").toString().slice(0,2),f=e.isInYearRange(g+a,e.yearrange.minyear,e.yearrange.maxyear))return b.buffer[c++]=g.charAt(0),b.buffer[c++]=g.charAt(1),{pos:c}}return f},cardinality:1},{validator:function(a,b,c,d,e){var f=e.isInYearRange(a,e.yearrange.minyear,e.yearrange.maxyear);if(!d&&!f){var g=e.determinebaseyear(e.yearrange.minyear,e.yearrange.maxyear,a).toString().slice(0,2);if(f=e.isInYearRange(a[0]+g[1]+a[1],e.yearrange.minyear,e.yearrange.maxyear))return b.buffer[c++]=g.charAt(1),{pos:c};if(g=e.determinebaseyear(e.yearrange.minyear,e.yearrange.maxyear,a).toString().slice(0,2),e.isInYearRange(g+a,e.yearrange.minyear,e.yearrange.maxyear)){var h=b.buffer.join("").substr(0,6);if(h!=e.leapday)f=!0;else{var i=parseInt(a,10);f=i%4===0&&(i%100!==0||i%400===0)}}else f=!1;if(f)return b.buffer[c-1]=g.charAt(0),b.buffer[c++]=g.charAt(1),b.buffer[c++]=a.charAt(0),{refreshFromBuffer:{start:c-3,end:c},pos:c}}return f},cardinality:2},{validator:function(a,b,c,d,e){return e.isInYearRange(a,e.yearrange.minyear,e.yearrange.maxyear)},cardinality:3}]}},insertMode:!1,autoUnmask:!1},"mm/dd/yyyy":{placeholder:"mm/dd/yyyy",alias:"dd/mm/yyyy",regex:{val2pre:function(b){var c=a.inputmask.escapeRegex.call(this,b);return new RegExp("((0[13-9]|1[012])"+c+"[0-3])|(02"+c+"[0-2])")},val2:function(b){var c=a.inputmask.escapeRegex.call(this,b);return new RegExp("((0[1-9]|1[012])"+c+"(0[1-9]|[12][0-9]))|((0[13-9]|1[012])"+c+"30)|((0[13578]|1[02])"+c+"31)")},val1pre:new RegExp("[01]"),val1:new RegExp("0[1-9]|1[012]")},leapday:"02/29/",onKeyUp:function(b){var c=a(this);if(b.ctrlKey&&b.keyCode==a.inputmask.keyCode.RIGHT){var d=new Date;c.val((d.getMonth()+1).toString()+d.getDate().toString()+d.getFullYear().toString())}}},"yyyy/mm/dd":{mask:"y/1/2",placeholder:"yyyy/mm/dd",alias:"mm/dd/yyyy",leapday:"/02/29",onKeyUp:function(b){var c=a(this);if(b.ctrlKey&&b.keyCode==a.inputmask.keyCode.RIGHT){var d=new Date;c.val(d.getFullYear().toString()+(d.getMonth()+1).toString()+d.getDate().toString())}}},"dd.mm.yyyy":{mask:"1.2.y",placeholder:"dd.mm.yyyy",leapday:"29.02.",separator:".",alias:"dd/mm/yyyy"},"dd-mm-yyyy":{mask:"1-2-y",placeholder:"dd-mm-yyyy",leapday:"29-02-",separator:"-",alias:"dd/mm/yyyy"},"mm.dd.yyyy":{mask:"1.2.y",placeholder:"mm.dd.yyyy",leapday:"02.29.",separator:".",alias:"mm/dd/yyyy"},"mm-dd-yyyy":{mask:"1-2-y",placeholder:"mm-dd-yyyy",leapday:"02-29-",separator:"-",alias:"mm/dd/yyyy"},"yyyy.mm.dd":{mask:"y.1.2",placeholder:"yyyy.mm.dd",leapday:".02.29",separator:".",alias:"yyyy/mm/dd"},"yyyy-mm-dd":{mask:"y-1-2",placeholder:"yyyy-mm-dd",leapday:"-02-29",separator:"-",alias:"yyyy/mm/dd"},datetime:{mask:"1/2/y h:s",placeholder:"dd/mm/yyyy hh:mm",alias:"dd/mm/yyyy",regex:{hrspre:new RegExp("[012]"),hrs24:new RegExp("2[0-4]|1[3-9]"),hrs:new RegExp("[01][0-9]|2[0-4]"),ampm:new RegExp("^[a|p|A|P][m|M]"),mspre:new RegExp("[0-5]"),ms:new RegExp("[0-5][0-9]")},timeseparator:":",hourFormat:"24",definitions:{h:{validator:function(a,b,c,d,e){if("24"==e.hourFormat&&24==parseInt(a,10))return b.buffer[c-1]="0",b.buffer[c]="0",{refreshFromBuffer:{start:c-1,end:c},c:"0"};var f=e.regex.hrs.test(a);if(!d&&!f&&(a.charAt(1)==e.timeseparator||-1!="-.:".indexOf(a.charAt(1)))&&(f=e.regex.hrs.test("0"+a.charAt(0))))return b.buffer[c-1]="0",b.buffer[c]=a.charAt(0),c++,{refreshFromBuffer:{start:c-2,end:c},pos:c,c:e.timeseparator};if(f&&"24"!==e.hourFormat&&e.regex.hrs24.test(a)){var g=parseInt(a,10);return 24==g?(b.buffer[c+5]="a",b.buffer[c+6]="m"):(b.buffer[c+5]="p",b.buffer[c+6]="m"),g-=12,10>g?(b.buffer[c]=g.toString(),b.buffer[c-1]="0"):(b.buffer[c]=g.toString().charAt(1),b.buffer[c-1]=g.toString().charAt(0)),{refreshFromBuffer:{start:c-1,end:c+6},c:b.buffer[c]}}return f},cardinality:2,prevalidator:[{validator:function(a,b,c,d,e){var f=e.regex.hrspre.test(a);return d||f||!(f=e.regex.hrs.test("0"+a))?f:(b.buffer[c]="0",c++,{pos:c})},cardinality:1}]},s:{validator:"[0-5][0-9]",cardinality:2,prevalidator:[{validator:function(a,b,c,d,e){var f=e.regex.mspre.test(a);return d||f||!(f=e.regex.ms.test("0"+a))?f:(b.buffer[c]="0",c++,{pos:c})},cardinality:1}]},t:{validator:function(a,b,c,d,e){return e.regex.ampm.test(a+"m")},casing:"lower",cardinality:1}},insertMode:!1,autoUnmask:!1},datetime12:{mask:"1/2/y h:s t\\m",placeholder:"dd/mm/yyyy hh:mm xm",alias:"datetime",hourFormat:"12"},"hh:mm t":{mask:"h:s t\\m",placeholder:"hh:mm xm",alias:"datetime",hourFormat:"12"},"h:s t":{mask:"h:s t\\m",placeholder:"hh:mm xm",alias:"datetime",hourFormat:"12"},"hh:mm:ss":{mask:"h:s:s",placeholder:"hh:mm:ss",alias:"datetime",autoUnmask:!1},"hh:mm":{mask:"h:s",placeholder:"hh:mm",alias:"datetime",autoUnmask:!1},date:{alias:"dd/mm/yyyy"},"mm/yyyy":{mask:"1/y",placeholder:"mm/yyyy",leapday:"donotuse",separator:"/",alias:"mm/dd/yyyy"}}),a.fn.inputmask}(jQuery),function(a){return a.extend(a.inputmask.defaults.definitions,{A:{validator:"[A-Za-zА-яЁёÀ-ÿµ]",cardinality:1,casing:"upper"},"#":{validator:"[0-9A-Za-zА-яЁёÀ-ÿµ]",cardinality:1,casing:"upper"}}),a.extend(a.inputmask.defaults.aliases,{url:{mask:"ir",placeholder:"",separator:"",defaultPrefix:"http://",regex:{urlpre1:new RegExp("[fh]"),urlpre2:new RegExp("(ft|ht)"),urlpre3:new RegExp("(ftp|htt)"),urlpre4:new RegExp("(ftp:|http|ftps)"),urlpre5:new RegExp("(ftp:/|ftps:|http:|https)"),urlpre6:new RegExp("(ftp://|ftps:/|http:/|https:)"),urlpre7:new RegExp("(ftp://|ftps://|http://|https:/)"),urlpre8:new RegExp("(ftp://|ftps://|http://|https://)")},definitions:{i:{validator:function(){return!0},cardinality:8,prevalidator:function(){for(var a=[],b=8,c=0;b>c;c++)a[c]=function(){var a=c;return{validator:function(b,c,d,e,f){if(f.regex["urlpre"+(a+1)]){var g,h=b;a+1-b.length>0&&(h=c.buffer.join("").substring(0,a+1-b.length)+""+h);var i=f.regex["urlpre"+(a+1)].test(h);if(!e&&!i){for(d-=a,g=0;g<f.defaultPrefix.length;g++)c.buffer[d]=f.defaultPrefix[g],d++;for(g=0;g<h.length-1;g++)c.buffer[d]=h[g],d++;return{pos:d}}return i}return!1},cardinality:a}}();return a}()},r:{validator:".",cardinality:50}},insertMode:!1,autoUnmask:!1},ip:{mask:"i[i[i]].i[i[i]].i[i[i]].i[i[i]]",definitions:{i:{validator:function(a,b,c){return c-1>-1&&"."!=b.buffer[c-1]?(a=b.buffer[c-1]+a,a=c-2>-1&&"."!=b.buffer[c-2]?b.buffer[c-2]+a:"0"+a):a="00"+a,new RegExp("25[0-5]|2[0-4][0-9]|[01][0-9][0-9]").test(a)},cardinality:1}}},email:{mask:"*{1,64}[.*{1,64}][.*{1,64}][.*{1,64}]@*{1,64}[.*{2,64}][.*{2,6}][.*{1,2}]",greedy:!1,onBeforePaste:function(a){return a=a.toLowerCase(),a.replace("mailto:","")},definitions:{"*":{validator:"[0-9A-Za-z!#$%&'*+/=?^_`{|}~-]",cardinality:1,casing:"lower"}}}}),a.fn.inputmask}(jQuery),function(a){return a.extend(a.inputmask.defaults.aliases,{numeric:{mask:function(a){if(0!==a.repeat&&isNaN(a.integerDigits)&&(a.integerDigits=a.repeat),a.repeat=0,a.groupSeparator==a.radixPoint&&(a.groupSeparator="."==a.radixPoint?",":","==a.radixPoint?".":"")," "===a.groupSeparator&&(a.skipOptionalPartCharacter=void 0),a.autoGroup=a.autoGroup&&""!=a.groupSeparator,a.autoGroup&&isFinite(a.integerDigits)){var b=Math.floor(a.integerDigits/a.groupSize),c=a.integerDigits%a.groupSize;a.integerDigits+=0==c?b-1:b}a.definitions[";"]=a.definitions["~"];var d=a.prefix;return d+="[+]",d+="~{1,"+a.integerDigits+"}",void 0!=a.digits&&(isNaN(a.digits)||parseInt(a.digits)>0)&&(d+=a.digitsOptional?"["+(a.decimalProtect?":":a.radixPoint)+";{"+a.digits+"}]":(a.decimalProtect?":":a.radixPoint)+";{"+a.digits+"}"),d+=a.suffix},placeholder:"",greedy:!1,digits:"*",digitsOptional:!0,groupSeparator:"",radixPoint:".",radixFocus:!0,groupSize:3,autoGroup:!1,allowPlus:!0,allowMinus:!0,integerDigits:"+",prefix:"",suffix:"",rightAlign:!0,decimalProtect:!0,postFormat:function(b,c,d,e){var f=!1,g=b[c];if(""==e.groupSeparator||-1!=a.inArray(e.radixPoint,b)&&c>=a.inArray(e.radixPoint,b)||new RegExp("[-+]").test(g))return{pos:c};var h=b.slice();g==e.groupSeparator&&(h.splice(c--,1),g=h[c]),d?h[c]="?":h.splice(c,0,"?");var i=h.join("");if(e.autoGroup||d&&-1!=i.indexOf(e.groupSeparator)){var j=a.inputmask.escapeRegex.call(this,e.groupSeparator);f=0==i.indexOf(e.groupSeparator),i=i.replace(new RegExp(j,"g"),"");var k=i.split(e.radixPoint);if(i=k[0],i!=e.prefix+"?0"&&i.length>=e.groupSize+e.prefix.length){f=!0;for(var l=new RegExp("([-+]?[\\d?]+)([\\d?]{"+e.groupSize+"})");l.test(i);)i=i.replace(l,"$1"+e.groupSeparator+"$2"),i=i.replace(e.groupSeparator+e.groupSeparator,e.groupSeparator)}k.length>1&&(i+=e.radixPoint+k[1])}b.length=i.length;for(var m=0,n=i.length;n>m;m++)b[m]=i.charAt(m);var o=a.inArray("?",b);return d?b[o]=g:b.splice(o,1),{pos:o,refreshFromBuffer:f}},onKeyDown:function(b,c,d,e){if(b.keyCode==a.inputmask.keyCode.TAB&&"0"!=e.placeholder.charAt(0)){var f=a.inArray(e.radixPoint,c);if(-1!=f&&isFinite(e.digits)){for(var g=1;g<=e.digits;g++)(void 0==c[f+g]||c[f+g]==e.placeholder.charAt(0))&&(c[f+g]="0");return{refreshFromBuffer:{start:++f,end:f+e.digits}}}}else if(e.autoGroup&&(b.keyCode==a.inputmask.keyCode.DELETE||b.keyCode==a.inputmask.keyCode.BACKSPACE)){var h=e.postFormat(c,d-1,!0,e);return h.caret=h.pos+1,h}},onKeyPress:function(a,b,c,d){if(d.autoGroup){var e=d.postFormat(b,c-1,!0,d);return e.caret=e.pos+1,e}},regex:{integerPart:function(){return new RegExp("[-+]?\\d+")},integerNPart:function(){return new RegExp("\\d+")}},signHandler:function(a,b,c,d,e){if(!d&&(e.allowMinus&&"-"===a||e.allowPlus&&"+"===a)){var f=b.join("").match(e.regex.integerPart(e));if(f&&f.length>0&&"0"!==f[f.index])return b[f.index]==("-"===a?"+":"-")?{pos:f.index,c:a,remove:f.index,caret:c}:b[f.index]==("-"===a?"-":"+")?{remove:f.index,caret:c-1}:{pos:f.index,c:a,caret:c+1}}return!1},radixHandler:function(b,c,d,e,f){if(!e&&b===f.radixPoint){var g=a.inArray(f.radixPoint,c.buffer),h=c.buffer.join("").match(f.regex.integerPart(f));if(-1!=g)return c.validPositions[g-1]?{caret:g+1}:{pos:h.index,c:h[0],caret:g+1}}return!1},leadingZeroHandler:function(b,c,d,e,f){var g=c.buffer.join("").match(f.regex.integerNPart(f)),h=a.inArray(f.radixPoint,c.buffer);if(g&&!e&&(-1==h||g.index<h))if(0==g[0].indexOf("0")&&d>=f.prefix.length){if(-1==h||h>=d&&void 0==c.validPositions[h])return c.buffer.splice(g.index,1),d=d>g.index?d-1:g.index,{pos:d,remove:g.index};if(d>g.index&&h>=d)return c.buffer.splice(g.index,1),d=d>g.index?d-1:g.index,{pos:d,remove:g.index}}else if("0"==b&&d<=g.index)return!1;return!0},definitions:{"~":{validator:function(b,c,d,e,f){var g=f.signHandler(b,c.buffer,d,e,f);if(!g&&(g=f.radixHandler(b,c,d,e,f),!g&&(g=e?new RegExp("[0-9"+a.inputmask.escapeRegex.call(this,f.groupSeparator)+"]").test(b):new RegExp("[0-9]").test(b),g===!0&&(g=f.leadingZeroHandler(b,c,d,e,f),g===!0)))){var h=a.inArray(f.radixPoint,c.buffer);f.digitsOptional===!1&&d>h&&!e&&(g={pos:d,remove:d}),g={pos:d}}return g},cardinality:1,prevalidator:null},"+":{validator:function(a,b,c,d,e){var f=e.signHandler(a,b.buffer,c,d,e);return f||(f=e.allowMinus&&"-"==a||e.allowPlus&&"+"==a),f},cardinality:1,prevalidator:null,placeholder:""},":":{validator:function(b,c,d,e,f){var g=f.signHandler(b,c.buffer,d,e,f);if(!g){var h="["+a.inputmask.escapeRegex.call(this,f.radixPoint)+"]";g=new RegExp(h).test(b),g&&c.validPositions[d]&&c.validPositions[d].match.placeholder==f.radixPoint&&(g={pos:d,remove:d})}return g},cardinality:1,prevalidator:null,placeholder:function(a){return a.radixPoint}}},insertMode:!0,autoUnmask:!1,onUnMask:function(b,c,d){var e=b.replace(d.prefix,"");return e=e.replace(d.suffix,""),e=e.replace(new RegExp(a.inputmask.escapeRegex.call(this,d.groupSeparator),"g"),"")},isComplete:function(b,c){var d=b.join(""),e=b.slice();if(c.postFormat(e,0,!0,c),e.join("")!=d)return!1;var f=d.replace(c.prefix,"");return f=f.replace(c.suffix,""),f=f.replace(new RegExp(a.inputmask.escapeRegex.call(this,c.groupSeparator),"g"),""),f=f.replace(a.inputmask.escapeRegex.call(this,c.radixPoint),"."),isFinite(f)},onBeforeMask:function(b,c){if(isFinite(b))return b.toString().replace(".",c.radixPoint);var d=b.match(/,/g),e=b.match(/\./g);return e&&d?e.length>d.length?(b=b.replace(/\./g,""),b=b.replace(",",c.radixPoint)):d.length>e.length&&(b=b.replace(/,/g,""),b=b.replace(".",c.radixPoint)):b=b.replace(new RegExp(a.inputmask.escapeRegex.call(this,c.groupSeparator),"g"),""),b}},currency:{prefix:"$ ",groupSeparator:",",radixPoint:".",alias:"numeric",placeholder:"0",autoGroup:!0,digits:2,digitsOptional:!1,clearMaskOnLostFocus:!1,decimalProtect:!0},decimal:{alias:"numeric"},integer:{alias:"numeric",digits:"0"}}),a.fn.inputmask}(jQuery),function(a){return a.extend(a.inputmask.defaults.aliases,{phone:{url:"phone-codes/phone-codes.js",maskInit:"+pp(pp)pppppppp",mask:function(b){b.definitions={p:{validator:function(){return!1},cardinality:1},"#":{validator:"[0-9]",cardinality:1}};var c=[];return a.ajax({url:b.url,async:!1,dataType:"json",success:function(a){c=a}}),c=c.sort(function(a,b){return(a.mask||a)<(b.mask||b)?-1:1}),c.splice(0,0,b.maskInit),c},nojumps:!0,nojumpsThreshold:1},phonebe:{alias:"phone",url:"phone-codes/phone-be.js",maskInit:"+32(pp)pppppppp",nojumpsThreshold:4}}),a.fn.inputmask}(jQuery),function(a){return a.extend(a.inputmask.defaults.aliases,{Regex:{mask:"r",greedy:!1,repeat:"*",regex:null,regexTokens:null,tokenizer:/\[\^?]?(?:[^\\\]]+|\\[\S\s]?)*]?|\\(?:0(?:[0-3][0-7]{0,2}|[4-7][0-7]?)?|[1-9][0-9]*|x[0-9A-Fa-f]{2}|u[0-9A-Fa-f]{4}|c[A-Za-z]|[\S\s]?)|\((?:\?[:=!]?)?|(?:[?*+]|\{[0-9]+(?:,[0-9]*)?\})\??|[^.?*+^${[()|\\]+|./g,quantifierFilter:/[0-9]+[^,]/,isComplete:function(a,b){return new RegExp(b.regex).test(a.join(""))},definitions:{r:{validator:function(b,c,d,e,f){function g(a,b){this.matches=[],this.isGroup=a||!1,this.isQuantifier=b||!1,this.quantifier={min:1,max:1},this.repeaterPart=void 0}function h(){var a,b,c=new g,d=[];for(f.regexTokens=[];a=f.tokenizer.exec(f.regex);)switch(b=a[0],b.charAt(0)){case"(":d.push(new g(!0));break;case")":var e=d.pop();d.length>0?d[d.length-1].matches.push(e):c.matches.push(e);break;case"{":case"+":case"*":var h=new g(!1,!0);b=b.replace(/[{}]/g,"");var i=b.split(","),j=isNaN(i[0])?i[0]:parseInt(i[0]),k=1==i.length?j:isNaN(i[1])?i[1]:parseInt(i[1]);if(h.quantifier={min:j,max:k},d.length>0){var l=d[d.length-1].matches;if(a=l.pop(),!a.isGroup){var e=new g(!0);e.matches.push(a),a=e}l.push(a),l.push(h)}else{if(a=c.matches.pop(),!a.isGroup){var e=new g(!0);e.matches.push(a),a=e}c.matches.push(a),c.matches.push(h)}break;default:d.length>0?d[d.length-1].matches.push(b):c.matches.push(b)}c.matches.length>0&&f.regexTokens.push(c)}function i(b,c){var d=!1;c&&(k+="(",m++);for(var e=0;e<b.matches.length;e++){var f=b.matches[e];if(1==f.isGroup)d=i(f,!0);else if(1==f.isQuantifier){var g=a.inArray(f,b.matches),h=b.matches[g-1],j=k;if(isNaN(f.quantifier.max)){for(;f.repeaterPart&&f.repeaterPart!=k&&f.repeaterPart.length>k.length&&!(d=i(h,!0)););d=d||i(h,!0),d&&(f.repeaterPart=k),k=j+f.quantifier.max}else{for(var l=0,o=f.quantifier.max-1;o>l&&!(d=i(h,!0));l++);k=j+"{"+f.quantifier.min+","+f.quantifier.max+"}"}}else if(void 0!=f.matches)for(var p=0;p<f.length&&!(d=i(f[p],c));p++);else{var q;if("["==f.charAt(0)){q=k,q+=f;for(var r=0;m>r;r++)q+=")";var s=new RegExp("^("+q+")$");d=s.test(n)}else for(var t=0,u=f.length;u>t;t++)if("\\"!=f.charAt(t)){q=k,q+=f.substr(0,t+1),q=q.replace(/\|$/,"");for(var r=0;m>r;r++)q+=")";var s=new RegExp("^("+q+")$");if(d=s.test(n))break}k+=f}if(d)break}return c&&(k+=")",m--),d}null==f.regexTokens&&h();var j=c.buffer.slice(),k="",l=!1,m=0;j.splice(d,0,b);for(var n=j.join(""),o=0;o<f.regexTokens.length;o++){var g=f.regexTokens[o];if(l=i(g,g.isGroup))break}return l},cardinality:1}}}}),a.fn.inputmask}(jQuery),jQuery(document).ready(function(a){jQuery(document).on("cf.add",function(){a("[data-inputmask]").inputmask()}),jQuery(document).trigger("cf.add")}),function(a){"function"==typeof define&&define.amd?define(["jquery"],a):a("object"==typeof exports?require("jquery"):jQuery)}(function(a){function b(){var a=document.createElement("input");return a.setAttribute("type","range"),"text"!==a.type}function c(a,b){var c=Array.prototype.slice.call(arguments,2);return setTimeout(function(){return a.apply(null,c)},b)}function d(a,b){return b=b||100,function(){if(!a.debouncing){var c=Array.prototype.slice.apply(arguments);a.lastReturnVal=a.apply(window,c),a.debouncing=!0}return clearTimeout(a.debounceTimeout),a.debounceTimeout=setTimeout(function(){a.debouncing=!1},b),a.lastReturnVal}}function e(b,e){if(this.$window=a(window),this.$document=a(document),this.$element=a(b),this.options=a.extend({},i,e),this._defaults=i,this._name=f,this.startEvent=this.options.startEvent.join("."+f+" ")+"."+f,this.moveEvent=this.options.moveEvent.join("."+f+" ")+"."+f,this.endEvent=this.options.endEvent.join("."+f+" ")+"."+f,this.polyfill=this.options.polyfill,this.onInit=this.options.onInit,this.onSlide=this.options.onSlide,this.onSlideEnd=this.options.onSlideEnd,this.polyfill&&h)return!1;this.identifier="js-"+f+"-"+ +new Date,this.min=parseFloat(this.$element[0].getAttribute("min")||0),this.max=parseFloat(this.$element[0].getAttribute("max")||100),this.value=parseFloat(this.$element[0].value||this.min+(this.max-this.min)/2),this.step=parseFloat(this.$element[0].getAttribute("step")||1),this.$fill=a('<div class="'+this.options.fillClass+'" />'),this.$handle=a('<div class="'+this.options.handleClass+'" />'),this.$range=a('<div class="'+this.options.rangeClass+'" id="'+this.identifier+'" />').insertAfter(this.$element).prepend(this.$fill,this.$handle),this.$element.css({position:"absolute",width:"1px",height:"1px",overflow:"hidden",opacity:"0"}),this.handleDown=a.proxy(this.handleDown,this),this.handleMove=a.proxy(this.handleMove,this),this.handleEnd=a.proxy(this.handleEnd,this),this.init();var g=this;this.$window.on("resize."+f,d(function(){c(function(){g.update()},300)},20)),this.$document.on(this.startEvent,"#"+this.identifier+":not(."+this.options.disabledClass+")",this.handleDown),this.$element.on("change."+f,function(a,b){if(!b||b.origin!==f){var c=a.target.value,d=g.getPositionFromValue(c);g.setPosition(d)}})}var f="rangeslider",g=[],h=b(),i={polyfill:!0,rangeClass:"rangeslider",disabledClass:"rangeslider--disabled",fillClass:"rangeslider__fill",handleClass:"rangeslider__handle",startEvent:["mousedown","touchstart","pointerdown"],moveEvent:["mousemove","touchmove","pointermove"],endEvent:["mouseup","touchend","pointerup"]};e.prototype.init=function(){this.onInit&&"function"==typeof this.onInit&&this.onInit(),this.update()},e.prototype.update=function(){this.handleWidth=this.$handle[0].offsetWidth,this.rangeWidth=this.$range[0].offsetWidth,this.maxHandleX=this.rangeWidth-this.handleWidth,this.grabX=this.handleWidth/2,this.position=this.getPositionFromValue(this.value),this.$element[0].disabled?this.$range.addClass(this.options.disabledClass):this.$range.removeClass(this.options.disabledClass),this.setPosition(this.position)},e.prototype.handleDown=function(a){if(a.preventDefault(),this.$document.on(this.moveEvent,this.handleMove),this.$document.on(this.endEvent,this.handleEnd),!((" "+a.target.className+" ").replace(/[\n\t]/g," ").indexOf(this.options.handleClass)>-1)){var b=this.getRelativePosition(this.$range[0],a),c=this.getPositionFromNode(this.$handle[0])-this.getPositionFromNode(this.$range[0]);this.setPosition(b-this.grabX),b>=c&&b<c+this.handleWidth&&(this.grabX=b-c)}},e.prototype.handleMove=function(a){a.preventDefault();var b=this.getRelativePosition(this.$range[0],a);this.setPosition(b-this.grabX)},e.prototype.handleEnd=function(a){a.preventDefault(),this.$document.off(this.moveEvent,this.handleMove),this.$document.off(this.endEvent,this.handleEnd);var b=this.getRelativePosition(this.$range[0],a);this.onSlideEnd&&"function"==typeof this.onSlideEnd&&this.onSlideEnd(b-this.grabX,this.value)},e.prototype.cap=function(a,b,c){return a<b?b:a>c?c:a},e.prototype.setPosition=function(a){var b,c;b=this.getValueFromPosition(this.cap(a,0,this.maxHandleX))/this.step*this.step,c=this.getPositionFromValue(b),this.$fill[0].style.width=c+this.grabX+"px",this.$handle[0].style.left=c+"px",this.setValue(b),this.position=c,this.value=b,this.onSlide&&"function"==typeof this.onSlide&&this.onSlide(c,b)},e.prototype.getPositionFromNode=function(a){for(var b=0;null!==a;)b+=a.offsetLeft,a=a.offsetParent;return b},e.prototype.getRelativePosition=function(a,b){return(b.pageX||b.originalEvent.clientX||b.originalEvent.touches[0].clientX||b.currentPoint.x)-this.getPositionFromNode(a)},e.prototype.getPositionFromValue=function(a){var b,c;return b=(a-this.min)/(this.max-this.min),c=b*this.maxHandleX},e.prototype.getValueFromPosition=function(a){var b,c;return b=a/(this.maxHandleX||1),c=this.step*Math.ceil((b*(this.max-this.min)+this.min)/this.step),Number(c.toFixed(2))},e.prototype.setValue=function(a){a!==this.value&&this.$element.val(a).trigger("change",{origin:f})},e.prototype.destroy=function(){this.$document.off(this.startEvent,"#"+this.identifier,this.handleDown),this.$element.off("."+f).removeAttr("style").removeData("plugin_"+f),this.$range&&this.$range.length&&this.$range[0].parentNode.removeChild(this.$range[0]),g.splice(g.indexOf(this.$element[0]),1),g.length||this.$window.off("."+f)},a.fn[f]=function(b){return this.each(function(){var c=a(this),d=c.data("plugin_"+f);d||(c.data("plugin_"+f,d=new e(this,b)),g.push(this)),"string"==typeof b&&d[b]()})}}),function(a){"use strict";var b={init:function(c){return this.each(function(){this.self=a(this),b.destroy.call(this.self),this.opt=a.extend(!0,{},a.fn.raty.defaults,c),b._adjustCallback.call(this),b._adjustNumber.call(this),"img"!==this.opt.starType&&b._adjustStarType.call(this),b._adjustPath.call(this),b._createStars.call(this),this.opt.cancel&&b._createCancel.call(this),this.opt.precision&&b._adjustPrecision.call(this),b._createScore.call(this),b._apply.call(this,this.opt.score),b._target.call(this,this.opt.score),this.opt.readOnly?b._lock.call(this):(this.style.cursor="pointer",b._binds.call(this)),this.self.data("options",this.opt)})},_adjustCallback:function(){for(var a=["number","readOnly","score","scoreName"],b=0;b<a.length;b++)"function"==typeof this.opt[a[b]]&&(this.opt[a[b]]=this.opt[a[b]].call(this))},_adjustNumber:function(){this.opt.number=b._between(this.opt.number,1,this.opt.numberMax)},_adjustPath:function(){this.opt.path=this.opt.path||"",this.opt.path&&"/"!==this.opt.path.charAt(this.opt.path.length-1)&&(this.opt.path+="/")},_adjustPrecision:function(){this.opt.half=!0,this.opt.targetType="score"},_adjustStarType:function(){this.opt.path="";for(var a=["cancelOff","cancelOn","starHalf","starOff","starOn"],b=0;b<a.length;b++)this.opt[a[b]]=this.opt[a[b]].replace(".","-")},_apply:function(a){b._fill.call(this,a),a&&(a>0&&this.score.val(b._between(a,0,this.opt.number)),b._roundStars.call(this,a))},_between:function(a,b,c){
4
- return Math.min(Math.max(parseFloat(a),b),c)},_binds:function(){this.cancel&&(b._bindOverCancel.call(this),b._bindClickCancel.call(this),b._bindOutCancel.call(this)),b._bindOver.call(this),b._bindClick.call(this),b._bindOut.call(this)},_bindClick:function(){var b=this;b.stars.on("click.raty",function(c){var d=a(this);b.score.val(b.opt.half||b.opt.precision?b.self.data("score"):this.alt||d.data("alt")),b.opt.click&&b.opt.click.call(b,+b.score.val(),c)})},_bindClickCancel:function(){var a=this;a.cancel.on("click.raty",function(b){a.score.removeAttr("value"),a.opt.click&&a.opt.click.call(a,null,b)})},_bindOut:function(){var a=this;a.self.on("mouseleave.raty",function(c){var d=+a.score.val()||void 0;b._apply.call(a,d),b._target.call(a,d,c),a.opt.mouseout&&a.opt.mouseout.call(a,d,c)})},_bindOutCancel:function(){var b=this;b.cancel.on("mouseleave.raty",function(c){var d=a(this),e=b.opt.path+b.opt.cancelOff;if("img"===b.opt.starType)d.attr("src",e);else{var f=b.opt.path+b.opt.cancelOn;d.removeClass(f).addClass(e)}if(b.opt.mouseout){var g=+b.score.val()||void 0;b.opt.mouseout.call(b,g,c)}})},_bindOver:function(){var a=this,c=a.opt.half?"mousemove.raty":"mouseover.raty";a.stars.on(c,function(c){var d=b._getScoreByPosition.call(a,c,this);b._fill.call(a,d),a.opt.half&&(b._roundStars.call(a,d),a.self.data("score",d)),b._target.call(a,d,c),a.opt.mouseover&&a.opt.mouseover.call(a,d,c)})},_bindOverCancel:function(){var c=this;c.cancel.on("mouseover.raty",function(d){var e=c.opt.path+c.opt.cancelOn,f=a(this),g=c.opt.path+c.opt.starOff;if("img"===c.opt.starType)f.attr("src",e),c.stars.attr("src",g);else{c.stars.attr("class",g);var h=c.opt.path+c.opt.cancelOff;f.removeClass(h).addClass(e).css("color",c.opt.starColor)}b._target.call(c,null,d),c.opt.mouseover&&c.opt.mouseover.call(c,null)})},_buildScoreField:function(){return a("<input />",{name:this.opt.scoreName,type:"hidden"}).appendTo(this)},_createCancel:function(){var b=this.opt.path+this.opt.cancelOff,c=a("<"+this.opt.starType+" />",{title:this.opt.cancelHint,class:"raty-cancel"}).css("marginRight",this.opt.space?this.opt.spaceWidth+"px":"0");"img"===this.opt.starType?c.attr({src:b,alt:"x"}):c.attr("data-alt","x").addClass(b),"left"===this.opt.cancelPlace?this.self.prepend("&#160;").prepend(c):this.self.append("&#160;").append(c),this.cancel=c},_createScore:function(){var c=a(this.opt.targetScore);this.score=c.length?c:b._buildScoreField.call(this)},_createStars:function(){for(var c=1;c<=this.opt.number;c++){var d,e=this.opt.score&&this.opt.score>=c?"starOn":"starOff",f=b._getHint.call(this,c);e=this.opt.path+this.opt[e],d="img"!==this.opt.starType?{"data-alt":c,class:e}:{src:e,alt:c},d.title=f,a("<"+this.opt.starType+" />",d).css("marginRight",c<this.opt.number&&this.opt.space?this.opt.spaceWidth+"px":"0").appendTo(this),this.opt.space}this.stars=this.self.children(this.opt.starType)},_error:function(b){a(this).text(b),a.error(b)},_fill:function(a){for(var c=0,d=1;d<=this.stars.length;d++){var e,f=this.stars.eq(d-1),g=b._turnOn.call(this,d,a);if(this.opt.iconRange&&this.opt.iconRange.length>c){var h=this.opt.iconRange[c];e=b._getIconRange.call(this,h,g),d<=h.range&&("img"===this.opt.starType?f.attr("src",e):f.attr("class",e)),d===h.range&&c++}else e=this.opt.path+this.opt[g?"starOn":"starOff"],"img"===this.opt.starType?f.attr("src",e):f.attr("class",e),g?f.css("color",this.opt.starColor):f.css("color","")}},_getIconRange:function(a,b){return this.opt.path+(b?a.on||this.opt.starOn:a.off||this.opt.starOff)},_getScoreByPosition:function(c,d){var e=a(d),f=parseInt(d.alt||e.data("alt"),10);if(this.opt.half){var g=b._getSize.call(this),h=parseFloat((c.pageX-e.offset().left)/g);f=this.opt.precision?f-1+h:f-1+(h>.5?1:.5)}return f},_getSize:function(){var a;return a="img"===this.opt.starType?this.stars[0].width:parseFloat(this.stars.eq(0).css("font-size")),a||b._error.call(this,"Could not be possible get the icon size!"),a},_turnOn:function(a,b){return this.opt.single?a===b:a<=b},_getHint:function(a){var b=this.opt.hints[a-1];return""===b?"":b||a},_lock:function(){var a=parseInt(this.score.val(),10),c=a?b._getHint.call(this,a):this.opt.noRatedMsg;this.style.cursor="",this.title=c,this.score.prop("readonly",!0),this.stars.prop("title",c),this.cancel&&this.cancel.hide(),this.self.data("readonly",!0)},_roundStars:function(a){var b=(a%1).toFixed(2);if(b>this.opt.round.down){var c="starOn";this.opt.halfShow&&b<this.opt.round.up?c="starHalf":b<this.opt.round.full&&(c="starOff");var d=this.stars[Math.ceil(a)-1];"img"===this.opt.starType?d.src=this.opt.path+this.opt[c]:d.style.className=this.opt[c]}},_target:function(c,d){if(this.opt.target){var e=a(this.opt.target);e.length||b._error.call(this,"Target selector invalid or missing!");var f=d&&"mouseover"===d.type;if(void 0===c)c=this.opt.targetText;else if(null===c)c=f?this.opt.cancelHint:this.opt.targetText;else{"hint"===this.opt.targetType?c=b._getHint.call(this,Math.ceil(c)):this.opt.precision&&(c=parseFloat(c).toFixed(1));var g=d&&"mousemove"===d.type;f||g||this.opt.targetKeep||(c=this.opt.targetText)}c&&(c=this.opt.targetFormat.toString().replace("{score}",c)),e.is(":input")?e.val(c):e.html(c)}},_unlock:function(){this.style.cursor="pointer",this.removeAttribute("title"),this.score.removeAttr("readonly"),this.self.data("readonly",!1);for(var a=0;a<this.opt.number;a++)this.stars[a].title=b._getHint.call(this,a+1);this.cancel&&this.cancel.css("display","")},cancel:function(c){return this.each(function(){var d=a(this);d.data("readonly")!==!0&&(b[c?"click":"score"].call(d,null),this.score.removeAttr("value"))})},click:function(c){return this.each(function(){a(this).data("readonly")!==!0&&(b._apply.call(this,c),this.opt.click&&this.opt.click.call(this,c,a.Event("click")),b._target.call(this,c))})},destroy:function(){return this.each(function(){var b=a(this),c=b.data("raw");c?b.off(".raty").empty().css({cursor:c.style.cursor}).removeData("readonly"):b.data("raw",b.clone()[0])})},getScore:function(){var a,b=[];return this.each(function(){a=this.score.val(),b.push(a?+a:void 0)}),b.length>1?b:b[0]},move:function(c){return this.each(function(){var d=parseInt(c,10),e=a(this).data("options"),f=(+c).toFixed(1).split(".")[1];d>=e.number&&(d=e.number-1,f=10);var g=b._getSize.call(this),h=g/10,i=a(this.stars[d]),j=i.offset().left+h*parseInt(f,10),k=a.Event("mousemove",{pageX:j});i.trigger(k)})},readOnly:function(c){return this.each(function(){var d=a(this);d.data("readonly")!==c&&(c?(d.off(".raty").children("img").off(".raty"),b._lock.call(this)):(b._binds.call(this),b._unlock.call(this)),d.data("readonly",c))})},reload:function(){return b.set.call(this,{})},score:function(){var c=a(this);return arguments.length?b.setScore.apply(c,arguments):b.getScore.call(c)},set:function(b){return this.each(function(){var c=a(this),d=c.data("options"),e=a.extend({},d,b);c.raty(e)})},setScore:function(c){return this.each(function(){a(this).data("readonly")!==!0&&(b._apply.call(this,c),b._target.call(this,c))})}};a.fn.raty=function(c){return b[c]?b[c].apply(this,Array.prototype.slice.call(arguments,1)):"object"!=typeof c&&c?void a.error("Method "+c+" does not exist!"):b.init.apply(this,arguments)},a.fn.raty.defaults={cancel:!1,cancelHint:"Cancel this rating!",cancelOff:"raty-cancel-off",cancelOn:"raty-cancel-on",cancelPlace:"left",click:void 0,half:!1,halfShow:!0,hints:["1"],iconRange:void 0,mouseout:void 0,mouseover:void 0,noRatedMsg:"Not rated yet!",number:5,numberMax:20,path:void 0,precision:!1,readOnly:!1,round:{down:.25,full:.6,up:.76},score:void 0,scoreName:"score",single:!1,space:!0,spaceWidth:3,starColor:"#ff00aa",starHalf:"star-half.png",starOff:"raty-dot-off",starOn:"raty-dot-on",starType:"img",target:void 0,targetFormat:"{score}",targetKeep:!1,targetScore:void 0,targetText:"",targetType:"hint"}}(jQuery),jQuery(function(a){a("body").on("click",".cf-toggle-group-buttons a",function(){var b=a(this),c=b.closest(".caldera-config-field"),d=c.find('[data-ref="'+b.attr("id")+'"]');c.find(".btn").removeClass(b.data("active")).addClass(b.data("default")),b.addClass(b.data("active")).removeClass(b.data("default")),d.prop("checked",!0).trigger("change")})});
1
+ function color_picker_init(){jQuery(".minicolor-picker").miniColors()}function toggle_button_init(a,b){var c=jQuery(b),d=c.find(".cf-toggle-group-radio:checked");d.length&&jQuery("#"+d.data("ref")).trigger("click")}jQuery&&function(a){a.extend(a.fn,{miniColors:function(b,c){var d=function(b,c,d){var e=s(b.val());e||(e="ffffff");var f=x(e),h=a('<span class="input-group-addon" style="background-color: #'+e+'" href="#"></span>');h.insertAfter(b),b.addClass("miniColors").data("original-maxlength",b.attr("maxlength")||null).data("original-autocomplete",b.attr("autocomplete")||null).data("letterCase",c.letterCase?c.letterCase:"uppercase").data("trigger",h).data("hsb",f).data("change",c.change?c.change:null).data("close",c.close?c.close:null).data("open",c.open?c.open:null).attr("maxlength",7).attr("autocomplete","off").val("#"+o(e,c.letterCase)).trigger("change"),c.readonly&&b.prop("readonly",!0),c.disabled&&g(b),h.on("click.miniColors",function(a){a.preventDefault(),""===b.val()&&b.val("#").trigger("change"),i(b)}),b.on("focus.miniColors",function(a){""===b.val()&&b.val("#").trigger("change"),i(b)}),b.on("blur.miniColors",function(a){var c=s(y(b.data("hsb")));b.val(c?"#"+o(c,b.data("letterCase")):"").trigger("change")}),b.on("keydown.miniColors",function(a){9===a.keyCode&&j(b)}),b.on("keyup.miniColors",function(a){n(b)}),b.on("paste.miniColors",function(a){setTimeout(function(){n(b)},5)})},e=function(b){j(),b=a(b),b.data("trigger").remove(),b.attr("autocomplete",b.data("original-autocomplete")).attr("maxlength",b.data("original-maxlength")).removeData().removeClass("miniColors").off(".miniColors"),a(document).off(".miniColors")},f=function(a){a.prop("disabled",!1).data("trigger").css("opacity",1)},g=function(a){j(a),a.prop("disabled",!0).data("trigger").css("opacity",.5)},i=function(b){if(b.prop("disabled"))return!1;j();var c=a('<div class="miniColors-selector"></div>');c.append('<div class="miniColors-colors" style="background-color: #FFF;"><div class="miniColors-colorPicker"><div class="miniColors-colorPicker-inner"></div></div>').append('<div class="miniColors-hues"><div class="miniColors-huePicker"></div></div>').css("display","none").addClass(b.attr("class")).removeClass("form-control");var d=b.data("hsb");c.find(".miniColors-colors").css("backgroundColor","#"+y({h:d.h,s:100,b:100}));var e=b.data("colorPosition");e||(e=p(d)),c.find(".miniColors-colorPicker").css("top",e.y+"px").css("left",e.x+"px");var f=b.data("huePosition");f||(f=q(d)),c.find(".miniColors-huePicker").css("top",f.y+"px"),b.data("selector",c).data("huePicker",c.find(".miniColors-huePicker")).data("colorPicker",c.find(".miniColors-colorPicker")).data("mousebutton",0),a("BODY").append(c);var g=b.data("trigger"),h=!b.is(":visible"),i=h?g.offset().top+g.outerHeight():b.offset().top+b.outerHeight(),m=h?g.offset().left:b.offset().left,n=c.outerWidth(),o=c.outerHeight(),r=g.outerWidth(),s=g.outerHeight(),u=a(window).height(),v=a(window).width(),w=a(window).scrollTop(),x=a(window).scrollLeft();i+o>u+w&&(i=i-o-s),m+n>v+x&&(m=m-n+r),c.css({top:i,left:m}).fadeIn(100),c.on("selectstart",function(){return!1}),(!a.browser.msie||a.browser.msie&&a.browser.version>=9)&&a(window).on("resize.miniColors",function(a){j(b)}),a(document).on("mousedown.miniColors touchstart.miniColors",function(c){b.data("mousebutton",1);var d=a(c.target).parents().andSelf();if(d.hasClass("miniColors-colors")&&(c.preventDefault(),b.data("moving","colors"),k(b,c)),d.hasClass("miniColors-hues")&&(c.preventDefault(),b.data("moving","hues"),l(b,c)),d.hasClass("miniColors-selector"))return void c.preventDefault();d.hasClass("miniColors")||j(b)}),a(document).on("mouseup.miniColors touchend.miniColors",function(a){a.preventDefault(),b.data("mousebutton",0).removeData("moving")}).on("mousemove.miniColors touchmove.miniColors",function(a){a.preventDefault(),1===b.data("mousebutton")&&("colors"===b.data("moving")&&k(b,a),"hues"===b.data("moving")&&l(b,a))}),b.data("open")&&b.data("open").call(b.get(0),"#"+y(d),t(d))},j=function(b){b||(b=a(".miniColors")),b.each(function(){var c=a(this).data("selector");a(this).removeData("selector"),a(c).fadeOut(100,function(){if(b.data("close")){var c=b.data("hsb"),d=y(c);b.data("close").call(b.get(0),"#"+d,t(c))}a(this).remove()})}),a(document).off(".miniColors")},k=function(a,b){var c=a.data("colorPicker");c.hide();var d={x:b.pageX,y:b.pageY};b.originalEvent.changedTouches&&(d.x=b.originalEvent.changedTouches[0].pageX,d.y=b.originalEvent.changedTouches[0].pageY),d.x=d.x-a.data("selector").find(".miniColors-colors").offset().left-5,d.y=d.y-a.data("selector").find(".miniColors-colors").offset().top-5,d.x<=-5&&(d.x=-5),d.x>=144&&(d.x=144),d.y<=-5&&(d.y=-5),d.y>=144&&(d.y=144),a.data("colorPosition",d),c.css("left",d.x).css("top",d.y).show();var e=Math.round(.67*(d.x+5));e<0&&(e=0),e>100&&(e=100);var f=100-Math.round(.67*(d.y+5));f<0&&(f=0),f>100&&(f=100);var g=a.data("hsb");g.s=e,g.b=f,m(a,g,!0)},l=function(a,b){var c=a.data("huePicker");c.hide();var d={y:b.pageY};b.originalEvent.changedTouches&&(d.y=b.originalEvent.changedTouches[0].pageY),d.y=d.y-a.data("selector").find(".miniColors-colors").offset().top-1,d.y<=-1&&(d.y=-1),d.y>=149&&(d.y=149),a.data("huePosition",d),c.css("top",d.y).show();var e=Math.round(2.4*(150-d.y-1));e<0&&(e=0),e>360&&(e=360);var f=a.data("hsb");f.h=e,m(a,f,!0)},m=function(a,b,c){a.data("hsb",b);var d=y(b);if(c&&a.val("#"+o(d,a.data("letterCase"))).trigger("change"),a.data("trigger").css("backgroundColor","#"+d),a.data("selector")&&a.data("selector").find(".miniColors-colors").css("backgroundColor","#"+y({h:b.h,s:100,b:100})),a.data("change")){if(d===a.data("lastChange"))return;a.data("change").call(a.get(0),"#"+d,t(b)),a.data("lastChange",d)}},n=function(b){b.val("#"+r(b.val())).trigger("change");var c=s(b.val());if(!c)return!1;var d=x(c),e=b.data("hsb");if(d.h===e.h&&d.s===e.s&&d.b===e.b)return!0;var f=p(d);a(b.data("colorPicker")).css("top",f.y+"px").css("left",f.x+"px"),b.data("colorPosition",f);var g=q(d);return a(b.data("huePicker")).css("top",g.y+"px"),b.data("huePosition",g),m(b,d),!0},o=function(a,b){return"lowercase"===b?a.toLowerCase():"uppercase"===b?a.toUpperCase():a},p=function(a){var b=Math.ceil(a.s/.67);b<0&&(b=0),b>150&&(b=150);var c=150-Math.ceil(a.b/.67);return c<0&&(c=0),c>150&&(c=150),{x:b-5,y:c-5}},q=function(a){var b=150-a.h/2.4;return b<0&&(h=0),b>150&&(h=150),{y:b-1}},r=function(a){return a.replace(/[^A-F0-9]/gi,"")},s=function(a){return(a=r(a))?(3===a.length&&(a=a[0]+a[0]+a[1]+a[1]+a[2]+a[2]),6===a.length?a:null):null},t=function(a){var b={},c=Math.round(a.h),d=Math.round(255*a.s/100),e=Math.round(255*a.b/100);if(0===d)b.r=b.g=b.b=e;else{var f=e,g=(255-d)*e/255,h=c%60*(f-g)/60;360===c&&(c=0),c<60?(b.r=f,b.b=g,b.g=g+h):c<120?(b.g=f,b.b=g,b.r=f-h):c<180?(b.g=f,b.r=g,b.b=g+h):c<240?(b.b=f,b.r=g,b.g=f-h):c<300?(b.b=f,b.g=g,b.r=g+h):c<360?(b.r=f,b.g=g,b.b=f-h):(b.r=0,b.g=0,b.b=0)}return{r:Math.round(b.r),g:Math.round(b.g),b:Math.round(b.b)}},u=function(b){var c=[b.r.toString(16),b.g.toString(16),b.b.toString(16)];return a.each(c,function(a,b){1===b.length&&(c[a]="0"+b)}),c.join("")},v=function(a){return a=parseInt(a.indexOf("#")>-1?a.substring(1):a,16),{r:a>>16,g:(65280&a)>>8,b:255&a}},w=function(a){var b={h:0,s:0,b:0},c=Math.min(a.r,a.g,a.b),d=Math.max(a.r,a.g,a.b),e=d-c;return b.b=d,b.s=0!==d?255*e/d:0,0!==b.s?a.r===d?b.h=(a.g-a.b)/e:a.g===d?b.h=2+(a.b-a.r)/e:b.h=4+(a.r-a.g)/e:b.h=-1,b.h*=60,b.h<0&&(b.h+=360),b.s*=100/255,b.b*=100/255,b},x=function(a){var b=w(v(a));return 0===b.s&&(b.h=360),b},y=function(a){return u(t(a))};switch(b){case"readonly":return a(this).each(function(){a(this).hasClass("miniColors")&&a(this).prop("readonly",c)}),a(this);case"disabled":return a(this).each(function(){a(this).hasClass("miniColors")&&(c?g(a(this)):f(a(this)))}),a(this);case"value":if(void 0===c){if(!a(this).hasClass("miniColors"))return;var z=a(this),A=s(z.val());return A?"#"+o(A,z.data("letterCase")):null}return a(this).each(function(){a(this).hasClass("miniColors")&&(a(this).val(c).trigger("change"),n(a(this)))}),a(this);case"destroy":return a(this).each(function(){a(this).hasClass("miniColors")&&e(a(this))}),a(this);default:return b||(b={}),a(this).each(function(){"input"===a(this)[0].tagName.toLowerCase()&&(a(this).data("trigger")||d(a(this),b))}),a(this)}}})}(jQuery),document.addEventListener("load",color_picker_init,!1),jQuery(document).ajaxComplete(function(){color_picker_init()}),function(a,b){function c(){return new Date(Date.UTC.apply(Date,arguments))}function d(){var a=new Date;return c(a.getFullYear(),a.getMonth(),a.getDate())}function e(a){return function(){return this[a].apply(this,arguments)}}function f(b,c){function d(a,b){return b.toLowerCase()}var e,f=a(b).data(),g={},h=new RegExp("^"+c.toLowerCase()+"([A-Z])");c=new RegExp("^"+c.toLowerCase());for(var i in f)c.test(i)&&(e=i.replace(h,d),g[e]=f[i]);return g}function g(b){var c={};if(o[b]||(b=b.split("-")[0],o[b])){var d=o[b];return a.each(n,function(a,b){b in d&&(c[b]=d[b])}),c}}var h=a(window),i=function(){var b={get:function(a){return this.slice(a)[0]},contains:function(a){for(var b=a&&a.valueOf(),c=0,d=this.length;c<d;c++)if(this[c].valueOf()===b)return c;return-1},remove:function(a){this.splice(a,1)},replace:function(b){b&&(a.isArray(b)||(b=[b]),this.clear(),this.push.apply(this,b))},clear:function(){this.splice(0)},copy:function(){var a=new i;return a.replace(this),a}};return function(){var c=[];return c.push.apply(c,arguments),a.extend(c,b),c}}(),j=function(b,c){this.dates=new i,this.viewDate=d(),this.focusDate=null,this._process_options(c),this.element=a(b),this.isInline=!1,this.isInput=this.element.is("input"),this.component=!!this.element.is(".date")&&this.element.find(".add-on, .input-group-addon, .btn"),this.hasInput=this.component&&this.element.find("input").length,this.component&&0===this.component.length&&(this.component=!1),this.picker=a(p.template),this._buildEvents(),this._attachEvents(),this.isInline?this.picker.addClass("cfdatepicker-inline").appendTo(this.element):this.picker.addClass("cfdatepicker-dropdown dropdown-menu"),this.o.rtl&&this.picker.addClass("cfdatepicker-rtl"),this.viewMode=this.o.startView,this.o.calendarWeeks&&this.picker.find("tfoot th.today").attr("colspan",function(a,b){return parseInt(b)+1}),this._allow_update=!1,this.setStartDate(this._o.startDate),this.setEndDate(this._o.endDate),this.setDaysOfWeekDisabled(this.o.daysOfWeekDisabled),this.fillDow(),this.fillMonths(),this._allow_update=!0,this.update(),this.showMode(),this.isInline&&this.show()};j.prototype={constructor:j,_process_options:function(b){this._o=a.extend({},this._o,b);var c=this.o=a.extend({},this._o),d=c.language;switch(o[d]||(d=d.split("-")[0],o[d]||(d=m.language)),c.language=d,c.startView){case 2:case"decade":c.startView=2;break;case 1:case"year":c.startView=1;break;default:c.startView=0}switch(c.minViewMode){case 1:case"months":c.minViewMode=1;break;case 2:case"years":c.minViewMode=2;break;default:c.minViewMode=0}c.startView=Math.max(c.startView,c.minViewMode),!0!==c.multidate&&(c.multidate=Number(c.multidate)||!1,!1!==c.multidate?c.multidate=Math.max(0,c.multidate):c.multidate=1),c.multidateSeparator=String(c.multidateSeparator),c.weekStart%=7,c.weekEnd=(c.weekStart+6)%7;var e=p.parseFormat(c.format);c.startDate!==-1/0&&(c.startDate?c.startDate instanceof Date?c.startDate=this._local_to_utc(this._zero_time(c.startDate)):c.startDate=p.parseDate(c.startDate,e,c.language):c.startDate=-1/0),c.endDate!==1/0&&(c.endDate?c.endDate instanceof Date?c.endDate=this._local_to_utc(this._zero_time(c.endDate)):c.endDate=p.parseDate(c.endDate,e,c.language):c.endDate=1/0),c.daysOfWeekDisabled=c.daysOfWeekDisabled||[],a.isArray(c.daysOfWeekDisabled)||(c.daysOfWeekDisabled=c.daysOfWeekDisabled.split(/[,\s]*/)),c.daysOfWeekDisabled=a.map(c.daysOfWeekDisabled,function(a){return parseInt(a,10)});var f=String(c.orientation).toLowerCase().split(/\s+/g),g=c.orientation.toLowerCase();if(f=a.grep(f,function(a){return/^auto|left|right|top|bottom$/.test(a)}),c.orientation={x:"auto",y:"auto"},g&&"auto"!==g)if(1===f.length)switch(f[0]){case"top":case"bottom":c.orientation.y=f[0];break;case"left":case"right":c.orientation.x=f[0]}else g=a.grep(f,function(a){return/^left|right$/.test(a)}),c.orientation.x=g[0]||"auto",g=a.grep(f,function(a){return/^top|bottom$/.test(a)}),c.orientation.y=g[0]||"auto";else;},_events:[],_secondaryEvents:[],_applyEvents:function(a){for(var b,c,d,e=0;e<a.length;e++)b=a[e][0],2===a[e].length?(c=void 0,d=a[e][1]):3===a[e].length&&(c=a[e][1],d=a[e][2]),b.on(d,c)},_unapplyEvents:function(a){for(var b,c,d,e=0;e<a.length;e++)b=a[e][0],2===a[e].length?(d=void 0,c=a[e][1]):3===a[e].length&&(d=a[e][1],c=a[e][2]),b.off(c,d)},_buildEvents:function(){this.isInput?this._events=[[this.element,{focus:a.proxy(this.show,this),keyup:a.proxy(function(b){-1===a.inArray(b.keyCode,[27,37,39,38,40,32,13,9])&&this.update()},this),keydown:a.proxy(this.keydown,this)}]]:this.component&&this.hasInput?this._events=[[this.element.find("input"),{focus:a.proxy(this.show,this),keyup:a.proxy(function(b){-1===a.inArray(b.keyCode,[27,37,39,38,40,32,13,9])&&this.update()},this),keydown:a.proxy(this.keydown,this)}],[this.component,{click:a.proxy(this.show,this)}]]:this.element.is("div")?this.isInline=!0:this._events=[[this.element,{click:a.proxy(this.show,this)}]],this._events.push([this.element,"*",{blur:a.proxy(function(a){this._focused_from=a.target},this)}],[this.element,{blur:a.proxy(function(a){this._focused_from=a.target},this)}]),this._secondaryEvents=[[this.picker,{click:a.proxy(this.click,this)}],[a(window),{resize:a.proxy(this.place,this)}],[a(document),{"mousedown touchstart":a.proxy(function(a){this.element.is(a.target)||this.element.find(a.target).length||this.picker.is(a.target)||this.picker.find(a.target).length||this.hide()},this)}]]},_attachEvents:function(){this._detachEvents(),this._applyEvents(this._events)},_detachEvents:function(){this._unapplyEvents(this._events)},_attachSecondaryEvents:function(){this._detachSecondaryEvents(),this._applyEvents(this._secondaryEvents)},_detachSecondaryEvents:function(){this._unapplyEvents(this._secondaryEvents)},_trigger:function(b,c){var d=c||this.dates.get(-1),e=this._utc_to_local(d);this.element.trigger({type:b,date:e,dates:a.map(this.dates,this._utc_to_local),format:a.proxy(function(a,b){0===arguments.length?(a=this.dates.length-1,b=this.o.format):"string"==typeof a&&(b=a,a=this.dates.length-1),b=b||this.o.format;var c=this.dates.get(a);return p.formatDate(c,b,this.o.language)},this)})},show:function(){this.isInline||this.picker.appendTo("body"),this.picker.show(),this.place(),this._attachSecondaryEvents(),this._trigger("show")},hide:function(){this.isInline||this.picker.is(":visible")&&(this.focusDate=null,this.picker.hide().detach(),this._detachSecondaryEvents(),this.viewMode=this.o.startView,this.showMode(),this.o.forceParse&&(this.isInput&&this.element.val()||this.hasInput&&this.element.find("input").val())&&this.setValue(),this._trigger("hide"))},remove:function(){this.hide(),this._detachEvents(),this._detachSecondaryEvents(),this.picker.remove(),delete this.element.data().cfdatepicker,this.isInput||delete this.element.data().date},_utc_to_local:function(a){return a&&new Date(a.getTime()+6e4*a.getTimezoneOffset())},_local_to_utc:function(a){return a&&new Date(a.getTime()-6e4*a.getTimezoneOffset())},_zero_time:function(a){return a&&new Date(a.getFullYear(),a.getMonth(),a.getDate())},_zero_utc_time:function(a){return a&&new Date(Date.UTC(a.getUTCFullYear(),a.getUTCMonth(),a.getUTCDate()))},getDates:function(){return a.map(this.dates,this._utc_to_local)},getUTCDates:function(){return a.map(this.dates,function(a){return new Date(a)})},getDate:function(){return this._utc_to_local(this.getUTCDate())},getUTCDate:function(){return new Date(this.dates.get(-1))},setDates:function(){var b=a.isArray(arguments[0])?arguments[0]:arguments;this.update.apply(this,b),this._trigger("changeDate"),this.setValue()},setUTCDates:function(){var b=a.isArray(arguments[0])?arguments[0]:arguments;this.update.apply(this,a.map(b,this._utc_to_local)),this._trigger("changeDate"),this.setValue()},setDate:e("setDates"),setUTCDate:e("setUTCDates"),setValue:function(){var a=this.getFormattedDate();this.isInput?this.element.val(a).change():this.component&&this.element.find("input").val(a).change()},getFormattedDate:function(b){void 0===b&&(b=this.o.format);var c=this.o.language;return a.map(this.dates,function(a){return p.formatDate(a,b,c)}).join(this.o.multidateSeparator)},setStartDate:function(a){this._process_options({startDate:a}),this.update(),this.updateNavArrows()},setEndDate:function(a){this._process_options({endDate:a}),this.update(),this.updateNavArrows()},setDaysOfWeekDisabled:function(a){this._process_options({daysOfWeekDisabled:a}),this.update(),this.updateNavArrows()},place:function(){if(!this.isInline){var b,c=this.picker.outerWidth(),d=this.picker.outerHeight(),e=h.width(),f=h.height(),g=h.scrollTop(),i=jQuery(this.element).data("form-id"),j=document.getElementById("modal-"+i+"-content");b=null!==j?1e4:parseInt(this.element.parents().filter(function(){return"auto"!==a(this).css("z-index")}).first().css("z-index"))+10;var k=this.component?this.component.parent().offset():this.element.offset(),l=this.component?this.component.outerHeight(!0):this.element.outerHeight(!1),m=this.component?this.component.outerWidth(!0):this.element.outerWidth(!1),n=k.left,o=k.top;this.picker.removeClass("cfdatepicker-orient-top cfdatepicker-orient-bottom cfdatepicker-orient-right cfdatepicker-orient-left"),"auto"!==this.o.orientation.x?(this.picker.addClass("cfdatepicker-orient-"+this.o.orientation.x),"right"===this.o.orientation.x&&(n-=c-m)):(this.picker.addClass("cfdatepicker-orient-left"),k.left<0?n-=k.left-10:k.left+c>e&&(n=e-c-10));var p,q,r=this.o.orientation.y;"auto"===r&&(p=-g+k.top-d,q=g+f-(k.top+l+d),r=Math.max(p,q)===q?"top":"bottom"),this.picker.addClass("cfdatepicker-orient-"+r),"top"===r?o+=l:o-=d+parseInt(this.picker.css("padding-top")),this.picker.css({top:o,left:n,zIndex:b})}},_allow_update:!0,update:function(){if(this._allow_update){var b=this.dates.copy(),c=[],d=!1;arguments.length?(a.each(arguments,a.proxy(function(a,b){b instanceof Date&&(b=this._local_to_utc(b)),c.push(b)},this)),d=!0):(c=this.isInput?this.element.val():this.element.data("date")||this.element.find("input").val(),c=c&&this.o.multidate?c.split(this.o.multidateSeparator):[c],delete this.element.data().date),c=a.map(c,a.proxy(function(a){return p.parseDate(a,this.o.format,this.o.language)},this)),c=a.grep(c,a.proxy(function(a){return a<this.o.startDate||a>this.o.endDate||!a},this),!0),this.dates.replace(c),this.dates.length?this.viewDate=new Date(this.dates.get(-1)):this.viewDate<this.o.startDate?this.viewDate=new Date(this.o.startDate):this.viewDate>this.o.endDate&&(this.viewDate=new Date(this.o.endDate)),d?this.setValue():c.length&&String(b)!==String(this.dates)&&this._trigger("changeDate"),!this.dates.length&&b.length&&this._trigger("clearDate"),this.fill()}},fillDow:function(){var a=this.o.weekStart,b="<tr>";if(this.o.calendarWeeks){var c='<th class="cw">&nbsp;</th>';b+=c,this.picker.find(".cfdatepicker-days thead tr:first-child").prepend(c)}for(;a<this.o.weekStart+7;)b+='<th class="dow">'+o[this.o.language].daysMin[a++%7]+"</th>";b+="</tr>",this.picker.find(".cfdatepicker-days thead").append(b)},fillMonths:function(){for(var a="",b=0;b<12;)a+='<span class="month">'+o[this.o.language].monthsShort[b++]+"</span>";this.picker.find(".cfdatepicker-months td").html(a)},setRange:function(b){b&&b.length?this.range=a.map(b,function(a){return a.valueOf()}):delete this.range,this.fill()},getClassNames:function(b){var c=[],d=this.viewDate.getUTCFullYear(),e=this.viewDate.getUTCMonth(),f=new Date;return b.getUTCFullYear()<d||b.getUTCFullYear()===d&&b.getUTCMonth()<e?c.push("old"):(b.getUTCFullYear()>d||b.getUTCFullYear()===d&&b.getUTCMonth()>e)&&c.push("new"),this.focusDate&&b.valueOf()===this.focusDate.valueOf()&&c.push("focused"),this.o.todayHighlight&&b.getUTCFullYear()===f.getFullYear()&&b.getUTCMonth()===f.getMonth()&&b.getUTCDate()===f.getDate()&&c.push("today"),-1!==this.dates.contains(b)&&c.push("active"),(b.valueOf()<this.o.startDate||b.valueOf()>this.o.endDate||-1!==a.inArray(b.getUTCDay(),this.o.daysOfWeekDisabled))&&c.push("disabled"),this.range&&(b>this.range[0]&&b<this.range[this.range.length-1]&&c.push("range"),-1!==a.inArray(b.valueOf(),this.range)&&c.push("selected")),c},fill:function(){var b,d=new Date(this.viewDate),e=d.getUTCFullYear(),f=d.getUTCMonth(),g=this.o.startDate!==-1/0?this.o.startDate.getUTCFullYear():-1/0,h=this.o.startDate!==-1/0?this.o.startDate.getUTCMonth():-1/0,i=this.o.endDate!==1/0?this.o.endDate.getUTCFullYear():1/0,j=this.o.endDate!==1/0?this.o.endDate.getUTCMonth():1/0,k=o[this.o.language].today||o.en.today||"",l=o[this.o.language].clear||o.en.clear||"";this.picker.find(".cfdatepicker-days thead th.cfdatepicker-switch").text(o[this.o.language].months[f]+" "+e),this.picker.find("tfoot th.today").text(k).toggle(!1!==this.o.todayBtn),this.picker.find("tfoot th.clear").text(l).toggle(!1!==this.o.clearBtn),this.updateNavArrows(),this.fillMonths();var m=c(e,f-1,28),n=p.getDaysInMonth(m.getUTCFullYear(),m.getUTCMonth());m.setUTCDate(n),m.setUTCDate(n-(m.getUTCDay()-this.o.weekStart+7)%7);var q=new Date(m);q.setUTCDate(q.getUTCDate()+42),q=q.valueOf();for(var r,s=[];m.valueOf()<q;){if(m.getUTCDay()===this.o.weekStart&&(s.push("<tr>"),this.o.calendarWeeks)){var t=new Date(+m+(this.o.weekStart-m.getUTCDay()-7)%7*864e5),u=new Date(Number(t)+(11-t.getUTCDay())%7*864e5),v=new Date(Number(v=c(u.getUTCFullYear(),0,1))+(11-v.getUTCDay())%7*864e5),w=(u-v)/864e5/7+1;s.push('<td class="cw">'+w+"</td>")}if(r=this.getClassNames(m),r.push("day"),this.o.beforeShowDay!==a.noop){var x=this.o.beforeShowDay(this._utc_to_local(m));void 0===x?x={}:"boolean"==typeof x?x={enabled:x}:"string"==typeof x&&(x={classes:x}),!1===x.enabled&&r.push("disabled"),x.classes&&(r=r.concat(x.classes.split(/\s+/))),x.tooltip&&(b=x.tooltip)}r=a.unique(r),s.push('<td class="'+r.join(" ")+'"'+(b?' title="'+b+'"':"")+">"+m.getUTCDate()+"</td>"),m.getUTCDay()===this.o.weekEnd&&s.push("</tr>"),m.setUTCDate(m.getUTCDate()+1)}this.picker.find(".cfdatepicker-days tbody").empty().append(s.join(""));var y=this.picker.find(".cfdatepicker-months").find("th:eq(1)").text(e).end().find("span").removeClass("active");a.each(this.dates,function(a,b){b.getUTCFullYear()===e&&y.eq(b.getUTCMonth()).addClass("active")}),(e<g||e>i)&&y.addClass("disabled"),e===g&&y.slice(0,h).addClass("disabled"),e===i&&y.slice(j+1).addClass("disabled"),s="",e=10*parseInt(e/10,10);var z=this.picker.find(".cfdatepicker-years").find("th:eq(1)").text(e+"-"+(e+9)).end().find("td");e-=1;for(var A,B=a.map(this.dates,function(a){return a.getUTCFullYear()}),C=-1;C<11;C++)A=["year"],-1===C?A.push("old"):10===C&&A.push("new"),-1!==a.inArray(e,B)&&A.push("active"),(e<g||e>i)&&A.push("disabled"),s+='<span class="'+A.join(" ")+'">'+e+"</span>",e+=1;z.html(s)},updateNavArrows:function(){if(this._allow_update){var a=new Date(this.viewDate),b=a.getUTCFullYear(),c=a.getUTCMonth();switch(this.viewMode){case 0:this.o.startDate!==-1/0&&b<=this.o.startDate.getUTCFullYear()&&c<=this.o.startDate.getUTCMonth()?this.picker.find(".prev").css({visibility:"hidden"}):this.picker.find(".prev").css({visibility:"visible"}),this.o.endDate!==1/0&&b>=this.o.endDate.getUTCFullYear()&&c>=this.o.endDate.getUTCMonth()?this.picker.find(".next").css({visibility:"hidden"}):this.picker.find(".next").css({visibility:"visible"});break;case 1:case 2:this.o.startDate!==-1/0&&b<=this.o.startDate.getUTCFullYear()?this.picker.find(".prev").css({visibility:"hidden"}):this.picker.find(".prev").css({visibility:"visible"}),this.o.endDate!==1/0&&b>=this.o.endDate.getUTCFullYear()?this.picker.find(".next").css({visibility:"hidden"}):this.picker.find(".next").css({visibility:"visible"})}}},click:function(b){b.preventDefault();var d,e,f,g=a(b.target).closest("span, td, th");if(1===g.length)switch(g[0].nodeName.toLowerCase()){case"th":switch(g[0].className){case"cfdatepicker-switch":this.showMode(1);break;case"prev":case"next":var h=p.modes[this.viewMode].navStep*("prev"===g[0].className?-1:1);switch(this.viewMode){case 0:this.viewDate=this.moveMonth(this.viewDate,h),this._trigger("changeMonth",this.viewDate);break;case 1:case 2:this.viewDate=this.moveYear(this.viewDate,h),1===this.viewMode&&this._trigger("changeYear",this.viewDate)}this.fill();break;case"today":var i=new Date;i=c(i.getFullYear(),i.getMonth(),i.getDate(),0,0,0),this.showMode(-2);var j="linked"===this.o.todayBtn?null:"view";this._setDate(i,j);break;case"clear":var k;this.isInput?k=this.element:this.component&&(k=this.element.find("input")),k&&k.val("").change(),this.update(),this._trigger("changeDate"),this.o.autoclose&&this.hide()}break;case"span":g.is(".disabled")||(this.viewDate.setUTCDate(1),g.is(".month")?(f=1,e=g.parent().find("span").index(g),d=this.viewDate.getUTCFullYear(),this.viewDate.setUTCMonth(e),this._trigger("changeMonth",this.viewDate),1===this.o.minViewMode&&this._setDate(c(d,e,f))):(f=1,e=0,d=parseInt(g.text(),10)||0,this.viewDate.setUTCFullYear(d),this._trigger("changeYear",this.viewDate),2===this.o.minViewMode&&this._setDate(c(d,e,f))),this.showMode(-1),this.fill());break;case"td":g.is(".day")&&!g.is(".disabled")&&(f=parseInt(g.text(),10)||1,d=this.viewDate.getUTCFullYear(),e=this.viewDate.getUTCMonth(),g.is(".old")?0===e?(e=11,d-=1):e-=1:g.is(".new")&&(11===e?(e=0,d+=1):e+=1),this._setDate(c(d,e,f)))}this.picker.is(":visible")&&this._focused_from&&a(this._focused_from).focus(),delete this._focused_from},_toggle_multidate:function(a){var b=this.dates.contains(a);if(a?-1!==b?this.dates.remove(b):this.dates.push(a):this.dates.clear(),"number"==typeof this.o.multidate)for(;this.dates.length>this.o.multidate;)this.dates.remove(0)},_setDate:function(a,b){b&&"date"!==b||this._toggle_multidate(a&&new Date(a)),b&&"view"!==b||(this.viewDate=a&&new Date(a)),this.fill(),this.setValue(),this._trigger("changeDate");var c;this.isInput?c=this.element:this.component&&(c=this.element.find("input")),c&&c.change(),!this.o.autoclose||b&&"date"!==b||this.hide()},moveMonth:function(a,b){if(a){if(!b)return a;var c,d,e=new Date(a.valueOf()),f=e.getUTCDate(),g=e.getUTCMonth(),h=Math.abs(b);if(b=b>0?1:-1,1===h)d=-1===b?function(){return e.getUTCMonth()===g}:function(){return e.getUTCMonth()!==c},c=g+b,e.setUTCMonth(c),(c<0||c>11)&&(c=(c+12)%12);else{for(var i=0;i<h;i++)e=this.moveMonth(e,b);c=e.getUTCMonth(),e.setUTCDate(f),d=function(){return c!==e.getUTCMonth()}}for(;d();)e.setUTCDate(--f),e.setUTCMonth(c);return e}},moveYear:function(a,b){return this.moveMonth(a,12*b)},dateWithinRange:function(a){return a>=this.o.startDate&&a<=this.o.endDate},keydown:function(a){if(this.picker.is(":not(:visible)"))return void(27===a.keyCode&&this.show());var b,c,e,f=!1,g=this.focusDate||this.viewDate;switch(a.keyCode){case 27:this.focusDate?(this.focusDate=null,this.viewDate=this.dates.get(-1)||this.viewDate,this.fill()):this.hide(),a.preventDefault();break;case 37:case 39:if(!this.o.keyboardNavigation)break;b=37===a.keyCode?-1:1,a.ctrlKey?(c=this.moveYear(this.dates.get(-1)||d(),b),e=this.moveYear(g,b),this._trigger("changeYear",this.viewDate)):a.shiftKey?(c=this.moveMonth(this.dates.get(-1)||d(),b),e=this.moveMonth(g,b),this._trigger("changeMonth",this.viewDate)):(c=new Date(this.dates.get(-1)||d()),c.setUTCDate(c.getUTCDate()+b),e=new Date(g),e.setUTCDate(g.getUTCDate()+b)),this.dateWithinRange(c)&&(this.focusDate=this.viewDate=e,this.setValue(),this.fill(),a.preventDefault());break;case 38:case 40:if(!this.o.keyboardNavigation)break;b=38===a.keyCode?-1:1,a.ctrlKey?(c=this.moveYear(this.dates.get(-1)||d(),b),e=this.moveYear(g,b),this._trigger("changeYear",this.viewDate)):a.shiftKey?(c=this.moveMonth(this.dates.get(-1)||d(),b),e=this.moveMonth(g,b),this._trigger("changeMonth",this.viewDate)):(c=new Date(this.dates.get(-1)||d()),c.setUTCDate(c.getUTCDate()+7*b),e=new Date(g),e.setUTCDate(g.getUTCDate()+7*b)),this.dateWithinRange(c)&&(this.focusDate=this.viewDate=e,this.setValue(),this.fill(),a.preventDefault());break;case 32:break;case 13:g=this.focusDate||this.dates.get(-1)||this.viewDate,this._toggle_multidate(g),f=!0,this.focusDate=null,this.viewDate=this.dates.get(-1)||this.viewDate,this.setValue(),this.fill(),this.picker.is(":visible")&&(a.preventDefault(),this.o.autoclose&&this.hide());break;case 9:this.focusDate=null,this.viewDate=this.dates.get(-1)||this.viewDate,this.fill(),this.hide()}if(f){this.dates.length?this._trigger("changeDate"):this._trigger("clearDate");var h;this.isInput?h=this.element:this.component&&(h=this.element.find("input")),h&&h.change()}},showMode:function(a){a&&(this.viewMode=Math.max(this.o.minViewMode,Math.min(2,this.viewMode+a))),this.picker.find(">div").hide().filter(".cfdatepicker-"+p.modes[this.viewMode].clsName).css("display","block"),this.updateNavArrows()}};var k=function(b,c){this.element=a(b),this.inputs=a.map(c.inputs,function(a){return a.jquery?a[0]:a}),delete c.inputs,a(this.inputs).cfdatepicker(c).bind("changeDate",a.proxy(this.dateUpdated,this)),this.pickers=a.map(this.inputs,function(b){return a(b).data("cfdatepicker")}),this.updateDates()};k.prototype={updateDates:function(){this.dates=a.map(this.pickers,function(a){return a.getUTCDate()}),this.updateRanges()},updateRanges:function(){var b=a.map(this.dates,function(a){return a.valueOf()});a.each(this.pickers,function(a,c){c.setRange(b)})},dateUpdated:function(b){if(!this.updating){this.updating=!0;var c=a(b.target).data("cfdatepicker"),d=c.getUTCDate(),e=a.inArray(b.target,this.inputs),f=this.inputs.length;if(-1!==e){if(a.each(this.pickers,function(a,b){b.getUTCDate()||b.setUTCDate(d)}),d<this.dates[e])for(;e>=0&&d<this.dates[e];)this.pickers[e--].setUTCDate(d);else if(d>this.dates[e])for(;e<f&&d>this.dates[e];)this.pickers[e++].setUTCDate(d);this.updateDates(),delete this.updating}}},remove:function(){a.map(this.pickers,function(a){a.remove()}),delete this.element.data().cfdatepicker}};var l=a.fn.cfdatepicker;a.fn.cfdatepicker=function(b){var c=Array.apply(null,arguments);c.shift();var d;return this.each(function(){var e=a(this),h=e.data("cfdatepicker"),i="object"==typeof b&&b;if(!h){var l=f(this,"date"),n=a.extend({},m,l,i),o=g(n.language),p=a.extend({},m,o,l,i);if(e.is(".input-daterange")||p.inputs){var q={inputs:p.inputs||e.find("input").toArray()};e.data("cfdatepicker",h=new k(this,a.extend(p,q)))}else e.data("cfdatepicker",h=new j(this,p))}if("string"==typeof b&&"function"==typeof h[b]&&void 0!==(d=h[b].apply(h,c)))return!1}),void 0!==d?d:this};var m=a.fn.cfdatepicker.defaults={autoclose:!1,beforeShowDay:a.noop,calendarWeeks:!1,clearBtn:!1,daysOfWeekDisabled:[],endDate:1/0,forceParse:!0,format:"mm/dd/yyyy",keyboardNavigation:!0,language:"en",minViewMode:0,multidate:!1,multidateSeparator:",",orientation:"auto",rtl:!1,startDate:-1/0,startView:0,todayBtn:!1,todayHighlight:!1,weekStart:0},n=a.fn.cfdatepicker.locale_opts=["format","rtl","weekStart"];a.fn.cfdatepicker.Constructor=j;var o=a.fn.cfdatepicker.dates={en:{days:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday","Sunday"],daysShort:["Sun","Mon","Tue","Wed","Thu","Fri","Sat","Sun"],daysMin:["Su","Mo","Tu","We","Th","Fr","Sa","Su"],months:["January","February","March","April","May","June","July","August","September","October","November","December"],monthsShort:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],today:"Today",clear:"Clear"}},p={modes:[{clsName:"days",navFnc:"Month",navStep:1},{clsName:"months",navFnc:"FullYear",navStep:1},{clsName:"years",navFnc:"FullYear",navStep:10}],isLeapYear:function(a){return a%4==0&&a%100!=0||a%400==0},getDaysInMonth:function(a,b){return[31,p.isLeapYear(a)?29:28,31,30,31,30,31,31,30,31,30,31][b]},validParts:/dd?|DD?|mm?|MM?|yy(?:yy)?/g,
2
+ nonpunctuation:/[^ -\/:-@\[\u3400-\u9fff-`{-~\t\n\r]+/g,parseFormat:function(a){var b=a.replace(this.validParts,"\0").split("\0"),c=a.match(this.validParts);if(!b||!b.length||!c||0===c.length)throw new Error("Invalid date format.");return{separators:b,parts:c}},parseDate:function(b,d,e){function f(){var a=this.slice(0,l[i].length);return a===l[i].slice(0,a.length)}if(b){if(b instanceof Date)return b;"string"==typeof d&&(d=p.parseFormat(d));var g,h,i,k=/([\-+]\d+)([dmwy])/,l=b.match(/([\-+]\d+)([dmwy])/g);if(/^[\-+]\d+[dmwy]([\s,]+[\-+]\d+[dmwy])*$/.test(b)){for(b=new Date,i=0;i<l.length;i++)switch(g=k.exec(l[i]),h=parseInt(g[1]),g[2]){case"d":b.setUTCDate(b.getUTCDate()+h);break;case"m":b=j.prototype.moveMonth.call(j.prototype,b,h);break;case"w":b.setUTCDate(b.getUTCDate()+7*h);break;case"y":b=j.prototype.moveYear.call(j.prototype,b,h)}return c(b.getUTCFullYear(),b.getUTCMonth(),b.getUTCDate(),0,0,0)}l=b&&b.match(this.nonpunctuation)||[],b=new Date;var m,n,q={},r=["yyyy","yy","M","MM","m","mm","d","dd"],s={yyyy:function(a,b){return a.setUTCFullYear(b)},yy:function(a,b){return a.setUTCFullYear(2e3+b)},m:function(a,b){if(isNaN(a))return a;for(b-=1;b<0;)b+=12;for(b%=12,a.setUTCMonth(b);a.getUTCMonth()!==b;)a.setUTCDate(a.getUTCDate()-1);return a},d:function(a,b){return a.setUTCDate(b)}};s.M=s.MM=s.mm=s.m,s.dd=s.d,b=c(b.getFullYear(),b.getMonth(),b.getDate(),0,0,0);var t=d.parts.slice();if(l.length!==t.length&&(t=a(t).filter(function(b,c){return-1!==a.inArray(c,r)}).toArray()),l.length===t.length){var u;for(i=0,u=t.length;i<u;i++){if(m=parseInt(l[i],10),g=t[i],isNaN(m))switch(g){case"MM":n=a(o[e].months).filter(f),m=a.inArray(n[0],o[e].months)+1;break;case"M":n=a(o[e].monthsShort).filter(f),m=a.inArray(n[0],o[e].monthsShort)+1}q[g]=m}var v,w;for(i=0;i<r.length;i++)(w=r[i])in q&&!isNaN(q[w])&&(v=new Date(b),s[w](v,q[w]),isNaN(v)||(b=v))}return b}},formatDate:function(b,c,d){if(!b)return"";"string"==typeof c&&(c=p.parseFormat(c));var e={d:b.getUTCDate(),D:o[d].daysShort[b.getUTCDay()],DD:o[d].days[b.getUTCDay()],m:b.getUTCMonth()+1,M:o[d].monthsShort[b.getUTCMonth()],MM:o[d].months[b.getUTCMonth()],yy:b.getUTCFullYear().toString().substring(2),yyyy:b.getUTCFullYear()};e.dd=(e.d<10?"0":"")+e.d,e.mm=(e.m<10?"0":"")+e.m,b=[];for(var f=a.extend([],c.separators),g=0,h=c.parts.length;g<=h;g++)f.length&&b.push(f.shift()),b.push(e[c.parts[g]]);return b.join("")},headTemplate:'<thead><tr><th class="prev">&laquo;</th><th colspan="5" class="cfdatepicker-switch"></th><th class="next">&raquo;</th></tr></thead>',contTemplate:'<tbody><tr><td colspan="7"></td></tr></tbody>',footTemplate:'<tfoot><tr><th colspan="7" class="today"></th></tr><tr><th colspan="7" class="clear"></th></tr></tfoot>'};p.template='<div class="cfdatepicker"><div class="cfdatepicker-days"><table class=" table-condensed">'+p.headTemplate+"<tbody></tbody>"+p.footTemplate+'</table></div><div class="cfdatepicker-months"><table class="table-condensed">'+p.headTemplate+p.contTemplate+p.footTemplate+'</table></div><div class="cfdatepicker-years"><table class="table-condensed">'+p.headTemplate+p.contTemplate+p.footTemplate+"</table></div></div>",a.fn.cfdatepicker.DPGlobal=p,a.fn.cfdatepicker.noConflict=function(){return a.fn.cfdatepicker=l,this},a(document).on("focus.cfdatepicker.data-api click.cfdatepicker.data-api",'[data-provide="cfdatepicker"]',function(b){var c=a(this);c.data("cfdatepicker")||(b.preventDefault(),c.cfdatepicker("show").on("show",function(){a(this).trigger("blur")}).on("hide",function(){a(this).attr("disabled",!1)}))})}(window.jQuery),function(a){function b(a){var b=document.createElement("input"),c="on"+a,d=c in b;return d||(b.setAttribute(c,"return;"),d="function"==typeof b[c]),b=null,d}function c(a){var b="text"==a||"tel"==a;if(!b){var c=document.createElement("input");c.setAttribute("type",a),b="text"===c.type,c=null}return b}function d(b,c,e){var f=e.aliases[b];return!!f&&(f.alias&&d(f.alias,void 0,e),a.extend(!0,e,f),a.extend(!0,e,c),!0)}function e(b,c){function d(a){function c(a,b,c,d){this.matches=[],this.isGroup=a||!1,this.isOptional=b||!1,this.isQuantifier=c||!1,this.isAlternator=d||!1,this.quantifier={min:1,max:1}}function d(a,c,d){var e=b.definitions[c],f=0==a.matches.length;if(d=void 0!=d?d:a.matches.length,e&&!l){for(var g=e.prevalidator,h=g?g.length:0,i=1;i<e.cardinality;i++){var j=h>=i?g[i-1]:[],k=j.validator,m=j.cardinality;a.matches.splice(d++,0,{fn:k?"string"==typeof k?new RegExp(k):new function(){this.test=k}:new RegExp("."),cardinality:m||1,optionality:a.isOptional,newBlockMarker:f,casing:e.casing,def:e.definitionSymbol||c,placeholder:e.placeholder,mask:c})}a.matches.splice(d++,0,{fn:e.validator?"string"==typeof e.validator?new RegExp(e.validator):new function(){this.test=e.validator}:new RegExp("."),cardinality:e.cardinality,optionality:a.isOptional,newBlockMarker:f,casing:e.casing,def:e.definitionSymbol||c,placeholder:e.placeholder,mask:c})}else a.matches.splice(d++,0,{fn:null,cardinality:0,optionality:a.isOptional,newBlockMarker:f,casing:null,def:c,placeholder:void 0,mask:c}),l=!1}for(var e,f,g,h,i,j,k=/(?:[?*+]|\{[0-9\+\*]+(?:,[0-9\+\*]*)?\})\??|[^.?*+^${[]()|\\]+|./g,l=!1,m=new c,n=[],o=[];e=k.exec(a);)switch(f=e[0],f.charAt(0)){case b.optionalmarker.end:case b.groupmarker.end:if(g=n.pop(),n.length>0){if(h=n[n.length-1],h.matches.push(g),h.isAlternator){i=n.pop();for(var p=0;p<i.matches.length;p++)i.matches[p].isGroup=!1;n.length>0?(h=n[n.length-1],h.matches.push(i)):m.matches.push(i)}}else m.matches.push(g);break;case b.optionalmarker.start:n.push(new c(!1,!0));break;case b.groupmarker.start:n.push(new c(!0));break;case b.quantifiermarker.start:var q=new c(!1,!1,!0);f=f.replace(/[{}]/g,"");var r=f.split(","),s=isNaN(r[0])?r[0]:parseInt(r[0]),t=1==r.length?s:isNaN(r[1])?r[1]:parseInt(r[1]);if(("*"==t||"+"==t)&&(s="*"==t?0:1),q.quantifier={min:s,max:t},n.length>0){var u=n[n.length-1].matches;if(e=u.pop(),!e.isGroup){var v=new c(!0);v.matches.push(e),e=v}u.push(e),u.push(q)}else{if(e=m.matches.pop(),!e.isGroup){var v=new c(!0);v.matches.push(e),e=v}m.matches.push(e),m.matches.push(q)}break;case b.escapeChar:l=!0;break;case b.alternatormarker:n.length>0?(h=n[n.length-1],j=h.matches.pop()):j=m.matches.pop(),j.isAlternator?n.push(j):(i=new c(!1,!1,!1,!0),i.matches.push(j),n.push(i));break;default:if(n.length>0){if(h=n[n.length-1],h.matches.length>0&&(j=h.matches[h.matches.length-1],j.isGroup&&(j.isGroup=!1,d(j,b.groupmarker.start,0),d(j,b.groupmarker.end))),d(h,f),h.isAlternator){i=n.pop();for(var p=0;p<i.matches.length;p++)i.matches[p].isGroup=!1;n.length>0?(h=n[n.length-1],h.matches.push(i)):m.matches.push(i)}}else m.matches.length>0&&(j=m.matches[m.matches.length-1],j.isGroup&&(j.isGroup=!1,d(j,b.groupmarker.start,0),d(j,b.groupmarker.end))),d(m,f)}return m.matches.length>0&&(j=m.matches[m.matches.length-1],j.isGroup&&(j.isGroup=!1,d(j,b.groupmarker.start,0),d(j,b.groupmarker.end)),o.push(m)),o}function e(c,e){if(b.numericInput&&!0!==b.multi){c=c.split("").reverse();for(var f=0;f<c.length;f++)c[f]==b.optionalmarker.start?c[f]=b.optionalmarker.end:c[f]==b.optionalmarker.end?c[f]=b.optionalmarker.start:c[f]==b.groupmarker.start?c[f]=b.groupmarker.end:c[f]==b.groupmarker.end&&(c[f]=b.groupmarker.start);c=c.join("")}if(void 0!=c&&""!=c){if(1==c.length&&0==b.greedy&&0!=b.repeat&&(b.placeholder=""),b.repeat>0||"*"==b.repeat||"+"==b.repeat){var g="*"==b.repeat?0:"+"==b.repeat?1:b.repeat;c=b.groupmarker.start+c+b.groupmarker.end+b.quantifiermarker.start+g+","+b.repeat+b.quantifiermarker.end}return void 0==a.inputmask.masksCache[c]&&(a.inputmask.masksCache[c]={mask:c,maskToken:d(c),validPositions:{},_buffer:void 0,buffer:void 0,tests:{},metadata:e}),a.extend(!0,{},a.inputmask.masksCache[c])}}var f=void 0;if(a.isFunction(b.mask)&&(b.mask=b.mask.call(this,b)),a.isArray(b.mask))if(c)f=[],a.each(b.mask,function(b,c){f.push(void 0==c.mask||a.isFunction(c.mask)?e(c.toString(),c):e(c.mask.toString(),c))});else{b.keepStatic=void 0==b.keepStatic||b.keepStatic;var g="(";a.each(b.mask,function(b,c){g.length>1&&(g+=")|("),g+=void 0==c.mask||a.isFunction(c.mask)?c.toString():c.mask.toString()}),g+=")",f=e(g,b.mask)}else b.mask&&(f=void 0==b.mask.mask||a.isFunction(b.mask.mask)?e(b.mask.toString(),b.mask):e(b.mask.mask.toString(),b.mask));return f}function f(d,e,f){function h(a,b,c){b=b||0;var d,e,f,g=[],h=0;do{if(!0===a&&o().validPositions[h]){var i=o().validPositions[h];e=i.match,d=i.locator.slice(),g.push(!0===c?i.input:I(h,e))}else{if(b>h){f=w(h,d,h-1)[0]}else f=t(h,d,h-1);e=f.match,d=f.locator.slice(),g.push(I(h,e))}h++}while((void 0==ea||ea>h-1)&&null!=e.fn||null==e.fn&&""!=e.def||b>=h);return g.pop(),g}function o(){return e}function p(a){var b=o();b.buffer=void 0,b.tests={},!0!==a&&(b._buffer=void 0,b.validPositions={},b.p=0)}function q(a){var b=o(),c=-1,d=b.validPositions;void 0==a&&(a=-1);var e=c,f=c;for(var g in d){var h=parseInt(g);(-1==a||null!=d[h].match.fn)&&(a>h&&(e=h),h>=a&&(f=h))}return c=a-e>1||a>f?e:f}function r(b,c,d){if(f.insertMode&&void 0!=o().validPositions[b]&&void 0==d){var e,g=a.extend(!0,{},o().validPositions),h=q();for(e=b;h>=e;e++)delete o().validPositions[e];o().validPositions[b]=c;var i,j=!0;for(e=b;h>=e;e++){var k=g[e];if(void 0!=k){var l=o().validPositions;i=!f.keepStatic&&(void 0!=l[e+1]&&w(e+1,l[e].locator.slice(),e).length>1||l[e]&&void 0!=l[e].alternation)?e+1:E(e),j=v(i,k.match.def)?j&&!1!==B(i,k.input,!0,!0):null==k.match.fn}if(!j)break}if(!j)return o().validPositions=a.extend(!0,{},g),!1}else o().validPositions[b]=c;return!0}function s(a,b){var c,d=a;for(void 0!=o().validPositions[a]&&o().validPositions[a].input==f.radixPoint&&(b++,d++),c=d;b>c;c++)void 0==o().validPositions[c]||o().validPositions[c].input==f.radixPoint&&c!=q()||delete o().validPositions[c];for(c=b;c<=q();){var e=o().validPositions[c],g=o().validPositions[d];void 0!=e&&void 0==g?(v(d,e.match.def)&&!1!==B(d,e.input,!0)&&(delete o().validPositions[c],c++),d++):c++}var h=q();h>=a&&void 0!=o().validPositions[h]&&o().validPositions[h].input==f.radixPoint&&delete o().validPositions[h],p(!0)}function t(b,c,d){for(var e,g=w(b,c,d),h=q(),i=o().validPositions[h]||w(0)[0],j=void 0!=i.alternation?i.locator[i.alternation].split(","):[],k=0;k<g.length&&(e=g[k],!(f.greedy||e.match&&(!1===e.match.optionality||!1===e.match.newBlockMarker)&&!0!==e.match.optionalQuantifier&&(void 0==i.alternation||void 0!=e.locator[i.alternation]&&function(b,c,d){for(var e=!1,f=b.locator[c].toString().split(","),g=0;g<f.length;g++)if(-1!=a.inArray(f[g],d)){e=!0;break}return e}(e,i.alternation,j))));k++);return e}function u(a){return o().validPositions[a]?o().validPositions[a].match:w(a)[0].match}function v(a,b){for(var c=!1,d=w(a),e=0;e<d.length;e++)if(d[e].match&&d[e].match.def==b){c=!0;break}return c}function w(b,c,d){function e(c,d,g,i){function l(g,i,n){if(h>1e4)return alert("jquery.inputmask: There is probably an error in your mask definition or in the code. Create an issue on github with an example of the mask you are using. "+o().mask),!0;if(h==b&&void 0==g.matches)return j.push({match:g,locator:i.reverse()}),!0;if(void 0!=g.matches){if(g.isGroup&&!0!==n){if(g=l(c.matches[m+1],i))return!0}else if(g.isOptional){var p=g;if(g=e(g,d,i,n)){var q=j[j.length-1].match,r=0==a.inArray(q,p.matches);r&&(k=!0),h=b}}else if(g.isAlternator){var s,t=g,u=[],v=j.slice(),w=i.length,x=d.length>0?d.shift():-1;if(-1==x||"string"==typeof x){var y,z=h,A=d.slice();"string"==typeof x&&(y=x.split(","));for(var B=0;B<t.matches.length;B++){j=[],g=l(t.matches[B],[B].concat(i),n)||g,s=j.slice(),h=z,j=[];for(var C=0;C<A.length;C++)d[C]=A[C];for(var D=0;D<s.length;D++)for(var E=s[D],F=0;F<u.length;F++){var G=u[F];if(E.match.mask==G.match.mask&&("string"!=typeof x||-1!=a.inArray(E.locator[w].toString(),y))){s.splice(D,1),G.locator[w]=G.locator[w]+","+E.locator[w],G.alternation=w;break}}u=u.concat(s)}"string"==typeof x&&(u=a.map(u,function(b,c){if(isFinite(c)){var d=b.locator[w].toString().split(",");b.locator[w]=void 0,b.alternation=void 0;for(var e=0;e<d.length;e++)-1!=a.inArray(d[e],y)&&(void 0!=b.locator[w]?(b.locator[w]+=",",b.alternation=w,b.locator[w]+=d[e]):b.locator[w]=parseInt(d[e]));if(void 0!=b.locator[w])return b}})),j=v.concat(u),k=!0}else g=l(t.matches[x],[x].concat(i),n);if(g)return!0}else if(g.isQuantifier&&!0!==n){var H=g;f.greedy=f.greedy&&isFinite(H.quantifier.max);for(var I=d.length>0&&!0!==n?d.shift():0;I<(isNaN(H.quantifier.max)?I+1:H.quantifier.max)&&b>=h;I++){var J=c.matches[a.inArray(H,c.matches)-1];if(g=l(J,[I].concat(i),!0)){var q=j[j.length-1].match;q.optionalQuantifier=I>H.quantifier.min-1;var r=0==a.inArray(q,J.matches);if(r){if(I>H.quantifier.min-1){k=!0,h=b;break}return!0}return!0}}}else if(g=e(g,d,i,n))return!0}else h++}for(var m=d.length>0?d.shift():0;m<c.matches.length;m++)if(!0!==c.matches[m].isQuantifier){var n=l(c.matches[m],[m].concat(g),i);if(n&&h==b)return n;if(h>b)break}}var g=o().maskToken,h=c?d:0,i=c||[0],j=[],k=!1;if(void 0==c){for(var l,m=b-1;void 0==(l=o().validPositions[m])&&m>-1;)m--;if(void 0!=l&&m>-1)h=m,i=l.locator.slice();else{for(m=b-1;void 0==(l=o().tests[m])&&m>-1;)m--;void 0!=l&&m>-1&&(h=m,i=l[0].locator.slice())}}for(var n=i.shift();n<g.length;n++){if(e(g[n],i,[n])&&h==b||h>b)break}return(0==j.length||k)&&j.push({match:{fn:null,cardinality:0,optionality:!0,casing:null,def:""},locator:[]}),o().tests[b]=a.extend(!0,[],j),o().tests[b]}function x(){return void 0==o()._buffer&&(o()._buffer=h(!1,1)),o()._buffer}function y(){return void 0==o().buffer&&(o().buffer=h(!0,q(),!0)),o().buffer}function z(a,b){var c=y().slice();if(!0===a)p(),a=0,b=c.length;else for(var d=a;b>d;d++)delete o().validPositions[d],delete o().tests[d];for(var d=a;b>d;d++)c[d]!=f.skipOptionalPartCharacter&&B(d,c[d],!0,!0)}function A(a,b){switch(b.casing){case"upper":a=a.toUpperCase();break;case"lower":a=a.toLowerCase()}return a}function B(b,c,d,e){function g(b,c,d,e){var g=!1;return a.each(w(b),function(h,i){for(var j=i.match,k=c?1:0,l="",m=(y(),j.cardinality);m>k;m--)l+=G(b-(m-1));if(c&&(l+=c),!1!==(g=null!=j.fn?j.fn.test(l,o(),b,d,f):(c==j.def||c==f.skipOptionalPartCharacter)&&""!=j.def&&{c:j.def,pos:b})){var n=void 0!=g.c?g.c:c;n=n==f.skipOptionalPartCharacter&&null===j.fn?j.def:n;var t=b;if(void 0!=g.remove&&s(g.remove,g.remove+1),g.refreshFromBuffer){var u=g.refreshFromBuffer;if(d=!0,z(!0===u?u:u.start,u.end),void 0==g.pos&&void 0==g.c)return g.pos=q(),!1;if((t=void 0!=g.pos?g.pos:b)!=b)return g=a.extend(g,B(t,n,!0)),!1}else if(!0!==g&&void 0!=g.pos&&g.pos!=b&&(t=g.pos,z(b,t),t!=b))return g=a.extend(g,B(t,n,!0)),!1;return(1==g||void 0!=g.pos||void 0!=g.c)&&(h>0&&p(!0),r(t,a.extend({},i,{input:A(n,j)}),e)||(g=!1),!1)}}),g}d=!0===d;for(var h=y(),i=b-1;i>-1&&(!o().validPositions[i]||null!=o().validPositions[i].match.fn);i--)void 0==o().validPositions[i]&&(!C(i)||h[i]!=I(i))&&w(i).length>1&&g(i,h[i],!0);var j=b,k=!1;if(e&&j>=D()&&p(!0),j<D()&&(k=g(j,c,d,e),!d&&!1===k)){var l=o().validPositions[j];if(!l||null!=l.match.fn||l.match.def!=c&&c!=f.skipOptionalPartCharacter){if((f.insertMode||void 0==o().validPositions[E(j)])&&!C(j))for(var m=j+1,n=E(j);n>=m;m++)if(!1!==(k=g(m,c,d,e))){j=m;break}}else k={caret:E(j)}}return!1===k&&f.keepStatic&&R(h)&&(k=function(b,c,d,e){var g,h,i=a.extend(!0,{},o().validPositions);for(g=q();g>=0;g--)if(o().validPositions[g]&&void 0!=o().validPositions[g].alternation){h=o().validPositions[g].alternation;break}if(void 0!=h)for(var j in o().validPositions)if(parseInt(j)>parseInt(g)&&void 0===o().validPositions[j].alternation){for(var k=o().validPositions[j],l=k.locator[h],m=o().validPositions[g].locator[h].split(","),n=0;n<m.length;n++)if(l<m[n]){for(var r,s,t=j-1;t>=0;t--)if(void 0!=(r=o().validPositions[t])){s=r.locator[h],r.locator[h]=m[n];break}if(l!=r.locator[h]){for(var u=y().slice(),v=j;v<q()+1;v++)delete o().validPositions[v],delete o().tests[v];p(!0),f.keepStatic=!f.keepStatic;for(var v=j;v<u.length;v++)u[v]!=f.skipOptionalPartCharacter&&B(q()+1,u[v],!1,!0);r.locator[h]=s;var w=B(b,c,d,e);if(f.keepStatic=!f.keepStatic,w)return w;p(),o().validPositions=a.extend(!0,{},i)}}break}return!1}(b,c,d,e)),!0===k&&(k={pos:j}),k}function C(a){var b=u(a);return null!=b.fn&&b.fn}function D(){var a;if(ea=da.prop("maxLength"),-1==ea&&(ea=void 0),0==f.greedy){var b,c=q(),d=o().validPositions[c],e=void 0!=d?d.locator.slice():void 0;for(b=c+1;void 0==d||null!=d.match.fn||null==d.match.fn&&""!=d.match.def;b++)d=t(b,e,b-1),e=d.locator.slice();a=b}else a=y().length;return void 0==ea||ea>a?a:ea}function E(a){var b=D();if(a>=b)return b;for(var c=a;++c<b&&!C(c)&&(!0!==f.nojumps||f.nojumpsThreshold>c););return c}function F(a){var b=a;if(0>=b)return 0;for(;--b>0&&!C(b););return b}function G(a){return void 0==o().validPositions[a]?I(a):o().validPositions[a].input}function H(a,b,c){a._valueSet(b.join("")),void 0!=c&&O(a,c)}function I(b,c){c=c||u(b);var d=a.isFunction(c.placeholder)?c.placeholder.call(this,f):c.placeholder;return void 0!=d?d:null==c.fn?c.def:f.placeholder.charAt(b%f.placeholder.length)}function J(b,c,d,e,g){var h=void 0!=e?e.slice():L(b._valueGet()).split("");if(p(),c&&b._valueSet(""),a.each(h,function(c,e){if(!0===g){var f=q(),h=-1==f?c:E(f);-1==a.inArray(e,x().slice(f+1,h))&&Y.call(b,void 0,!0,e.charCodeAt(0),!1,d,d?c:o().p)}else Y.call(b,void 0,!0,e.charCodeAt(0),!1,d,d?c:o().p),d=d||c>0&&c>o().p}),c){var i=f.onKeyPress.call(this,void 0,y(),0,f);W(b,i),H(b,y(),a(b).is(":focus")?E(q(0)):void 0)}}function K(b){return a.inputmask.escapeRegex.call(this,b)}function L(a){return a.replace(new RegExp("("+K(x().join(""))+")*$"),"")}function M(b){if(b.data("_inputmask")&&!b.hasClass("hasDatepicker")){var c=[],d=o().validPositions;for(var e in d)d[e].match&&null!=d[e].match.fn&&c.push(d[e].input);var g=(fa?c.reverse():c).join(""),h=(fa?y().slice().reverse():y()).join("");return a.isFunction(f.onUnMask)&&(g=f.onUnMask.call(b,h,g,f)||g),g}return b[0]._valueGet()}function N(a){if(fa&&"number"==typeof a&&(!f.greedy||""!=f.placeholder)){a=y().length-a}return a}function O(b,c,d){var e,g=b.jquery&&b.length>0?b[0]:b;if("number"!=typeof c){var h=a(g).data("_inputmask");return!a(g).is(":visible")&&h&&void 0!=h.caret?(c=h.caret.begin,d=h.caret.end):g.setSelectionRange?(c=g.selectionStart,d=g.selectionEnd):document.selection&&document.selection.createRange&&(e=document.selection.createRange(),c=0-e.duplicate().moveStart("character",-1e5),d=c+e.text.length),c=N(c),d=N(d),{begin:c,end:d}}c=N(c),d=N(d),d="number"==typeof d?d:c;var h=a(g).data("_inputmask")||{};h.caret={begin:c,end:d},a(g).data("_inputmask",h),a(g).is(":visible")&&(g.scrollLeft=g.scrollWidth,0==f.insertMode&&c==d&&d++,g.setSelectionRange?(g.selectionStart=c,g.selectionEnd=d):g.createTextRange&&(e=g.createTextRange(),e.collapse(!0),e.moveEnd("character",d),e.moveStart("character",c),e.select()))}function P(b){var c,d,e=y(),f=e.length,g=q(),h={},i=o().validPositions[g],j=void 0!=i?i.locator.slice():void 0;for(c=g+1;c<e.length;c++)d=t(c,j,c-1),j=d.locator.slice(),h[c]=a.extend(!0,{},d);var k=i&&void 0!=i.alternation?i.locator[i.alternation].split(","):[];for(c=f-1;c>g&&(d=h[c].match,(d.optionality||d.optionalQuantifier||i&&void 0!=i.alternation&&void 0!=h[c].locator[i.alternation]&&-1!=a.inArray(h[c].locator[i.alternation].toString(),k))&&e[c]==I(c,d));c--)f--;return b?{l:f,def:h[f]?h[f].match:void 0}:f}function Q(a){for(var b=y(),c=b.slice(),d=P(),e=c.length-1;e>d&&!C(e);e--);c.splice(d,e+1-d),H(a,c)}function R(b){if(a.isFunction(f.isComplete))return f.isComplete.call(da,b,f);if("*"!=f.repeat){var c=!1,d=P(!0),e=F(d.l);if(q()==e&&(void 0==d.def||d.def.newBlockMarker||d.def.optionalQuantifier)){c=!0;for(var g=0;e>=g;g++){var h=C(g);if(h&&(void 0==b[g]||b[g]==I(g))||!h&&b[g]!=I(g)){c=!1;break}}}return c}}function S(a,b){return fa?a-b>1||a-b==1&&f.insertMode:b-a>1||b-a==1&&f.insertMode}function T(b){var c=a._data(b).events;a.each(c,function(b,c){a.each(c,function(a,b){if("inputmask"==b.namespace&&"setvalue"!=b.type){var c=b.handler;b.handler=function(a){return this.readOnly||this.disabled?void a.preventDefault:c.apply(this,arguments)}}})})}function U(b){function c(){var b=a(this),c=a(this).data("_inputmask");return c?c.opts.autoUnmask?b.inputmask("unmaskedvalue"):e.call(this)!=x().join("")?e.call(this):"":e.call(this)}function d(b){var c=a(this).data("_inputmask");c?(f.call(this,a.isFunction(c.opts.onBeforeMask)?c.opts.onBeforeMask.call(na,b,c.opts)||b:b),a(this).triggerHandler("setvalue.inputmask")):f.call(this,b)}var e,f;b._valueGet||(Object.getOwnPropertyDescriptor&&Object.getOwnPropertyDescriptor(b,"value"),document.__lookupGetter__&&b.__lookupGetter__("value")?(e=b.__lookupGetter__("value"),f=b.__lookupSetter__("value"),b.__defineGetter__("value",c),b.__defineSetter__("value",d)):(e=function(){return b.value},f=function(a){b.value=a},function(b){if(void 0==a.valHooks[b]||1!=a.valHooks[b].inputmaskpatch){var c=a.valHooks[b]&&a.valHooks[b].get?a.valHooks[b].get:function(a){return a.value},d=a.valHooks[b]&&a.valHooks[b].set?a.valHooks[b].set:function(a,b){return a.value=b,a};a.valHooks[b]={get:function(b){var d=a(b);if(d.data("_inputmask")){if(d.data("_inputmask").opts.autoUnmask)return d.inputmask("unmaskedvalue");var e=c(b),f=d.data("_inputmask"),g=f.maskset,h=g._buffer;return h=h?h.join(""):"",e!=h?e:""}return c(b)},set:function(b,c){var e,f=a(b),g=f.data("_inputmask");return g?(e=d(b,a.isFunction(g.opts.onBeforeMask)?g.opts.onBeforeMask.call(na,c,g.opts)||c:c),f.triggerHandler("setvalue.inputmask")):e=d(b,c),e},inputmaskpatch:!0}}}(b.type),function(b){a(b).bind("mouseenter.inputmask",function(){var b=a(this),c=this,d=c._valueGet();""!=d&&d!=y().join("")&&b.trigger("setvalue")});var c=a._data(b).events,d=c.mouseover;if(d){for(var e=d[d.length-1],f=d.length-1;f>0;f--)d[f]=d[f-1];d[0]=e}}(b)),b._valueGet=function(){return fa?e.call(this).split("").reverse().join(""):e.call(this)},b._valueSet=function(a){f.call(this,fa?a.split("").reverse().join(""):a)})}function V(b,c,d){if((f.numericInput||fa)&&(c==a.inputmask.keyCode.BACKSPACE?c=a.inputmask.keyCode.DELETE:c==a.inputmask.keyCode.DELETE&&(c=a.inputmask.keyCode.BACKSPACE),fa)){var e=d.end;d.end=d.begin,d.begin=e}c==a.inputmask.keyCode.BACKSPACE&&d.end-d.begin<=1?d.begin=F(d.begin):c==a.inputmask.keyCode.DELETE&&d.begin==d.end&&d.end++,s(d.begin,d.end),function(){if(f.keepStatic){p(!0);var a,c=[];for(a=q();a>=0;a--)if(o().validPositions[a]){if(void 0!=o().validPositions[a].alternation)break;c.push(o().validPositions[a].input),delete o().validPositions[a]}if(a>0)for(;c.length>0;)o().p=E(q()),Y.call(b,void 0,!0,c.pop().charCodeAt(0),!1,!1,o().p)}}();var g=q(d.begin);g<d.begin?(-1==g&&p(),o().p=E(g)):o().p=d.begin}function W(a,b,c){if(b&&b.refreshFromBuffer){var d=b.refreshFromBuffer;z(!0===d?d:d.start,d.end),p(!0),void 0!=c&&(H(a,y()),O(a,b.caret||c.begin,b.caret||c.end))}}function X(c){ga=!1;var d=this,e=a(d),g=c.keyCode,h=O(d);g==a.inputmask.keyCode.BACKSPACE||g==a.inputmask.keyCode.DELETE||i&&127==g||c.ctrlKey&&88==g&&!b("cut")?(c.preventDefault(),88==g&&(ca=y().join("")),V(d,g,h),H(d,y(),o().p),d._valueGet()==x().join("")&&e.trigger("cleared"),f.showTooltip&&e.prop("title",o().mask)):g==a.inputmask.keyCode.END||g==a.inputmask.keyCode.PAGE_DOWN?setTimeout(function(){var a=E(q());f.insertMode||a!=D()||c.shiftKey||a--,O(d,c.shiftKey?h.begin:a,a)},0):g==a.inputmask.keyCode.HOME&&!c.shiftKey||g==a.inputmask.keyCode.PAGE_UP?O(d,0,c.shiftKey?h.begin:0):g==a.inputmask.keyCode.ESCAPE||90==g&&c.ctrlKey?(J(d,!0,!1,ca.split("")),e.click()):g!=a.inputmask.keyCode.INSERT||c.shiftKey||c.ctrlKey?0!=f.insertMode||c.shiftKey||(g==a.inputmask.keyCode.RIGHT?setTimeout(function(){var a=O(d);O(d,a.begin)},0):g==a.inputmask.keyCode.LEFT&&setTimeout(function(){var a=O(d);O(d,fa?a.begin+1:a.begin-1)},0)):(f.insertMode=!f.insertMode,O(d,f.insertMode||h.begin!=D()?h.begin:h.begin-1));var j=O(d),k=f.onKeyDown.call(this,c,y(),j.begin,f);W(d,k,j),ia=-1!=a.inArray(g,f.ignorables)}function Y(b,c,d,e,g,h){if(void 0==d&&ga)return!1;ga=!0;var i=this,j=a(i);b=b||window.event;var d=c?d:b.which||b.charCode||b.keyCode;if(!(!0===c||b.ctrlKey&&b.altKey)&&(b.ctrlKey||b.metaKey||ia))return!0;if(d){!0!==c&&46==d&&0==b.shiftKey&&","==f.radixPoint&&(d=44);var k,l=c?{begin:h,end:h}:O(i),m=String.fromCharCode(d),n=S(l.begin,l.end);n&&(o().undoPositions=a.extend(!0,{},o().validPositions),V(i,a.inputmask.keyCode.DELETE,l),f.insertMode||(f.insertMode=!f.insertMode,r(l.begin,g),f.insertMode=!f.insertMode),n=!f.multi),o().writeOutBuffer=!0;var q=fa&&!n?l.end:l.begin,s=B(q,m,g);if(!1!==s){if(!0!==s&&(q=void 0!=s.pos?s.pos:q,m=void 0!=s.c?s.c:m),p(!0),void 0!=s.caret)k=s.caret;else{var t=o().validPositions;k=!f.keepStatic&&(void 0!=t[q+1]&&w(q+1,t[q].locator.slice(),q).length>1||void 0!=t[q].alternation)?q+1:E(q)}o().p=k}if(!1!==e){var u=this;if(setTimeout(function(){f.onKeyValidation.call(u,s,f)},0),o().writeOutBuffer&&!1!==s){var v=y();H(i,v,c?void 0:f.numericInput?F(k):k),!0!==c&&setTimeout(function(){!0===R(v)&&j.trigger("complete"),ha=!0,j.trigger("input")},0)}else n&&(o().buffer=void 0,o().validPositions=o().undoPositions)}else n&&(o().buffer=void 0,o().validPositions=o().undoPositions);if(f.showTooltip&&j.prop("title",o().mask),b&&1!=c){b.preventDefault();var x=O(i);W(i,f.onKeyPress.call(this,b,y(),x.begin,f),x)}}}function Z(b){var c=a(this),d=this,e=b.keyCode,g=y(),h=O(d);W(d,f.onKeyUp.call(this,b,g,h.begin,f),h),e==a.inputmask.keyCode.TAB&&f.showMaskOnFocus&&(c.hasClass("focus-inputmask")&&0==d._valueGet().length?(p(),g=y(),H(d,g),O(d,0),ca=y().join("")):(H(d,g),O(d,N(0),N(D()))))}function $(b){if(!0===ha&&"input"==b.type)return ha=!1,!0;var c=this,d=a(c),e=c._valueGet(),g=O(c);if("propertychange"==b.type&&c._valueGet().length<=D())return!0;"paste"==b.type&&(window.clipboardData&&window.clipboardData.getData?e=e.substr(0,g.begin)+window.clipboardData.getData("Text")+e.substr(g.end,e.length):b.originalEvent&&b.originalEvent.clipboardData&&b.originalEvent.clipboardData.getData&&(e=e.substr(0,g.begin)+b.originalEvent.clipboardData.getData("text/plain")+e.substr(g.end,e.length)));var h=a.isFunction(f.onBeforePaste)?f.onBeforePaste.call(c,e,f)||e:e;return J(c,!0,!1,fa?h.split("").reverse():h.split(""),!0),d.click(),!0===R(y())&&d.trigger("complete"),!1}function _(b){if(!0===ha&&"input"==b.type)return ha=!1,!0;var c=this,d=O(c),e=c._valueGet();e=e.replace(new RegExp("("+K(x().join(""))+")*"),""),d.begin>e.length&&(O(c,e.length),d=O(c)),y().length-e.length!=1||e.charAt(d.begin)==y()[d.begin]||e.charAt(d.begin+1)==y()[d.begin]||C(d.begin)||(b.keyCode=a.inputmask.keyCode.BACKSPACE,X.call(c,b)),b.preventDefault()}function aa(b){if(!0===ha&&"input"==b.type)return ha=!1,!0;var c=this,d=O(c),e=c._valueGet();O(c,d.begin-1);var g=a.Event("keypress");g.which=e.charCodeAt(d.begin-1),ga=!1,ia=!1,Y.call(c,g,void 0,void 0,!1);var h=o().p;H(c,y(),f.numericInput?F(h):h),b.preventDefault()}function ba(b){ha=!0;var c=this;return setTimeout(function(){O(c,O(c).begin-1);var d=a.Event("keypress");d.which=b.originalEvent.data.charCodeAt(0),ga=!1,ia=!1,Y.call(c,d,void 0,void 0,!1);var e=o().p;H(c,y(),f.numericInput?F(e):e)},0),!1}var ca,da,ea,fa=!1,ga=!1,ha=!1,ia=!1;if(void 0!=d)switch(d.action){case"isComplete":return da=a(d.el),e=da.data("_inputmask").maskset,f=da.data("_inputmask").opts,R(d.buffer);case"unmaskedvalue":return da=d.$input,e=da.data("_inputmask").maskset,f=da.data("_inputmask").opts,fa=d.$input.data("_inputmask").isRTL,M(d.$input);case"mask":ca=y().join(""),function(b){if(da=a(b),da.is(":input")&&c(da.attr("type"))){if(da.data("_inputmask",{maskset:e,opts:f,isRTL:!1}),f.showTooltip&&da.prop("title",o().mask),("rtl"==b.dir||f.rightAlign)&&da.css("text-align","right"),"rtl"==b.dir||f.numericInput){b.dir="ltr",da.removeAttr("dir");var d=da.data("_inputmask");d.isRTL=!0,da.data("_inputmask",d),fa=!0}da.unbind(".inputmask"),da.removeClass("focus-inputmask"),da.closest("form").bind("submit",function(){ca!=y().join("")&&da.change(),da[0]._valueGet&&da[0]._valueGet()==x().join("")&&da[0]._valueSet(""),f.autoUnmask&&f.removeMaskOnSubmit&&da.inputmask("remove")}).bind("reset",function(){setTimeout(function(){da.trigger("setvalue")},0)}),da.bind("mouseenter.inputmask",function(){var b=a(this),c=this;!b.hasClass("focus-inputmask")&&f.showMaskOnHover&&c._valueGet()!=y().join("")&&H(c,y())}).bind("blur.inputmask",function(){var b=a(this),c=this;if(b.data("_inputmask")){var d=c._valueGet(),e=y();b.removeClass("focus-inputmask"),ca!=y().join("")&&b.change(),f.clearMaskOnLostFocus&&""!=d&&(d==x().join("")?c._valueSet(""):Q(c)),!1===R(e)&&(b.trigger("incomplete"),f.clearIncomplete&&(p(),f.clearMaskOnLostFocus?c._valueSet(""):(e=x().slice(),H(c,e))))}}).bind("focus.inputmask",function(){var b=a(this),c=this,d=c._valueGet();f.showMaskOnFocus&&!b.hasClass("focus-inputmask")&&(!f.showMaskOnHover||f.showMaskOnHover&&""==d)&&c._valueGet()!=y().join("")&&H(c,y(),E(q())),b.addClass("focus-inputmask"),ca=y().join("")}).bind("mouseleave.inputmask",function(){var b=a(this),c=this;f.clearMaskOnLostFocus&&(b.hasClass("focus-inputmask")||c._valueGet()==b.attr("placeholder")||(c._valueGet()==x().join("")||""==c._valueGet()?c._valueSet(""):Q(c)))}).bind("click.inputmask",function(){var b=this;a(b).is(":focus")&&setTimeout(function(){var c=O(b);if(c.begin==c.end)if(f.radixFocus&&""!=f.radixPoint&&-1!=a.inArray(f.radixPoint,y())&&y().join("")==x().join(""))O(b,a.inArray(f.radixPoint,y()));else{var d=fa?N(c.begin):c.begin,e=E(q(d));e>d?O(b,C(d)?d:E(d)):O(b,e)}},0)}).bind("dblclick.inputmask",function(){var a=this;setTimeout(function(){O(a,0,E(q()))},0)}).bind(n+".inputmask dragdrop.inputmask drop.inputmask",$).bind("setvalue.inputmask",function(){var a=this;J(a,!0,!1,void 0,!0),ca=y().join(""),(f.clearMaskOnLostFocus||f.clearIncomplete)&&a._valueGet()==x().join("")&&a._valueSet("")}).bind("cut.inputmask",function(b){ha=!0;var c=this,d=a(c),e=O(c);V(c,a.inputmask.keyCode.DELETE,e),W(c,f.onKeyPress.call(this,b,y(),o().p,f),{begin:o().p,end:o().p}),c._valueGet()==x().join("")&&d.trigger("cleared"),f.showTooltip&&d.prop("title",o().mask)}).bind("complete.inputmask",f.oncomplete).bind("incomplete.inputmask",f.onincomplete).bind("cleared.inputmask",f.oncleared),da.bind("keydown.inputmask",X).bind("keypress.inputmask",Y).bind("keyup.inputmask",Z).bind("compositionupdate.inputmask",ba),"paste"!==n||g||da.bind("input.inputmask",aa),g&&da.bind("input.inputmask",$),(j||l||k||m)&&("input"==n&&da.unbind(n+".inputmask"),da.bind("input.inputmask",_)),U(b);J(b,!0,!1,(a.isFunction(f.onBeforeMask)?f.onBeforeMask.call(b,b._valueGet(),f)||b._valueGet():b._valueGet()).split(""),!0),ca=y().join("");var h;try{h=document.activeElement}catch(a){}!1===R(y())&&f.clearIncomplete&&p(),f.clearMaskOnLostFocus?y().join("")==x().join("")?b._valueSet(""):Q(b):H(b,y()),h===b&&(da.addClass("focus-inputmask"),O(b,E(q()))),T(b)}}(d.el);break;case"format":da=a({}),da.data("_inputmask",{maskset:e,opts:f,isRTL:f.numericInput}),f.numericInput&&(fa=!0);var ja=(a.isFunction(f.onBeforeMask)?f.onBeforeMask.call(da,d.value,f)||d.value:d.value).split("");return J(da,!1,!1,fa?ja.reverse():ja,!0),f.onKeyPress.call(this,void 0,y(),0,f),d.metadata?{value:fa?y().slice().reverse().join(""):y().join(""),metadata:da.inputmask("getmetadata")}:fa?y().slice().reverse().join(""):y().join("");case"isValid":da=a({}),da.data("_inputmask",{maskset:e,opts:f,isRTL:f.numericInput}),f.numericInput&&(fa=!0);var ja=d.value.split("");J(da,!1,!0,fa?ja.reverse():ja);for(var ka=y(),la=P(),ma=ka.length-1;ma>la&&!C(ma);ma--);return ka.splice(la,ma+1-la),R(ka)&&d.value==ka.join("");case"getemptymask":return da=a(d.el),e=da.data("_inputmask").maskset,f=da.data("_inputmask").opts,x();case"remove":var na=d.el;da=a(na),e=da.data("_inputmask").maskset,f=da.data("_inputmask").opts,na._valueSet(M(da)),da.unbind(".inputmask"),da.removeClass("focus-inputmask"),da.removeData("_inputmask");var oa;Object.getOwnPropertyDescriptor&&(oa=Object.getOwnPropertyDescriptor(na,"value")),oa&&oa.get?na._valueGet&&Object.defineProperty(na,"value",{get:na._valueGet,set:na._valueSet
3
+ }):document.__lookupGetter__&&na.__lookupGetter__("value")&&na._valueGet&&(na.__defineGetter__("value",na._valueGet),na.__defineSetter__("value",na._valueSet));try{delete na._valueGet,delete na._valueSet}catch(a){na._valueGet=void 0,na._valueSet=void 0}break;case"getmetadata":if(da=a(d.el),e=da.data("_inputmask").maskset,f=da.data("_inputmask").opts,a.isArray(e.metadata)){for(var pa,qa=q(),ra=qa;ra>=0;ra--)if(o().validPositions[ra]&&void 0!=o().validPositions[ra].alternation){pa=o().validPositions[ra].alternation;break}return void 0!=pa?e.metadata[o().validPositions[qa].locator[pa]]:e.metadata[0]}return e.metadata}}if(void 0===a.fn.inputmask){var g="function"==typeof ScriptEngineMajorVersion?ScriptEngineMajorVersion():new Function("/*@cc_on return @_jscript_version; @*/")()>=10,h=navigator.userAgent,i=null!==h.match(new RegExp("iphone","i")),j=null!==h.match(new RegExp("android.*safari.*","i")),k=null!==h.match(new RegExp("android.*chrome.*","i")),l=null!==h.match(new RegExp("android.*firefox.*","i")),m=/Kindle/i.test(h)||/Silk/i.test(h)||/KFTT/i.test(h)||/KFOT/i.test(h)||/KFJWA/i.test(h)||/KFJWI/i.test(h)||/KFSOWI/i.test(h)||/KFTHWA/i.test(h)||/KFTHWI/i.test(h)||/KFAPWA/i.test(h)||/KFAPWI/i.test(h),n=b("paste")?"paste":b("input")?"input":"propertychange";a.inputmask={defaults:{placeholder:"_",optionalmarker:{start:"[",end:"]"},quantifiermarker:{start:"{",end:"}"},groupmarker:{start:"(",end:")"},alternatormarker:"|",escapeChar:"\\",mask:null,oncomplete:a.noop,onincomplete:a.noop,oncleared:a.noop,repeat:0,greedy:!0,autoUnmask:!1,removeMaskOnSubmit:!0,clearMaskOnLostFocus:!0,insertMode:!0,clearIncomplete:!1,aliases:{},alias:null,onKeyUp:a.noop,onKeyPress:a.noop,onKeyDown:a.noop,onBeforeMask:void 0,onBeforePaste:void 0,onUnMask:void 0,showMaskOnFocus:!0,showMaskOnHover:!0,onKeyValidation:a.noop,skipOptionalPartCharacter:" ",showTooltip:!1,numericInput:!1,rightAlign:!1,radixPoint:"",radixFocus:!1,nojumps:!1,nojumpsThreshold:0,keepStatic:void 0,definitions:{9:{validator:"[0-9]",cardinality:1,definitionSymbol:"*"},a:{validator:"[A-Za-zА-яЁёÀ-ÿµ]",cardinality:1,definitionSymbol:"*"},"*":{validator:"[0-9A-Za-zА-яЁёÀ-ÿµ]",cardinality:1}},ignorables:[8,9,13,19,27,33,34,35,36,37,38,39,40,45,46,93,112,113,114,115,116,117,118,119,120,121,122,123],isComplete:void 0},keyCode:{ALT:18,BACKSPACE:8,CAPS_LOCK:20,COMMA:188,COMMAND:91,COMMAND_LEFT:91,COMMAND_RIGHT:93,CONTROL:17,DELETE:46,DOWN:40,END:35,ENTER:13,ESCAPE:27,HOME:36,INSERT:45,LEFT:37,MENU:93,NUMPAD_ADD:107,NUMPAD_DECIMAL:110,NUMPAD_DIVIDE:111,NUMPAD_ENTER:108,NUMPAD_MULTIPLY:106,NUMPAD_SUBTRACT:109,PAGE_DOWN:34,PAGE_UP:33,PERIOD:190,RIGHT:39,SHIFT:16,SPACE:32,TAB:9,UP:38,WINDOWS:91},masksCache:{},escapeRegex:function(a){var b=["/",".","*","+","?","|","(",")","[","]","{","}","\\"];return a.replace(new RegExp("(\\"+b.join("|\\")+")","gim"),"\\$1")},format:function(b,c,g){var h=a.extend(!0,{},a.inputmask.defaults,c);return d(h.alias,c,h),f({action:"format",value:b,metadata:g},e(h),h)},isValid:function(b,c){var g=a.extend(!0,{},a.inputmask.defaults,c);return d(g.alias,c,g),f({action:"isValid",value:b},e(g),g)}},a.fn.inputmask=function(b,c,g,h,i){function j(b,c,e){var f=a(b);f.data("inputmask-alias")&&d(f.data("inputmask-alias"),{},c);for(var g in c){var h=f.data("inputmask-"+g.toLowerCase());void 0!=h&&("mask"==g&&0==h.indexOf("[")?(c[g]=h.replace(/[\s[\]]/g,"").split("','"),c[g][0]=c[g][0].replace("'",""),c[g][c[g].length-1]=c[g][c[g].length-1].replace("'","")):c[g]="boolean"==typeof h?h:h.toString(),e&&(e[g]=c[g]))}return c}g=g||f,h=h||"_inputmask";var k,l=a.extend(!0,{},a.inputmask.defaults,c);if("string"==typeof b)switch(b){case"mask":return d(l.alias,c,l),k=e(l,g!==f),void 0==k?this:this.each(function(){g({action:"mask",el:this},a.extend(!0,{},k),j(this,l))});case"unmaskedvalue":var m=a(this);return m.data(h)?g({action:"unmaskedvalue",$input:m}):m.val();case"remove":return this.each(function(){a(this).data(h)&&g({action:"remove",el:this})});case"getemptymask":return this.data(h)?g({action:"getemptymask",el:this}):"";case"hasMaskedValue":return!!this.data(h)&&!this.data(h).opts.autoUnmask;case"isComplete":return!this.data(h)||g({action:"isComplete",buffer:this[0]._valueGet().split(""),el:this});case"getmetadata":return this.data(h)?g({action:"getmetadata",el:this}):void 0;case"_detectScope":return d(l.alias,c,l),void 0==i||d(i,c,l)||-1!=a.inArray(i,["mask","unmaskedvalue","remove","getemptymask","hasMaskedValue","isComplete","getmetadata","_detectScope"])||(l.mask=i),a.isFunction(l.mask)&&(l.mask=l.mask.call(this,l)),a.isArray(l.mask);default:return d(l.alias,c,l),d(b,c,l)||(l.mask=b),k=e(l,g!==f),void 0==k?this:this.each(function(){g({action:"mask",el:this},a.extend(!0,{},k),j(this,l))})}else{if("object"==typeof b)return l=a.extend(!0,{},a.inputmask.defaults,b),d(l.alias,b,l),k=e(l,g!==f),void 0==k?this:this.each(function(){g({action:"mask",el:this},a.extend(!0,{},k),j(this,l))});if(void 0==b)return this.each(function(){var b=a(this).attr("data-inputmask");if(b&&""!=b)try{b=b.replace(new RegExp("'","g"),'"');var e=a.parseJSON("{"+b+"}");a.extend(!0,e,c),l=a.extend(!0,{},a.inputmask.defaults,e),l=j(this,l),d(l.alias,e,l),l.alias=void 0,a(this).inputmask("mask",l,g)}catch(a){}if(a(this).attr("data-inputmask-mask")||a(this).attr("data-inputmask-alias")){l=a.extend(!0,{},a.inputmask.defaults,{});var f={};l=j(this,l,f),d(l.alias,f,l),l.alias=void 0,a(this).inputmask("mask",l,g)}})}}}a.fn.inputmask}(jQuery),function(a){a.extend(a.inputmask.defaults.definitions,{h:{validator:"[01][0-9]|2[0-3]",cardinality:2,prevalidator:[{validator:"[0-2]",cardinality:1}]},s:{validator:"[0-5][0-9]",cardinality:2,prevalidator:[{validator:"[0-5]",cardinality:1}]},d:{validator:"0[1-9]|[12][0-9]|3[01]",cardinality:2,prevalidator:[{validator:"[0-3]",cardinality:1}]},m:{validator:"0[1-9]|1[012]",cardinality:2,prevalidator:[{validator:"[01]",cardinality:1}]},y:{validator:"(19|20)\\d{2}",cardinality:4,prevalidator:[{validator:"[12]",cardinality:1},{validator:"(19|20)",cardinality:2},{validator:"(19|20)\\d",cardinality:3}]}}),a.extend(a.inputmask.defaults.aliases,{"dd/mm/yyyy":{mask:"1/2/y",placeholder:"dd/mm/yyyy",regex:{val1pre:new RegExp("[0-3]"),val1:new RegExp("0[1-9]|[12][0-9]|3[01]"),val2pre:function(b){var c=a.inputmask.escapeRegex.call(this,b);return new RegExp("((0[1-9]|[12][0-9]|3[01])"+c+"[01])")},val2:function(b){var c=a.inputmask.escapeRegex.call(this,b);return new RegExp("((0[1-9]|[12][0-9])"+c+"(0[1-9]|1[012]))|(30"+c+"(0[13-9]|1[012]))|(31"+c+"(0[13578]|1[02]))")}},leapday:"29/02/",separator:"/",yearrange:{minyear:1900,maxyear:2099},isInYearRange:function(a,b,c){if(isNaN(a))return!1;var d=parseInt(a.concat(b.toString().slice(a.length))),e=parseInt(a.concat(c.toString().slice(a.length)));return!isNaN(d)&&(d>=b&&c>=d)||!isNaN(e)&&(e>=b&&c>=e)},determinebaseyear:function(a,b,c){var d=(new Date).getFullYear();if(a>d)return a;if(d>b){for(var e=b.toString().slice(0,2),f=b.toString().slice(2,4);e+c>b;)e--;var g=e+f;return a>g?a:g}return d},onKeyUp:function(b){var c=a(this);if(b.ctrlKey&&b.keyCode==a.inputmask.keyCode.RIGHT){var d=new Date;c.val(d.getDate().toString()+(d.getMonth()+1).toString()+d.getFullYear().toString())}},definitions:{1:{validator:function(a,b,c,d,e){var f=e.regex.val1.test(a);return d||f||a.charAt(1)!=e.separator&&-1=="-./".indexOf(a.charAt(1))||!(f=e.regex.val1.test("0"+a.charAt(0)))?f:(b.buffer[c-1]="0",{refreshFromBuffer:{start:c-1,end:c},pos:c,c:a.charAt(0)})},cardinality:2,prevalidator:[{validator:function(a,b,c,d,e){isNaN(b.buffer[c+1])||(a+=b.buffer[c+1]);var f=1==a.length?e.regex.val1pre.test(a):e.regex.val1.test(a);return d||f||!(f=e.regex.val1.test("0"+a))?f:(b.buffer[c]="0",c++,{pos:c})},cardinality:1}]},2:{validator:function(a,b,c,d,e){var f=e.mask.indexOf("2")==e.mask.length-1?b.buffer.join("").substr(5,3):b.buffer.join("").substr(0,3);-1!=f.indexOf(e.placeholder[0])&&(f="01"+e.separator);var g=e.regex.val2(e.separator).test(f+a);if(!d&&!g&&(a.charAt(1)==e.separator||-1!="-./".indexOf(a.charAt(1)))&&(g=e.regex.val2(e.separator).test(f+"0"+a.charAt(0))))return b.buffer[c-1]="0",{refreshFromBuffer:{start:c-1,end:c},pos:c,c:a.charAt(0)};if(e.mask.indexOf("2")==e.mask.length-1&&g){if(b.buffer.join("").substr(4,4)+a!=e.leapday)return!0;var h=parseInt(b.buffer.join("").substr(0,4),10);return h%4==0&&(h%100!=0||h%400==0)}return g},cardinality:2,prevalidator:[{validator:function(a,b,c,d,e){isNaN(b.buffer[c+1])||(a+=b.buffer[c+1]);var f=e.mask.indexOf("2")==e.mask.length-1?b.buffer.join("").substr(5,3):b.buffer.join("").substr(0,3);-1!=f.indexOf(e.placeholder[0])&&(f="01"+e.separator);var g=1==a.length?e.regex.val2pre(e.separator).test(f+a):e.regex.val2(e.separator).test(f+a);return d||g||!(g=e.regex.val2(e.separator).test(f+"0"+a))?g:(b.buffer[c]="0",c++,{pos:c})},cardinality:1}]},y:{validator:function(a,b,c,d,e){if(e.isInYearRange(a,e.yearrange.minyear,e.yearrange.maxyear)){if(b.buffer.join("").substr(0,6)!=e.leapday)return!0;var f=parseInt(a,10);return f%4==0&&(f%100!=0||f%400==0)}return!1},cardinality:4,prevalidator:[{validator:function(a,b,c,d,e){var f=e.isInYearRange(a,e.yearrange.minyear,e.yearrange.maxyear);if(!d&&!f){var g=e.determinebaseyear(e.yearrange.minyear,e.yearrange.maxyear,a+"0").toString().slice(0,1);if(f=e.isInYearRange(g+a,e.yearrange.minyear,e.yearrange.maxyear))return b.buffer[c++]=g.charAt(0),{pos:c};if(g=e.determinebaseyear(e.yearrange.minyear,e.yearrange.maxyear,a+"0").toString().slice(0,2),f=e.isInYearRange(g+a,e.yearrange.minyear,e.yearrange.maxyear))return b.buffer[c++]=g.charAt(0),b.buffer[c++]=g.charAt(1),{pos:c}}return f},cardinality:1},{validator:function(a,b,c,d,e){var f=e.isInYearRange(a,e.yearrange.minyear,e.yearrange.maxyear);if(!d&&!f){var g=e.determinebaseyear(e.yearrange.minyear,e.yearrange.maxyear,a).toString().slice(0,2);if(f=e.isInYearRange(a[0]+g[1]+a[1],e.yearrange.minyear,e.yearrange.maxyear))return b.buffer[c++]=g.charAt(1),{pos:c};if(g=e.determinebaseyear(e.yearrange.minyear,e.yearrange.maxyear,a).toString().slice(0,2),e.isInYearRange(g+a,e.yearrange.minyear,e.yearrange.maxyear)){if(b.buffer.join("").substr(0,6)!=e.leapday)f=!0;else{var h=parseInt(a,10);f=h%4==0&&(h%100!=0||h%400==0)}}else f=!1;if(f)return b.buffer[c-1]=g.charAt(0),b.buffer[c++]=g.charAt(1),b.buffer[c++]=a.charAt(0),{refreshFromBuffer:{start:c-3,end:c},pos:c}}return f},cardinality:2},{validator:function(a,b,c,d,e){return e.isInYearRange(a,e.yearrange.minyear,e.yearrange.maxyear)},cardinality:3}]}},insertMode:!1,autoUnmask:!1},"mm/dd/yyyy":{placeholder:"mm/dd/yyyy",alias:"dd/mm/yyyy",regex:{val2pre:function(b){var c=a.inputmask.escapeRegex.call(this,b);return new RegExp("((0[13-9]|1[012])"+c+"[0-3])|(02"+c+"[0-2])")},val2:function(b){var c=a.inputmask.escapeRegex.call(this,b);return new RegExp("((0[1-9]|1[012])"+c+"(0[1-9]|[12][0-9]))|((0[13-9]|1[012])"+c+"30)|((0[13578]|1[02])"+c+"31)")},val1pre:new RegExp("[01]"),val1:new RegExp("0[1-9]|1[012]")},leapday:"02/29/",onKeyUp:function(b){var c=a(this);if(b.ctrlKey&&b.keyCode==a.inputmask.keyCode.RIGHT){var d=new Date;c.val((d.getMonth()+1).toString()+d.getDate().toString()+d.getFullYear().toString())}}},"yyyy/mm/dd":{mask:"y/1/2",placeholder:"yyyy/mm/dd",alias:"mm/dd/yyyy",leapday:"/02/29",onKeyUp:function(b){var c=a(this);if(b.ctrlKey&&b.keyCode==a.inputmask.keyCode.RIGHT){var d=new Date;c.val(d.getFullYear().toString()+(d.getMonth()+1).toString()+d.getDate().toString())}}},"dd.mm.yyyy":{mask:"1.2.y",placeholder:"dd.mm.yyyy",leapday:"29.02.",separator:".",alias:"dd/mm/yyyy"},"dd-mm-yyyy":{mask:"1-2-y",placeholder:"dd-mm-yyyy",leapday:"29-02-",separator:"-",alias:"dd/mm/yyyy"},"mm.dd.yyyy":{mask:"1.2.y",placeholder:"mm.dd.yyyy",leapday:"02.29.",separator:".",alias:"mm/dd/yyyy"},"mm-dd-yyyy":{mask:"1-2-y",placeholder:"mm-dd-yyyy",leapday:"02-29-",separator:"-",alias:"mm/dd/yyyy"},"yyyy.mm.dd":{mask:"y.1.2",placeholder:"yyyy.mm.dd",leapday:".02.29",separator:".",alias:"yyyy/mm/dd"},"yyyy-mm-dd":{mask:"y-1-2",placeholder:"yyyy-mm-dd",leapday:"-02-29",separator:"-",alias:"yyyy/mm/dd"},datetime:{mask:"1/2/y h:s",placeholder:"dd/mm/yyyy hh:mm",alias:"dd/mm/yyyy",regex:{hrspre:new RegExp("[012]"),hrs24:new RegExp("2[0-4]|1[3-9]"),hrs:new RegExp("[01][0-9]|2[0-4]"),ampm:new RegExp("^[a|p|A|P][m|M]"),mspre:new RegExp("[0-5]"),ms:new RegExp("[0-5][0-9]")},timeseparator:":",hourFormat:"24",definitions:{h:{validator:function(a,b,c,d,e){if("24"==e.hourFormat&&24==parseInt(a,10))return b.buffer[c-1]="0",b.buffer[c]="0",{refreshFromBuffer:{start:c-1,end:c},c:"0"};var f=e.regex.hrs.test(a);if(!d&&!f&&(a.charAt(1)==e.timeseparator||-1!="-.:".indexOf(a.charAt(1)))&&(f=e.regex.hrs.test("0"+a.charAt(0))))return b.buffer[c-1]="0",b.buffer[c]=a.charAt(0),c++,{refreshFromBuffer:{start:c-2,end:c},pos:c,c:e.timeseparator};if(f&&"24"!==e.hourFormat&&e.regex.hrs24.test(a)){var g=parseInt(a,10);return 24==g?(b.buffer[c+5]="a",b.buffer[c+6]="m"):(b.buffer[c+5]="p",b.buffer[c+6]="m"),g-=12,10>g?(b.buffer[c]=g.toString(),b.buffer[c-1]="0"):(b.buffer[c]=g.toString().charAt(1),b.buffer[c-1]=g.toString().charAt(0)),{refreshFromBuffer:{start:c-1,end:c+6},c:b.buffer[c]}}return f},cardinality:2,prevalidator:[{validator:function(a,b,c,d,e){var f=e.regex.hrspre.test(a);return d||f||!(f=e.regex.hrs.test("0"+a))?f:(b.buffer[c]="0",c++,{pos:c})},cardinality:1}]},s:{validator:"[0-5][0-9]",cardinality:2,prevalidator:[{validator:function(a,b,c,d,e){var f=e.regex.mspre.test(a);return d||f||!(f=e.regex.ms.test("0"+a))?f:(b.buffer[c]="0",c++,{pos:c})},cardinality:1}]},t:{validator:function(a,b,c,d,e){return e.regex.ampm.test(a+"m")},casing:"lower",cardinality:1}},insertMode:!1,autoUnmask:!1},datetime12:{mask:"1/2/y h:s t\\m",placeholder:"dd/mm/yyyy hh:mm xm",alias:"datetime",hourFormat:"12"},"hh:mm t":{mask:"h:s t\\m",placeholder:"hh:mm xm",alias:"datetime",hourFormat:"12"},"h:s t":{mask:"h:s t\\m",placeholder:"hh:mm xm",alias:"datetime",hourFormat:"12"},"hh:mm:ss":{mask:"h:s:s",placeholder:"hh:mm:ss",alias:"datetime",autoUnmask:!1},"hh:mm":{mask:"h:s",placeholder:"hh:mm",alias:"datetime",autoUnmask:!1},date:{alias:"dd/mm/yyyy"},"mm/yyyy":{mask:"1/y",placeholder:"mm/yyyy",leapday:"donotuse",separator:"/",alias:"mm/dd/yyyy"}}),a.fn.inputmask}(jQuery),function(a){a.extend(a.inputmask.defaults.definitions,{A:{validator:"[A-Za-zА-яЁёÀ-ÿµ]",cardinality:1,casing:"upper"},"#":{validator:"[0-9A-Za-zА-яЁёÀ-ÿµ]",cardinality:1,casing:"upper"}}),a.extend(a.inputmask.defaults.aliases,{url:{mask:"ir",placeholder:"",separator:"",defaultPrefix:"http://",regex:{urlpre1:new RegExp("[fh]"),urlpre2:new RegExp("(ft|ht)"),urlpre3:new RegExp("(ftp|htt)"),urlpre4:new RegExp("(ftp:|http|ftps)"),urlpre5:new RegExp("(ftp:/|ftps:|http:|https)"),urlpre6:new RegExp("(ftp://|ftps:/|http:/|https:)"),urlpre7:new RegExp("(ftp://|ftps://|http://|https:/)"),urlpre8:new RegExp("(ftp://|ftps://|http://|https://)")},definitions:{i:{validator:function(){return!0},cardinality:8,prevalidator:function(){for(var a=[],b=0;8>b;b++)a[b]=function(){var a=b;return{validator:function(b,c,d,e,f){if(f.regex["urlpre"+(a+1)]){var g,h=b;a+1-b.length>0&&(h=c.buffer.join("").substring(0,a+1-b.length)+""+h);var i=f.regex["urlpre"+(a+1)].test(h);if(!e&&!i){for(d-=a,g=0;g<f.defaultPrefix.length;g++)c.buffer[d]=f.defaultPrefix[g],d++;for(g=0;g<h.length-1;g++)c.buffer[d]=h[g],d++;return{pos:d}}return i}return!1},cardinality:a}}();return a}()},r:{validator:".",cardinality:50}},insertMode:!1,autoUnmask:!1},ip:{mask:"i[i[i]].i[i[i]].i[i[i]].i[i[i]]",definitions:{i:{validator:function(a,b,c){return c-1>-1&&"."!=b.buffer[c-1]?(a=b.buffer[c-1]+a,a=c-2>-1&&"."!=b.buffer[c-2]?b.buffer[c-2]+a:"0"+a):a="00"+a,new RegExp("25[0-5]|2[0-4][0-9]|[01][0-9][0-9]").test(a)},cardinality:1}}},email:{mask:"*{1,64}[.*{1,64}][.*{1,64}][.*{1,64}]@*{1,64}[.*{2,64}][.*{2,6}][.*{1,2}]",greedy:!1,onBeforePaste:function(a){return a=a.toLowerCase(),a.replace("mailto:","")},definitions:{"*":{validator:"[0-9A-Za-z!#$%&'*+/=?^_`{|}~-]",cardinality:1,casing:"lower"}}}}),a.fn.inputmask}(jQuery),function(a){a.extend(a.inputmask.defaults.aliases,{numeric:{mask:function(a){if(0!==a.repeat&&isNaN(a.integerDigits)&&(a.integerDigits=a.repeat),a.repeat=0,a.groupSeparator==a.radixPoint&&(a.groupSeparator="."==a.radixPoint?",":","==a.radixPoint?".":"")," "===a.groupSeparator&&(a.skipOptionalPartCharacter=void 0),a.autoGroup=a.autoGroup&&""!=a.groupSeparator,a.autoGroup&&isFinite(a.integerDigits)){var b=Math.floor(a.integerDigits/a.groupSize),c=a.integerDigits%a.groupSize;a.integerDigits+=0==c?b-1:b}a.definitions[";"]=a.definitions["~"];var d=a.prefix;return d+="[+]",d+="~{1,"+a.integerDigits+"}",void 0!=a.digits&&(isNaN(a.digits)||parseInt(a.digits)>0)&&(d+=a.digitsOptional?"["+(a.decimalProtect?":":a.radixPoint)+";{"+a.digits+"}]":(a.decimalProtect?":":a.radixPoint)+";{"+a.digits+"}"),d+=a.suffix},placeholder:"",greedy:!1,digits:"*",digitsOptional:!0,groupSeparator:"",radixPoint:".",radixFocus:!0,groupSize:3,autoGroup:!1,allowPlus:!0,allowMinus:!0,integerDigits:"+",prefix:"",suffix:"",rightAlign:!0,decimalProtect:!0,postFormat:function(b,c,d,e){var f=!1,g=b[c];if(""==e.groupSeparator||-1!=a.inArray(e.radixPoint,b)&&c>=a.inArray(e.radixPoint,b)||new RegExp("[-+]").test(g))return{pos:c};var h=b.slice();g==e.groupSeparator&&(h.splice(c--,1),g=h[c]),d?h[c]="?":h.splice(c,0,"?");var i=h.join("");if(e.autoGroup||d&&-1!=i.indexOf(e.groupSeparator)){var j=a.inputmask.escapeRegex.call(this,e.groupSeparator);f=0==i.indexOf(e.groupSeparator),i=i.replace(new RegExp(j,"g"),"");var k=i.split(e.radixPoint);if((i=k[0])!=e.prefix+"?0"&&i.length>=e.groupSize+e.prefix.length){f=!0;for(var l=new RegExp("([-+]?[\\d?]+)([\\d?]{"+e.groupSize+"})");l.test(i);)i=i.replace(l,"$1"+e.groupSeparator+"$2"),i=i.replace(e.groupSeparator+e.groupSeparator,e.groupSeparator)}k.length>1&&(i+=e.radixPoint+k[1])}b.length=i.length;for(var m=0,n=i.length;n>m;m++)b[m]=i.charAt(m);var o=a.inArray("?",b);return d?b[o]=g:b.splice(o,1),{pos:o,refreshFromBuffer:f}},onKeyDown:function(b,c,d,e){if(b.keyCode==a.inputmask.keyCode.TAB&&"0"!=e.placeholder.charAt(0)){var f=a.inArray(e.radixPoint,c);if(-1!=f&&isFinite(e.digits)){for(var g=1;g<=e.digits;g++)(void 0==c[f+g]||c[f+g]==e.placeholder.charAt(0))&&(c[f+g]="0");return{refreshFromBuffer:{start:++f,end:f+e.digits}}}}else if(e.autoGroup&&(b.keyCode==a.inputmask.keyCode.DELETE||b.keyCode==a.inputmask.keyCode.BACKSPACE)){var h=e.postFormat(c,d-1,!0,e);return h.caret=h.pos+1,h}},onKeyPress:function(a,b,c,d){if(d.autoGroup){var e=d.postFormat(b,c-1,!0,d);return e.caret=e.pos+1,e}},regex:{integerPart:function(){return new RegExp("[-+]?\\d+")},integerNPart:function(){return new RegExp("\\d+")}},signHandler:function(a,b,c,d,e){if(!d&&(e.allowMinus&&"-"===a||e.allowPlus&&"+"===a)){var f=b.join("").match(e.regex.integerPart(e));if(f&&f.length>0&&"0"!==f[f.index])return b[f.index]==("-"===a?"+":"-")?{pos:f.index,c:a,remove:f.index,caret:c}:b[f.index]==("-"===a?"-":"+")?{remove:f.index,caret:c-1}:{pos:f.index,c:a,caret:c+1}}return!1},radixHandler:function(b,c,d,e,f){if(!e&&b===f.radixPoint){var g=a.inArray(f.radixPoint,c.buffer),h=c.buffer.join("").match(f.regex.integerPart(f));if(-1!=g)return c.validPositions[g-1]?{caret:g+1}:{pos:h.index,c:h[0],caret:g+1}}return!1},leadingZeroHandler:function(b,c,d,e,f){var g=c.buffer.join("").match(f.regex.integerNPart(f)),h=a.inArray(f.radixPoint,c.buffer);if(g&&!e&&(-1==h||g.index<h))if(0==g[0].indexOf("0")&&d>=f.prefix.length){if(-1==h||h>=d&&void 0==c.validPositions[h])return c.buffer.splice(g.index,1),d=d>g.index?d-1:g.index,{pos:d,remove:g.index};if(d>g.index&&h>=d)return c.buffer.splice(g.index,1),d=d>g.index?d-1:g.index,{pos:d,remove:g.index}}else if("0"==b&&d<=g.index)return!1;return!0},definitions:{"~":{validator:function(b,c,d,e,f){var g=f.signHandler(b,c.buffer,d,e,f);if(!g&&!(g=f.radixHandler(b,c,d,e,f))&&!0===(g=e?new RegExp("[0-9"+a.inputmask.escapeRegex.call(this,f.groupSeparator)+"]").test(b):new RegExp("[0-9]").test(b))&&!0===(g=f.leadingZeroHandler(b,c,d,e,f))){var h=a.inArray(f.radixPoint,c.buffer);!1===f.digitsOptional&&d>h&&!e&&(g={pos:d,remove:d}),g={pos:d}}return g},cardinality:1,prevalidator:null},"+":{validator:function(a,b,c,d,e){var f=e.signHandler(a,b.buffer,c,d,e);return f||(f=e.allowMinus&&"-"==a||e.allowPlus&&"+"==a),f},cardinality:1,prevalidator:null,placeholder:""},":":{validator:function(b,c,d,e,f){var g=f.signHandler(b,c.buffer,d,e,f);if(!g){var h="["+a.inputmask.escapeRegex.call(this,f.radixPoint)+"]";(g=new RegExp(h).test(b))&&c.validPositions[d]&&c.validPositions[d].match.placeholder==f.radixPoint&&(g={pos:d,remove:d})}return g},cardinality:1,prevalidator:null,placeholder:function(a){return a.radixPoint}}},insertMode:!0,autoUnmask:!1,onUnMask:function(b,c,d){var e=b.replace(d.prefix,"");return e=e.replace(d.suffix,""),e=e.replace(new RegExp(a.inputmask.escapeRegex.call(this,d.groupSeparator),"g"),"")},isComplete:function(b,c){var d=b.join(""),e=b.slice();if(c.postFormat(e,0,!0,c),e.join("")!=d)return!1;var f=d.replace(c.prefix,"");return f=f.replace(c.suffix,""),f=f.replace(new RegExp(a.inputmask.escapeRegex.call(this,c.groupSeparator),"g"),""),f=f.replace(a.inputmask.escapeRegex.call(this,c.radixPoint),"."),isFinite(f)},onBeforeMask:function(b,c){if(isFinite(b))return b.toString().replace(".",c.radixPoint);var d=b.match(/,/g),e=b.match(/\./g);return e&&d?e.length>d.length?(b=b.replace(/\./g,""),b=b.replace(",",c.radixPoint)):d.length>e.length&&(b=b.replace(/,/g,""),b=b.replace(".",c.radixPoint)):b=b.replace(new RegExp(a.inputmask.escapeRegex.call(this,c.groupSeparator),"g"),""),b}},currency:{prefix:"$ ",groupSeparator:",",radixPoint:".",alias:"numeric",placeholder:"0",autoGroup:!0,digits:2,digitsOptional:!1,clearMaskOnLostFocus:!1,decimalProtect:!0},decimal:{alias:"numeric"},integer:{alias:"numeric",digits:"0"}}),a.fn.inputmask}(jQuery),function(a){a.extend(a.inputmask.defaults.aliases,{phone:{url:"phone-codes/phone-codes.js",maskInit:"+pp(pp)pppppppp",mask:function(b){b.definitions={p:{validator:function(){return!1},cardinality:1},"#":{validator:"[0-9]",cardinality:1}};var c=[];return a.ajax({url:b.url,async:!1,dataType:"json",success:function(a){c=a}}),c=c.sort(function(a,b){return(a.mask||a)<(b.mask||b)?-1:1}),c.splice(0,0,b.maskInit),c},nojumps:!0,nojumpsThreshold:1},phonebe:{alias:"phone",url:"phone-codes/phone-be.js",maskInit:"+32(pp)pppppppp",nojumpsThreshold:4}}),a.fn.inputmask}(jQuery),function(a){a.extend(a.inputmask.defaults.aliases,{Regex:{mask:"r",greedy:!1,repeat:"*",regex:null,regexTokens:null,tokenizer:/\[\^?]?(?:[^\\\]]+|\\[\S\s]?)*]?|\\(?:0(?:[0-3][0-7]{0,2}|[4-7][0-7]?)?|[1-9][0-9]*|x[0-9A-Fa-f]{2}|u[0-9A-Fa-f]{4}|c[A-Za-z]|[\S\s]?)|\((?:\?[:=!]?)?|(?:[?*+]|\{[0-9]+(?:,[0-9]*)?\})\??|[^.?*+^${[()|\\]+|./g,quantifierFilter:/[0-9]+[^,]/,isComplete:function(a,b){return new RegExp(b.regex).test(a.join(""))},definitions:{r:{validator:function(b,c,d,e,f){function g(a,b){this.matches=[],this.isGroup=a||!1,this.isQuantifier=b||!1,this.quantifier={min:1,max:1},this.repeaterPart=void 0}function h(b,c){var d=!1;c&&(j+="(",l++);for(var e=0;e<b.matches.length;e++){var f=b.matches[e];if(1==f.isGroup)d=h(f,!0);else if(1==f.isQuantifier){var g=a.inArray(f,b.matches),i=b.matches[g-1],k=j;if(isNaN(f.quantifier.max)){for(;f.repeaterPart&&f.repeaterPart!=j&&f.repeaterPart.length>j.length&&!(d=h(i,!0)););d=d||h(i,!0),d&&(f.repeaterPart=j),j=k+f.quantifier.max}else{for(var n=0,o=f.quantifier.max-1;o>n&&!(d=h(i,!0));n++);j=k+"{"+f.quantifier.min+","+f.quantifier.max+"}"}}else if(void 0!=f.matches)for(var p=0;p<f.length&&!(d=h(f[p],c));p++);else{var q;if("["==f.charAt(0)){q=j,q+=f;for(var r=0;l>r;r++)q+=")";var s=new RegExp("^("+q+")$");d=s.test(m)}else for(var t=0,u=f.length;u>t;t++)if("\\"!=f.charAt(t)){q=j,q+=f.substr(0,t+1),q=q.replace(/\|$/,"");for(var r=0;l>r;r++)q+=")";var s=new RegExp("^("+q+")$");if(d=s.test(m))break}j+=f}if(d)break}return c&&(j+=")",l--),d}null==f.regexTokens&&function(){var a,b,c=new g,d=[];for(f.regexTokens=[];a=f.tokenizer.exec(f.regex);)switch(b=a[0],b.charAt(0)){case"(":d.push(new g(!0));break;case")":var e=d.pop();d.length>0?d[d.length-1].matches.push(e):c.matches.push(e);break;case"{":case"+":case"*":var h=new g(!1,!0);b=b.replace(/[{}]/g,"");var i=b.split(","),j=isNaN(i[0])?i[0]:parseInt(i[0]),k=1==i.length?j:isNaN(i[1])?i[1]:parseInt(i[1]);if(h.quantifier={min:j,max:k},d.length>0){var l=d[d.length-1].matches;if(a=l.pop(),!a.isGroup){var e=new g(!0);e.matches.push(a),a=e}l.push(a),l.push(h)}else{if(a=c.matches.pop(),!a.isGroup){var e=new g(!0);e.matches.push(a),a=e}c.matches.push(a),c.matches.push(h)}break;default:d.length>0?d[d.length-1].matches.push(b):c.matches.push(b)}c.matches.length>0&&f.regexTokens.push(c)}();var i=c.buffer.slice(),j="",k=!1,l=0;i.splice(d,0,b);for(var m=i.join(""),n=0;n<f.regexTokens.length;n++){var g=f.regexTokens[n];if(k=h(g,g.isGroup))break}return k},cardinality:1}}}}),a.fn.inputmask}(jQuery),jQuery(document).ready(function(a){jQuery(document).on("cf.add",function(){a("[data-inputmask]").inputmask()}),jQuery(document).trigger("cf.add")}),function(a){"function"==typeof define&&define.amd?define(["jquery"],a):a("object"==typeof exports?require("jquery"):jQuery)}(function(a){function b(a,b){var c=Array.prototype.slice.call(arguments,2);return setTimeout(function(){return a.apply(null,c)},b)}function c(a,b){return b=b||100,function(){if(!a.debouncing){var c=Array.prototype.slice.apply(arguments);a.lastReturnVal=a.apply(window,c),a.debouncing=!0}return clearTimeout(a.debounceTimeout),a.debounceTimeout=setTimeout(function(){a.debouncing=!1},b),a.lastReturnVal}}function d(d,f){if(this.$window=a(window),this.$document=a(document),this.$element=a(d),this.options=a.extend({},h,f),this._defaults=h,this._name=e,this.startEvent=this.options.startEvent.join("."+e+" ")+"."+e,this.moveEvent=this.options.moveEvent.join("."+e+" ")+"."+e,this.endEvent=this.options.endEvent.join("."+e+" ")+"."+e,this.polyfill=this.options.polyfill,this.onInit=this.options.onInit,this.onSlide=this.options.onSlide,this.onSlideEnd=this.options.onSlideEnd,this.polyfill&&g)return!1;this.identifier="js-"+e+"-"+ +new Date,this.min=parseFloat(this.$element[0].getAttribute("min")||0),this.max=parseFloat(this.$element[0].getAttribute("max")||100),this.value=parseFloat(this.$element[0].value||this.min+(this.max-this.min)/2),this.step=parseFloat(this.$element[0].getAttribute("step")||1),this.$fill=a('<div class="'+this.options.fillClass+'" />'),this.$handle=a('<div class="'+this.options.handleClass+'" />'),this.$range=a('<div class="'+this.options.rangeClass+'" id="'+this.identifier+'" />').insertAfter(this.$element).prepend(this.$fill,this.$handle),this.$element.css({position:"absolute",width:"1px",height:"1px",overflow:"hidden",opacity:"0"}),this.handleDown=a.proxy(this.handleDown,this),this.handleMove=a.proxy(this.handleMove,this),this.handleEnd=a.proxy(this.handleEnd,this),this.init();var i=this;this.$window.on("resize."+e,c(function(){b(function(){i.update()},300)},20)),this.$document.on(this.startEvent,"#"+this.identifier+":not(."+this.options.disabledClass+")",this.handleDown),this.$element.on("change."+e,function(a,b){if(!b||b.origin!==e){var c=a.target.value,d=i.getPositionFromValue(c);i.setPosition(d)}})}var e="rangeslider",f=[],g=function(){var a=document.createElement("input");return a.setAttribute("type","range"),"text"!==a.type}(),h={polyfill:!0,rangeClass:"rangeslider",disabledClass:"rangeslider--disabled",fillClass:"rangeslider__fill",handleClass:"rangeslider__handle",startEvent:["mousedown","touchstart","pointerdown"],moveEvent:["mousemove","touchmove","pointermove"],endEvent:["mouseup","touchend","pointerup"]};d.prototype.init=function(){this.onInit&&"function"==typeof this.onInit&&this.onInit(),this.update()},d.prototype.update=function(){this.handleWidth=this.$handle[0].offsetWidth,this.rangeWidth=this.$range[0].offsetWidth,this.maxHandleX=this.rangeWidth-this.handleWidth,this.grabX=this.handleWidth/2,this.position=this.getPositionFromValue(this.value),this.$element[0].disabled?this.$range.addClass(this.options.disabledClass):this.$range.removeClass(this.options.disabledClass),this.setPosition(this.position)},d.prototype.handleDown=function(a){if(a.preventDefault(),this.$document.on(this.moveEvent,this.handleMove),this.$document.on(this.endEvent,this.handleEnd),!((" "+a.target.className+" ").replace(/[\n\t]/g," ").indexOf(this.options.handleClass)>-1)){var b=this.getRelativePosition(this.$range[0],a),c=this.getPositionFromNode(this.$handle[0])-this.getPositionFromNode(this.$range[0]);this.setPosition(b-this.grabX),b>=c&&b<c+this.handleWidth&&(this.grabX=b-c)}},d.prototype.handleMove=function(a){a.preventDefault();var b=this.getRelativePosition(this.$range[0],a);this.setPosition(b-this.grabX)},d.prototype.handleEnd=function(a){a.preventDefault(),this.$document.off(this.moveEvent,this.handleMove),this.$document.off(this.endEvent,this.handleEnd);var b=this.getRelativePosition(this.$range[0],a);this.onSlideEnd&&"function"==typeof this.onSlideEnd&&this.onSlideEnd(b-this.grabX,this.value)},d.prototype.cap=function(a,b,c){return a<b?b:a>c?c:a},d.prototype.setPosition=function(a){var b,c;b=this.getValueFromPosition(this.cap(a,0,this.maxHandleX))/this.step*this.step,c=this.getPositionFromValue(b),this.$fill[0].style.width=c+this.grabX+"px",this.$handle[0].style.left=c+"px",this.setValue(b),this.position=c,this.value=b,this.onSlide&&"function"==typeof this.onSlide&&this.onSlide(c,b)},d.prototype.getPositionFromNode=function(a){for(var b=0;null!==a;)b+=a.offsetLeft,a=a.offsetParent;return b},d.prototype.getRelativePosition=function(a,b){return(b.pageX||b.originalEvent.clientX||b.originalEvent.touches[0].clientX||b.currentPoint.x)-this.getPositionFromNode(a)},d.prototype.getPositionFromValue=function(a){var b;return b=(a-this.min)/(this.max-this.min),b*this.maxHandleX},d.prototype.getValueFromPosition=function(a){var b,c;return b=a/(this.maxHandleX||1),c=this.step*Math.ceil((b*(this.max-this.min)+this.min)/this.step),Number(c.toFixed(2))},d.prototype.setValue=function(a){a!==this.value&&this.$element.val(a).trigger("change",{origin:e})},d.prototype.destroy=function(){this.$document.off(this.startEvent,"#"+this.identifier,this.handleDown),this.$element.off("."+e).removeAttr("style").removeData("plugin_"+e),this.$range&&this.$range.length&&this.$range[0].parentNode.removeChild(this.$range[0]),f.splice(f.indexOf(this.$element[0]),1),f.length||this.$window.off("."+e)},a.fn[e]=function(b){return this.each(function(){var c=a(this),g=c.data("plugin_"+e);g||(c.data("plugin_"+e,g=new d(this,b)),f.push(this)),"string"==typeof b&&g[b]()})}}),function(a){"use strict";var b={init:function(c){return this.each(function(){this.self=a(this),b.destroy.call(this.self),this.opt=a.extend(!0,{},a.fn.raty.defaults,c),b._adjustCallback.call(this),b._adjustNumber.call(this),"img"!==this.opt.starType&&b._adjustStarType.call(this),b._adjustPath.call(this),b._createStars.call(this),this.opt.cancel&&b._createCancel.call(this),this.opt.precision&&b._adjustPrecision.call(this),b._createScore.call(this),b._apply.call(this,this.opt.score),b._target.call(this,this.opt.score),this.opt.readOnly?b._lock.call(this):(this.style.cursor="pointer",b._binds.call(this)),this.self.data("options",this.opt)})},_adjustCallback:function(){for(var a=["number","readOnly","score","scoreName"],b=0;b<a.length;b++)"function"==typeof this.opt[a[b]]&&(this.opt[a[b]]=this.opt[a[b]].call(this))},_adjustNumber:function(){this.opt.number=b._between(this.opt.number,1,this.opt.numberMax)},_adjustPath:function(){this.opt.path=this.opt.path||"",this.opt.path&&"/"!==this.opt.path.charAt(this.opt.path.length-1)&&(this.opt.path+="/")},_adjustPrecision:function(){this.opt.half=!0,this.opt.targetType="score"},_adjustStarType:function(){this.opt.path="";for(var a=["cancelOff","cancelOn","starHalf","starOff","starOn"],b=0;b<a.length;b++)this.opt[a[b]]=this.opt[a[b]].replace(".","-")},_apply:function(a){b._fill.call(this,a),a&&(a>0&&this.score.val(b._between(a,0,this.opt.number)),b._roundStars.call(this,a))},
4
+ _between:function(a,b,c){return Math.min(Math.max(parseFloat(a),b),c)},_binds:function(){this.cancel&&(b._bindOverCancel.call(this),b._bindClickCancel.call(this),b._bindOutCancel.call(this)),b._bindOver.call(this),b._bindClick.call(this),b._bindOut.call(this)},_bindClick:function(){var b=this;b.stars.on("click.raty",function(c){var d=a(this);b.score.val(b.opt.half||b.opt.precision?b.self.data("score"):this.alt||d.data("alt")),b.opt.click&&b.opt.click.call(b,+b.score.val(),c)})},_bindClickCancel:function(){var a=this;a.cancel.on("click.raty",function(b){a.score.removeAttr("value"),a.opt.click&&a.opt.click.call(a,null,b)})},_bindOut:function(){var a=this;a.self.on("mouseleave.raty",function(c){var d=+a.score.val()||void 0;b._apply.call(a,d),b._target.call(a,d,c),a.opt.mouseout&&a.opt.mouseout.call(a,d,c)})},_bindOutCancel:function(){var b=this;b.cancel.on("mouseleave.raty",function(c){var d=a(this),e=b.opt.path+b.opt.cancelOff;if("img"===b.opt.starType)d.attr("src",e);else{var f=b.opt.path+b.opt.cancelOn;d.removeClass(f).addClass(e)}if(b.opt.mouseout){var g=+b.score.val()||void 0;b.opt.mouseout.call(b,g,c)}})},_bindOver:function(){var a=this,c=a.opt.half?"mousemove.raty":"mouseover.raty";a.stars.on(c,function(c){var d=b._getScoreByPosition.call(a,c,this);b._fill.call(a,d),a.opt.half&&(b._roundStars.call(a,d),a.self.data("score",d)),b._target.call(a,d,c),a.opt.mouseover&&a.opt.mouseover.call(a,d,c)})},_bindOverCancel:function(){var c=this;c.cancel.on("mouseover.raty",function(d){var e=c.opt.path+c.opt.cancelOn,f=a(this),g=c.opt.path+c.opt.starOff;if("img"===c.opt.starType)f.attr("src",e),c.stars.attr("src",g);else{c.stars.attr("class",g);var h=c.opt.path+c.opt.cancelOff;f.removeClass(h).addClass(e).css("color",c.opt.starColor)}b._target.call(c,null,d),c.opt.mouseover&&c.opt.mouseover.call(c,null)})},_buildScoreField:function(){return a("<input />",{name:this.opt.scoreName,type:"hidden"}).appendTo(this)},_createCancel:function(){var b=this.opt.path+this.opt.cancelOff,c=a("<"+this.opt.starType+" />",{title:this.opt.cancelHint,class:"raty-cancel"}).css("marginRight",this.opt.space?this.opt.spaceWidth+"px":"0");"img"===this.opt.starType?c.attr({src:b,alt:"x"}):c.attr("data-alt","x").addClass(b),"left"===this.opt.cancelPlace?this.self.prepend("&#160;").prepend(c):this.self.append("&#160;").append(c),this.cancel=c},_createScore:function(){var c=a(this.opt.targetScore);this.score=c.length?c:b._buildScoreField.call(this)},_createStars:function(){for(var c=1;c<=this.opt.number;c++){var d,e=this.opt.score&&this.opt.score>=c?"starOn":"starOff",f=b._getHint.call(this,c);e=this.opt.path+this.opt[e],d="img"!==this.opt.starType?{"data-alt":c,class:e}:{src:e,alt:c},d.title=f,a("<"+this.opt.starType+" />",d).css("marginRight",c<this.opt.number&&this.opt.space?this.opt.spaceWidth+"px":"0").appendTo(this),this.opt.space}this.stars=this.self.children(this.opt.starType)},_error:function(b){a(this).text(b),a.error(b)},_fill:function(a){for(var c=0,d=1;d<=this.stars.length;d++){var e,f=this.stars.eq(d-1),g=b._turnOn.call(this,d,a);if(this.opt.iconRange&&this.opt.iconRange.length>c){var h=this.opt.iconRange[c];e=b._getIconRange.call(this,h,g),d<=h.range&&("img"===this.opt.starType?f.attr("src",e):f.attr("class",e)),d===h.range&&c++}else e=this.opt.path+this.opt[g?"starOn":"starOff"],"img"===this.opt.starType?f.attr("src",e):f.attr("class",e),g?f.css("color",this.opt.starColor):f.css("color","")}},_getIconRange:function(a,b){return this.opt.path+(b?a.on||this.opt.starOn:a.off||this.opt.starOff)},_getScoreByPosition:function(c,d){var e=a(d),f=parseInt(d.alt||e.data("alt"),10);if(this.opt.half){var g=b._getSize.call(this),h=parseFloat((c.pageX-e.offset().left)/g);f=this.opt.precision?f-1+h:f-1+(h>.5?1:.5)}return f},_getSize:function(){var a;return a="img"===this.opt.starType?this.stars[0].width:parseFloat(this.stars.eq(0).css("font-size")),a||b._error.call(this,"Could not be possible get the icon size!"),a},_turnOn:function(a,b){return this.opt.single?a===b:a<=b},_getHint:function(a){var b=this.opt.hints[a-1];return""===b?"":b||a},_lock:function(){var a=parseInt(this.score.val(),10),c=a?b._getHint.call(this,a):this.opt.noRatedMsg;this.style.cursor="",this.title=c,this.score.prop("readonly",!0),this.stars.prop("title",c),this.cancel&&this.cancel.hide(),this.self.data("readonly",!0)},_roundStars:function(a){var b=(a%1).toFixed(2);if(b>this.opt.round.down){var c="starOn";this.opt.halfShow&&b<this.opt.round.up?c="starHalf":b<this.opt.round.full&&(c="starOff");var d=this.stars[Math.ceil(a)-1];"img"===this.opt.starType?d.src=this.opt.path+this.opt[c]:d.style.className=this.opt[c]}},_target:function(c,d){if(this.opt.target){var e=a(this.opt.target);e.length||b._error.call(this,"Target selector invalid or missing!");var f=d&&"mouseover"===d.type;if(void 0===c)c=this.opt.targetText;else if(null===c)c=f?this.opt.cancelHint:this.opt.targetText;else{"hint"===this.opt.targetType?c=b._getHint.call(this,Math.ceil(c)):this.opt.precision&&(c=parseFloat(c).toFixed(1));var g=d&&"mousemove"===d.type;f||g||this.opt.targetKeep||(c=this.opt.targetText)}c&&(c=this.opt.targetFormat.toString().replace("{score}",c)),e.is(":input")?e.val(c):e.html(c)}},_unlock:function(){this.style.cursor="pointer",this.removeAttribute("title"),this.score.removeAttr("readonly"),this.self.data("readonly",!1);for(var a=0;a<this.opt.number;a++)this.stars[a].title=b._getHint.call(this,a+1);this.cancel&&this.cancel.css("display","")},cancel:function(c){return this.each(function(){var d=a(this);!0!==d.data("readonly")&&(b[c?"click":"score"].call(d,null),this.score.removeAttr("value"))})},click:function(c){return this.each(function(){!0!==a(this).data("readonly")&&(b._apply.call(this,c),this.opt.click&&this.opt.click.call(this,c,a.Event("click")),b._target.call(this,c))})},destroy:function(){return this.each(function(){var b=a(this),c=b.data("raw");c?b.off(".raty").empty().css({cursor:c.style.cursor}).removeData("readonly"):b.data("raw",b.clone()[0])})},getScore:function(){var a,b=[];return this.each(function(){a=this.score.val(),b.push(a?+a:void 0)}),b.length>1?b:b[0]},move:function(c){return this.each(function(){var d=parseInt(c,10),e=a(this).data("options"),f=(+c).toFixed(1).split(".")[1];d>=e.number&&(d=e.number-1,f=10);var g=b._getSize.call(this),h=g/10,i=a(this.stars[d]),j=i.offset().left+h*parseInt(f,10),k=a.Event("mousemove",{pageX:j});i.trigger(k)})},readOnly:function(c){return this.each(function(){var d=a(this);d.data("readonly")!==c&&(c?(d.off(".raty").children("img").off(".raty"),b._lock.call(this)):(b._binds.call(this),b._unlock.call(this)),d.data("readonly",c))})},reload:function(){return b.set.call(this,{})},score:function(){var c=a(this);return arguments.length?b.setScore.apply(c,arguments):b.getScore.call(c)},set:function(b){return this.each(function(){var c=a(this),d=c.data("options"),e=a.extend({},d,b);c.raty(e)})},setScore:function(c){return this.each(function(){!0!==a(this).data("readonly")&&(b._apply.call(this,c),b._target.call(this,c))})}};a.fn.raty=function(c){return b[c]?b[c].apply(this,Array.prototype.slice.call(arguments,1)):"object"!=typeof c&&c?void a.error("Method "+c+" does not exist!"):b.init.apply(this,arguments)},a.fn.raty.defaults={cancel:!1,cancelHint:"Cancel this rating!",cancelOff:"raty-cancel-off",cancelOn:"raty-cancel-on",cancelPlace:"left",click:void 0,half:!1,halfShow:!0,hints:["1"],iconRange:void 0,mouseout:void 0,mouseover:void 0,noRatedMsg:"Not rated yet!",number:5,numberMax:20,path:void 0,precision:!1,readOnly:!1,round:{down:.25,full:.6,up:.76},score:void 0,scoreName:"score",single:!1,space:!0,spaceWidth:3,starColor:"#ff00aa",starHalf:"star-half.png",starOff:"raty-dot-off",starOn:"raty-dot-on",starType:"img",target:void 0,targetFormat:"{score}",targetKeep:!1,targetScore:void 0,targetText:"",targetType:"hint"}}(jQuery),jQuery(function(a){a("body").on("click",".cf-toggle-group-buttons a",function(){var b=a(this),c=b.closest(".caldera-config-field"),d=c.find('[data-ref="'+b.attr("id")+'"]');c.find(".btn").removeClass(b.data("active")).addClass(b.data("default")),b.addClass(b.data("active")).removeClass(b.data("default")),d.prop("checked",!0).trigger("change")})});
assets/build/js/formobject.min.js CHANGED
@@ -1 +1 @@
1
- !function(a){function b(b){if(b.data("form")){var c="/cf-api/"+b.data("form")+"/";b.data("entry")&&(c+=b.data("entry")+"/"),c+="?cf_instance="+(a(".caldera_forms_form."+b.data("form")).length+1),b.data("width")?b.css({width:b.data("width")}):b.css({width:!1}),a.get(c,function(c){a("#modal-"+b.data("form")+"-content").html(c),resBaldrickTriggers(),"undefined"!=typeof caldera_conditionals&&calders_forms_init_conditions()})}}if(a.fn.formJSON=function(){for(var b=a(this),c=b.find("[name]"),d={},e={},f=0;f<c.length;f++){var g=a(c[f]),h=g.prop("name").replace(/\]/gi,"").split("["),i=g.val(),j={};if(!g.is(":radio")&&!g.is(":checkbox")||g.is(":checked")){for(var k=h.length-1;k>=0;k--){var l=h[k];if("undefined"==typeof l&&(l=""),0===l.length&&(j=[],"undefined"==typeof e[h[k-1]]?e[h[k-1]]=0:e[h[k-1]]+=1,l=e[h[k-1]]),k===h.length-1){if(i)if("true"===i)i=!0;else if("false"===i)i=!1;else if(isNaN(parseFloat(i))||parseFloat(i).toString()!==i)if("string"!=typeof i||"{"!==i.substr(0,1)&&"["!==i.substr(0,1)){if("object"==typeof i&&i.length&&g.is("select")){for(var m={},k=0;k<i.length;k++)m["n"+k]=i[k];i=m}}else try{i=JSON.parse(i)}catch(a){}else i=parseFloat(i);j[l]=i}else{var n=j;j={},j[l]=n}}a.extend(!0,d,j)}}return d},a(".caldera_forms_form").on("click",".cf-form-trigger",function(b){var c=a(this);form=c.closest("form.caldera_forms_form"),form_id=form.prop("id"),calderaforms=window[form_id],data=form.formJSON(),fields={},target=c.data("target");for(var d in calderaforms)fields[calderaforms[d].slug]=data[d];if("function"==typeof window[target])window[target](fields,b);else{try{var e=a(target)}catch(a){}if(e&&e.length){fields=JSON.stringify(fields);var f=["textarea","text","hidden"];e.each(function(b,c){this.type&&f.indexOf(this.type)>=0?a(this).val(fields).trigger("change"):this.innerHTML=fields})}else a.post(target,fields)}}),cfModals){var c=a("head"),d=a("body");for(var e in cfModals.style)a("#cf-"+e+"-styles-css").length||c.append('<link id="cf-'+e+'-styles-css" rel="stylesheet" type="text/css" href="'+cfModals.style[e]+'">');for(var f in cfModals.script)a('script[src^="'+cfModals.script[f]+'"]').length||null===cfModals.script[f]||d.append('<script src="'+cfModals.script[f]+'" type="text/javascript">');a(".caldera-forms-modal").each(function(){var c=a(this),d=c.data("form"),e="";c.data("entry")&&(e+='data-entry="'+c.data("entry")+'"'),c.data("width")&&(e+='data-width="'+c.data("width")+'"'),a("body").append('<div class="remodal" data-form="'+d+'" '+e+' data-remodal-id="modal-'+d+'" id="modal-'+d+'"><button data-remodal-action="close" class="remodal-close"></button><div class="modal-content" id="modal-'+d+'-content"><span class="caldera-grid cf_processing cf_modal"></span></div></div>'),b(a("#modal-"+d))}),a(document).on("opened",".remodal",function(){a(document).trigger("cf.modal",a(this))}),a(document).on("cf.submission",function(c,d){setTimeout(function(){var c=a('[data-remodal-id="modal-'+d.data.form_id+'"]').remodal();b(c.$modal),"opened"===c.getState()&&c.close()},1500)})}}(jQuery);
1
+ !function(a){function b(b){if(b.data("form")){var c="/cf-api/"+b.data("form")+"/";b.data("entry")&&(c+=b.data("entry")+"/"),c+="?cf_instance="+(a(".caldera_forms_form."+b.data("form")).length+1),b.data("width")?b.css({width:b.data("width")}):b.css({width:!1}),a.get(c,function(c){a("#modal-"+b.data("form")+"-content").html(c),resBaldrickTriggers(),"undefined"!=typeof caldera_conditionals&&calders_forms_init_conditions()})}}if(a.fn.formJSON=function(){for(var b=a(this),c=b.find("[name]"),d={},e={},f=0;f<c.length;f++){var g=a(c[f]),h=g.prop("name").replace(/\]/gi,"").split("["),i=g.val(),j={};if(!g.is(":radio")&&!g.is(":checkbox")||g.is(":checked")){for(var k=h.length-1;k>=0;k--){var l=h[k];if(void 0===l&&(l=""),0===l.length&&(j=[],void 0===e[h[k-1]]?e[h[k-1]]=0:e[h[k-1]]+=1,l=e[h[k-1]]),k===h.length-1){if(i)if("true"===i)i=!0;else if("false"===i)i=!1;else if(isNaN(parseFloat(i))||parseFloat(i).toString()!==i)if("string"!=typeof i||"{"!==i.substr(0,1)&&"["!==i.substr(0,1)){if("object"==typeof i&&i.length&&g.is("select")){for(var m={},k=0;k<i.length;k++)m["n"+k]=i[k];i=m}}else try{i=JSON.parse(i)}catch(a){}else i=parseFloat(i);j[l]=i}else{var n=j;j={},j[l]=n}}a.extend(!0,d,j)}}return d},a(".caldera_forms_form").on("click",".cf-form-trigger",function(b){var c=a(this);form=c.closest("form.caldera_forms_form"),form_id=form.prop("id"),calderaforms=window[form_id],data=form.formJSON(),fields={},target=c.data("target");for(var d in calderaforms)fields[calderaforms[d].slug]=data[d];if("function"==typeof window[target])window[target](fields,b);else{try{var e=a(target)}catch(a){}if(e&&e.length){fields=JSON.stringify(fields);var f=["textarea","text","hidden"];e.each(function(b,c){this.type&&f.indexOf(this.type)>=0?a(this).val(fields).trigger("change"):this.innerHTML=fields})}else a.post(target,fields)}}),cfModals){var c=a("head"),d=a("body");for(var e in cfModals.style)a("#cf-"+e+"-styles-css").length||c.append('<link id="cf-'+e+'-styles-css" rel="stylesheet" type="text/css" href="'+cfModals.style[e]+'">');for(var f in cfModals.script)a('script[src^="'+cfModals.script[f]+'"]').length||null===cfModals.script[f]||d.append('<script src="'+cfModals.script[f]+'" type="text/javascript">');a(".caldera-forms-modal").each(function(){var c=a(this),d=c.data("form"),e="";c.data("entry")&&(e+='data-entry="'+c.data("entry")+'"'),c.data("width")&&(e+='data-width="'+c.data("width")+'"'),a("body").append('<div class="remodal" data-form="'+d+'" '+e+' data-remodal-id="modal-'+d+'" id="modal-'+d+'"><button data-remodal-action="close" class="remodal-close"></button><div class="modal-content" id="modal-'+d+'-content"><span class="caldera-grid cf_processing cf_modal"></span></div></div>'),b(a("#modal-"+d))}),a(document).on("opened",".remodal",function(){a(document).trigger("cf.modal",a(this))}),a(document).on("cf.submission",function(c,d){setTimeout(function(){var c=a('[data-remodal-id="modal-'+d.data.form_id+'"]').remodal();b(c.$modal),"opened"===c.getState()&&c.close()},1500)})}}(jQuery);
assets/build/js/frontend-script-init.min.js CHANGED
@@ -1 +1 @@
1
- function CalderaFormsFieldSync(a,b,c,d){for(var e=0;e<b.length;e++)d(document).on("keyup change blur mouseover","[data-field='"+b[e]+"']",function(){var b=a.data("sync");if(id=a.data("field"),reg=new RegExp("{{([^}]*?)}}","g"),template=b.match(reg),!a.data("unsync")&&void 0!=template&&template.length){for(var e=0;e<template.length;e++){for(var f=template[e].replace(/\}/g,"").replace(/\{/g,""),g=new RegExp(template[e],"g"),h=c.find("[data-field='"+f+"']"),i="",j=0;j<h.length;j++){var k=d(h[j]);(!k.is(":radio")&&!k.is(":checkbox")||k.is(":checked"))&&(i+=k.val())}b=b.replace(g,i)}a.val(b)}}),d("[data-field='"+b[e]+"']").trigger("change")}function CalderaFormsResetNonce(a,b,c){function d(a){var b=(new Date).getTime();return b-36e3>a}function e(){c.ajax({url:b.rest.tokens.nonce,method:"POST",beforeSend:function(a){a.setRequestHeader("X-WP-Nonce",b.rest.nonce)},data:{form_id:a}}).success(function(a){f.val(a.nonce),f.data("nonce-time",(new Date).getTime())})}var f;this.init=function(){f=c("#"+b.nonce.field+"_"+a),d(f.data("nonce-time"))&&e()}}var cf_jsfields_init,cf_presubmit;!function(a){cf_validate_form=function(a){return a.parsley({errorsWrapper:'<span class="help-block caldera_ajax_error_block"></span>',errorTemplate:"<span></span>",errorsContainer:function(a){return a.$element.closest(".form-group")}}).on("field:error",function(){this.$element.closest(".form-group").addClass("has-error")}).on("field:success",function(){this.$element.closest(".form-group").removeClass("has-error")})},a("[data-sync]").each(function(){var b=a(this);new CalderaFormsFieldSync(b,b.data("binds"),b.closest("form"),a)}),a(document).on("change keypress","[data-sync]",function(){a(this).data("unsync",!0)}),cf_jsfields_init=function(){a(".init_field_type[data-type]").each(function(b,c){var d=a(c);"function"==typeof window[d.data("type")+"_init"]&&window[d.data("type")+"_init"](d.prop("id"),d[0])}),window.Parsley.on("field:validated",function(){setTimeout(function(){a(document).trigger("cf.error")},15)}),"undefined"==typeof resBaldrickTriggers&&a(".caldera_forms_form").length,a(document).trigger("cf.fieldsInit")},a("document").ready(function(){cf_jsfields_init()}),a(".caldera-form-page").length&&a(".caldera-form-page").on("keypress","[data-field]:not(textarea)",function(a){13===a.keyCode&&a.preventDefault()}),a(document).on("click",".cf_modal_button",function(b){b.preventDefault();var c=a(this);a(c.attr("href")).show()}),a(document).on("click",".caldera-front-modal-closer",function(b){b.preventDefault();var c=a(this);c.closest(".caldera-front-modal-container").hide()}),a(document).on("cf.add cf.enable cf.disable cf.pagenav",cf_jsfields_init),a(document).on("click","[data-page]",function(b){var c,d,e,f=a(this),g=f.closest(".caldera-form-page"),h=f.closest("form.caldera_forms_form"),i=h.data("instance"),j=h.find(".caldera-form-page:visible").data("formpage"),k=g.data("formpage")?g.data("formpage"):f.data("page"),l=a('.breadcrumb[data-form="caldera_form_'+i+'"]'),m=!0,n={};if(h.length){if(cf_validate_form(h).destroy(),e=h.find("[data-field]"),h.find(".has-error").removeClass("has-error"),"prev"!==f.data("page")&&k>=j)for(var o=0;o<e.length;o++){var p=a(e[o]);if(p.is(":radio,:checkbox")){if(!p.hasClass("option-required")||!1===p.is(":visible"))continue;n[p.data("field")]||(n[p.data("field")]=[]),n[p.data("field")].push(p.prop("checked"))}else{if(p.prop("required")&&!1===p.is(":visible"))continue;if(p.prop("required")&&!0!==p.parsley().isValid()){if(p.is(":visible"))p.parsley().validate(),b.preventDefault();else{var q=parseFloat(p.closest(".caldera-form-page[data-formpage]").data("formpage"));q<parseFloat(k)&&h.find('[data-page="'+q+'"]').addClass("has-error")}m=!1}}}for(var r in n)n[r].indexOf(!0)<0?(a('[for="'+r+"_"+i+'"]').parent().addClass("has-error"),m=!1):a('[for="'+r+"_"+i+'"]').parent().removeClass("has-error");if(!1===m)return cf_validate_form(h).validate(),!1;"next"===f.data("page")?(l&&l.find("li.active").removeClass("active").children().attr("aria-expanded","false"),c=h.find('.caldera-form-page[data-formpage="'+(k+1)+'"]'),c.length&&(g.hide().attr("aria-hidden","true").css("visibility","hidden"),c.show().attr("aria-hidden","false").css("visibility","visible"),l&&l.find('a[data-page="'+(k+1)+'"]').attr("aria-expanded","true").parent().addClass("active"))):"prev"===f.data("page")?(l&&l.find("li.active").removeClass("active").children().attr("aria-expanded","false"),d=h.find('.caldera-form-page[data-formpage="'+(k-1)+'"]'),d.length&&(g.hide().attr("aria-hidden","true").css("visibility","hidden"),d.show().attr("aria-hidden","false").css("visibility","visible"),l&&l.find('a[data-page="'+(k-1)+'"]').attr("aria-expanded","true").parent().addClass("active"))):f.data("pagenav")&&(b.preventDefault(),f.closest(".breadcrumb").find("li.active").removeClass("active").children().attr("aria-expanded","false"),a("#"+f.data("pagenav")+" .caldera-form-page").hide().attr("aria-hidden","true").css("visibility","hidden"),a("#"+f.data("pagenav")+'\t.caldera-form-page[data-formpage="'+f.data("page")+'"]').show().attr("aria-hidden","false").css("visibility","visible"),f.parent().addClass("active").children().attr("aria-expanded","true")),a("html, body").animate({scrollTop:h.offset().top-100},200),a(document).trigger("cf.pagenav")}});var b;a(".caldera-grid .breadcrumb").each(function(c,d){a(d).find("a[data-pagenav]").each(function(c,d){var e=a(d),f=e.data("pagenav"),g=a("#"+f+' .caldera-form-page[data-formpage="'+e.data("page")+'"]');g.find(".has-error").length&&(e.parent().addClass("error"),"undefined"==typeof b&&(e.trigger("click"),b=!0))})}),a(document).on("click",'form.caldera_forms_form [type="submit"]',function(b){var c=a(this),d=c.closest(".caldera_forms_form"),e=cf_validate_form(d);e.validate()?e.destroy():b.preventDefault()})}(jQuery),window.addEventListener("load",function(){!function(a){"use strict";if("object"==typeof CF_API_DATA){var b,c={};a(".caldera_forms_form").each(function(d,e){b=a(e).data("form-id"),c[b]=new CalderaFormsResetNonce(b,CF_API_DATA,a),c[b].init()})}if("object"==typeof CFFIELD_CONFIG){var d,e,f,g,h;a(".caldera_forms_form").each(function(b,c){h=a(c),d=h.attr("id"),g=h.data("instance"),"object"==typeof CFFIELD_CONFIG[g]&&(f=CFFIELD_CONFIG[g],e=new Caldera_Forms_Field_Config(f,a(document.getElementById(d)),a),e.init())})}}(jQuery)});
1
+ function CalderaFormsFieldSync(a,b,c,d){for(var e=0;e<b.length;e++)d(document).on("keyup change blur mouseover","[data-field='"+b[e]+"']",function(){var b=a.data("sync");if(id=a.data("field"),reg=new RegExp("{{([^}]*?)}}","g"),template=b.match(reg),!a.data("unsync")&&void 0!=template&&template.length){for(var e=0;e<template.length;e++){for(var f=template[e].replace(/\}/g,"").replace(/\{/g,""),g=new RegExp(template[e],"g"),h=c.find("[data-field='"+f+"']"),i="",j=0;j<h.length;j++){var k=d(h[j]);(!k.is(":radio")&&!k.is(":checkbox")||k.is(":checked"))&&(i+=k.val())}b=b.replace(g,i)}a.val(b)}}),d("[data-field='"+b[e]+"']").trigger("change")}function CalderaFormsResetNonce(a,b,c){function d(a){return(new Date).getTime()-36e3>a}function e(){c.ajax({url:b.rest.tokens.nonce,method:"POST",beforeSend:function(a){a.setRequestHeader("X-WP-Nonce",b.rest.nonce)},data:{form_id:a}}).success(function(a){f.val(a.nonce),f.data("nonce-time",(new Date).getTime())})}var f;this.init=function(){f=c("#"+b.nonce.field+"_"+a),d(f.data("nonce-time"))&&e()}}var cf_jsfields_init,cf_presubmit;!function(a){cf_validate_form=function(a){return a.parsley({errorsWrapper:'<span class="help-block caldera_ajax_error_block"></span>',errorTemplate:"<span></span>",errorsContainer:function(a){return a.$element.closest(".form-group")}}).on("field:error",function(a){if("number"==this.$element.attr("type")&&0==this.$element.attr("min")){var b=this.$element.val();return void(0<=b&&(void 0==this.$element.attr("max")||b<=this.$element.attr("max"))&&(a.validationResult=!0))}this.$element.closest(".form-group").addClass("has-error")}).on("field:success",function(){this.$element.closest(".form-group").removeClass("has-error")})},a("[data-sync]").each(function(){var b=a(this);new CalderaFormsFieldSync(b,b.data("binds"),b.closest("form"),a)}),a(document).on("change keypress","[data-sync]",function(){a(this).data("unsync",!0)}),cf_jsfields_init=function(){a(".init_field_type[data-type]").each(function(b,c){var d=a(c);"function"==typeof window[d.data("type")+"_init"]&&window[d.data("type")+"_init"](d.prop("id"),d[0])}),window.Parsley.on("field:validated",function(){setTimeout(function(){a(document).trigger("cf.error")},15)}),"undefined"==typeof resBaldrickTriggers&&a(".caldera_forms_form").length,a(document).trigger("cf.fieldsInit")},a("document").ready(function(){cf_jsfields_init()}),a(".caldera-form-page").length&&a(".caldera-form-page").on("keypress","[data-field]:not(textarea)",function(a){13===a.keyCode&&a.preventDefault()}),a(document).on("click",".cf_modal_button",function(b){b.preventDefault();var c=a(this);a(c.attr("href")).show()}),a(document).on("click",".caldera-front-modal-closer",function(b){b.preventDefault(),a(this).closest(".caldera-front-modal-container").hide()}),a(document).on("cf.add cf.enable cf.disable cf.pagenav",cf_jsfields_init),a(document).on("click","[data-page]",function(b){var c,d,e,f=a(this),g=f.closest(".caldera-form-page"),h=f.closest("form.caldera_forms_form"),i=h.data("instance"),j=h.find(".caldera-form-page:visible").data("formpage"),k=g.data("formpage")?g.data("formpage"):f.data("page"),l=a('.breadcrumb[data-form="caldera_form_'+i+'"]'),m=!0,n={};if(h.length){if(cf_validate_form(h).destroy(),e=h.find("[data-field]"),h.find(".has-error").removeClass("has-error"),"prev"!==f.data("page")&&k>=j)for(var o=0;o<e.length;o++){var p=a(e[o]);if(p.is(":radio,:checkbox")){if(!p.hasClass("option-required")||!1===p.is(":visible"))continue;n[p.data("field")]||(n[p.data("field")]=[]),n[p.data("field")].push(p.prop("checked"))}else{if(p.prop("required")&&!1===p.is(":visible"))continue;if(p.prop("required")&&!0!==p.parsley().isValid()){if(p.is(":visible"))p.parsley().validate(),b.preventDefault();else{var q=parseFloat(p.closest(".caldera-form-page[data-formpage]").data("formpage"));q<parseFloat(k)&&h.find('[data-page="'+q+'"]').addClass("has-error")}m=!1}}}for(var r in n)n[r].indexOf(!0)<0?(a('[for="'+r+"_"+i+'"]').parent().addClass("has-error"),m=!1):a('[for="'+r+"_"+i+'"]').parent().removeClass("has-error");if(!1===m)return cf_validate_form(h).validate(),!1;"next"===f.data("page")?(l&&l.find("li.active").removeClass("active").children().attr("aria-expanded","false"),c=h.find('.caldera-form-page[data-formpage="'+(k+1)+'"]'),c.length&&(g.hide().attr("aria-hidden","true").css("visibility","hidden"),c.show().attr("aria-hidden","false").css("visibility","visible"),l&&l.find('a[data-page="'+(k+1)+'"]').attr("aria-expanded","true").parent().addClass("active"))):"prev"===f.data("page")?(l&&l.find("li.active").removeClass("active").children().attr("aria-expanded","false"),d=h.find('.caldera-form-page[data-formpage="'+(k-1)+'"]'),d.length&&(g.hide().attr("aria-hidden","true").css("visibility","hidden"),d.show().attr("aria-hidden","false").css("visibility","visible"),l&&l.find('a[data-page="'+(k-1)+'"]').attr("aria-expanded","true").parent().addClass("active"))):f.data("pagenav")&&(b.preventDefault(),f.closest(".breadcrumb").find("li.active").removeClass("active").children().attr("aria-expanded","false"),a("#"+f.data("pagenav")+" .caldera-form-page").hide().attr("aria-hidden","true").css("visibility","hidden"),a("#"+f.data("pagenav")+'\t.caldera-form-page[data-formpage="'+f.data("page")+'"]').show().attr("aria-hidden","false").css("visibility","visible"),f.parent().addClass("active").children().attr("aria-expanded","true")),a("html, body").animate({scrollTop:h.offset().top-100},200),a(document).trigger("cf.pagenav")}});var b;a(".caldera-grid .breadcrumb").each(function(c,d){a(d).find("a[data-pagenav]").each(function(c,d){var e=a(d),f=e.data("pagenav");a("#"+f+' .caldera-form-page[data-formpage="'+e.data("page")+'"]').find(".has-error").length&&(e.parent().addClass("error"),void 0===b&&(e.trigger("click"),b=!0))})}),a(document).on("click",'form.caldera_forms_form [type="submit"]',function(b){var c=a(this),d=c.closest(".caldera_forms_form"),e=cf_validate_form(d);e.validate()?e.destroy():b.preventDefault()})}(jQuery),window.addEventListener("load",function(){!function(a){"use strict";if("object"==typeof CF_API_DATA){var b,c={};a(".caldera_forms_form").each(function(d,e){b=a(e).data("form-id"),c[b]=new CalderaFormsResetNonce(b,CF_API_DATA,a),c[b].init()})}if("object"==typeof CFFIELD_CONFIG){var d,e,f,g,h;a(".caldera_forms_form").each(function(b,c){h=a(c),d=h.attr("id"),g=h.data("instance"),"object"==typeof CFFIELD_CONFIG[g]&&(f=CFFIELD_CONFIG[g],e=new Caldera_Forms_Field_Config(f,a(document.getElementById(d)),a),e.init())})}}(jQuery)});
assets/build/js/handlebars.min.js CHANGED
@@ -1,2 +1,2 @@
1
- Handlebars.registerHelper("even",function(a){var b=a.data.index/2;return b===Math.ceil(b)&&a.fn(this)}),Handlebars.registerHelper("odd",function(a){var b=a.data.index/2;return b!==Math.ceil(b)&&a.fn(this)}),Handlebars.registerHelper("json",function(a){return JSON.stringify(a)}),function(a){var b={};a.fn.baldrick.registerhelper("handlebars",{bind:function(c,d){var e=c.filter("[data-template-url]");e.length&&e.each(function(){var c=a(this);if("undefined"==typeof b[c.data("templateUrl")]){if(b[c.data("templateUrl")]=!0,"undefined"!=typeof Storage){var d,e;c.data("cacheLocal")?(e=c.data("cacheLocal"),d=localStorage.getItem("handlebars_"+e)):c.data("cacheSession")&&(e=c.data("cacheSession"),d=sessionStorage.getItem("handlebars_"+e))}d?b[c.data("templateUrl")]=Handlebars.compile(d):a.get(c.data("templateUrl"),function(a,d,e){if("undefined"!=typeof Storage){var f;c.data("cacheLocal")?(f=c.data("cacheLocal"),localStorage.setItem("handlebars_"+f,e.responseText)):c.data("cacheSession")&&(f=c.data("cacheSession"),sessionStorage.setItem("handlebars_"+f,e.responseText))}b[c.data("templateUrl")]=Handlebars.compile(e.responseText)})}})},request_params:function(a,b,c){if((c.trigger.data("templateUrl")||c.trigger.data("template"))&&"object"==typeof Handlebars)return a.dataType="json",a},filter:function(c,d){return c.params.trigger.data("templateUrl")?"function"==typeof b[c.params.trigger.data("templateUrl")]&&(c.data=b[c.params.trigger.data("templateUrl")](c.data)):c.params.trigger.data("template")&&("function"==typeof b[c.params.trigger.data("template")]?c.data=b[c.params.trigger.data("template")](c.data):a(c.params.trigger.data("template"))&&(b[c.params.trigger.data("template")]=Handlebars.compile(a(c.params.trigger.data("template")).html()),c.data=b[c.params.trigger.data("template")](c.data))),c}})}(jQuery),function(a,b){"function"==typeof define&&define.amd?define([],b):"object"==typeof exports?module.exports=b():a.Handlebars=a.Handlebars||b()}(this,function(){var a=function(){"use strict";function a(a){this.string=a}var b;return a.prototype.toString=function(){return""+this.string},b=a}(),b=function(a){"use strict";function b(a){return i[a]}function c(a){for(var b=1;b<arguments.length;b++)for(var c in arguments[b])Object.prototype.hasOwnProperty.call(arguments[b],c)&&(a[c]=arguments[b][c]);return a}function d(a){return a instanceof h?a.toString():null==a?"":a?(a=""+a,k.test(a)?a.replace(j,b):a):a+""}function e(a){return!a&&0!==a||!(!n(a)||0!==a.length)}function f(a,b){return(a?a+".":"")+b}var g={},h=a,i={"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#x27;","`":"&#x60;"},j=/[&<>"'`]/g,k=/[&<>"'`]/;g.extend=c;var l=Object.prototype.toString;g.toString=l;var m=function(a){return"function"==typeof a};m(/x/)&&(m=function(a){return"function"==typeof a&&"[object Function]"===l.call(a)});var m;g.isFunction=m;var n=Array.isArray||function(a){return!(!a||"object"!=typeof a)&&"[object Array]"===l.call(a)};return g.isArray=n,g.escapeExpression=d,g.isEmpty=e,g.appendContextPath=f,g}(a),c=function(){"use strict";function a(a,b){var d;b&&b.firstLine&&(d=b.firstLine,a+=" - "+d+":"+b.firstColumn);for(var e=Error.prototype.constructor.call(this,a),f=0;f<c.length;f++)this[c[f]]=e[c[f]];d&&(this.lineNumber=d,this.column=b.firstColumn)}var b,c=["description","fileName","lineNumber","message","name","number","stack"];return a.prototype=new Error,b=a}(),d=function(a,b){"use strict";function c(a,b){this.helpers=a||{},this.partials=b||{},d(this)}function d(a){a.registerHelper("helperMissing",function(){if(1!==arguments.length)throw new g("Missing helper: '"+arguments[arguments.length-1].name+"'")}),a.registerHelper("blockHelperMissing",function(b,c){var d=c.inverse,e=c.fn;if(b===!0)return e(this);if(b===!1||null==b)return d(this);if(k(b))return b.length>0?(c.ids&&(c.ids=[c.name]),a.helpers.each(b,c)):d(this);if(c.data&&c.ids){var g=q(c.data);g.contextPath=f.appendContextPath(c.data.contextPath,c.name),c={data:g}}return e(b,c)}),a.registerHelper("each",function(a,b){if(!b)throw new g("Must pass iterator to #each");var c,d,e=b.fn,h=b.inverse,i=0,j="";if(b.data&&b.ids&&(d=f.appendContextPath(b.data.contextPath,b.ids[0])+"."),l(a)&&(a=a.call(this)),b.data&&(c=q(b.data)),a&&"object"==typeof a)if(k(a))for(var m=a.length;i<m;i++)c&&(c.index=i,c.first=0===i,c.last=i===a.length-1,d&&(c.contextPath=d+i)),j+=e(a[i],{data:c});else for(var n in a)a.hasOwnProperty(n)&&(c&&(c.key=n,c.index=i,c.first=0===i,d&&(c.contextPath=d+n)),j+=e(a[n],{data:c}),i++);return 0===i&&(j=h(this)),j}),a.registerHelper("if",function(a,b){return l(a)&&(a=a.call(this)),!b.hash.includeZero&&!a||f.isEmpty(a)?b.inverse(this):b.fn(this)}),a.registerHelper("unless",function(b,c){return a.helpers.if.call(this,b,{fn:c.inverse,inverse:c.fn,hash:c.hash})}),a.registerHelper("with",function(a,b){l(a)&&(a=a.call(this));var c=b.fn;if(f.isEmpty(a))return b.inverse(this);if(b.data&&b.ids){var d=q(b.data);d.contextPath=f.appendContextPath(b.data.contextPath,b.ids[0]),b={data:d}}return c(a,b)}),a.registerHelper("log",function(b,c){var d=c.data&&null!=c.data.level?parseInt(c.data.level,10):1;a.log(d,b)}),a.registerHelper("lookup",function(a,b){return a&&a[b]})}var e={},f=a,g=b,h="2.0.0";e.VERSION=h;var i=6;e.COMPILER_REVISION=i;var j={1:"<= 1.0.rc.2",2:"== 1.0.0-rc.3",3:"== 1.0.0-rc.4",4:"== 1.x.x",5:"== 2.0.0-alpha.x",6:">= 2.0.0-beta.1"};e.REVISION_CHANGES=j;var k=f.isArray,l=f.isFunction,m=f.toString,n="[object Object]";e.HandlebarsEnvironment=c,c.prototype={constructor:c,logger:o,log:p,registerHelper:function(a,b){if(m.call(a)===n){if(b)throw new g("Arg not supported with multiple helpers");f.extend(this.helpers,a)}else this.helpers[a]=b},unregisterHelper:function(a){delete this.helpers[a]},registerPartial:function(a,b){m.call(a)===n?f.extend(this.partials,a):this.partials[a]=b},unregisterPartial:function(a){delete this.partials[a]}};var o={methodMap:{0:"debug",1:"info",2:"warn",3:"error"},DEBUG:0,INFO:1,WARN:2,ERROR:3,level:3,log:function(a,b){if(o.level<=a){var c=o.methodMap[a];"undefined"!=typeof console&&console[c]&&console[c].call(console,b)}}};e.logger=o;var p=o.log;e.log=p;var q=function(a){var b=f.extend({},a);return b._parent=a,b};return e.createFrame=q,e}(b,c),e=function(a,b,c){"use strict";function d(a){var b=a&&a[0]||1,c=m;if(b!==c){if(b<c){var d=n[c],e=n[b];throw new l("Template was precompiled with an older version of Handlebars than the current runtime. Please update your precompiler to a newer version ("+d+") or downgrade your runtime to an older version ("+e+").")}throw new l("Template was precompiled with a newer version of Handlebars than the current runtime. Please update your runtime to a newer version ("+a[1]+").")}}function e(a,b){if(!b)throw new l("No environment passed to template");if(!a||!a.main)throw new l("Unknown template object: "+typeof a);b.VM.checkRevision(a.compiler);var c=function(c,d,e,f,g,h,i,j,m){g&&(f=k.extend({},f,g));var n=b.VM.invokePartial.call(this,c,e,f,h,i,j,m);if(null==n&&b.compile){var o={helpers:h,partials:i,data:j,depths:m};i[e]=b.compile(c,{data:void 0!==j,compat:a.compat},b),n=i[e](f,o)}if(null!=n){if(d){for(var p=n.split("\n"),q=0,r=p.length;q<r&&(p[q]||q+1!==r);q++)p[q]=d+p[q];n=p.join("\n")}return n}throw new l("The partial "+e+" could not be compiled when running in runtime-only mode")},d={lookup:function(a,b){for(var c=a.length,d=0;d<c;d++)if(a[d]&&null!=a[d][b])return a[d][b]},lambda:function(a,b){return"function"==typeof a?a.call(b):a},escapeExpression:k.escapeExpression,invokePartial:c,fn:function(b){return a[b]},programs:[],program:function(a,b,c){var d=this.programs[a],e=this.fn(a);return b||c?d=f(this,a,e,b,c):d||(d=this.programs[a]=f(this,a,e)),d},data:function(a,b){for(;a&&b--;)a=a._parent;return a},merge:function(a,b){var c=a||b;return a&&b&&a!==b&&(c=k.extend({},b,a)),c},noop:b.VM.noop,compilerInfo:a.compiler},e=function(b,c){c=c||{};var f=c.data;e._setup(c),!c.partial&&a.useData&&(f=i(b,f));var g;return a.useDepths&&(g=c.depths?[b].concat(c.depths):[b]),a.main.call(d,b,d.helpers,d.partials,f,g)};return e.isTop=!0,e._setup=function(c){c.partial?(d.helpers=c.helpers,d.partials=c.partials):(d.helpers=d.merge(c.helpers,b.helpers),a.usePartial&&(d.partials=d.merge(c.partials,b.partials)))},e._child=function(b,c,e){if(a.useDepths&&!e)throw new l("must pass parent depths");return f(d,b,a[b],c,e)},e}function f(a,b,c,d,e){var f=function(b,f){return f=f||{},c.call(a,b,a.helpers,a.partials,f.data||d,e&&[b].concat(e))};return f.program=b,f.depth=e?e.length:0,f}function g(a,b,c,d,e,f,g){var h={partial:!0,helpers:d,partials:e,data:f,depths:g};if(void 0===a)throw new l("The partial "+b+" could not be found");if(a instanceof Function)return a(c,h)}function h(){return""}function i(a,b){return b&&"root"in b||(b=b?o(b):{},b.root=a),b}var j={},k=a,l=b,m=c.COMPILER_REVISION,n=c.REVISION_CHANGES,o=c.createFrame;return j.checkRevision=d,j.template=e,j.program=f,j.invokePartial=g,j.noop=h,j}(b,c,d),f=function(a,b,c,d,e){"use strict";var f,g=a,h=b,i=c,j=d,k=e,l=function(){var a=new g.HandlebarsEnvironment;return j.extend(a,g),a.SafeString=h,a.Exception=i,a.Utils=j,a.escapeExpression=j.escapeExpression,a.VM=k,a.template=function(b){return k.template(b,a)},a},m=l();return m.create=l,m.default=m,f=m}(d,a,c,b,e),g=function(a){"use strict";function b(a){a=a||{},this.firstLine=a.first_line,this.firstColumn=a.first_column,this.lastColumn=a.last_column,this.lastLine=a.last_line}var c,d=a,e={ProgramNode:function(a,c,d){b.call(this,d),this.type="program",this.statements=a,this.strip=c},MustacheNode:function(a,c,d,f,g){if(b.call(this,g),this.type="mustache",this.strip=f,null!=d&&d.charAt){var h=d.charAt(3)||d.charAt(2);this.escaped="{"!==h&&"&"!==h}else this.escaped=!!d;a instanceof e.SexprNode?this.sexpr=a:this.sexpr=new e.SexprNode(a,c),this.id=this.sexpr.id,this.params=this.sexpr.params,this.hash=this.sexpr.hash,this.eligibleHelper=this.sexpr.eligibleHelper,this.isHelper=this.sexpr.isHelper},SexprNode:function(a,c,d){b.call(this,d),this.type="sexpr",this.hash=c;var e=this.id=a[0],f=this.params=a.slice(1);this.isHelper=!(!f.length&&!c),this.eligibleHelper=this.isHelper||e.isSimple},PartialNode:function(a,c,d,e,f){b.call(this,f),this.type="partial",this.partialName=a,this.context=c,this.hash=d,this.strip=e,this.strip.inlineStandalone=!0},BlockNode:function(a,c,d,e,f){b.call(this,f),this.type="block",this.mustache=a,this.program=c,this.inverse=d,this.strip=e,d&&!c&&(this.isInverse=!0)},RawBlockNode:function(a,c,f,g){if(b.call(this,g),a.sexpr.id.original!==f)throw new d(a.sexpr.id.original+" doesn't match "+f,this);c=new e.ContentNode(c,g),this.type="block",this.mustache=a,this.program=new e.ProgramNode([c],{},g)},ContentNode:function(a,c){b.call(this,c),this.type="content",this.original=this.string=a},HashNode:function(a,c){b.call(this,c),this.type="hash",this.pairs=a},IdNode:function(a,c){b.call(this,c),this.type="ID";for(var e="",f=[],g=0,h="",i=0,j=a.length;i<j;i++){var k=a[i].part;if(e+=(a[i].separator||"")+k,".."===k||"."===k||"this"===k){if(f.length>0)throw new d("Invalid path: "+e,this);".."===k?(g++,h+="../"):this.isScoped=!0}else f.push(k)}this.original=e,this.parts=f,this.string=f.join("."),this.depth=g,this.idName=h+this.string,this.isSimple=1===a.length&&!this.isScoped&&0===g,this.stringModeValue=this.string},PartialNameNode:function(a,c){b.call(this,c),this.type="PARTIAL_NAME",this.name=a.original},DataNode:function(a,c){b.call(this,c),this.type="DATA",this.id=a,this.stringModeValue=a.stringModeValue,this.idName="@"+a.stringModeValue},StringNode:function(a,c){b.call(this,c),this.type="STRING",this.original=this.string=this.stringModeValue=a},NumberNode:function(a,c){b.call(this,c),this.type="NUMBER",this.original=this.number=a,this.stringModeValue=Number(a)},BooleanNode:function(a,c){b.call(this,c),this.type="BOOLEAN",this.bool=a,this.stringModeValue="true"===a},CommentNode:function(a,c){b.call(this,c),this.type="comment",this.comment=a,this.strip={inlineStandalone:!0}}};return c=e}(c),h=function(){"use strict";var a,b=function(){function a(){this.yy={}}var b={trace:function(){},yy:{},symbols_:{error:2,root:3,program:4,EOF:5,program_repetition0:6,statement:7,mustache:8,block:9,rawBlock:10,partial:11,CONTENT:12,COMMENT:13,openRawBlock:14,END_RAW_BLOCK:15,OPEN_RAW_BLOCK:16,sexpr:17,CLOSE_RAW_BLOCK:18,openBlock:19,block_option0:20,closeBlock:21,openInverse:22,block_option1:23,OPEN_BLOCK:24,CLOSE:25,OPEN_INVERSE:26,inverseAndProgram:27,INVERSE:28,OPEN_ENDBLOCK:29,path:30,OPEN:31,OPEN_UNESCAPED:32,CLOSE_UNESCAPED:33,OPEN_PARTIAL:34,partialName:35,param:36,partial_option0:37,partial_option1:38,sexpr_repetition0:39,sexpr_option0:40,dataName:41,STRING:42,NUMBER:43,BOOLEAN:44,OPEN_SEXPR:45,CLOSE_SEXPR:46,hash:47,hash_repetition_plus0:48,hashSegment:49,ID:50,EQUALS:51,DATA:52,pathSegments:53,SEP:54,$accept:0,$end:1},terminals_:{2:"error",5:"EOF",12:"CONTENT",13:"COMMENT",15:"END_RAW_BLOCK",16:"OPEN_RAW_BLOCK",18:"CLOSE_RAW_BLOCK",24:"OPEN_BLOCK",25:"CLOSE",26:"OPEN_INVERSE",28:"INVERSE",29:"OPEN_ENDBLOCK",31:"OPEN",32:"OPEN_UNESCAPED",33:"CLOSE_UNESCAPED",34:"OPEN_PARTIAL",42:"STRING",43:"NUMBER",44:"BOOLEAN",45:"OPEN_SEXPR",46:"CLOSE_SEXPR",50:"ID",51:"EQUALS",52:"DATA",54:"SEP"},productions_:[0,[3,2],[4,1],[7,1],[7,1],[7,1],[7,1],[7,1],[7,1],[10,3],[14,3],[9,4],[9,4],[19,3],[22,3],[27,2],[21,3],[8,3],[8,3],[11,5],[11,4],[17,3],[17,1],[36,1],[36,1],[36,1],[36,1],[36,1],[36,3],[47,1],[49,3],[35,1],[35,1],[35,1],[41,2],[30,1],[53,3],[53,1],[6,0],[6,2],[20,0],[20,1],[23,0],[23,1],[37,0],[37,1],[38,0],[38,1],[39,0],[39,2],[40,0],[40,1],[48,1],[48,2]],performAction:function(a,b,c,d,e,f,g){var h=f.length-1;switch(e){case 1:return d.prepareProgram(f[h-1].statements,!0),f[h-1];case 2:this.$=new d.ProgramNode(d.prepareProgram(f[h]),{},this._$);break;case 3:this.$=f[h];break;case 4:this.$=f[h];break;case 5:this.$=f[h];break;case 6:this.$=f[h];break;case 7:this.$=new d.ContentNode(f[h],this._$);break;case 8:this.$=new d.CommentNode(f[h],this._$);break;case 9:this.$=new d.RawBlockNode(f[h-2],f[h-1],f[h],this._$);break;case 10:this.$=new d.MustacheNode(f[h-1],null,"","",this._$);break;case 11:this.$=d.prepareBlock(f[h-3],f[h-2],f[h-1],f[h],!1,this._$);break;case 12:this.$=d.prepareBlock(f[h-3],f[h-2],f[h-1],f[h],!0,this._$);break;case 13:this.$=new d.MustacheNode(f[h-1],null,f[h-2],d.stripFlags(f[h-2],f[h]),this._$);break;case 14:this.$=new d.MustacheNode(f[h-1],null,f[h-2],d.stripFlags(f[h-2],f[h]),this._$);break;case 15:this.$={strip:d.stripFlags(f[h-1],f[h-1]),program:f[h]};break;case 16:this.$={path:f[h-1],strip:d.stripFlags(f[h-2],f[h])};break;case 17:this.$=new d.MustacheNode(f[h-1],null,f[h-2],d.stripFlags(f[h-2],f[h]),this._$);break;case 18:this.$=new d.MustacheNode(f[h-1],null,f[h-2],d.stripFlags(f[h-2],f[h]),this._$);break;case 19:this.$=new d.PartialNode(f[h-3],f[h-2],f[h-1],d.stripFlags(f[h-4],f[h]),this._$);break;case 20:this.$=new d.PartialNode(f[h-2],void 0,f[h-1],d.stripFlags(f[h-3],f[h]),this._$);break;case 21:this.$=new d.SexprNode([f[h-2]].concat(f[h-1]),f[h],this._$);break;case 22:this.$=new d.SexprNode([f[h]],null,this._$);break;case 23:this.$=f[h];break;case 24:this.$=new d.StringNode(f[h],this._$);break;case 25:this.$=new d.NumberNode(f[h],this._$);break;case 26:this.$=new d.BooleanNode(f[h],this._$);break;case 27:this.$=f[h];break;case 28:f[h-1].isHelper=!0,this.$=f[h-1];break;case 29:this.$=new d.HashNode(f[h],this._$);break;case 30:this.$=[f[h-2],f[h]];break;case 31:this.$=new d.PartialNameNode(f[h],this._$);break;case 32:this.$=new d.PartialNameNode(new d.StringNode(f[h],this._$),this._$);break;case 33:this.$=new d.PartialNameNode(new d.NumberNode(f[h],this._$));break;case 34:this.$=new d.DataNode(f[h],this._$);break;case 35:this.$=new d.IdNode(f[h],this._$);break;case 36:f[h-2].push({part:f[h],separator:f[h-1]}),this.$=f[h-2];break;case 37:this.$=[{part:f[h]}];break;case 38:this.$=[];break;case 39:f[h-1].push(f[h]);break;case 48:this.$=[];break;case 49:f[h-1].push(f[h]);break;case 52:this.$=[f[h]];break;case 53:f[h-1].push(f[h])}},table:[{3:1,4:2,5:[2,38],6:3,12:[2,38],13:[2,38],16:[2,38],24:[2,38],26:[2,38],31:[2,38],32:[2,38],34:[2,38]},{1:[3]},{5:[1,4]},{5:[2,2],7:5,8:6,9:7,10:8,11:9,12:[1,10],13:[1,11],14:16,16:[1,20],19:14,22:15,24:[1,18],26:[1,19],28:[2,2],29:[2,2],31:[1,12],32:[1,13],34:[1,17]},{1:[2,1]},{5:[2,39],12:[2,39],13:[2,39],16:[2,39],24:[2,39],26:[2,39],28:[2,39],29:[2,39],31:[2,39],32:[2,39],34:[2,39]},{5:[2,3],12:[2,3],13:[2,3],16:[2,3],24:[2,3],26:[2,3],28:[2,3],29:[2,3],31:[2,3],32:[2,3],34:[2,3]},{5:[2,4],12:[2,4],13:[2,4],16:[2,4],24:[2,4],26:[2,4],28:[2,4],29:[2,4],31:[2,4],32:[2,4],34:[2,4]},{5:[2,5],12:[2,5],13:[2,5],16:[2,5],24:[2,5],26:[2,5],28:[2,5],29:[2,5],31:[2,5],32:[2,5],34:[2,5]},{5:[2,6],12:[2,6],13:[2,6],16:[2,6],24:[2,6],26:[2,6],28:[2,6],29:[2,6],31:[2,6],32:[2,6],34:[2,6]},{5:[2,7],12:[2,7],13:[2,7],16:[2,7],24:[2,7],26:[2,7],28:[2,7],29:[2,7],31:[2,7],32:[2,7],34:[2,7]},{5:[2,8],12:[2,8],13:[2,8],16:[2,8],24:[2,8],26:[2,8],28:[2,8],29:[2,8],31:[2,8],32:[2,8],34:[2,8]},{17:21,30:22,41:23,50:[1,26],52:[1,25],53:24},{17:27,30:22,41:23,50:[1,26],52:[1,25],53:24},{4:28,6:3,12:[2,38],13:[2,38],16:[2,38],24:[2,38],26:[2,38],28:[2,38],29:[2,38],31:[2,38],32:[2,38],34:[2,38]},{4:29,6:3,12:[2,38],13:[2,38],16:[2,38],24:[2,38],26:[2,38],28:[2,38],29:[2,38],31:[2,38],32:[2,38],34:[2,38]},{12:[1,30]},{30:32,35:31,42:[1,33],43:[1,34],50:[1,26],53:24},{17:35,30:22,41:23,50:[1,26],52:[1,25],53:24},{17:36,30:22,41:23,50:[1,26],52:[1,25],53:24},{17:37,30:22,41:23,50:[1,26],52:[1,25],53:24},{25:[1,38]},{18:[2,48],25:[2,48],33:[2,48],39:39,42:[2,48],43:[2,48],44:[2,48],45:[2,48],46:[2,48],50:[2,48],52:[2,48]},{18:[2,22],25:[2,22],33:[2,22],46:[2,22]},{18:[2,35],25:[2,35],33:[2,35],42:[2,35],43:[2,35],44:[2,35],45:[2,35],46:[2,35],50:[2,35],52:[2,35],54:[1,40]},{30:41,50:[1,26],53:24},{18:[2,37],25:[2,37],33:[2,37],42:[2,37],43:[2,37],44:[2,37],45:[2,37],46:[2,37],50:[2,37],52:[2,37],54:[2,37]},{33:[1,42]},{20:43,27:44,28:[1,45],29:[2,40]},{23:46,27:47,28:[1,45],29:[2,42]},{15:[1,48]},{25:[2,46],30:51,36:49,38:50,41:55,42:[1,52],43:[1,53],44:[1,54],45:[1,56],47:57,48:58,49:60,50:[1,59],52:[1,25],53:24},{25:[2,31],42:[2,31],43:[2,31],44:[2,31],45:[2,31],50:[2,31],52:[2,31]},{25:[2,32],42:[2,32],43:[2,32],44:[2,32],45:[2,32],50:[2,32],52:[2,32]},{25:[2,33],42:[2,33],43:[2,33],44:[2,33],45:[2,33],50:[2,33],52:[2,33]},{25:[1,61]},{25:[1,62]},{18:[1,63]},{5:[2,17],12:[2,17],13:[2,17],16:[2,17],24:[2,17],26:[2,17],28:[2,17],29:[2,17],31:[2,17],32:[2,17],34:[2,17]},{18:[2,50],25:[2,50],30:51,33:[2,50],36:65,40:64,41:55,42:[1,52],43:[1,53],44:[1,54],45:[1,56],46:[2,50],47:66,48:58,49:60,50:[1,59],52:[1,25],53:24},{50:[1,67]},{18:[2,34],25:[2,34],33:[2,34],42:[2,34],43:[2,34],44:[2,34],45:[2,34],46:[2,34],50:[2,34],52:[2,34]},{5:[2,18],12:[2,18],13:[2,18],16:[2,18],24:[2,18],26:[2,18],28:[2,18],29:[2,18],31:[2,18],32:[2,18],34:[2,18]},{21:68,29:[1,69]},{29:[2,41]},{4:70,6:3,12:[2,38],13:[2,38],16:[2,38],24:[2,38],26:[2,38],29:[2,38],31:[2,38],32:[2,38],34:[2,38]},{21:71,29:[1,69]},{29:[2,43]},{5:[2,9],12:[2,9],13:[2,9],16:[2,9],24:[2,9],26:[2,9],28:[2,9],29:[2,9],31:[2,9],32:[2,9],34:[2,9]},{25:[2,44],37:72,47:73,48:58,49:60,50:[1,74]},{25:[1,75]},{18:[2,23],25:[2,23],33:[2,23],42:[2,23],43:[2,23],44:[2,23],45:[2,23],46:[2,23],50:[2,23],52:[2,23]},{18:[2,24],25:[2,24],33:[2,24],42:[2,24],43:[2,24],44:[2,24],45:[2,24],46:[2,24],50:[2,24],52:[2,24]},{18:[2,25],25:[2,25],33:[2,25],42:[2,25],43:[2,25],44:[2,25],45:[2,25],46:[2,25],50:[2,25],52:[2,25]},{18:[2,26],25:[2,26],33:[2,26],42:[2,26],43:[2,26],44:[2,26],45:[2,26],46:[2,26],50:[2,26],52:[2,26]},{18:[2,27],25:[2,27],33:[2,27],42:[2,27],43:[2,27],44:[2,27],45:[2,27],46:[2,27],50:[2,27],52:[2,27]},{17:76,30:22,41:23,50:[1,26],52:[1,25],53:24},{25:[2,47]},{18:[2,29],25:[2,29],33:[2,29],46:[2,29],49:77,50:[1,74]},{18:[2,37],25:[2,37],33:[2,37],42:[2,37],43:[2,37],44:[2,37],45:[2,37],46:[2,37],50:[2,37],51:[1,78],52:[2,37],54:[2,37]},{18:[2,52],25:[2,52],33:[2,52],46:[2,52],50:[2,52]},{12:[2,13],13:[2,13],16:[2,13],24:[2,13],26:[2,13],28:[2,13],29:[2,13],31:[2,13],32:[2,13],34:[2,13]},{12:[2,14],13:[2,14],16:[2,14],24:[2,14],26:[2,14],28:[2,14],29:[2,14],31:[2,14],32:[2,14],34:[2,14]},{12:[2,10]},{18:[2,21],25:[2,21],33:[2,21],46:[2,21]},{18:[2,49],25:[2,49],33:[2,49],42:[2,49],43:[2,49],44:[2,49],45:[2,49],46:[2,49],50:[2,49],52:[2,49]},{18:[2,51],25:[2,51],33:[2,51],46:[2,51]},{18:[2,36],25:[2,36],33:[2,36],42:[2,36],43:[2,36],44:[2,36],45:[2,36],46:[2,36],50:[2,36],52:[2,36],54:[2,36]},{5:[2,11],12:[2,11],13:[2,11],16:[2,11],24:[2,11],26:[2,11],28:[2,11],29:[2,11],31:[2,11],32:[2,11],34:[2,11]},{30:79,50:[1,26],53:24},{29:[2,15]},{5:[2,12],12:[2,12],13:[2,12],16:[2,12],24:[2,12],26:[2,12],28:[2,12],29:[2,12],31:[2,12],32:[2,12],34:[2,12]},{25:[1,80]},{25:[2,45]},{51:[1,78]},{5:[2,20],12:[2,20],13:[2,20],16:[2,20],24:[2,20],26:[2,20],28:[2,20],29:[2,20],31:[2,20],32:[2,20],34:[2,20]},{46:[1,81]},{18:[2,53],25:[2,53],33:[2,53],46:[2,53],50:[2,53]},{30:51,36:82,41:55,42:[1,52],43:[1,53],44:[1,54],45:[1,56],50:[1,26],52:[1,25],53:24},{25:[1,83]},{5:[2,19],12:[2,19],13:[2,19],16:[2,19],24:[2,19],26:[2,19],28:[2,19],29:[2,19],31:[2,19],32:[2,19],34:[2,19]},{18:[2,28],25:[2,28],33:[2,28],42:[2,28],43:[2,28],44:[2,28],45:[2,28],46:[2,28],50:[2,28],52:[2,28]},{18:[2,30],25:[2,30],33:[2,30],46:[2,30],50:[2,30]},{5:[2,16],12:[2,16],13:[2,16],16:[2,16],24:[2,16],26:[2,16],28:[2,16],29:[2,16],31:[2,16],32:[2,16],34:[2,16]}],defaultActions:{4:[2,1],44:[2,41],47:[2,43],57:[2,47],63:[2,10],70:[2,15],73:[2,45]},parseError:function(a,b){throw new Error(a)},parse:function(a){function b(){var a;return a=c.lexer.lex()||1,"number"!=typeof a&&(a=c.symbols_[a]||a),a}var c=this,d=[0],e=[null],f=[],g=this.table,h="",i=0,j=0,k=0;this.lexer.setInput(a),this.lexer.yy=this.yy,this.yy.lexer=this.lexer,this.yy.parser=this,"undefined"==typeof this.lexer.yylloc&&(this.lexer.yylloc={});var l=this.lexer.yylloc;f.push(l);var m=this.lexer.options&&this.lexer.options.ranges;"function"==typeof this.yy.parseError&&(this.parseError=this.yy.parseError);for(var n,o,p,q,r,s,t,u,v,w={};;){if(p=d[d.length-1],this.defaultActions[p]?q=this.defaultActions[p]:(null!==n&&"undefined"!=typeof n||(n=b()),q=g[p]&&g[p][n]),"undefined"==typeof q||!q.length||!q[0]){var x="";if(!k){v=[];for(s in g[p])this.terminals_[s]&&s>2&&v.push("'"+this.terminals_[s]+"'");x=this.lexer.showPosition?"Parse error on line "+(i+1)+":\n"+this.lexer.showPosition()+"\nExpecting "+v.join(", ")+", got '"+(this.terminals_[n]||n)+"'":"Parse error on line "+(i+1)+": Unexpected "+(1==n?"end of input":"'"+(this.terminals_[n]||n)+"'"),this.parseError(x,{text:this.lexer.match,token:this.terminals_[n]||n,line:this.lexer.yylineno,loc:l,expected:v})}}if(q[0]instanceof Array&&q.length>1)throw new Error("Parse Error: multiple actions possible at state: "+p+", token: "+n);switch(q[0]){case 1:d.push(n),e.push(this.lexer.yytext),f.push(this.lexer.yylloc),d.push(q[1]),n=null,o?(n=o,o=null):(j=this.lexer.yyleng,h=this.lexer.yytext,i=this.lexer.yylineno,l=this.lexer.yylloc,k>0&&k--);break;case 2:if(t=this.productions_[q[1]][1],w.$=e[e.length-t],w._$={first_line:f[f.length-(t||1)].first_line,last_line:f[f.length-1].last_line,first_column:f[f.length-(t||1)].first_column,last_column:f[f.length-1].last_column},m&&(w._$.range=[f[f.length-(t||1)].range[0],f[f.length-1].range[1]]),r=this.performAction.call(w,h,j,i,this.yy,q[1],e,f),"undefined"!=typeof r)return r;t&&(d=d.slice(0,-1*t*2),e=e.slice(0,-1*t),f=f.slice(0,-1*t)),d.push(this.productions_[q[1]][0]),e.push(w.$),f.push(w._$),u=g[d[d.length-2]][d[d.length-1]],d.push(u);break;case 3:return!0}}return!0}},c=function(){var a={EOF:1,parseError:function(a,b){if(!this.yy.parser)throw new Error(a);this.yy.parser.parseError(a,b)},setInput:function(a){return this._input=a,this._more=this._less=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match="",this.conditionStack=["INITIAL"],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},input:function(){var a=this._input[0];this.yytext+=a,this.yyleng++,this.offset++,this.match+=a,this.matched+=a;var b=a.match(/(?:\r\n?|\n).*/g);return b?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),a},unput:function(a){var b=a.length,c=a.split(/(?:\r\n?|\n)/g);this._input=a+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-b-1),this.offset-=b;var d=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),c.length-1&&(this.yylineno-=c.length-1);var e=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:c?(c.length===d.length?this.yylloc.first_column:0)+d[d.length-c.length].length-c[0].length:this.yylloc.first_column-b},this.options.ranges&&(this.yylloc.range=[e[0],e[0]+this.yyleng-b]),this},more:function(){return this._more=!0,this},less:function(a){this.unput(this.match.slice(a))},pastInput:function(){var a=this.matched.substr(0,this.matched.length-this.match.length);return(a.length>20?"...":"")+a.substr(-20).replace(/\n/g,"")},upcomingInput:function(){var a=this.match;return a.length<20&&(a+=this._input.substr(0,20-a.length)),(a.substr(0,20)+(a.length>20?"...":"")).replace(/\n/g,"")},showPosition:function(){var a=this.pastInput(),b=new Array(a.length+1).join("-");return a+this.upcomingInput()+"\n"+b+"^"},next:function(){if(this.done)return this.EOF;this._input||(this.done=!0);var a,b,c,d,e;this._more||(this.yytext="",this.match="");for(var f=this._currentRules(),g=0;g<f.length&&(c=this._input.match(this.rules[f[g]]),!c||b&&!(c[0].length>b[0].length)||(b=c,d=g,this.options.flex));g++);return b?(e=b[0].match(/(?:\r\n?|\n).*/g),e&&(this.yylineno+=e.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:e?e[e.length-1].length-e[e.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+b[0].length},this.yytext+=b[0],this.match+=b[0],this.matches=b,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._input=this._input.slice(b[0].length),this.matched+=b[0],a=this.performAction.call(this,this.yy,this,f[d],this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),a?a:void 0):""===this._input?this.EOF:this.parseError("Lexical error on line "+(this.yylineno+1)+". Unrecognized text.\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})},lex:function(){var a=this.next();return"undefined"!=typeof a?a:this.lex()},begin:function(a){this.conditionStack.push(a)},popState:function(){return this.conditionStack.pop()},_currentRules:function(){return this.conditions[this.conditionStack[this.conditionStack.length-1]].rules},topState:function(){return this.conditionStack[this.conditionStack.length-2]},pushState:function(a){this.begin(a)}};return a.options={},a.performAction=function(a,b,c,d){function e(a,c){return b.yytext=b.yytext.substr(a,b.yyleng-c)}switch(c){case 0:if("\\\\"===b.yytext.slice(-2)?(e(0,1),this.begin("mu")):"\\"===b.yytext.slice(-1)?(e(0,1),this.begin("emu")):this.begin("mu"),b.yytext)return 12;break;case 1:return 12;case 2:return this.popState(),12;case 3:return b.yytext=b.yytext.substr(5,b.yyleng-9),this.popState(),15;case 4:return 12;case 5:return e(0,4),this.popState(),13;case 6:return 45;case 7:return 46;case 8:return 16;case 9:return this.popState(),this.begin("raw"),18;case 10:return 34;case 11:return 24;case 12:return 29;case 13:return this.popState(),28;case 14:return this.popState(),28;case 15:return 26;case 16:return 26;case 17:return 32;case 18:return 31;case 19:this.popState(),this.begin("com");break;case 20:return e(3,5),this.popState(),13;case 21:return 31;case 22:return 51;case 23:return 50;case 24:return 50;case 25:return 54;case 26:break;case 27:return this.popState(),33;case 28:return this.popState(),25;case 29:return b.yytext=e(1,2).replace(/\\"/g,'"'),42;case 30:return b.yytext=e(1,2).replace(/\\'/g,"'"),42;case 31:return 52;case 32:return 44;case 33:return 44;case 34:return 43;case 35:return 50;case 36:return b.yytext=e(1,2),50;case 37:return"INVALID";case 38:return 5}},a.rules=[/^(?:[^\x00]*?(?=(\{\{)))/,/^(?:[^\x00]+)/,/^(?:[^\x00]{2,}?(?=(\{\{|\\\{\{|\\\\\{\{|$)))/,/^(?:\{\{\{\{\/[^\s!"#%-,\.\/;->@\[-\^`\{-~]+(?=[=}\s\/.])\}\}\}\})/,/^(?:[^\x00]*?(?=(\{\{\{\{\/)))/,/^(?:[\s\S]*?--\}\})/,/^(?:\()/,/^(?:\))/,/^(?:\{\{\{\{)/,/^(?:\}\}\}\})/,/^(?:\{\{(~)?>)/,/^(?:\{\{(~)?#)/,/^(?:\{\{(~)?\/)/,/^(?:\{\{(~)?\^\s*(~)?\}\})/,/^(?:\{\{(~)?\s*else\s*(~)?\}\})/,/^(?:\{\{(~)?\^)/,/^(?:\{\{(~)?\s*else\b)/,/^(?:\{\{(~)?\{)/,/^(?:\{\{(~)?&)/,/^(?:\{\{!--)/,/^(?:\{\{![\s\S]*?\}\})/,/^(?:\{\{(~)?)/,/^(?:=)/,/^(?:\.\.)/,/^(?:\.(?=([=~}\s\/.)])))/,/^(?:[\/.])/,/^(?:\s+)/,/^(?:\}(~)?\}\})/,/^(?:(~)?\}\})/,/^(?:"(\\["]|[^"])*")/,/^(?:'(\\[']|[^'])*')/,/^(?:@)/,/^(?:true(?=([~}\s)])))/,/^(?:false(?=([~}\s)])))/,/^(?:-?[0-9]+(?:\.[0-9]+)?(?=([~}\s)])))/,/^(?:([^\s!"#%-,\.\/;->@\[-\^`\{-~]+(?=([=~}\s\/.)]))))/,/^(?:\[[^\]]*\])/,/^(?:.)/,/^(?:$)/],a.conditions={mu:{rules:[6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38],inclusive:!1},emu:{rules:[2],inclusive:!1},com:{rules:[5],inclusive:!1},raw:{rules:[3,4],inclusive:!1},INITIAL:{rules:[0,1,38],inclusive:!0}},a}();return b.lexer=c,a.prototype=b,b.Parser=a,new a}();return a=b}(),i=function(a){"use strict";function b(a,b){return{left:"~"===a.charAt(2),right:"~"===b.charAt(b.length-3)}}function c(a,b,c,d,i,k){if(a.sexpr.id.original!==d.path.original)throw new j(a.sexpr.id.original+" doesn't match "+d.path.original,a);var l=c&&c.program,m={left:a.strip.left,right:d.strip.right,openStandalone:f(b.statements),closeStandalone:e((l||b).statements)};if(a.strip.right&&g(b.statements,null,!0),l){var n=c.strip;n.left&&h(b.statements,null,!0),n.right&&g(l.statements,null,!0),d.strip.left&&h(l.statements,null,!0),e(b.statements)&&f(l.statements)&&(h(b.statements),g(l.statements))}else d.strip.left&&h(b.statements,null,!0);return i?new this.BlockNode(a,l,b,m,k):new this.BlockNode(a,b,l,m,k)}function d(a,b){for(var c=0,d=a.length;c<d;c++){var i=a[c],j=i.strip;if(j){var k=e(a,c,b,"partial"===i.type),l=f(a,c,b),m=j.openStandalone&&k,n=j.closeStandalone&&l,o=j.inlineStandalone&&k&&l;j.right&&g(a,c,!0),j.left&&h(a,c,!0),o&&(g(a,c),h(a,c)&&"partial"===i.type&&(i.indent=/([ \t]+$)/.exec(a[c-1].original)?RegExp.$1:"")),m&&(g((i.program||i.inverse).statements),h(a,c)),n&&(g(a,c),h((i.inverse||i.program).statements))}}return a}function e(a,b,c){void 0===b&&(b=a.length);var d=a[b-1],e=a[b-2];return d?"content"===d.type?(e||!c?/\r?\n\s*?$/:/(^|\r?\n)\s*?$/).test(d.original):void 0:c}function f(a,b,c){void 0===b&&(b=-1);var d=a[b+1],e=a[b+2];return d?"content"===d.type?(e||!c?/^\s*?\r?\n/:/^\s*?(\r?\n|$)/).test(d.original):void 0:c}function g(a,b,c){var d=a[null==b?0:b+1];if(d&&"content"===d.type&&(c||!d.rightStripped)){var e=d.string;d.string=d.string.replace(c?/^\s+/:/^[ \t]*\r?\n?/,""),d.rightStripped=d.string!==e}}function h(a,b,c){var d=a[null==b?a.length-1:b-1];if(d&&"content"===d.type&&(c||!d.leftStripped)){var e=d.string;return d.string=d.string.replace(c?/\s+$/:/[ \t]+$/,""),d.leftStripped=d.string!==e,d.leftStripped}}var i={},j=a;return i.stripFlags=b,i.prepareBlock=c,i.prepareProgram=d,i}(c),j=function(a,b,c,d){"use strict";function e(a){return a.constructor===h.ProgramNode?a:(g.yy=k,g.parse(a))}var f={},g=a,h=b,i=c,j=d.extend;f.parser=g;var k={};return j(k,i,h),f.parse=e,f}(h,g,i,b),k=function(a,b){"use strict";function c(){}function d(a,b,c){if(null==a||"string"!=typeof a&&a.constructor!==c.AST.ProgramNode)throw new h("You must pass a string or Handlebars AST to Handlebars.precompile. You passed "+a);b=b||{},"data"in b||(b.data=!0),
2
- b.compat&&(b.useDepths=!0);var d=c.parse(a),e=(new c.Compiler).compile(d,b);return(new c.JavaScriptCompiler).compile(e,b)}function e(a,b,c){function d(){var d=c.parse(a),e=(new c.Compiler).compile(d,b),f=(new c.JavaScriptCompiler).compile(e,b,void 0,!0);return c.template(f)}if(null==a||"string"!=typeof a&&a.constructor!==c.AST.ProgramNode)throw new h("You must pass a string or Handlebars AST to Handlebars.compile. You passed "+a);b=b||{},"data"in b||(b.data=!0),b.compat&&(b.useDepths=!0);var e,f=function(a,b){return e||(e=d()),e.call(this,a,b)};return f._setup=function(a){return e||(e=d()),e._setup(a)},f._child=function(a,b,c){return e||(e=d()),e._child(a,b,c)},f}function f(a,b){if(a===b)return!0;if(i(a)&&i(b)&&a.length===b.length){for(var c=0;c<a.length;c++)if(!f(a[c],b[c]))return!1;return!0}}var g={},h=a,i=b.isArray,j=[].slice;return g.Compiler=c,c.prototype={compiler:c,equals:function(a){var b=this.opcodes.length;if(a.opcodes.length!==b)return!1;for(var c=0;c<b;c++){var d=this.opcodes[c],e=a.opcodes[c];if(d.opcode!==e.opcode||!f(d.args,e.args))return!1}for(b=this.children.length,c=0;c<b;c++)if(!this.children[c].equals(a.children[c]))return!1;return!0},guid:0,compile:function(a,b){this.opcodes=[],this.children=[],this.depths={list:[]},this.options=b,this.stringParams=b.stringParams,this.trackIds=b.trackIds;var c=this.options.knownHelpers;if(this.options.knownHelpers={helperMissing:!0,blockHelperMissing:!0,each:!0,if:!0,unless:!0,with:!0,log:!0,lookup:!0},c)for(var d in c)this.options.knownHelpers[d]=c[d];return this.accept(a)},accept:function(a){return this[a.type](a)},program:function(a){for(var b=a.statements,c=0,d=b.length;c<d;c++)this.accept(b[c]);return this.isSimple=1===d,this.depths.list=this.depths.list.sort(function(a,b){return a-b}),this},compileProgram:function(a){var b,c=(new this.compiler).compile(a,this.options),d=this.guid++;this.usePartial=this.usePartial||c.usePartial,this.children[d]=c;for(var e=0,f=c.depths.list.length;e<f;e++)b=c.depths.list[e],b<2||this.addDepth(b-1);return d},block:function(a){var b=a.mustache,c=a.program,d=a.inverse;c&&(c=this.compileProgram(c)),d&&(d=this.compileProgram(d));var e=b.sexpr,f=this.classifySexpr(e);"helper"===f?this.helperSexpr(e,c,d):"simple"===f?(this.simpleSexpr(e),this.opcode("pushProgram",c),this.opcode("pushProgram",d),this.opcode("emptyHash"),this.opcode("blockValue",e.id.original)):(this.ambiguousSexpr(e,c,d),this.opcode("pushProgram",c),this.opcode("pushProgram",d),this.opcode("emptyHash"),this.opcode("ambiguousBlockValue")),this.opcode("append")},hash:function(a){var b,c,d=a.pairs;for(this.opcode("pushHash"),b=0,c=d.length;b<c;b++)this.pushParam(d[b][1]);for(;b--;)this.opcode("assignToHash",d[b][0]);this.opcode("popHash")},partial:function(a){var b=a.partialName;this.usePartial=!0,a.hash?this.accept(a.hash):this.opcode("push","undefined"),a.context?this.accept(a.context):(this.opcode("getContext",0),this.opcode("pushContext")),this.opcode("invokePartial",b.name,a.indent||""),this.opcode("append")},content:function(a){a.string&&this.opcode("appendContent",a.string)},mustache:function(a){this.sexpr(a.sexpr),a.escaped&&!this.options.noEscape?this.opcode("appendEscaped"):this.opcode("append")},ambiguousSexpr:function(a,b,c){var d=a.id,e=d.parts[0],f=null!=b||null!=c;this.opcode("getContext",d.depth),this.opcode("pushProgram",b),this.opcode("pushProgram",c),this.ID(d),this.opcode("invokeAmbiguous",e,f)},simpleSexpr:function(a){var b=a.id;"DATA"===b.type?this.DATA(b):b.parts.length?this.ID(b):(this.addDepth(b.depth),this.opcode("getContext",b.depth),this.opcode("pushContext")),this.opcode("resolvePossibleLambda")},helperSexpr:function(a,b,c){var d=this.setupFullMustacheParams(a,b,c),e=a.id,f=e.parts[0];if(this.options.knownHelpers[f])this.opcode("invokeKnownHelper",d.length,f);else{if(this.options.knownHelpersOnly)throw new h("You specified knownHelpersOnly, but used the unknown helper "+f,a);e.falsy=!0,this.ID(e),this.opcode("invokeHelper",d.length,e.original,e.isSimple)}},sexpr:function(a){var b=this.classifySexpr(a);"simple"===b?this.simpleSexpr(a):"helper"===b?this.helperSexpr(a):this.ambiguousSexpr(a)},ID:function(a){this.addDepth(a.depth),this.opcode("getContext",a.depth);var b=a.parts[0];b?this.opcode("lookupOnContext",a.parts,a.falsy,a.isScoped):this.opcode("pushContext")},DATA:function(a){this.options.data=!0,this.opcode("lookupData",a.id.depth,a.id.parts)},STRING:function(a){this.opcode("pushString",a.string)},NUMBER:function(a){this.opcode("pushLiteral",a.number)},BOOLEAN:function(a){this.opcode("pushLiteral",a.bool)},comment:function(){},opcode:function(a){this.opcodes.push({opcode:a,args:j.call(arguments,1)})},addDepth:function(a){0!==a&&(this.depths[a]||(this.depths[a]=!0,this.depths.list.push(a)))},classifySexpr:function(a){var b=a.isHelper,c=a.eligibleHelper,d=this.options;if(c&&!b){var e=a.id.parts[0];d.knownHelpers[e]?b=!0:d.knownHelpersOnly&&(c=!1)}return b?"helper":c?"ambiguous":"simple"},pushParams:function(a){for(var b=0,c=a.length;b<c;b++)this.pushParam(a[b])},pushParam:function(a){this.stringParams?(a.depth&&this.addDepth(a.depth),this.opcode("getContext",a.depth||0),this.opcode("pushStringParam",a.stringModeValue,a.type),"sexpr"===a.type&&this.sexpr(a)):(this.trackIds&&this.opcode("pushId",a.type,a.idName||a.stringModeValue),this.accept(a))},setupFullMustacheParams:function(a,b,c){var d=a.params;return this.pushParams(d),this.opcode("pushProgram",b),this.opcode("pushProgram",c),a.hash?this.hash(a.hash):this.opcode("emptyHash"),d}},g.precompile=d,g.compile=e,g}(c,b),l=function(a,b){"use strict";function c(a){this.value=a}function d(){}var e,f=a.COMPILER_REVISION,g=a.REVISION_CHANGES,h=b;d.prototype={nameLookup:function(a,b){return d.isValidJavaScriptVariableName(b)?a+"."+b:a+"['"+b+"']"},depthedLookup:function(a){return this.aliases.lookup="this.lookup",'lookup(depths, "'+a+'")'},compilerInfo:function(){var a=f,b=g[a];return[a,b]},appendToBuffer:function(a){return this.environment.isSimple?"return "+a+";":{appendToBuffer:!0,content:a,toString:function(){return"buffer += "+a+";"}}},initializeBuffer:function(){return this.quotedString("")},namespace:"Handlebars",compile:function(a,b,c,d){this.environment=a,this.options=b,this.stringParams=this.options.stringParams,this.trackIds=this.options.trackIds,this.precompile=!d,this.name=this.environment.name,this.isChild=!!c,this.context=c||{programs:[],environments:[]},this.preamble(),this.stackSlot=0,this.stackVars=[],this.aliases={},this.registers={list:[]},this.hashes=[],this.compileStack=[],this.inlineStack=[],this.compileChildren(a,b),this.useDepths=this.useDepths||a.depths.list.length||this.options.compat;var e,f,g,i=a.opcodes;for(f=0,g=i.length;f<g;f++)e=i[f],this[e.opcode].apply(this,e.args);if(this.pushSource(""),this.stackSlot||this.inlineStack.length||this.compileStack.length)throw new h("Compile completed with content left on stack");var j=this.createFunctionContext(d);if(this.isChild)return j;var k={compiler:this.compilerInfo(),main:j},l=this.context.programs;for(f=0,g=l.length;f<g;f++)l[f]&&(k[f]=l[f]);return this.environment.usePartial&&(k.usePartial=!0),this.options.data&&(k.useData=!0),this.useDepths&&(k.useDepths=!0),this.options.compat&&(k.compat=!0),d||(k.compiler=JSON.stringify(k.compiler),k=this.objectLiteral(k)),k},preamble:function(){this.lastContext=0,this.source=[]},createFunctionContext:function(a){var b="",c=this.stackVars.concat(this.registers.list);c.length>0&&(b+=", "+c.join(", "));for(var d in this.aliases)this.aliases.hasOwnProperty(d)&&(b+=", "+d+"="+this.aliases[d]);var e=["depth0","helpers","partials","data"];this.useDepths&&e.push("depths");var f=this.mergeSource(b);return a?(e.push(f),Function.apply(this,e)):"function("+e.join(",")+") {\n "+f+"}"},mergeSource:function(a){for(var b,c,d="",e=!this.forceBuffer,f=0,g=this.source.length;f<g;f++){var h=this.source[f];h.appendToBuffer?b=b?b+"\n + "+h.content:h.content:(b&&(d?d+="buffer += "+b+";\n ":(c=!0,d=b+";\n "),b=void 0),d+=h+"\n ",this.environment.isSimple||(e=!1))}return e?!b&&d||(d+="return "+(b||'""')+";\n"):(a+=", buffer = "+(c?"":this.initializeBuffer()),d+=b?"return buffer + "+b+";\n":"return buffer;\n"),a&&(d="var "+a.substring(2)+(c?"":";\n ")+d),d},blockValue:function(a){this.aliases.blockHelperMissing="helpers.blockHelperMissing";var b=[this.contextName(0)];this.setupParams(a,0,b);var c=this.popStack();b.splice(1,0,c),this.push("blockHelperMissing.call("+b.join(", ")+")")},ambiguousBlockValue:function(){this.aliases.blockHelperMissing="helpers.blockHelperMissing";var a=[this.contextName(0)];this.setupParams("",0,a,!0),this.flushInline();var b=this.topStack();a.splice(1,0,b),this.pushSource("if (!"+this.lastHelper+") { "+b+" = blockHelperMissing.call("+a.join(", ")+"); }")},appendContent:function(a){this.pendingContent&&(a=this.pendingContent+a),this.pendingContent=a},append:function(){this.flushInline();var a=this.popStack();this.pushSource("if ("+a+" != null) { "+this.appendToBuffer(a)+" }"),this.environment.isSimple&&this.pushSource("else { "+this.appendToBuffer("''")+" }")},appendEscaped:function(){this.aliases.escapeExpression="this.escapeExpression",this.pushSource(this.appendToBuffer("escapeExpression("+this.popStack()+")"))},getContext:function(a){this.lastContext=a},pushContext:function(){this.pushStackLiteral(this.contextName(this.lastContext))},lookupOnContext:function(a,b,c){var d=0,e=a.length;for(c||!this.options.compat||this.lastContext?this.pushContext():this.push(this.depthedLookup(a[d++]));d<e;d++)this.replaceStack(function(c){var e=this.nameLookup(c,a[d],"context");return b?" && "+e:" != null ? "+e+" : "+c})},lookupData:function(a,b){a?this.pushStackLiteral("this.data(data, "+a+")"):this.pushStackLiteral("data");for(var c=b.length,d=0;d<c;d++)this.replaceStack(function(a){return" && "+this.nameLookup(a,b[d],"data")})},resolvePossibleLambda:function(){this.aliases.lambda="this.lambda",this.push("lambda("+this.popStack()+", "+this.contextName(0)+")")},pushStringParam:function(a,b){this.pushContext(),this.pushString(b),"sexpr"!==b&&("string"==typeof a?this.pushString(a):this.pushStackLiteral(a))},emptyHash:function(){this.pushStackLiteral("{}"),this.trackIds&&this.push("{}"),this.stringParams&&(this.push("{}"),this.push("{}"))},pushHash:function(){this.hash&&this.hashes.push(this.hash),this.hash={values:[],types:[],contexts:[],ids:[]}},popHash:function(){var a=this.hash;this.hash=this.hashes.pop(),this.trackIds&&this.push("{"+a.ids.join(",")+"}"),this.stringParams&&(this.push("{"+a.contexts.join(",")+"}"),this.push("{"+a.types.join(",")+"}")),this.push("{\n "+a.values.join(",\n ")+"\n }")},pushString:function(a){this.pushStackLiteral(this.quotedString(a))},push:function(a){return this.inlineStack.push(a),a},pushLiteral:function(a){this.pushStackLiteral(a)},pushProgram:function(a){null!=a?this.pushStackLiteral(this.programExpression(a)):this.pushStackLiteral(null)},invokeHelper:function(a,b,c){this.aliases.helperMissing="helpers.helperMissing";var d=this.popStack(),e=this.setupHelper(a,b),f=(c?e.name+" || ":"")+d+" || helperMissing";this.push("(("+f+").call("+e.callParams+"))")},invokeKnownHelper:function(a,b){var c=this.setupHelper(a,b);this.push(c.name+".call("+c.callParams+")")},invokeAmbiguous:function(a,b){this.aliases.functionType='"function"',this.aliases.helperMissing="helpers.helperMissing",this.useRegister("helper");var c=this.popStack();this.emptyHash();var d=this.setupHelper(0,a,b),e=this.lastHelper=this.nameLookup("helpers",a,"helper");this.push("((helper = (helper = "+e+" || "+c+") != null ? helper : helperMissing"+(d.paramsInit?"),("+d.paramsInit:"")+"),(typeof helper === functionType ? helper.call("+d.callParams+") : helper))")},invokePartial:function(a,b){var c=[this.nameLookup("partials",a,"partial"),"'"+b+"'","'"+a+"'",this.popStack(),this.popStack(),"helpers","partials"];this.options.data?c.push("data"):this.options.compat&&c.push("undefined"),this.options.compat&&c.push("depths"),this.push("this.invokePartial("+c.join(", ")+")")},assignToHash:function(a){var b,c,d,e=this.popStack();this.trackIds&&(d=this.popStack()),this.stringParams&&(c=this.popStack(),b=this.popStack());var f=this.hash;b&&f.contexts.push("'"+a+"': "+b),c&&f.types.push("'"+a+"': "+c),d&&f.ids.push("'"+a+"': "+d),f.values.push("'"+a+"': ("+e+")")},pushId:function(a,b){"ID"===a||"DATA"===a?this.pushString(b):"sexpr"===a?this.pushStackLiteral("true"):this.pushStackLiteral("null")},compiler:d,compileChildren:function(a,b){for(var c,d,e=a.children,f=0,g=e.length;f<g;f++){c=e[f],d=new this.compiler;var h=this.matchExistingProgram(c);null==h?(this.context.programs.push(""),h=this.context.programs.length,c.index=h,c.name="program"+h,this.context.programs[h]=d.compile(c,b,this.context,!this.precompile),this.context.environments[h]=c,this.useDepths=this.useDepths||d.useDepths):(c.index=h,c.name="program"+h)}},matchExistingProgram:function(a){for(var b=0,c=this.context.environments.length;b<c;b++){var d=this.context.environments[b];if(d&&d.equals(a))return b}},programExpression:function(a){var b=this.environment.children[a],c=(b.depths.list,this.useDepths),d=[b.index,"data"];return c&&d.push("depths"),"this.program("+d.join(", ")+")"},useRegister:function(a){this.registers[a]||(this.registers[a]=!0,this.registers.list.push(a))},pushStackLiteral:function(a){return this.push(new c(a))},pushSource:function(a){this.pendingContent&&(this.source.push(this.appendToBuffer(this.quotedString(this.pendingContent))),this.pendingContent=void 0),a&&this.source.push(a)},pushStack:function(a){this.flushInline();var b=this.incrStack();return this.pushSource(b+" = "+a+";"),this.compileStack.push(b),b},replaceStack:function(a){var b,d,e,f="";this.isInline();if(!this.isInline())throw new h("replaceStack on non-inline");var g=this.popStack(!0);if(g instanceof c)f=b=g.value,e=!0;else{d=!this.stackSlot;var i=d?this.incrStack():this.topStackName();f="("+this.push(i)+" = "+g+")",b=this.topStack()}var j=a.call(this,b);e||this.popStack(),d&&this.stackSlot--,this.push("("+f+j+")")},incrStack:function(){return this.stackSlot++,this.stackSlot>this.stackVars.length&&this.stackVars.push("stack"+this.stackSlot),this.topStackName()},topStackName:function(){return"stack"+this.stackSlot},flushInline:function(){var a=this.inlineStack;if(a.length){this.inlineStack=[];for(var b=0,d=a.length;b<d;b++){var e=a[b];e instanceof c?this.compileStack.push(e):this.pushStack(e)}}},isInline:function(){return this.inlineStack.length},popStack:function(a){var b=this.isInline(),d=(b?this.inlineStack:this.compileStack).pop();if(!a&&d instanceof c)return d.value;if(!b){if(!this.stackSlot)throw new h("Invalid stack pop");this.stackSlot--}return d},topStack:function(){var a=this.isInline()?this.inlineStack:this.compileStack,b=a[a.length-1];return b instanceof c?b.value:b},contextName:function(a){return this.useDepths&&a?"depths["+a+"]":"depth"+a},quotedString:function(a){return'"'+a.replace(/\\/g,"\\\\").replace(/"/g,'\\"').replace(/\n/g,"\\n").replace(/\r/g,"\\r").replace(/\u2028/g,"\\u2028").replace(/\u2029/g,"\\u2029")+'"'},objectLiteral:function(a){var b=[];for(var c in a)a.hasOwnProperty(c)&&b.push(this.quotedString(c)+":"+a[c]);return"{"+b.join(",")+"}"},setupHelper:function(a,b,c){var d=[],e=this.setupParams(b,a,d,c),f=this.nameLookup("helpers",b,"helper");return{params:d,paramsInit:e,name:f,callParams:[this.contextName(0)].concat(d).join(", ")}},setupOptions:function(a,b,c){var d,e,f,g={},h=[],i=[],j=[];g.name=this.quotedString(a),g.hash=this.popStack(),this.trackIds&&(g.hashIds=this.popStack()),this.stringParams&&(g.hashTypes=this.popStack(),g.hashContexts=this.popStack()),e=this.popStack(),f=this.popStack(),(f||e)&&(f||(f="this.noop"),e||(e="this.noop"),g.fn=f,g.inverse=e);for(var k=b;k--;)d=this.popStack(),c[k]=d,this.trackIds&&(j[k]=this.popStack()),this.stringParams&&(i[k]=this.popStack(),h[k]=this.popStack());return this.trackIds&&(g.ids="["+j.join(",")+"]"),this.stringParams&&(g.types="["+i.join(",")+"]",g.contexts="["+h.join(",")+"]"),this.options.data&&(g.data="data"),g},setupParams:function(a,b,c,d){var e=this.objectLiteral(this.setupOptions(a,b,c));return d?(this.useRegister("options"),c.push("options"),"options="+e):(c.push(e),"")}};for(var i="break else new var case finally return void catch for switch while continue function this with default if throw delete in try do instanceof typeof abstract enum int short boolean export interface static byte extends long super char final native synchronized class float package throws const goto private transient debugger implements protected volatile double import public let yield".split(" "),j=d.RESERVED_WORDS={},k=0,l=i.length;k<l;k++)j[i[k]]=!0;return d.isValidJavaScriptVariableName=function(a){return!d.RESERVED_WORDS[a]&&/^[a-zA-Z_$][0-9a-zA-Z_$]*$/.test(a)},e=d}(d,c),m=function(a,b,c,d,e){"use strict";var f,g=a,h=b,i=c.parser,j=c.parse,k=d.Compiler,l=d.compile,m=d.precompile,n=e,o=g.create,p=function(){var a=o();return a.compile=function(b,c){return l(b,c,a)},a.precompile=function(b,c){return m(b,c,a)},a.AST=h,a.Compiler=k,a.JavaScriptCompiler=n,a.Parser=i,a.parse=j,a};return g=p(),g.create=p,g.default=g,f=g}(f,g,j,k,l);return m}),Handlebars.registerHelper("is_single",function(a,b){return 1===Object.keys(a).length&&b.fn(this)}),Handlebars.registerHelper("script",function(a){return a.hash.src?'<script type="text/javascript" src="'+a.fn(this)+'"></script>':'<script type="text/javascript">'+a.fn(this)+"</script>"}),Handlebars.registerHelper("is",function(a,b){return"@key"===b.hash.value&&(b.hash.value=b.data.key),b.hash.value===a?b.fn(this):this[b.hash.value]&&this[b.hash.value]===a?b.fn(this):b.inverse(this)});
1
+ Handlebars.registerHelper("even",function(a){var b=a.data.index/2;return b===Math.ceil(b)&&a.fn(this)}),Handlebars.registerHelper("odd",function(a){var b=a.data.index/2;return b!==Math.ceil(b)&&a.fn(this)}),Handlebars.registerHelper("json",function(a){return JSON.stringify(a)}),function(a){var b={};a.fn.baldrick.registerhelper("handlebars",{bind:function(c,d){var e=c.filter("[data-template-url]");e.length&&e.each(function(){var c=a(this);if(void 0===b[c.data("templateUrl")]){if(b[c.data("templateUrl")]=!0,"undefined"!=typeof Storage){var d,e;c.data("cacheLocal")?(e=c.data("cacheLocal"),d=localStorage.getItem("handlebars_"+e)):c.data("cacheSession")&&(e=c.data("cacheSession"),d=sessionStorage.getItem("handlebars_"+e))}d?b[c.data("templateUrl")]=Handlebars.compile(d):a.get(c.data("templateUrl"),function(a,d,e){if("undefined"!=typeof Storage){var f;c.data("cacheLocal")?(f=c.data("cacheLocal"),localStorage.setItem("handlebars_"+f,e.responseText)):c.data("cacheSession")&&(f=c.data("cacheSession"),sessionStorage.setItem("handlebars_"+f,e.responseText))}b[c.data("templateUrl")]=Handlebars.compile(e.responseText)})}})},request_params:function(a,b,c){if((c.trigger.data("templateUrl")||c.trigger.data("template"))&&"object"==typeof Handlebars)return a.dataType="json",a},filter:function(c,d){return c.params.trigger.data("templateUrl")?"function"==typeof b[c.params.trigger.data("templateUrl")]&&(c.data=b[c.params.trigger.data("templateUrl")](c.data)):c.params.trigger.data("template")&&("function"==typeof b[c.params.trigger.data("template")]?c.data=b[c.params.trigger.data("template")](c.data):a(c.params.trigger.data("template"))&&(b[c.params.trigger.data("template")]=Handlebars.compile(a(c.params.trigger.data("template")).html()),c.data=b[c.params.trigger.data("template")](c.data))),c}})}(jQuery),function(a,b){"function"==typeof define&&define.amd?define([],b):"object"==typeof exports?module.exports=b():a.Handlebars=a.Handlebars||b()}(this,function(){var a=function(){"use strict";function a(a){this.string=a}return a.prototype.toString=function(){return""+this.string},a}(),b=function(a){"use strict";function b(a){return i[a]}function c(a){for(var b=1;b<arguments.length;b++)for(var c in arguments[b])Object.prototype.hasOwnProperty.call(arguments[b],c)&&(a[c]=arguments[b][c]);return a}function d(a){return a instanceof h?a.toString():null==a?"":a?(a=""+a,k.test(a)?a.replace(j,b):a):a+""}function e(a){return!a&&0!==a||!(!n(a)||0!==a.length)}function f(a,b){return(a?a+".":"")+b}var g={},h=a,i={"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#x27;","`":"&#x60;"},j=/[&<>"'`]/g,k=/[&<>"'`]/;g.extend=c;var l=Object.prototype.toString;g.toString=l;var m=function(a){return"function"==typeof a};m(/x/)&&(m=function(a){return"function"==typeof a&&"[object Function]"===l.call(a)});var m;g.isFunction=m;var n=Array.isArray||function(a){return!(!a||"object"!=typeof a)&&"[object Array]"===l.call(a)};return g.isArray=n,g.escapeExpression=d,g.isEmpty=e,g.appendContextPath=f,g}(a),c=function(){"use strict";function a(a,c){var d;c&&c.firstLine&&(d=c.firstLine,a+=" - "+d+":"+c.firstColumn);for(var e=Error.prototype.constructor.call(this,a),f=0;f<b.length;f++)this[b[f]]=e[b[f]];d&&(this.lineNumber=d,this.column=c.firstColumn)}var b=["description","fileName","lineNumber","message","name","number","stack"];return a.prototype=new Error,a}(),d=function(a,b){"use strict";function c(a,b){this.helpers=a||{},this.partials=b||{},d(this)}function d(a){a.registerHelper("helperMissing",function(){if(1!==arguments.length)throw new g("Missing helper: '"+arguments[arguments.length-1].name+"'")}),a.registerHelper("blockHelperMissing",function(b,c){var d=c.inverse,e=c.fn;if(!0===b)return e(this);if(!1===b||null==b)return d(this);if(i(b))return b.length>0?(c.ids&&(c.ids=[c.name]),a.helpers.each(b,c)):d(this);if(c.data&&c.ids){var g=n(c.data);g.contextPath=f.appendContextPath(c.data.contextPath,c.name),c={data:g}}return e(b,c)}),a.registerHelper("each",function(a,b){if(!b)throw new g("Must pass iterator to #each");var c,d,e=b.fn,h=b.inverse,k=0,l="";if(b.data&&b.ids&&(d=f.appendContextPath(b.data.contextPath,b.ids[0])+"."),j(a)&&(a=a.call(this)),b.data&&(c=n(b.data)),a&&"object"==typeof a)if(i(a))for(var m=a.length;k<m;k++)c&&(c.index=k,c.first=0===k,c.last=k===a.length-1,d&&(c.contextPath=d+k)),l+=e(a[k],{data:c});else for(var o in a)a.hasOwnProperty(o)&&(c&&(c.key=o,c.index=k,c.first=0===k,d&&(c.contextPath=d+o)),l+=e(a[o],{data:c}),k++);return 0===k&&(l=h(this)),l}),a.registerHelper("if",function(a,b){return j(a)&&(a=a.call(this)),!b.hash.includeZero&&!a||f.isEmpty(a)?b.inverse(this):b.fn(this)}),a.registerHelper("unless",function(b,c){return a.helpers.if.call(this,b,{fn:c.inverse,inverse:c.fn,hash:c.hash})}),a.registerHelper("with",function(a,b){j(a)&&(a=a.call(this));var c=b.fn;if(f.isEmpty(a))return b.inverse(this);if(b.data&&b.ids){var d=n(b.data);d.contextPath=f.appendContextPath(b.data.contextPath,b.ids[0]),b={data:d}}return c(a,b)}),a.registerHelper("log",function(b,c){var d=c.data&&null!=c.data.level?parseInt(c.data.level,10):1;a.log(d,b)}),a.registerHelper("lookup",function(a,b){return a&&a[b]})}var e={},f=a,g=b;e.VERSION="2.0.0";e.COMPILER_REVISION=6;var h={1:"<= 1.0.rc.2",2:"== 1.0.0-rc.3",3:"== 1.0.0-rc.4",4:"== 1.x.x",5:"== 2.0.0-alpha.x",6:">= 2.0.0-beta.1"};e.REVISION_CHANGES=h;var i=f.isArray,j=f.isFunction,k=f.toString;e.HandlebarsEnvironment=c,c.prototype={constructor:c,logger:l,log:m,registerHelper:function(a,b){if("[object Object]"===k.call(a)){if(b)throw new g("Arg not supported with multiple helpers");f.extend(this.helpers,a)}else this.helpers[a]=b},unregisterHelper:function(a){delete this.helpers[a]},registerPartial:function(a,b){"[object Object]"===k.call(a)?f.extend(this.partials,a):this.partials[a]=b},unregisterPartial:function(a){delete this.partials[a]}};var l={methodMap:{0:"debug",1:"info",2:"warn",3:"error"},DEBUG:0,INFO:1,WARN:2,ERROR:3,level:3,log:function(a,b){if(l.level<=a){var c=l.methodMap[a];"undefined"!=typeof console&&console[c]&&console[c].call(console,b)}}};e.logger=l;var m=l.log;e.log=m;var n=function(a){var b=f.extend({},a);return b._parent=a,b};return e.createFrame=n,e}(b,c),e=function(a,b,c){"use strict";function d(a){var b=a&&a[0]||1,c=m;if(b!==c){if(b<c){var d=n[c],e=n[b];throw new l("Template was precompiled with an older version of Handlebars than the current runtime. Please update your precompiler to a newer version ("+d+") or downgrade your runtime to an older version ("+e+").")}throw new l("Template was precompiled with a newer version of Handlebars than the current runtime. Please update your runtime to a newer version ("+a[1]+").")}}function e(a,b){if(!b)throw new l("No environment passed to template");if(!a||!a.main)throw new l("Unknown template object: "+typeof a);b.VM.checkRevision(a.compiler);var c=function(c,d,e,f,g,h,i,j,m){g&&(f=k.extend({},f,g));var n=b.VM.invokePartial.call(this,c,e,f,h,i,j,m);if(null==n&&b.compile){var o={helpers:h,partials:i,data:j,depths:m};i[e]=b.compile(c,{data:void 0!==j,compat:a.compat},b),n=i[e](f,o)}if(null!=n){if(d){for(var p=n.split("\n"),q=0,r=p.length;q<r&&(p[q]||q+1!==r);q++)p[q]=d+p[q];n=p.join("\n")}return n}throw new l("The partial "+e+" could not be compiled when running in runtime-only mode")},d={lookup:function(a,b){for(var c=a.length,d=0;d<c;d++)if(a[d]&&null!=a[d][b])return a[d][b]},lambda:function(a,b){return"function"==typeof a?a.call(b):a},escapeExpression:k.escapeExpression,invokePartial:c,fn:function(b){return a[b]},programs:[],program:function(a,b,c){var d=this.programs[a],e=this.fn(a);return b||c?d=f(this,a,e,b,c):d||(d=this.programs[a]=f(this,a,e)),d},data:function(a,b){for(;a&&b--;)a=a._parent;return a},merge:function(a,b){var c=a||b;return a&&b&&a!==b&&(c=k.extend({},b,a)),c},noop:b.VM.noop,compilerInfo:a.compiler},e=function(b,c){c=c||{};var f=c.data;e._setup(c),!c.partial&&a.useData&&(f=i(b,f));var g;return a.useDepths&&(g=c.depths?[b].concat(c.depths):[b]),a.main.call(d,b,d.helpers,d.partials,f,g)};return e.isTop=!0,e._setup=function(c){c.partial?(d.helpers=c.helpers,d.partials=c.partials):(d.helpers=d.merge(c.helpers,b.helpers),a.usePartial&&(d.partials=d.merge(c.partials,b.partials)))},e._child=function(b,c,e){if(a.useDepths&&!e)throw new l("must pass parent depths");return f(d,b,a[b],c,e)},e}function f(a,b,c,d,e){var f=function(b,f){return f=f||{},c.call(a,b,a.helpers,a.partials,f.data||d,e&&[b].concat(e))};return f.program=b,f.depth=e?e.length:0,f}function g(a,b,c,d,e,f,g){var h={partial:!0,helpers:d,partials:e,data:f,depths:g};if(void 0===a)throw new l("The partial "+b+" could not be found");if(a instanceof Function)return a(c,h)}function h(){return""}function i(a,b){return b&&"root"in b||(b=b?o(b):{},b.root=a),b}var j={},k=a,l=b,m=c.COMPILER_REVISION,n=c.REVISION_CHANGES,o=c.createFrame;return j.checkRevision=d,j.template=e,j.program=f,j.invokePartial=g,j.noop=h,j}(b,c,d),f=function(a,b,c,d,e){"use strict";var f=a,g=b,h=c,i=d,j=e,k=function(){var a=new f.HandlebarsEnvironment;return i.extend(a,f),a.SafeString=g,a.Exception=h,a.Utils=i,a.escapeExpression=i.escapeExpression,a.VM=j,a.template=function(b){return j.template(b,a)},a},l=k();return l.create=k,l.default=l,l}(d,a,c,b,e),g=function(a){"use strict";function b(a){a=a||{},this.firstLine=a.first_line,this.firstColumn=a.first_column,this.lastColumn=a.last_column,this.lastLine=a.last_line}var c=a,d={ProgramNode:function(a,c,d){b.call(this,d),this.type="program",this.statements=a,this.strip=c},MustacheNode:function(a,c,e,f,g){if(b.call(this,g),this.type="mustache",this.strip=f,null!=e&&e.charAt){var h=e.charAt(3)||e.charAt(2);this.escaped="{"!==h&&"&"!==h}else this.escaped=!!e;a instanceof d.SexprNode?this.sexpr=a:this.sexpr=new d.SexprNode(a,c),this.id=this.sexpr.id,this.params=this.sexpr.params,this.hash=this.sexpr.hash,this.eligibleHelper=this.sexpr.eligibleHelper,this.isHelper=this.sexpr.isHelper},SexprNode:function(a,c,d){b.call(this,d),this.type="sexpr",this.hash=c;var e=this.id=a[0],f=this.params=a.slice(1);this.isHelper=!(!f.length&&!c),this.eligibleHelper=this.isHelper||e.isSimple},PartialNode:function(a,c,d,e,f){b.call(this,f),this.type="partial",this.partialName=a,this.context=c,this.hash=d,this.strip=e,this.strip.inlineStandalone=!0},BlockNode:function(a,c,d,e,f){b.call(this,f),this.type="block",this.mustache=a,this.program=c,this.inverse=d,this.strip=e,d&&!c&&(this.isInverse=!0)},RawBlockNode:function(a,e,f,g){if(b.call(this,g),a.sexpr.id.original!==f)throw new c(a.sexpr.id.original+" doesn't match "+f,this);e=new d.ContentNode(e,g),this.type="block",this.mustache=a,this.program=new d.ProgramNode([e],{},g)},ContentNode:function(a,c){b.call(this,c),this.type="content",this.original=this.string=a},HashNode:function(a,c){b.call(this,c),this.type="hash",this.pairs=a},IdNode:function(a,d){b.call(this,d),this.type="ID";for(var e="",f=[],g=0,h="",i=0,j=a.length;i<j;i++){var k=a[i].part;if(e+=(a[i].separator||"")+k,".."===k||"."===k||"this"===k){if(f.length>0)throw new c("Invalid path: "+e,this);".."===k?(g++,h+="../"):this.isScoped=!0}else f.push(k)}this.original=e,this.parts=f,this.string=f.join("."),this.depth=g,this.idName=h+this.string,this.isSimple=1===a.length&&!this.isScoped&&0===g,this.stringModeValue=this.string},PartialNameNode:function(a,c){b.call(this,c),this.type="PARTIAL_NAME",this.name=a.original},DataNode:function(a,c){b.call(this,c),this.type="DATA",this.id=a,this.stringModeValue=a.stringModeValue,this.idName="@"+a.stringModeValue},StringNode:function(a,c){b.call(this,c),this.type="STRING",this.original=this.string=this.stringModeValue=a},NumberNode:function(a,c){b.call(this,c),this.type="NUMBER",this.original=this.number=a,this.stringModeValue=Number(a)},BooleanNode:function(a,c){b.call(this,c),this.type="BOOLEAN",this.bool=a,this.stringModeValue="true"===a},CommentNode:function(a,c){b.call(this,c),this.type="comment",this.comment=a,this.strip={inlineStandalone:!0}}};return d}(c),h=function(){"use strict";return function(){function a(){this.yy={}}var b={trace:function(){},yy:{},symbols_:{error:2,root:3,program:4,EOF:5,program_repetition0:6,statement:7,mustache:8,block:9,rawBlock:10,partial:11,CONTENT:12,COMMENT:13,openRawBlock:14,END_RAW_BLOCK:15,OPEN_RAW_BLOCK:16,sexpr:17,CLOSE_RAW_BLOCK:18,openBlock:19,block_option0:20,closeBlock:21,openInverse:22,block_option1:23,OPEN_BLOCK:24,CLOSE:25,OPEN_INVERSE:26,inverseAndProgram:27,INVERSE:28,OPEN_ENDBLOCK:29,path:30,OPEN:31,OPEN_UNESCAPED:32,CLOSE_UNESCAPED:33,OPEN_PARTIAL:34,partialName:35,param:36,partial_option0:37,partial_option1:38,sexpr_repetition0:39,sexpr_option0:40,dataName:41,STRING:42,NUMBER:43,BOOLEAN:44,OPEN_SEXPR:45,CLOSE_SEXPR:46,hash:47,hash_repetition_plus0:48,hashSegment:49,ID:50,EQUALS:51,DATA:52,pathSegments:53,SEP:54,$accept:0,$end:1},terminals_:{2:"error",5:"EOF",12:"CONTENT",13:"COMMENT",15:"END_RAW_BLOCK",16:"OPEN_RAW_BLOCK",18:"CLOSE_RAW_BLOCK",24:"OPEN_BLOCK",25:"CLOSE",26:"OPEN_INVERSE",28:"INVERSE",29:"OPEN_ENDBLOCK",31:"OPEN",32:"OPEN_UNESCAPED",33:"CLOSE_UNESCAPED",34:"OPEN_PARTIAL",42:"STRING",43:"NUMBER",44:"BOOLEAN",45:"OPEN_SEXPR",46:"CLOSE_SEXPR",50:"ID",51:"EQUALS",52:"DATA",54:"SEP"},productions_:[0,[3,2],[4,1],[7,1],[7,1],[7,1],[7,1],[7,1],[7,1],[10,3],[14,3],[9,4],[9,4],[19,3],[22,3],[27,2],[21,3],[8,3],[8,3],[11,5],[11,4],[17,3],[17,1],[36,1],[36,1],[36,1],[36,1],[36,1],[36,3],[47,1],[49,3],[35,1],[35,1],[35,1],[41,2],[30,1],[53,3],[53,1],[6,0],[6,2],[20,0],[20,1],[23,0],[23,1],[37,0],[37,1],[38,0],[38,1],[39,0],[39,2],[40,0],[40,1],[48,1],[48,2]],performAction:function(a,b,c,d,e,f,g){var h=f.length-1;switch(e){case 1:return d.prepareProgram(f[h-1].statements,!0),f[h-1];case 2:this.$=new d.ProgramNode(d.prepareProgram(f[h]),{},this._$);break;case 3:case 4:case 5:case 6:this.$=f[h];break;case 7:this.$=new d.ContentNode(f[h],this._$);break;case 8:this.$=new d.CommentNode(f[h],this._$);break;case 9:this.$=new d.RawBlockNode(f[h-2],f[h-1],f[h],this._$);break;case 10:this.$=new d.MustacheNode(f[h-1],null,"","",this._$);break;case 11:this.$=d.prepareBlock(f[h-3],f[h-2],f[h-1],f[h],!1,this._$);break;case 12:this.$=d.prepareBlock(f[h-3],f[h-2],f[h-1],f[h],!0,this._$);break;case 13:case 14:this.$=new d.MustacheNode(f[h-1],null,f[h-2],d.stripFlags(f[h-2],f[h]),this._$);break;case 15:this.$={strip:d.stripFlags(f[h-1],f[h-1]),program:f[h]};break;case 16:this.$={path:f[h-1],strip:d.stripFlags(f[h-2],f[h])};break;case 17:case 18:this.$=new d.MustacheNode(f[h-1],null,f[h-2],d.stripFlags(f[h-2],f[h]),this._$);break;case 19:this.$=new d.PartialNode(f[h-3],f[h-2],f[h-1],d.stripFlags(f[h-4],f[h]),this._$);break;case 20:this.$=new d.PartialNode(f[h-2],void 0,f[h-1],d.stripFlags(f[h-3],f[h]),this._$);break;case 21:this.$=new d.SexprNode([f[h-2]].concat(f[h-1]),f[h],this._$);break;case 22:this.$=new d.SexprNode([f[h]],null,this._$);break;case 23:this.$=f[h];break;case 24:this.$=new d.StringNode(f[h],this._$);break;case 25:this.$=new d.NumberNode(f[h],this._$);break;case 26:this.$=new d.BooleanNode(f[h],this._$);break;case 27:this.$=f[h];break;case 28:f[h-1].isHelper=!0,this.$=f[h-1];break;case 29:this.$=new d.HashNode(f[h],this._$);break;case 30:this.$=[f[h-2],f[h]];break;case 31:this.$=new d.PartialNameNode(f[h],this._$);break;case 32:this.$=new d.PartialNameNode(new d.StringNode(f[h],this._$),this._$);break;case 33:this.$=new d.PartialNameNode(new d.NumberNode(f[h],this._$));break;case 34:this.$=new d.DataNode(f[h],this._$);break;case 35:this.$=new d.IdNode(f[h],this._$);break;case 36:f[h-2].push({part:f[h],separator:f[h-1]}),this.$=f[h-2];break;case 37:this.$=[{part:f[h]}];break;case 38:this.$=[];break;case 39:f[h-1].push(f[h]);break;case 48:this.$=[];break;case 49:f[h-1].push(f[h]);break;case 52:this.$=[f[h]];break;case 53:f[h-1].push(f[h])}},table:[{3:1,4:2,5:[2,38],6:3,12:[2,38],13:[2,38],16:[2,38],24:[2,38],26:[2,38],31:[2,38],32:[2,38],34:[2,38]},{1:[3]},{5:[1,4]},{5:[2,2],7:5,8:6,9:7,10:8,11:9,12:[1,10],13:[1,11],14:16,16:[1,20],19:14,22:15,24:[1,18],26:[1,19],28:[2,2],29:[2,2],31:[1,12],32:[1,13],34:[1,17]},{1:[2,1]},{5:[2,39],12:[2,39],13:[2,39],16:[2,39],24:[2,39],26:[2,39],28:[2,39],29:[2,39],31:[2,39],32:[2,39],34:[2,39]},{5:[2,3],12:[2,3],13:[2,3],16:[2,3],24:[2,3],26:[2,3],28:[2,3],29:[2,3],31:[2,3],32:[2,3],34:[2,3]},{5:[2,4],12:[2,4],13:[2,4],16:[2,4],24:[2,4],26:[2,4],28:[2,4],29:[2,4],31:[2,4],32:[2,4],34:[2,4]},{5:[2,5],12:[2,5],13:[2,5],16:[2,5],24:[2,5],26:[2,5],28:[2,5],29:[2,5],31:[2,5],32:[2,5],34:[2,5]},{5:[2,6],12:[2,6],13:[2,6],16:[2,6],24:[2,6],26:[2,6],28:[2,6],29:[2,6],31:[2,6],32:[2,6],34:[2,6]},{5:[2,7],12:[2,7],13:[2,7],16:[2,7],24:[2,7],26:[2,7],28:[2,7],29:[2,7],31:[2,7],32:[2,7],34:[2,7]},{5:[2,8],12:[2,8],13:[2,8],16:[2,8],24:[2,8],26:[2,8],28:[2,8],29:[2,8],31:[2,8],32:[2,8],34:[2,8]},{17:21,30:22,41:23,50:[1,26],52:[1,25],53:24},{17:27,30:22,41:23,50:[1,26],52:[1,25],53:24},{4:28,6:3,12:[2,38],13:[2,38],16:[2,38],24:[2,38],26:[2,38],28:[2,38],29:[2,38],31:[2,38],32:[2,38],34:[2,38]},{4:29,6:3,12:[2,38],13:[2,38],16:[2,38],24:[2,38],26:[2,38],28:[2,38],29:[2,38],31:[2,38],32:[2,38],34:[2,38]},{12:[1,30]},{30:32,35:31,42:[1,33],43:[1,34],50:[1,26],53:24},{17:35,30:22,41:23,50:[1,26],52:[1,25],53:24},{17:36,30:22,41:23,50:[1,26],52:[1,25],53:24},{17:37,30:22,41:23,50:[1,26],52:[1,25],53:24},{25:[1,38]},{18:[2,48],25:[2,48],33:[2,48],39:39,42:[2,48],43:[2,48],44:[2,48],45:[2,48],46:[2,48],50:[2,48],52:[2,48]},{18:[2,22],25:[2,22],33:[2,22],46:[2,22]},{18:[2,35],25:[2,35],33:[2,35],42:[2,35],43:[2,35],44:[2,35],45:[2,35],46:[2,35],50:[2,35],52:[2,35],54:[1,40]},{30:41,50:[1,26],53:24},{18:[2,37],25:[2,37],33:[2,37],42:[2,37],43:[2,37],44:[2,37],45:[2,37],46:[2,37],50:[2,37],52:[2,37],54:[2,37]},{33:[1,42]},{20:43,27:44,28:[1,45],29:[2,40]},{23:46,27:47,28:[1,45],29:[2,42]},{15:[1,48]},{25:[2,46],30:51,36:49,38:50,41:55,42:[1,52],43:[1,53],44:[1,54],45:[1,56],47:57,48:58,49:60,50:[1,59],52:[1,25],53:24},{25:[2,31],42:[2,31],43:[2,31],44:[2,31],45:[2,31],50:[2,31],52:[2,31]},{25:[2,32],42:[2,32],43:[2,32],44:[2,32],45:[2,32],50:[2,32],52:[2,32]},{25:[2,33],42:[2,33],43:[2,33],44:[2,33],45:[2,33],50:[2,33],52:[2,33]},{25:[1,61]},{25:[1,62]},{18:[1,63]},{5:[2,17],12:[2,17],13:[2,17],16:[2,17],24:[2,17],26:[2,17],28:[2,17],29:[2,17],31:[2,17],32:[2,17],34:[2,17]},{18:[2,50],25:[2,50],30:51,33:[2,50],36:65,40:64,41:55,42:[1,52],43:[1,53],44:[1,54],45:[1,56],46:[2,50],47:66,48:58,49:60,50:[1,59],52:[1,25],53:24},{50:[1,67]},{18:[2,34],25:[2,34],33:[2,34],42:[2,34],43:[2,34],44:[2,34],45:[2,34],46:[2,34],50:[2,34],52:[2,34]},{5:[2,18],12:[2,18],13:[2,18],16:[2,18],24:[2,18],26:[2,18],28:[2,18],29:[2,18],31:[2,18],32:[2,18],34:[2,18]},{21:68,29:[1,69]},{29:[2,41]},{4:70,6:3,12:[2,38],13:[2,38],16:[2,38],24:[2,38],26:[2,38],29:[2,38],31:[2,38],32:[2,38],34:[2,38]},{21:71,29:[1,69]},{29:[2,43]},{5:[2,9],12:[2,9],13:[2,9],16:[2,9],24:[2,9],26:[2,9],28:[2,9],29:[2,9],31:[2,9],32:[2,9],34:[2,9]},{25:[2,44],37:72,47:73,48:58,49:60,50:[1,74]},{25:[1,75]},{18:[2,23],25:[2,23],33:[2,23],42:[2,23],43:[2,23],44:[2,23],45:[2,23],46:[2,23],50:[2,23],52:[2,23]},{18:[2,24],25:[2,24],33:[2,24],42:[2,24],43:[2,24],44:[2,24],45:[2,24],46:[2,24],50:[2,24],52:[2,24]},{18:[2,25],25:[2,25],33:[2,25],42:[2,25],43:[2,25],44:[2,25],45:[2,25],46:[2,25],50:[2,25],52:[2,25]},{18:[2,26],25:[2,26],33:[2,26],42:[2,26],43:[2,26],44:[2,26],45:[2,26],46:[2,26],50:[2,26],52:[2,26]},{18:[2,27],25:[2,27],33:[2,27],42:[2,27],43:[2,27],44:[2,27],45:[2,27],46:[2,27],50:[2,27],52:[2,27]},{17:76,30:22,41:23,50:[1,26],52:[1,25],53:24},{25:[2,47]},{18:[2,29],25:[2,29],33:[2,29],46:[2,29],49:77,50:[1,74]},{18:[2,37],25:[2,37],33:[2,37],42:[2,37],43:[2,37],44:[2,37],45:[2,37],46:[2,37],50:[2,37],51:[1,78],52:[2,37],54:[2,37]},{18:[2,52],25:[2,52],33:[2,52],46:[2,52],50:[2,52]},{12:[2,13],13:[2,13],16:[2,13],24:[2,13],26:[2,13],28:[2,13],29:[2,13],31:[2,13],32:[2,13],34:[2,13]},{12:[2,14],13:[2,14],16:[2,14],24:[2,14],26:[2,14],28:[2,14],29:[2,14],31:[2,14],32:[2,14],34:[2,14]},{12:[2,10]},{18:[2,21],25:[2,21],33:[2,21],46:[2,21]},{18:[2,49],25:[2,49],33:[2,49],42:[2,49],43:[2,49],44:[2,49],45:[2,49],46:[2,49],50:[2,49],52:[2,49]},{18:[2,51],25:[2,51],33:[2,51],46:[2,51]},{18:[2,36],25:[2,36],33:[2,36],42:[2,36],43:[2,36],44:[2,36],45:[2,36],46:[2,36],50:[2,36],52:[2,36],54:[2,36]},{5:[2,11],12:[2,11],13:[2,11],16:[2,11],24:[2,11],26:[2,11],28:[2,11],29:[2,11],31:[2,11],32:[2,11],34:[2,11]},{30:79,50:[1,26],53:24},{29:[2,15]},{5:[2,12],12:[2,12],13:[2,12],16:[2,12],24:[2,12],26:[2,12],28:[2,12],29:[2,12],31:[2,12],32:[2,12],34:[2,12]},{25:[1,80]},{25:[2,45]},{51:[1,78]},{5:[2,20],12:[2,20],13:[2,20],16:[2,20],24:[2,20],26:[2,20],28:[2,20],29:[2,20],31:[2,20],32:[2,20],34:[2,20]},{46:[1,81]},{18:[2,53],25:[2,53],33:[2,53],46:[2,53],50:[2,53]},{30:51,36:82,41:55,42:[1,52],43:[1,53],44:[1,54],45:[1,56],50:[1,26],52:[1,25],53:24},{25:[1,83]},{5:[2,19],12:[2,19],13:[2,19],16:[2,19],24:[2,19],26:[2,19],28:[2,19],29:[2,19],31:[2,19],32:[2,19],34:[2,19]},{18:[2,28],25:[2,28],33:[2,28],42:[2,28],43:[2,28],44:[2,28],45:[2,28],46:[2,28],50:[2,28],52:[2,28]},{18:[2,30],25:[2,30],33:[2,30],46:[2,30],50:[2,30]},{5:[2,16],12:[2,16],13:[2,16],16:[2,16],24:[2,16],26:[2,16],28:[2,16],29:[2,16],31:[2,16],32:[2,16],34:[2,16]}],defaultActions:{4:[2,1],44:[2,41],47:[2,43],57:[2,47],63:[2,10],70:[2,15],73:[2,45]},parseError:function(a,b){throw new Error(a)},parse:function(a){var b=this,c=[0],d=[null],e=[],f=this.table,g="",h=0,i=0,j=0;this.lexer.setInput(a),this.lexer.yy=this.yy,this.yy.lexer=this.lexer,this.yy.parser=this,void 0===this.lexer.yylloc&&(this.lexer.yylloc={});var k=this.lexer.yylloc;e.push(k);var l=this.lexer.options&&this.lexer.options.ranges;"function"==typeof this.yy.parseError&&(this.parseError=this.yy.parseError);for(var m,n,o,p,q,r,s,t,u,v={};;){if(o=c[c.length-1],this.defaultActions[o]?p=this.defaultActions[o]:(null!==m&&void 0!==m||(m=function(){var a;return a=b.lexer.lex()||1,"number"!=typeof a&&(a=b.symbols_[a]||a),a}()),p=f[o]&&f[o][m]),void 0===p||!p.length||!p[0]){var w="";if(!j){u=[];for(r in f[o])this.terminals_[r]&&r>2&&u.push("'"+this.terminals_[r]+"'");w=this.lexer.showPosition?"Parse error on line "+(h+1)+":\n"+this.lexer.showPosition()+"\nExpecting "+u.join(", ")+", got '"+(this.terminals_[m]||m)+"'":"Parse error on line "+(h+1)+": Unexpected "+(1==m?"end of input":"'"+(this.terminals_[m]||m)+"'"),this.parseError(w,{text:this.lexer.match,token:this.terminals_[m]||m,line:this.lexer.yylineno,loc:k,expected:u})}}if(p[0]instanceof Array&&p.length>1)throw new Error("Parse Error: multiple actions possible at state: "+o+", token: "+m);switch(p[0]){case 1:c.push(m),d.push(this.lexer.yytext),e.push(this.lexer.yylloc),c.push(p[1]),m=null,n?(m=n,n=null):(i=this.lexer.yyleng,g=this.lexer.yytext,h=this.lexer.yylineno,k=this.lexer.yylloc,j>0&&j--);break;case 2:if(s=this.productions_[p[1]][1],v.$=d[d.length-s],v._$={first_line:e[e.length-(s||1)].first_line,last_line:e[e.length-1].last_line,first_column:e[e.length-(s||1)].first_column,last_column:e[e.length-1].last_column},l&&(v._$.range=[e[e.length-(s||1)].range[0],e[e.length-1].range[1]]),void 0!==(q=this.performAction.call(v,g,i,h,this.yy,p[1],d,e)))return q;s&&(c=c.slice(0,-1*s*2),d=d.slice(0,-1*s),e=e.slice(0,-1*s)),c.push(this.productions_[p[1]][0]),d.push(v.$),e.push(v._$),t=f[c[c.length-2]][c[c.length-1]],c.push(t);break;case 3:return!0}}return!0}},c=function(){var a={EOF:1,parseError:function(a,b){if(!this.yy.parser)throw new Error(a);this.yy.parser.parseError(a,b)},setInput:function(a){return this._input=a,this._more=this._less=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match="",this.conditionStack=["INITIAL"],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},input:function(){var a=this._input[0];return this.yytext+=a,this.yyleng++,this.offset++,this.match+=a,this.matched+=a,a.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),a},unput:function(a){var b=a.length,c=a.split(/(?:\r\n?|\n)/g);this._input=a+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-b-1),this.offset-=b;var d=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),c.length-1&&(this.yylineno-=c.length-1);var e=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:c?(c.length===d.length?this.yylloc.first_column:0)+d[d.length-c.length].length-c[0].length:this.yylloc.first_column-b},this.options.ranges&&(this.yylloc.range=[e[0],e[0]+this.yyleng-b]),this},more:function(){return this._more=!0,this},less:function(a){this.unput(this.match.slice(a))},pastInput:function(){var a=this.matched.substr(0,this.matched.length-this.match.length);return(a.length>20?"...":"")+a.substr(-20).replace(/\n/g,"")},upcomingInput:function(){var a=this.match;return a.length<20&&(a+=this._input.substr(0,20-a.length)),(a.substr(0,20)+(a.length>20?"...":"")).replace(/\n/g,"")},showPosition:function(){var a=this.pastInput(),b=new Array(a.length+1).join("-");return a+this.upcomingInput()+"\n"+b+"^"},next:function(){if(this.done)return this.EOF;this._input||(this.done=!0);var a,b,c,d,e;this._more||(this.yytext="",this.match="");for(var f=this._currentRules(),g=0;g<f.length&&(!(c=this._input.match(this.rules[f[g]]))||b&&!(c[0].length>b[0].length)||(b=c,d=g,this.options.flex));g++);return b?(e=b[0].match(/(?:\r\n?|\n).*/g),e&&(this.yylineno+=e.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:e?e[e.length-1].length-e[e.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+b[0].length},this.yytext+=b[0],this.match+=b[0],this.matches=b,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._input=this._input.slice(b[0].length),this.matched+=b[0],a=this.performAction.call(this,this.yy,this,f[d],this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),a||void 0):""===this._input?this.EOF:this.parseError("Lexical error on line "+(this.yylineno+1)+". Unrecognized text.\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})},lex:function(){var a=this.next();return void 0!==a?a:this.lex()},begin:function(a){this.conditionStack.push(a)},popState:function(){return this.conditionStack.pop()},_currentRules:function(){return this.conditions[this.conditionStack[this.conditionStack.length-1]].rules},topState:function(){return this.conditionStack[this.conditionStack.length-2]},pushState:function(a){this.begin(a)}};return a.options={},a.performAction=function(a,b,c,d){function e(a,c){return b.yytext=b.yytext.substr(a,b.yyleng-c)}switch(c){case 0:if("\\\\"===b.yytext.slice(-2)?(e(0,1),this.begin("mu")):"\\"===b.yytext.slice(-1)?(e(0,1),this.begin("emu")):this.begin("mu"),b.yytext)return 12;break;case 1:return 12;case 2:return this.popState(),12;case 3:return b.yytext=b.yytext.substr(5,b.yyleng-9),this.popState(),15;case 4:return 12;case 5:return e(0,4),this.popState(),13;case 6:return 45;case 7:return 46;case 8:return 16;case 9:return this.popState(),this.begin("raw"),18;case 10:return 34;case 11:return 24;case 12:return 29;case 13:case 14:return this.popState(),28;case 15:case 16:return 26;case 17:return 32;case 18:return 31;case 19:this.popState(),this.begin("com");break;case 20:return e(3,5),this.popState(),13;case 21:return 31;case 22:return 51;case 23:case 24:return 50;case 25:return 54;case 26:break;case 27:return this.popState(),33;case 28:return this.popState(),25;case 29:return b.yytext=e(1,2).replace(/\\"/g,'"'),42;case 30:return b.yytext=e(1,2).replace(/\\'/g,"'"),42;case 31:return 52;case 32:case 33:return 44;case 34:return 43;case 35:return 50;case 36:return b.yytext=e(1,2),50;case 37:return"INVALID";case 38:return 5}},a.rules=[/^(?:[^\x00]*?(?=(\{\{)))/,/^(?:[^\x00]+)/,/^(?:[^\x00]{2,}?(?=(\{\{|\\\{\{|\\\\\{\{|$)))/,/^(?:\{\{\{\{\/[^\s!"#%-,\.\/;->@\[-\^`\{-~]+(?=[=}\s\/.])\}\}\}\})/,/^(?:[^\x00]*?(?=(\{\{\{\{\/)))/,/^(?:[\s\S]*?--\}\})/,/^(?:\()/,/^(?:\))/,/^(?:\{\{\{\{)/,/^(?:\}\}\}\})/,/^(?:\{\{(~)?>)/,/^(?:\{\{(~)?#)/,/^(?:\{\{(~)?\/)/,/^(?:\{\{(~)?\^\s*(~)?\}\})/,/^(?:\{\{(~)?\s*else\s*(~)?\}\})/,/^(?:\{\{(~)?\^)/,/^(?:\{\{(~)?\s*else\b)/,/^(?:\{\{(~)?\{)/,/^(?:\{\{(~)?&)/,/^(?:\{\{!--)/,/^(?:\{\{![\s\S]*?\}\})/,/^(?:\{\{(~)?)/,/^(?:=)/,/^(?:\.\.)/,/^(?:\.(?=([=~}\s\/.)])))/,/^(?:[\/.])/,/^(?:\s+)/,/^(?:\}(~)?\}\})/,/^(?:(~)?\}\})/,/^(?:"(\\["]|[^"])*")/,/^(?:'(\\[']|[^'])*')/,/^(?:@)/,/^(?:true(?=([~}\s)])))/,/^(?:false(?=([~}\s)])))/,/^(?:-?[0-9]+(?:\.[0-9]+)?(?=([~}\s)])))/,/^(?:([^\s!"#%-,\.\/;->@\[-\^`\{-~]+(?=([=~}\s\/.)]))))/,/^(?:\[[^\]]*\])/,/^(?:.)/,/^(?:$)/],a.conditions={mu:{rules:[6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38],inclusive:!1},emu:{rules:[2],inclusive:!1},com:{rules:[5],inclusive:!1},raw:{rules:[3,4],inclusive:!1},INITIAL:{rules:[0,1,38],inclusive:!0}},a}();return b.lexer=c,a.prototype=b,b.Parser=a,new a}()}(),i=function(a){"use strict";function b(a,b){return{left:"~"===a.charAt(2),right:"~"===b.charAt(b.length-3)}}function c(a,b,c,d,i,k){if(a.sexpr.id.original!==d.path.original)throw new j(a.sexpr.id.original+" doesn't match "+d.path.original,a);var l=c&&c.program,m={left:a.strip.left,right:d.strip.right,openStandalone:f(b.statements),closeStandalone:e((l||b).statements)};if(a.strip.right&&g(b.statements,null,!0),l){var n=c.strip;n.left&&h(b.statements,null,!0),n.right&&g(l.statements,null,!0),d.strip.left&&h(l.statements,null,!0),e(b.statements)&&f(l.statements)&&(h(b.statements),g(l.statements))}else d.strip.left&&h(b.statements,null,!0);return i?new this.BlockNode(a,l,b,m,k):new this.BlockNode(a,b,l,m,k)}function d(a,b){for(var c=0,d=a.length;c<d;c++){var i=a[c],j=i.strip;if(j){var k=e(a,c,b,i.type),l=f(a,c,b),m=j.openStandalone&&k,n=j.closeStandalone&&l,o=j.inlineStandalone&&k&&l;j.right&&g(a,c,!0),j.left&&h(a,c,!0),o&&(g(a,c),h(a,c)&&"partial"===i.type&&(i.indent=/([ \t]+$)/.exec(a[c-1].original)?RegExp.$1:"")),m&&(g((i.program||i.inverse).statements),h(a,c)),n&&(g(a,c),h((i.inverse||i.program).statements))}}return a}function e(a,b,c){void 0===b&&(b=a.length);var d=a[b-1],e=a[b-2];return d?"content"===d.type?(e||!c?/\r?\n\s*?$/:/(^|\r?\n)\s*?$/).test(d.original):void 0:c}function f(a,b,c){void 0===b&&(b=-1);var d=a[b+1],e=a[b+2];return d?"content"===d.type?(e||!c?/^\s*?\r?\n/:/^\s*?(\r?\n|$)/).test(d.original):void 0:c}function g(a,b,c){var d=a[null==b?0:b+1];if(d&&"content"===d.type&&(c||!d.rightStripped)){var e=d.string;d.string=d.string.replace(c?/^\s+/:/^[ \t]*\r?\n?/,""),d.rightStripped=d.string!==e}}function h(a,b,c){var d=a[null==b?a.length-1:b-1];if(d&&"content"===d.type&&(c||!d.leftStripped)){var e=d.string;return d.string=d.string.replace(c?/\s+$/:/[ \t]+$/,""),d.leftStripped=d.string!==e,d.leftStripped}}var i={},j=a;return i.stripFlags=b,i.prepareBlock=c,i.prepareProgram=d,i}(c),j=function(a,b,c,d){"use strict";function e(a){return a.constructor===h.ProgramNode?a:(g.yy=k,g.parse(a))}var f={},g=a,h=b,i=c,j=d.extend;f.parser=g;var k={};return j(k,i,h),f.parse=e,f}(h,g,i,b),k=function(a,b){"use strict";function c(){}function d(a,b,c){if(null==a||"string"!=typeof a&&a.constructor!==c.AST.ProgramNode)throw new h("You must pass a string or Handlebars AST to Handlebars.precompile. You passed "+a);b=b||{},"data"in b||(b.data=!0),b.compat&&(b.useDepths=!0);var d=c.parse(a),e=(new c.Compiler).compile(d,b);return(new c.JavaScriptCompiler).compile(e,b)}function e(a,b,c){function d(){var d=c.parse(a),e=(new c.Compiler).compile(d,b),f=(new c.JavaScriptCompiler).compile(e,b,void 0,!0);return c.template(f)}
2
+ if(null==a||"string"!=typeof a&&a.constructor!==c.AST.ProgramNode)throw new h("You must pass a string or Handlebars AST to Handlebars.compile. You passed "+a);b=b||{},"data"in b||(b.data=!0),b.compat&&(b.useDepths=!0);var e,f=function(a,b){return e||(e=d()),e.call(this,a,b)};return f._setup=function(a){return e||(e=d()),e._setup(a)},f._child=function(a,b,c){return e||(e=d()),e._child(a,b,c)},f}function f(a,b){if(a===b)return!0;if(i(a)&&i(b)&&a.length===b.length){for(var c=0;c<a.length;c++)if(!f(a[c],b[c]))return!1;return!0}}var g={},h=a,i=b.isArray,j=[].slice;return g.Compiler=c,c.prototype={compiler:c,equals:function(a){var b=this.opcodes.length;if(a.opcodes.length!==b)return!1;for(var c=0;c<b;c++){var d=this.opcodes[c],e=a.opcodes[c];if(d.opcode!==e.opcode||!f(d.args,e.args))return!1}for(b=this.children.length,c=0;c<b;c++)if(!this.children[c].equals(a.children[c]))return!1;return!0},guid:0,compile:function(a,b){this.opcodes=[],this.children=[],this.depths={list:[]},this.options=b,this.stringParams=b.stringParams,this.trackIds=b.trackIds;var c=this.options.knownHelpers;if(this.options.knownHelpers={helperMissing:!0,blockHelperMissing:!0,each:!0,if:!0,unless:!0,with:!0,log:!0,lookup:!0},c)for(var d in c)this.options.knownHelpers[d]=c[d];return this.accept(a)},accept:function(a){return this[a.type](a)},program:function(a){for(var b=a.statements,c=0,d=b.length;c<d;c++)this.accept(b[c]);return this.isSimple=1===d,this.depths.list=this.depths.list.sort(function(a,b){return a-b}),this},compileProgram:function(a){var b,c=(new this.compiler).compile(a,this.options),d=this.guid++;this.usePartial=this.usePartial||c.usePartial,this.children[d]=c;for(var e=0,f=c.depths.list.length;e<f;e++)(b=c.depths.list[e])<2||this.addDepth(b-1);return d},block:function(a){var b=a.mustache,c=a.program,d=a.inverse;c&&(c=this.compileProgram(c)),d&&(d=this.compileProgram(d));var e=b.sexpr,f=this.classifySexpr(e);"helper"===f?this.helperSexpr(e,c,d):"simple"===f?(this.simpleSexpr(e),this.opcode("pushProgram",c),this.opcode("pushProgram",d),this.opcode("emptyHash"),this.opcode("blockValue",e.id.original)):(this.ambiguousSexpr(e,c,d),this.opcode("pushProgram",c),this.opcode("pushProgram",d),this.opcode("emptyHash"),this.opcode("ambiguousBlockValue")),this.opcode("append")},hash:function(a){var b,c,d=a.pairs;for(this.opcode("pushHash"),b=0,c=d.length;b<c;b++)this.pushParam(d[b][1]);for(;b--;)this.opcode("assignToHash",d[b][0]);this.opcode("popHash")},partial:function(a){var b=a.partialName;this.usePartial=!0,a.hash?this.accept(a.hash):this.opcode("push","undefined"),a.context?this.accept(a.context):(this.opcode("getContext",0),this.opcode("pushContext")),this.opcode("invokePartial",b.name,a.indent||""),this.opcode("append")},content:function(a){a.string&&this.opcode("appendContent",a.string)},mustache:function(a){this.sexpr(a.sexpr),a.escaped&&!this.options.noEscape?this.opcode("appendEscaped"):this.opcode("append")},ambiguousSexpr:function(a,b,c){var d=a.id,e=d.parts[0],f=null!=b||null!=c;this.opcode("getContext",d.depth),this.opcode("pushProgram",b),this.opcode("pushProgram",c),this.ID(d),this.opcode("invokeAmbiguous",e,f)},simpleSexpr:function(a){var b=a.id;"DATA"===b.type?this.DATA(b):b.parts.length?this.ID(b):(this.addDepth(b.depth),this.opcode("getContext",b.depth),this.opcode("pushContext")),this.opcode("resolvePossibleLambda")},helperSexpr:function(a,b,c){var d=this.setupFullMustacheParams(a,b,c),e=a.id,f=e.parts[0];if(this.options.knownHelpers[f])this.opcode("invokeKnownHelper",d.length,f);else{if(this.options.knownHelpersOnly)throw new h("You specified knownHelpersOnly, but used the unknown helper "+f,a);e.falsy=!0,this.ID(e),this.opcode("invokeHelper",d.length,e.original,e.isSimple)}},sexpr:function(a){var b=this.classifySexpr(a);"simple"===b?this.simpleSexpr(a):"helper"===b?this.helperSexpr(a):this.ambiguousSexpr(a)},ID:function(a){this.addDepth(a.depth),this.opcode("getContext",a.depth),a.parts[0]?this.opcode("lookupOnContext",a.parts,a.falsy,a.isScoped):this.opcode("pushContext")},DATA:function(a){this.options.data=!0,this.opcode("lookupData",a.id.depth,a.id.parts)},STRING:function(a){this.opcode("pushString",a.string)},NUMBER:function(a){this.opcode("pushLiteral",a.number)},BOOLEAN:function(a){this.opcode("pushLiteral",a.bool)},comment:function(){},opcode:function(a){this.opcodes.push({opcode:a,args:j.call(arguments,1)})},addDepth:function(a){0!==a&&(this.depths[a]||(this.depths[a]=!0,this.depths.list.push(a)))},classifySexpr:function(a){var b=a.isHelper,c=a.eligibleHelper,d=this.options;if(c&&!b){var e=a.id.parts[0];d.knownHelpers[e]?b=!0:d.knownHelpersOnly&&(c=!1)}return b?"helper":c?"ambiguous":"simple"},pushParams:function(a){for(var b=0,c=a.length;b<c;b++)this.pushParam(a[b])},pushParam:function(a){this.stringParams?(a.depth&&this.addDepth(a.depth),this.opcode("getContext",a.depth||0),this.opcode("pushStringParam",a.stringModeValue,a.type),"sexpr"===a.type&&this.sexpr(a)):(this.trackIds&&this.opcode("pushId",a.type,a.idName||a.stringModeValue),this.accept(a))},setupFullMustacheParams:function(a,b,c){var d=a.params;return this.pushParams(d),this.opcode("pushProgram",b),this.opcode("pushProgram",c),a.hash?this.hash(a.hash):this.opcode("emptyHash"),d}},g.precompile=d,g.compile=e,g}(c,b),l=function(a,b){"use strict";function c(a){this.value=a}function d(){}var e=a.COMPILER_REVISION,f=a.REVISION_CHANGES,g=b;d.prototype={nameLookup:function(a,b){return d.isValidJavaScriptVariableName(b)?a+"."+b:a+"['"+b+"']"},depthedLookup:function(a){return this.aliases.lookup="this.lookup",'lookup(depths, "'+a+'")'},compilerInfo:function(){var a=e;return[a,f[a]]},appendToBuffer:function(a){return this.environment.isSimple?"return "+a+";":{appendToBuffer:!0,content:a,toString:function(){return"buffer += "+a+";"}}},initializeBuffer:function(){return this.quotedString("")},namespace:"Handlebars",compile:function(a,b,c,d){this.environment=a,this.options=b,this.stringParams=this.options.stringParams,this.trackIds=this.options.trackIds,this.precompile=!d,this.name=this.environment.name,this.isChild=!!c,this.context=c||{programs:[],environments:[]},this.preamble(),this.stackSlot=0,this.stackVars=[],this.aliases={},this.registers={list:[]},this.hashes=[],this.compileStack=[],this.inlineStack=[],this.compileChildren(a,b),this.useDepths=this.useDepths||a.depths.list.length||this.options.compat;var e,f,h,i=a.opcodes;for(f=0,h=i.length;f<h;f++)e=i[f],this[e.opcode].apply(this,e.args);if(this.pushSource(""),this.stackSlot||this.inlineStack.length||this.compileStack.length)throw new g("Compile completed with content left on stack");var j=this.createFunctionContext(d);if(this.isChild)return j;var k={compiler:this.compilerInfo(),main:j},l=this.context.programs;for(f=0,h=l.length;f<h;f++)l[f]&&(k[f]=l[f]);return this.environment.usePartial&&(k.usePartial=!0),this.options.data&&(k.useData=!0),this.useDepths&&(k.useDepths=!0),this.options.compat&&(k.compat=!0),d||(k.compiler=JSON.stringify(k.compiler),k=this.objectLiteral(k)),k},preamble:function(){this.lastContext=0,this.source=[]},createFunctionContext:function(a){var b="",c=this.stackVars.concat(this.registers.list);c.length>0&&(b+=", "+c.join(", "));for(var d in this.aliases)this.aliases.hasOwnProperty(d)&&(b+=", "+d+"="+this.aliases[d]);var e=["depth0","helpers","partials","data"];this.useDepths&&e.push("depths");var f=this.mergeSource(b);return a?(e.push(f),Function.apply(this,e)):"function("+e.join(",")+") {\n "+f+"}"},mergeSource:function(a){for(var b,c,d="",e=!this.forceBuffer,f=0,g=this.source.length;f<g;f++){var h=this.source[f];h.appendToBuffer?b=b?b+"\n + "+h.content:h.content:(b&&(d?d+="buffer += "+b+";\n ":(c=!0,d=b+";\n "),b=void 0),d+=h+"\n ",this.environment.isSimple||(e=!1))}return e?!b&&d||(d+="return "+(b||'""')+";\n"):(a+=", buffer = "+(c?"":this.initializeBuffer()),d+=b?"return buffer + "+b+";\n":"return buffer;\n"),a&&(d="var "+a.substring(2)+(c?"":";\n ")+d),d},blockValue:function(a){this.aliases.blockHelperMissing="helpers.blockHelperMissing";var b=[this.contextName(0)];this.setupParams(a,0,b);var c=this.popStack();b.splice(1,0,c),this.push("blockHelperMissing.call("+b.join(", ")+")")},ambiguousBlockValue:function(){this.aliases.blockHelperMissing="helpers.blockHelperMissing";var a=[this.contextName(0)];this.setupParams("",0,a,!0),this.flushInline();var b=this.topStack();a.splice(1,0,b),this.pushSource("if (!"+this.lastHelper+") { "+b+" = blockHelperMissing.call("+a.join(", ")+"); }")},appendContent:function(a){this.pendingContent&&(a=this.pendingContent+a),this.pendingContent=a},append:function(){this.flushInline();var a=this.popStack();this.pushSource("if ("+a+" != null) { "+this.appendToBuffer(a)+" }"),this.environment.isSimple&&this.pushSource("else { "+this.appendToBuffer("''")+" }")},appendEscaped:function(){this.aliases.escapeExpression="this.escapeExpression",this.pushSource(this.appendToBuffer("escapeExpression("+this.popStack()+")"))},getContext:function(a){this.lastContext=a},pushContext:function(){this.pushStackLiteral(this.contextName(this.lastContext))},lookupOnContext:function(a,b,c){var d=0,e=a.length;for(c||!this.options.compat||this.lastContext?this.pushContext():this.push(this.depthedLookup(a[d++]));d<e;d++)this.replaceStack(function(c){var e=this.nameLookup(c,a[d],"context");return b?" && "+e:" != null ? "+e+" : "+c})},lookupData:function(a,b){a?this.pushStackLiteral("this.data(data, "+a+")"):this.pushStackLiteral("data");for(var c=b.length,d=0;d<c;d++)this.replaceStack(function(a){return" && "+this.nameLookup(a,b[d],"data")})},resolvePossibleLambda:function(){this.aliases.lambda="this.lambda",this.push("lambda("+this.popStack()+", "+this.contextName(0)+")")},pushStringParam:function(a,b){this.pushContext(),this.pushString(b),"sexpr"!==b&&("string"==typeof a?this.pushString(a):this.pushStackLiteral(a))},emptyHash:function(){this.pushStackLiteral("{}"),this.trackIds&&this.push("{}"),this.stringParams&&(this.push("{}"),this.push("{}"))},pushHash:function(){this.hash&&this.hashes.push(this.hash),this.hash={values:[],types:[],contexts:[],ids:[]}},popHash:function(){var a=this.hash;this.hash=this.hashes.pop(),this.trackIds&&this.push("{"+a.ids.join(",")+"}"),this.stringParams&&(this.push("{"+a.contexts.join(",")+"}"),this.push("{"+a.types.join(",")+"}")),this.push("{\n "+a.values.join(",\n ")+"\n }")},pushString:function(a){this.pushStackLiteral(this.quotedString(a))},push:function(a){return this.inlineStack.push(a),a},pushLiteral:function(a){this.pushStackLiteral(a)},pushProgram:function(a){null!=a?this.pushStackLiteral(this.programExpression(a)):this.pushStackLiteral(null)},invokeHelper:function(a,b,c){this.aliases.helperMissing="helpers.helperMissing";var d=this.popStack(),e=this.setupHelper(a,b),f=(c?e.name+" || ":"")+d+" || helperMissing";this.push("(("+f+").call("+e.callParams+"))")},invokeKnownHelper:function(a,b){var c=this.setupHelper(a,b);this.push(c.name+".call("+c.callParams+")")},invokeAmbiguous:function(a,b){this.aliases.functionType='"function"',this.aliases.helperMissing="helpers.helperMissing",this.useRegister("helper");var c=this.popStack();this.emptyHash();var d=this.setupHelper(0,a,b),e=this.lastHelper=this.nameLookup("helpers",a,"helper");this.push("((helper = (helper = "+e+" || "+c+") != null ? helper : helperMissing"+(d.paramsInit?"),("+d.paramsInit:"")+"),(typeof helper === functionType ? helper.call("+d.callParams+") : helper))")},invokePartial:function(a,b){var c=[this.nameLookup("partials",a,"partial"),"'"+b+"'","'"+a+"'",this.popStack(),this.popStack(),"helpers","partials"];this.options.data?c.push("data"):this.options.compat&&c.push("undefined"),this.options.compat&&c.push("depths"),this.push("this.invokePartial("+c.join(", ")+")")},assignToHash:function(a){var b,c,d,e=this.popStack();this.trackIds&&(d=this.popStack()),this.stringParams&&(c=this.popStack(),b=this.popStack());var f=this.hash;b&&f.contexts.push("'"+a+"': "+b),c&&f.types.push("'"+a+"': "+c),d&&f.ids.push("'"+a+"': "+d),f.values.push("'"+a+"': ("+e+")")},pushId:function(a,b){"ID"===a||"DATA"===a?this.pushString(b):"sexpr"===a?this.pushStackLiteral("true"):this.pushStackLiteral("null")},compiler:d,compileChildren:function(a,b){for(var c,d,e=a.children,f=0,g=e.length;f<g;f++){c=e[f],d=new this.compiler;var h=this.matchExistingProgram(c);null==h?(this.context.programs.push(""),h=this.context.programs.length,c.index=h,c.name="program"+h,this.context.programs[h]=d.compile(c,b,this.context,!this.precompile),this.context.environments[h]=c,this.useDepths=this.useDepths||d.useDepths):(c.index=h,c.name="program"+h)}},matchExistingProgram:function(a){for(var b=0,c=this.context.environments.length;b<c;b++){var d=this.context.environments[b];if(d&&d.equals(a))return b}},programExpression:function(a){var b=this.environment.children[a],c=(b.depths.list,this.useDepths),d=[b.index,"data"];return c&&d.push("depths"),"this.program("+d.join(", ")+")"},useRegister:function(a){this.registers[a]||(this.registers[a]=!0,this.registers.list.push(a))},pushStackLiteral:function(a){return this.push(new c(a))},pushSource:function(a){this.pendingContent&&(this.source.push(this.appendToBuffer(this.quotedString(this.pendingContent))),this.pendingContent=void 0),a&&this.source.push(a)},pushStack:function(a){this.flushInline();var b=this.incrStack();return this.pushSource(b+" = "+a+";"),this.compileStack.push(b),b},replaceStack:function(a){var b,d,e,f="";this.isInline();if(!this.isInline())throw new g("replaceStack on non-inline");var h=this.popStack(!0);if(h instanceof c)f=b=h.value,e=!0;else{d=!this.stackSlot;var i=d?this.incrStack():this.topStackName();f="("+this.push(i)+" = "+h+")",b=this.topStack()}var j=a.call(this,b);e||this.popStack(),d&&this.stackSlot--,this.push("("+f+j+")")},incrStack:function(){return this.stackSlot++,this.stackSlot>this.stackVars.length&&this.stackVars.push("stack"+this.stackSlot),this.topStackName()},topStackName:function(){return"stack"+this.stackSlot},flushInline:function(){var a=this.inlineStack;if(a.length){this.inlineStack=[];for(var b=0,d=a.length;b<d;b++){var e=a[b];e instanceof c?this.compileStack.push(e):this.pushStack(e)}}},isInline:function(){return this.inlineStack.length},popStack:function(a){var b=this.isInline(),d=(b?this.inlineStack:this.compileStack).pop();if(!a&&d instanceof c)return d.value;if(!b){if(!this.stackSlot)throw new g("Invalid stack pop");this.stackSlot--}return d},topStack:function(){var a=this.isInline()?this.inlineStack:this.compileStack,b=a[a.length-1];return b instanceof c?b.value:b},contextName:function(a){return this.useDepths&&a?"depths["+a+"]":"depth"+a},quotedString:function(a){return'"'+a.replace(/\\/g,"\\\\").replace(/"/g,'\\"').replace(/\n/g,"\\n").replace(/\r/g,"\\r").replace(/\u2028/g,"\\u2028").replace(/\u2029/g,"\\u2029")+'"'},objectLiteral:function(a){var b=[];for(var c in a)a.hasOwnProperty(c)&&b.push(this.quotedString(c)+":"+a[c]);return"{"+b.join(",")+"}"},setupHelper:function(a,b,c){var d=[];return{params:d,paramsInit:this.setupParams(b,a,d,c),name:this.nameLookup("helpers",b,"helper"),callParams:[this.contextName(0)].concat(d).join(", ")}},setupOptions:function(a,b,c){var d,e,f,g={},h=[],i=[],j=[];g.name=this.quotedString(a),g.hash=this.popStack(),this.trackIds&&(g.hashIds=this.popStack()),this.stringParams&&(g.hashTypes=this.popStack(),g.hashContexts=this.popStack()),e=this.popStack(),((f=this.popStack())||e)&&(f||(f="this.noop"),e||(e="this.noop"),g.fn=f,g.inverse=e);for(var k=b;k--;)d=this.popStack(),c[k]=d,this.trackIds&&(j[k]=this.popStack()),this.stringParams&&(i[k]=this.popStack(),h[k]=this.popStack());return this.trackIds&&(g.ids="["+j.join(",")+"]"),this.stringParams&&(g.types="["+i.join(",")+"]",g.contexts="["+h.join(",")+"]"),this.options.data&&(g.data="data"),g},setupParams:function(a,b,c,d){var e=this.objectLiteral(this.setupOptions(a,b,c));return d?(this.useRegister("options"),c.push("options"),"options="+e):(c.push(e),"")}};for(var h="break else new var case finally return void catch for switch while continue function this with default if throw delete in try do instanceof typeof abstract enum int short boolean export interface static byte extends long super char final native synchronized class float package throws const goto private transient debugger implements protected volatile double import public let yield".split(" "),i=d.RESERVED_WORDS={},j=0,k=h.length;j<k;j++)i[h[j]]=!0;return d.isValidJavaScriptVariableName=function(a){return!d.RESERVED_WORDS[a]&&/^[a-zA-Z_$][0-9a-zA-Z_$]*$/.test(a)},d}(d,c);return function(a,b,c,d,e){"use strict";var f=a,g=b,h=c.parser,i=c.parse,j=d.Compiler,k=d.compile,l=d.precompile,m=e,n=f.create,o=function(){var a=n();return a.compile=function(b,c){return k(b,c,a)},a.precompile=function(b,c){return l(b,c,a)},a.AST=g,a.Compiler=j,a.JavaScriptCompiler=m,a.Parser=h,a.parse=i,a};return f=o(),f.create=o,f.default=f,f}(f,g,j,k,l)}),Handlebars.registerHelper("is_single",function(a,b){return 1===Object.keys(a).length&&b.fn(this)}),Handlebars.registerHelper("script",function(a){return a.hash.src?'<script type="text/javascript" src="'+a.fn(this)+'"></script>':'<script type="text/javascript">'+a.fn(this)+"</script>"}),Handlebars.registerHelper("is",function(a,b){return"@key"===b.hash.value&&(b.hash.value=b.data.key),b.hash.value===a?b.fn(this):this[b.hash.value]&&this[b.hash.value]===a?b.fn(this):b.inverse(this)});
assets/build/js/i18n/al.js ADDED
@@ -0,0 +1,29 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ // Validation errors messages for Parsley
2
+
3
+
4
+ Parsley.addMessages('al', {
5
+ defaultMessage: "Kjo vlerë është invalide.",
6
+ type: {
7
+ email: "Kjo vlerë duhet të ketë formë valide të një email adrese.",
8
+ url: "Kjo vlerë duhet të ketë formë valide të një URL-je.",
9
+ number: "Kjo vlerë duhet të jetë numërike.",
10
+ integer: "Kjo vlerë duhet të jetë numër i plotë.",
11
+ digits: "Kjo vlerë duhet të jetë shifër.",
12
+ alphanum: "Kjo vlerë duhet të jetë alfanumerike."
13
+ },
14
+ notblank: "Kjo vlerë nuk duhet të jetë e zbrazët.",
15
+ required: "Kjo vlerë kërkohet domosdosmërisht.",
16
+ pattern: "Kjo vlerë është invalide.",
17
+ min: "Kjo vlerë duhet të jetë më e madhe ose e barabartë me %s.",
18
+ max: "Kjo vlerë duhet të jetë më e vogël ose e barabartë me %s.",
19
+ range: "Kjo vlerë duhet të jetë në mes të %s dhe %s.",
20
+ minlength: "Kjo vlerë është shum e shkurtë. Ajo duhet të ketë %s apo më shum shkronja.",
21
+ maxlength: "Kjo vlerë është shum e gjatë. Ajo duhet të ketë %s apo më pak shkronja",
22
+ length: "Gjatësia e kësaj vlere është invalide. Ajo duhet të jetë në mes të %s dhe %s shkronjash.",
23
+ mincheck: "Ju duhet të zgjedhni së paku %s zgjedhje.",
24
+ maxcheck: "Ju duhet të zgjedhni %s ose më pak zgjedhje.",
25
+ check: "Ju duhet të zgjedhni në mes të %s dhe %s zgjedhjeve.",
26
+ equalto: "Kjo vlerë duhet të jetë e njejtë."
27
+ });
28
+
29
+ Parsley.setLocale('al');
assets/build/js/i18n/eu.js ADDED
@@ -0,0 +1,29 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ // Validation errors messages for Parsley
2
+ // Load this after Parsley
3
+
4
+ Parsley.addMessages('eu', {
5
+ defaultMessage: "Balio hau baliogabekoa dirudi.",
6
+ type: {
7
+ email: "Balio honek posta balioduna izan behar da.",
8
+ url: "Balio honek URL balioduna izan behar da.",
9
+ number: "Balio honek zenbaki balioduna izan behar da.",
10
+ integer: "Balio honek zenbaki balioduna izan behar da.",
11
+ digits: "Balio honek digitu balioduna izan behar da.",
12
+ alphanum: "Balio honek alfanumerikoa izan behar da."
13
+ },
14
+ notblank: "Balio honek ezin da hutsik egon.",
15
+ required: "Balio hau nahitaezkoa da.",
16
+ pattern: "Balio hau ez da zuzena.",
17
+ min: "Balio honek %s baino baxuagoa ezin da izan.",
18
+ max: "Balio honek %s baino altuagoa ezin da izan.",
19
+ range: "Balio honek %s eta %s artean egon behar da.",
20
+ minlength: "Balio hau oso motza da. Gutxienezko luzera %s karakteretakoa da.",
21
+ maxlength: "Balio hau oso luzea da. Gehienezko luzera %s karakteretakoa da.",
22
+ length: "Balio honen luzera %s eta %s karaketere artean egon behar da.",
23
+ mincheck: "%s aukera hautatu behar dituzu gutxienez.",
24
+ maxcheck: "%s aukera edo gutxiago hautatu behar dituzu.",
25
+ check: "%s eta %s aukeren artean hautatu behar duzu.",
26
+ equalto: "Balio honek berbera izan behar da."
27
+ });
28
+
29
+ Parsley.setLocale('eu');
assets/build/js/i18n/fr.extra.js CHANGED
@@ -2,6 +2,13 @@
2
  // Load this after Parsley
3
 
4
  Parsley.addMessages('fr', {
5
- dateiso: "Cette valeur n'est pas une date valide (YYYY-MM-DD).",
 
 
 
 
 
 
 
6
  notequalto: "Cette valeur doit être différente."
7
  });
2
  // Load this after Parsley
3
 
4
  Parsley.addMessages('fr', {
5
+ dateiso: "Cette valeur n'est pas une date valide (YYYY-MM-DD).",
6
+ minwords: "Cette valeur est trop courte. Elle doit contenir au moins %s mots.",
7
+ maxwords: "Cette valeur est trop longue. Elle doit contenir tout au plus %s mots.",
8
+ words: "Cette valeur est invalide. Elle doit contenir entre %s et %s mots.",
9
+ gt: "Cette valeur doit être plus grande.",
10
+ gte: "Cette valeur doit être plus grande ou égale.",
11
+ lt: "Cette valeur doit être plus petite.",
12
+ lte: "Cette valeur doit être plus petite ou égale.",
13
  notequalto: "Cette valeur doit être différente."
14
  });
assets/build/js/i18n/fr.js CHANGED
@@ -1,6 +1,7 @@
1
- // Load this after Parsley to add these error messages
 
2
 
3
- window.Parsley.addMessages('fr', {
4
  defaultMessage: "Cette valeur semble non valide.",
5
  type: {
6
  email: "Cette valeur n'est pas une adresse email valide.",
@@ -24,3 +25,5 @@ window.Parsley.addMessages('fr', {
24
  check: "Vous devez sélectionner entre %s et %s choix.",
25
  equalto: "Cette valeur devrait être identique."
26
  });
 
 
1
+ // Validation errors messages for Parsley
2
+ // Load this after Parsley
3
 
4
+ Parsley.addMessages('fr', {
5
  defaultMessage: "Cette valeur semble non valide.",
6
  type: {
7
  email: "Cette valeur n'est pas une adresse email valide.",
25
  check: "Vous devez sélectionner entre %s et %s choix.",
26
  equalto: "Cette valeur devrait être identique."
27
  });
28
+
29
+ Parsley.setLocale('fr');
assets/build/js/i18n/hr.extra.js ADDED
@@ -0,0 +1,14 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ // Validation errors messages for Parsley
2
+ // Load this after Parsley
3
+
4
+ Parsley.addMessages('hr', {
5
+ dateiso: "Ovo polje treba sadržavati ispravno unešen datum (GGGG-MM-DD).",
6
+ minwords: "Unos je prekratak. Treba sadržavati %s ili više riječi.",
7
+ maxwords: "Unos je predugačak. Treba sadržavati %s ili manje riječi.",
8
+ words: "Neispravna duljina unosa. Treba sadržavati između %s i %s riječi.",
9
+ gt: "Ova vrijednost treba biti veća.",
10
+ gte: "Ova vrijednost treba biti veća ili jednaka.",
11
+ lt: "Ova vrijednost treba biti manja.",
12
+ lte: "Ova vrijednost treba biti manja ili jednaka.",
13
+ notequalto: "Ova vrijednost treba biti drugačija."
14
+ });
assets/build/js/i18n/hr.js ADDED
@@ -0,0 +1,29 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ // Validation errors messages for Parsley
2
+ // Load this after Parsley
3
+
4
+ Parsley.addMessages('hr', {
5
+ defaultMessage: "Neispravan unos.",
6
+ type: {
7
+ email: "Ovo polje treba sadržavati ispravnu email adresu.",
8
+ url: "Ovo polje treba sadržavati ispravni url.",
9
+ number: "Ovo polje treba sadržavati ispravno upisan broj.",
10
+ integer: "Ovo polje treba sadržavati ispravno upisan cijeli broj.",
11
+ digits: "Ovo polje treba sadržavati znamenke.",
12
+ alphanum: "Ovo polje treba sadržavati brojke ili slova."
13
+ },
14
+ notblank: "Ovo polje ne smije biti prazno.",
15
+ required: "Ovo polje je obavezno.",
16
+ pattern: "Neispravan unos.",
17
+ min: "Vrijednost treba biti jednaka ili veća od %s.",
18
+ max: "Vrijednost treba biti jednaka ili manja od %s.",
19
+ range: "Vrijednost treba biti između %s i %s.",
20
+ minlength: "Unos je prekratak. Treba sadržavati %s ili više znakova.",
21
+ maxlength: "Unos je predugačak. Treba sadržavati %s ili manje znakova.",
22
+ length: "Neispravna duljina unosa. Treba sadržavati između %s i %s znakova.",
23
+ mincheck: "Treba odabrati najmanje %s izbora.",
24
+ maxcheck: "Treba odabrati %s ili manje izbora.",
25
+ check: "Treba odabrati između %s i %s izbora.",
26
+ equalto: "Ova vrijednost treba biti ista."
27
+ });
28
+
29
+ Parsley.setLocale('hr');
assets/build/js/i18n/hu.extra.js ADDED
@@ -0,0 +1,14 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ // Validation errors messages for Parsley
2
+ // Load this after Parsley
3
+
4
+ Parsley.addMessages('hu', {
5
+ dateiso: "A mező értéke csak érvényes dátum lehet (YYYY-MM-DD).",
6
+ minwords: "Minimum %s szó megadása szükséges.",
7
+ maxwords: "Maximum %s szó megadása engedélyezett.",
8
+ words: "Minimum %s, maximum %s szó megadása szükséges.",
9
+ gt: "A mező értéke nagyobb kell legyen.",
10
+ gte: "A mező értéke nagyobb vagy egyenlő kell legyen.",
11
+ lt: "A mező értéke kevesebb kell legyen.",
12
+ lte: "A mező értéke kevesebb vagy egyenlő kell legyen.",
13
+ notequalto: "Az érték különböző kell legyen."
14
+ });
assets/build/js/i18n/hu.js ADDED
@@ -0,0 +1,30 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ // This is included with the Parsley library itself,
2
+ // thus there is no use in adding it to your project.
3
+
4
+
5
+ Parsley.addMessages('hu', {
6
+ defaultMessage: "Érvénytelen mező.",
7
+ type: {
8
+ email: "Érvénytelen email cím.",
9
+ url: "Érvénytelen URL cím.",
10
+ number: "Érvénytelen szám.",
11
+ integer: "Érvénytelen egész szám.",
12
+ digits: "Érvénytelen szám.",
13
+ alphanum: "Érvénytelen alfanumerikus érték."
14
+ },
15
+ notblank: "Ez a mező nem maradhat üresen.",
16
+ required: "A mező kitöltése kötelező.",
17
+ pattern: "Érvénytelen érték.",
18
+ min: "A mező értéke nagyobb vagy egyenlő kell legyen mint %s.",
19
+ max: "A mező értéke kisebb vagy egyenlő kell legyen mint %s.",
20
+ range: "A mező értéke %s és %s közé kell essen.",
21
+ minlength: "Legalább %s karakter megadása szükséges.",
22
+ maxlength: "Legfeljebb %s karakter megadása engedélyezett.",
23
+ length: "Nem megfelelő karakterszám. Minimum %s, maximum %s karakter adható meg.",
24
+ mincheck: "Legalább %s értéket kell kiválasztani.",
25
+ maxcheck: "Maximum %s értéket lehet kiválasztani.",
26
+ check: "Legalább %s, legfeljebb %s értéket kell kiválasztani.",
27
+ equalto: "A mező értéke nem egyező."
28
+ });
29
+
30
+ Parsley.setLocale('hu');
assets/build/js/i18n/ja.extra.js ADDED
@@ -0,0 +1,14 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ // Validation errors messages for Parsley
2
+ // Load this after Parsley
3
+
4
+ Parsley.addMessages('ja', {
5
+ dateiso: "有効な日付を入力してください。 (YYYY-MM-DD).",
6
+ minwords: "語句が短すぎます。 %s 語以上で入力してください。",
7
+ maxwords: "語句が長すぎます。 %s 語以内で入力してください。",
8
+ words: "語句の長さが正しくありません。 %s 語から %s 語の間で入力してください。",
9
+ gt: "より大きい値を入力してください。",
10
+ gte: "より大きいか、同じ値を入力してください。",
11
+ lt: "より小さい値を入力してください。",
12
+ lte: "より小さいか、同じ値を入力してください。",
13
+ notequalto: "異なる値を入力してください。"
14
+ });
assets/build/js/i18n/ja.js CHANGED
@@ -4,12 +4,12 @@
4
  Parsley.addMessages('ja', {
5
  defaultMessage: "無効な値です。",
6
  type: {
7
- email: "正しいメールアドレスを入力してください。",
8
- url: "正しいURLを入力してください。",
9
- number: "正しい数字を入力してください。",
10
- integer: "正しい数値を入力してください。",
11
- digits: "正しい桁数で入力してください。",
12
- alphanum: "正しい英数字を入力してください。"
13
  },
14
  notblank: "この値を入力してください",
15
  required: "この値は必須です。",
4
  Parsley.addMessages('ja', {
5
  defaultMessage: "無効な値です。",
6
  type: {
7
+ email: "有効なメールアドレスを入力してください。",
8
+ url: "有効なURLを入力してください。",
9
+ number: "数値を入力してください。",
10
+ integer: "整数を入力してください。",
11
+ digits: "数字を入力してください。",
12
+ alphanum: "英数字を入力してください。"
13
  },
14
  notblank: "この値を入力してください",
15
  required: "この値は必須です。",
assets/build/js/i18n/ko.js CHANGED
@@ -7,7 +7,7 @@ Parsley.addMessages('ko', {
7
  email: "입력하신 이메일이 유효하지 않습니다.",
8
  url: "입력하신 URL이 유효하지 않습니다.",
9
  number: "입력하신 전화번호가 올바르지 않습니다.",
10
- integer: "입력하신 URL이 유효하지 않습니다.",
11
  digits: "숫자를 입력하여 주십시오.",
12
  alphanum: "입력하신 내용은 알파벳과 숫자의 조합이어야 합니다."
13
  },
7
  email: "입력하신 이메일이 유효하지 않습니다.",
8
  url: "입력하신 URL이 유효하지 않습니다.",
9
  number: "입력하신 전화번호가 올바르지 않습니다.",
10
+ integer: "입력하신 정수가 유효하지 않습니다.",
11
  digits: "숫자를 입력하여 주십시오.",
12
  alphanum: "입력하신 내용은 알파벳과 숫자의 조합이어야 합니다."
13
  },
assets/build/js/i18n/lt.extra.js ADDED
@@ -0,0 +1,14 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ // Validation errors messages for Parsley
2
+ // Load this after Parsley
3
+
4
+ Parsley.addMessages('lt', {
5
+ dateiso: "Šis įrašas turi būti teisingo formato data (YYYY-MM-DD).",
6
+ minwords: "Šis įrašas turi turėti ne mažiau kaip %s žodžių.",
7
+ maxwords: "Šis įrašas turi turėti ne daugiau kaip %s žodžių.",
8
+ words: "Šis įrašas turi turėti nuo %s iki %s žodžių.",
9
+ gt: "Ši vertė turi būti didesnė.",
10
+ gte: "Ši vertė turi būti didesnė arba lygi.",
11
+ lt: "Ši vertė turi būti mažesnė.",
12
+ lte: "Ši vertė turi būti mažesnė arba lygi.",
13
+ notequalto: "Ši vertė turi būti skirtinga."
14
+ });
assets/build/js/i18n/lt.js ADDED
@@ -0,0 +1,29 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ // Validation errors messages for Parsley
2
+ // Load this after Parsley
3
+
4
+ Parsley.addMessages('lt', {
5
+ defaultMessage: "Šis įrašas neteisingas.",
6
+ type: {
7
+ email: "Šis įrašas nėra teisingas el. paštas.",
8
+ url: "Šis įrašas nėra teisingas url.",
9
+ number: "Šis įrašas nėra skaičius.",
10
+ integer: "Šis įrašas nėra sveikasis skaičius.",
11
+ digits: "Šis įrašas turi būti skaičius.",
12
+ alphanum: "Šis įrašas turi būti iš skaičių ir raidžių."
13
+ },
14
+ notblank: "Šis įrašas negali būti tuščias.",
15
+ required: "Šis įrašas yra privalomas",
16
+ pattern: "Šis įrašas neteisingas.",
17
+ min: "Ši vertė turi būti didesnė arba lygi %s.",
18
+ max: "Ši vertė turi būti mažesnė arba lygi %s.",
19
+ range: "Ši vertė turi būti tarp %s ir %s.",
20
+ minlength: "Šis įrašas per trumpas. Jis turi turėti %s simbolius arba daugiau.",
21
+ maxlength: "Šis įrašas per ilgas. Jis turi turėti %s simbolius arba mažiau.",
22
+ length: "Šio įrašo ilgis neteisingas. Jis turėtų būti tarp %s ir %s simbolių.",
23
+ mincheck: "Jūs turite pasirinkti bent %s pasirinkimus.",
24
+ maxcheck: "Jūs turite pasirinkti ne daugiau %s pasirinkimų.",
25
+ check: "Jūs turite pasirinkti tarp %s ir %s pasirinkimų.",
26
+ equalto: "Ši reikšmė turėtų būti vienoda."
27
+ });
28
+
29
+ Parsley.setLocale('lt');
assets/build/js/i18n/lv.extra.js ADDED
@@ -0,0 +1,14 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ // Validation errors messages for Parsley
2
+ // Load this after Parsley
3
+
4
+ Parsley.addMessages('lv', {
5
+ dateiso: "Šai vērtībai jābūt korekti noformētam datumam (YYYY-MM-DD).",
6
+ minwords: "Šī vērtība ir par īsu. Tai jābūt vismaz %s vārdus garai.",
7
+ maxwords: "Šī vērtība ir par garu. Tai jābūt %s vārdus garai vai īsākai.",
8
+ words: "Šīs vērtības garums ir nederīgs. Tai jābūt no %s līdz %s vārdus garai.",
9
+ gt: "Šai vērtībai jābūt lielākai.",
10
+ gte: "Šai vērtībai jābūt lielākai vai vienādai.",
11
+ lt: "Šai vērtībai jābūt mazākai.",
12
+ lte: "Šai vērtībai jābūt mazākai vai vienādai.",
13
+ notequalto: "Šai vērtībai jābūt atšķirīgai."
14
+ });
assets/build/js/i18n/lv.js ADDED
@@ -0,0 +1,29 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ // Validation errors messages for Parsley
2
+ // Load this after Parsley
3
+
4
+ Parsley.addMessages('lv', {
5
+ defaultMessage: "Šis ieraksts veikts nekorekti.",
6
+ type: {
7
+ email: "Šeit jāieraksta derīgs e-pasts.",
8
+ url: "Šeit jāieraksta korekts url.",
9
+ number: "Šeit jāieraksta derīgs skaitlis.",
10
+ integer: "Šeit jāieraksta vesels skaitlis.",
11
+ digits: "Šeit jāieraksta cipari.",
12
+ alphanum: "Šeit derīgi tikai alfabēta burti vai cipari."
13
+ },
14
+ notblank: "Šis ieraksts nedrīkst būt tukšs.",
15
+ required: "Šis ieraksts ir obligāti jāaizpilda.",
16
+ pattern: "Šis ieraksts aizpildīts nekorekti.",
17
+ min: "Šai vērtībai jābūt lielākai vai vienādai ar %s.",
18
+ max: "Šai vērtībai jābūt mazākai vai vienādai ar %s.",
19
+ range: "Šai vērtībai jābūt starp %s un %s.",
20
+ minlength: "Vērtībai jābūt vismaz %s simbolu garai.",
21
+ maxlength: "Vērtībai jābūt %s simbolus garai vai īsākai.",
22
+ length: "Šīs vērtības garums ir neatbilstošs. Tai jābūt %s līdz %s simbolus garai.",
23
+ mincheck: "Jāizvēlas vismaz %s varianti.",
24
+ maxcheck: "Jāizvēlas %s varianti vai mazāk.",
25
+ check: "Jāizvēlas no %s līdz %s variantiem.",
26
+ equalto: "Šai vērtībai jāsakrīt."
27
+ });
28
+
29
+ Parsley.setLocale('lv');
assets/build/js/i18n/no.js CHANGED
@@ -4,25 +4,25 @@
4
  Parsley.addMessages('no', {
5
  defaultMessage: "Verdien er ugyldig.",
6
  type: {
7
- email: "Verdien må være en gyldig e-post.",
8
  url: "Verdien må være en gyldig url.",
9
  number: "Verdien må være et gyldig tall.",
10
  integer: "Verdien må være et gyldig heltall.",
11
- digits: "Verdien må være et siffer",
12
  alphanum: "Verdien må være alfanumerisk"
13
  },
14
- notblank: "Verdien ikke være blank.",
15
  required: "Verdien er obligatorisk.",
16
  pattern: "Verdien er ugyldig.",
17
  min: "Verdien må være større eller lik %s.",
18
  max: "Verdien må være mindre eller lik %s.",
19
  range: "Verdien må være mellom %s and %s.",
20
- minlength: "Verdien er for kort. Den burde bestå av minst %s tegn.",
21
  maxlength: "Verdien er for lang. Den kan bestå av maksimalt %s tegn.",
22
- length: "Verdilengden er ugyldig. Den må være mellom %s og %s tegn lang.",
23
- mincheck: "Du må huke av minst %s valg.",
24
- maxcheck: "Du må huke av %s valg eller mindre.",
25
- check: "Du må huke av mellom %s og %s valg.",
26
  equalto: "Verdien må være lik."
27
  });
28
 
4
  Parsley.addMessages('no', {
5
  defaultMessage: "Verdien er ugyldig.",
6
  type: {
7
+ email: "Verdien må være en gyldig e-postadresse.",
8
  url: "Verdien må være en gyldig url.",
9
  number: "Verdien må være et gyldig tall.",
10
  integer: "Verdien må være et gyldig heltall.",
11
+ digits: "Verdien må være et siffer.",
12
  alphanum: "Verdien må være alfanumerisk"
13
  },
14
+ notblank: "Verdien kan ikke være blank.",
15
  required: "Verdien er obligatorisk.",
16
  pattern: "Verdien er ugyldig.",
17
  min: "Verdien må være større eller lik %s.",
18
  max: "Verdien må være mindre eller lik %s.",
19
  range: "Verdien må være mellom %s and %s.",
20
+ minlength: "Verdien er for kort. Den bestå av minst %s tegn.",
21
  maxlength: "Verdien er for lang. Den kan bestå av maksimalt %s tegn.",
22
+ length: "Verdien har ugyldig lengde. Den må være mellom %s og %s tegn lang.",
23
+ mincheck: "Du må velge minst %s alternativer.",
24
+ maxcheck: "Du må velge %s eller færre alternativer.",
25
+ check: "Du må velge mellom %s og %s alternativer.",
26
  equalto: "Verdien må være lik."
27
  });
28
 
assets/build/js/i18n/pl.js CHANGED
@@ -7,23 +7,23 @@ Parsley.addMessages('pl', {
7
  email: "Wpisz poprawny adres e-mail.",
8
  url: "Wpisz poprawny adres URL.",
9
  number: "Wpisz poprawną liczbę.",
10
- integer: "Dozwolone jedynie liczby człkowite.",
11
- digits: "Dozwolone jedynie cyfry.",
12
- alphanum: "Dozwolone jedynie znaki alfanumeryczne."
13
  },
14
- notblank: "Pole nie może zostać puste",
15
  required: "Pole jest wymagane.",
16
- pattern: "Wartość wygląda na nieprawidłową.",
17
- min: "Wartość powinna być większa od %s.",
18
- max: "Wartość powinna być mniejsza od %s.",
19
- range: "Wartość powinna być większa od %s i mniejsza od %s.",
20
- minlength: "Ilość znaków powinna wynosić %s lub więcej.",
21
- maxlength: "Ilość znaków powinna wynosić %s lub mniej.",
22
- length: "Ilość znaków powinna wynosić od %s do %s.",
23
- mincheck: "Musisz wybrać minimum %s opcji.",
24
- maxcheck: "Możesz wybrać maksymalnie %s opcji.",
25
- check: "Minimalnie możesz wybrać od %s do %s opcji",
26
- equalto: "Wartości nie są identyczne"
27
  });
28
 
29
  Parsley.setLocale('pl');
7
  email: "Wpisz poprawny adres e-mail.",
8
  url: "Wpisz poprawny adres URL.",
9
  number: "Wpisz poprawną liczbę.",
10
+ integer: "Dozwolone jedynie liczby całkowite.",
11
+ digits: "Dozwolone jedynie cyfry.",
12
+ alphanum: "Dozwolone jedynie znaki alfanumeryczne."
13
  },
14
+ notblank: "Pole nie może być puste.",
15
  required: "Pole jest wymagane.",
16
+ pattern: "Pole zawiera nieprawidłową wartość.",
17
+ min: "Wartość nie może być mniejsza od %s.",
18
+ max: "Wartość nie może być większa od %s.",
19
+ range: "Wartość powinna zaweriać się pomiędzy %s a %s.",
20
+ minlength: "Minimalna ilość znaków wynosi %s.",
21
+ maxlength: "Maksymalna ilość znaków wynosi %s.",
22
+ length: "Ilość znaków wynosi od %s do %s.",
23
+ mincheck: "Wybierz minimalnie %s opcji.",
24
+ maxcheck: "Wybierz maksymalnie %s opcji.",
25
+ check: "Wybierz od %s do %s opcji.",
26
+ equalto: "Wartości nie są identyczne."
27
  });
28
 
29
  Parsley.setLocale('pl');
assets/build/js/i18n/ru.extra.js CHANGED
@@ -5,5 +5,10 @@ Parsley.addMessages('ru', {
5
  dateiso: "Это значение должно быть корректной датой (ГГГГ-ММ-ДД).",
6
  minwords: "Это значение должно содержать не менее %s слов.",
7
  maxwords: "Это значение должно содержать не более %s слов.",
8
- words: "Это значение должно содержать от %s до %s слов."
 
 
 
 
 
9
  });
5
  dateiso: "Это значение должно быть корректной датой (ГГГГ-ММ-ДД).",
6
  minwords: "Это значение должно содержать не менее %s слов.",
7
  maxwords: "Это значение должно содержать не более %s слов.",
8
+ words: "Это значение должно содержать от %s до %s слов.",
9
+ gt: "Это значение должно быть больше.",
10
+ gte: "Это значение должно быть больше или равно.",
11
+ lt: "Это значение должно быть меньше.",
12
+ lte: "Это значение должно быть меньше или равно.",
13
+ notequalto: "Это значение должно отличаться."
14
  });
assets/build/js/i18n/sk.extra.js ADDED
@@ -0,0 +1,13 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ // Validation errors messages for Parsley
2
+ // Load this after Parsley
3
+
4
+ Parsley.addMessages('sk', {
5
+ dateiso: "Prosím zadajte dátum vo formáte RRRR-MM-DD.",
6
+ minwords: "Prosím zadajte hodnotu dlhú %s slov a viacej.",
7
+ maxwords: "Prosím zadajte hodnotu kratšiu ako %s slov.",
8
+ words: "Prosím zadajte hodnotu medzi %s a %s slov.",
9
+ gt: "Táto hodnota musí byť väčšia.",
10
+ gte: "Táto hodnota musí byť väčšia alebo rovná.",
11
+ lt: "Táto hodnota musí byť menšia.",
12
+ lte: "Táto hodnota musí byť menšia alebo rovná."
13
+ });
assets/build/js/i18n/sk.js ADDED
@@ -0,0 +1,29 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ // Validation errors messages for Parsley
2
+ // Load this after Parsley
3
+
4
+ Parsley.addMessages('sk', {
5
+ defaultMessage: "Prosím zadajte správnu hodnotu.",
6
+ type: {
7
+ email: "Prosím zadajte správnu emailovú adresu.",
8
+ url: "Prosím zadajte platnú URL adresu.",
9
+ number: "Toto pole môže obsahovať len čísla",
10
+ integer: "Toto pole môže obsahovať len celé čísla",
11
+ digits: "Toto pole môže obsahovať len kladné celé čísla.",
12
+ alphanum: "Toto pole môže obsahovať len alfanumerické znaky."
13
+ },
14
+ notblank: "Toto pole nesmie byť prázdne.",
15
+ required: "Toto pole je povinné.",
16
+ pattern: "Toto pole je je neplatné.",
17
+ min: "Prosím zadajte hodnotu väčšiu alebo rovnú %s.",
18
+ max: "Prosím zadajte hodnotu menšiu alebo rovnú %s.",
19
+ range: "Prosím zadajte hodnotu v rozmedzí %s a %s",
20
+ minlength: "Prosím zadajte hodnotu dlhú %s znakov a viacej.",
21
+ maxlength: "Prosím zadajte hodnotu kratšiu ako %s znakov.",
22
+ length: "Prosím zadajte hodnotu medzi %s a %s znakov.",
23
+ mincheck: "Je nutné vybrať minimálne %s z možností.",
24
+ maxcheck: "Je nutné vybrať maximálne %s z možností.",
25
+ check: "Je nutné vybrať od %s do %s z možností.",
26
+ equalto: "Prosím zadajte rovnakú hodnotu."
27
+ });
28
+
29
+ Parsley.setLocale('sk');
assets/build/js/i18n/sl.extra.js ADDED
@@ -0,0 +1,14 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ // Validation errors messages for Parsley
2
+ // Load this after Parsley
3
+
4
+ Parsley.addMessages('sl', {
5
+ dateiso: "Vnesite datum v ISO obliki (YYYY-MM-DD).",
6
+ minwords: "Vpis je prekratek. Vpisati morate najmnaj %s besed.",
7
+ maxwords: "Vpis je predolg. Vpišete lahko največ %s besed.",
8
+ words: "Dolžina vpisa je napačna. Dolžina je lahko samo med %s in %s besed.",
9
+ gt: "Vpisani podatek mora biti večji.",
10
+ gte: "Vpisani podatek mora biti enak ali večji.",
11
+ lt: "Vpisani podatek mora biti manjši.",
12
+ lte: "Vpisani podatek mora biti enak ali manjši.",
13
+ notequalto: "Vpisana vrednost mora biti drugačna."
14
+ });
assets/build/js/i18n/sl.js ADDED
@@ -0,0 +1,30 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ // This is included with the Parsley library itself,
2
+ // thus there is no use in adding it to your project.
3
+
4
+
5
+ Parsley.addMessages('sl', {
6
+ defaultMessage: "Podatek ne ustreza vpisnim kriterijem.",
7
+ type: {
8
+ email: "Vpišite pravilen email.",
9
+ url: "Vpišite pravilen url naslov.",
10
+ number: "Vpišite številko.",
11
+ integer: "Vpišite celo število brez decimalnih mest.",
12
+ digits: "Vpišite samo cifre.",
13
+ alphanum: "Vpišite samo alfanumerične znake (cifre in črke)."
14
+ },
15
+ notblank: "To polje ne sme biti prazno.",
16
+ required: "To polje je obvezno.",
17
+ pattern: "Podatek ne ustreza vpisnim kriterijem.",
18
+ min: "Vrednost mora biti višja ali enaka kot %s.",
19
+ max: "Vrednost mora biti nižja ali enaka kot %s.",
20
+ range: "Vrednost mora biti med %s in %s.",
21
+ minlength: "Vpis je prekratek. Mora imeti najmanj %s znakov.",
22
+ maxlength: "Vpis je predolg. Lahko ima največ %s znakov.",
23
+ length: "Število vpisanih znakov je napačno. Število znakov je lahko samo med %s in %s.",
24
+ mincheck: "Izbrati morate vsaj %s možnosti.",
25
+ maxcheck: "Izberete lahko največ %s možnosti.",
26
+ check: "Število izbranih možnosti je lahko samo med %s in %s.",
27
+ equalto: "Vnos mora biti enak."
28
+ });
29
+
30
+ Parsley.setLocale('sl');
assets/build/js/i18n/sr.extra.js ADDED
@@ -0,0 +1,14 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ // Extra validation errors messages for Parsley
2
+ // Load this after Parsley
3
+
4
+ Parsley.addMessages('sr', {
5
+ dateiso: "Unesite validan datum u formatu YYYY-MM-DD.",
6
+ minwords: "Potrebno je da unesete %s ili više reči.",
7
+ maxwords: "Moguće je uneti maksimalno %s reči.",
8
+ words: "Potrebno je da unesete između %s i %s reči.",
9
+ gt: "Ova vrednost mora da bude veća.",
10
+ gte: "Ova vrednost mora da bude veća ili jednaka.",
11
+ lt: "Ova vrednost mora da bude manja.",
12
+ lte: "Ova vrednost mora da bude manja ili jednaka.",
13
+ notequalto: "Sadržaj ovog polja mora biti različit."
14
+ });
assets/build/js/i18n/sr.js ADDED
@@ -0,0 +1,29 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ // Validation errors messages for Parsley
2
+ // Load this after Parsley
3
+
4
+ Parsley.addMessages('sr', {
5
+ defaultMessage: "Uneta vrednost nije validna.",
6
+ type: {
7
+ email: "Unesite pravilnu email adresu.",
8
+ url: "Unesite pravilnu url adresu.",
9
+ number: "Unesite numeričku vrednost.",
10
+ integer: "Unesite ceo broj bez decimala.",
11
+ digits: "Unesite samo brojeve.",
12
+ alphanum: "Unesite samo alfanumeričke znake (slova i brojeve)."
13
+ },
14
+ notblank: "Ovo polje ne sme biti prazno.",
15
+ required: "Ovo polje je obavezno.",
16
+ pattern: "Uneta vrednost nije validna.",
17
+ min: "Vrednost mora biti veća ili jednaka %s.",
18
+ max: "Vrednost mora biti manja ili jednaka %s.",
19
+ range: "Vrednost mora biti između %s i %s.",
20
+ minlength: "Unos je prekratak. Mora imati najmanje %s znakova.",
21
+ maxlength: "Unos je predug. Može imati najviše %s znakova.",
22
+ length: "Dužina unosa je pogrešna. Broj znakova mora biti između %s i %s.",
23
+ mincheck: "Morate izabrati minimalno %s opcija.",
24
+ maxcheck: "Možete izabrati najviše %s opcija.",
25
+ check: "Broj izabranih opcija mora biti između %s i %s.",
26
+ equalto: "Unos mora biti jednak."
27
+ });
28
+
29
+ Parsley.setLocale('sr');
assets/build/js/i18n/ua.extra.js ADDED
@@ -0,0 +1,14 @@
 
 
 
 
 
 
 
 
 
 
 
 
1
+ // Validation errors messages for Parsley
2
+ // Load this after Parsley
3
+
4
+ Parsley.addMessages('ua', {
5
+ dateiso: "Це значення повинно бути коректною датою (РРРР-ММ-ДД).",
6
+ minwords: "Це значення повинно містити не менше %s слів.",
7
+ maxwords: "Це значення повинно містити не більше %s слів.",
8
+ words: "Це значення повинно містити від %s до %s слів.",
9
+ gt: "Це значення повинно бути більше.",
10
+ gte: "Це значення повинно бути більше або дорівнює.",
11
+ lt: "Це значення повинно бути менше.",
12
+ lte: "Це значення повинно бути м�