Browse Source

update/clean js

windhamdavid 4 years ago
parent
commit
45a9b9b9bf
20 changed files with 7508 additions and 3036 deletions
  1. 626 0
      css/jasny-bootstrap-3.1.3.css
  2. 43 37
      functions.php
  3. 3 10
      gruntfile.js
  4. 3143 0
      js/amplitude.js
  5. 0 8
      js/analytics.js
  6. 2363 0
      js/bootstrap-3.3.5.js
  7. 7 0
      js/bootstrap-3.3.5.min.js
  8. 0 0
      js/contact.js
  9. 10 60
      js/desk.js
  10. 2 2
      js/fm.js
  11. 6 0
      js/jasny-bootstrap-3.1.3.min.js
  12. 0 167
      js/material-ripples.js
  13. 0 209
      js/material.js
  14. 653 324
      js/script.js
  15. 10 9
      js/script.min.js
  16. 641 0
      js/scripts.js
  17. 0 568
      js/smooth.js
  18. 0 364
      js/validate-chimp.js
  19. 0 1277
      js/validate-form.js
  20. 1 1
      js/validate.min.js

+ 626 - 0
css/jasny-bootstrap-3.1.3.css

@@ -0,0 +1,626 @@
+/*!
+ * Jasny Bootstrap v3.1.3 (http://jasny.github.io/bootstrap)
+ * Copyright 2012-2015 Arnold Daniels
+ * Licensed under Apache-2.0 (https://github.com/jasny/bootstrap/blob/master/LICENSE)
+ */
+
+.container-smooth {
+  max-width: 1170px;
+}
+@media (min-width: 1px) {
+  .container-smooth {
+    width: auto;
+  }
+}
+.btn-labeled {
+  padding-top: 0;
+  padding-bottom: 0;
+}
+.btn-label {
+  position: relative;
+  left: -12px;
+  display: inline-block;
+  padding: 6px 12px;
+  background: transparent;
+  background: rgba(0, 0, 0, .15);
+  border-radius: 3px 0 0 3px;
+}
+.btn-label.btn-label-right {
+  right: -12px;
+  left: auto;
+  border-radius: 0 3px 3px 0;
+}
+.btn-lg .btn-label {
+  left: -16px;
+  padding: 10px 16px;
+  border-radius: 5px 0 0 5px;
+}
+.btn-lg .btn-label.btn-label-right {
+  right: -16px;
+  left: auto;
+  border-radius: 0 5px 5px 0;
+}
+.btn-sm .btn-label {
+  left: -10px;
+  padding: 5px 10px;
+  border-radius: 2px 0 0 2px;
+}
+.btn-sm .btn-label.btn-label-right {
+  right: -10px;
+  left: auto;
+  border-radius: 0 2px 2px 0;
+}
+.btn-xs .btn-label {
+  left: -5px;
+  padding: 1px 5px;
+  border-radius: 2px 0 0 2px;
+}
+.btn-xs .btn-label.btn-label-right {
+  right: -5px;
+  left: auto;
+  border-radius: 0 2px 2px 0;
+}
+.btn-group > .btn:last-child:not(:first-child) .btn-label,
+.btn-group > .dropdown-toggle:not(:first-child) .btn-label {
+  border-top-left-radius: 0;
+  border-bottom-left-radius: 0;
+}
+.nav-tabs-bottom {
+  border-top: 1px solid #ddd;
+  border-bottom: 0;
+}
+.nav-tabs-bottom > li {
+  margin-top: -1px;
+  margin-bottom: 0;
+}
+.nav-tabs-bottom > li > a {
+  border-radius: 0 0 4px 4px;
+}
+.nav-tabs-bottom > li > a:hover,
+.nav-tabs-bottom > li > a:focus,
+.nav-tabs-bottom > li.active > a,
+.nav-tabs-bottom > li.active > a:hover,
+.nav-tabs-bottom > li.active > a:focus {
+  border: 1px solid #ddd;
+  border-top-color: transparent;
+}
+.nav-tabs-left {
+  border-right: 1px solid #ddd;
+  border-bottom: 0;
+}
+.nav-tabs-left > li {
+  float: none;
+  margin-right: -1px;
+  margin-bottom: 0;
+}
+.nav-tabs-left > li > a {
+  margin-right: 0;
+  margin-bottom: 2px;
+  border-radius: 4px 0 0 4px;
+}
+.nav-tabs-left > li > a:hover,
+.nav-tabs-left > li > a:focus,
+.nav-tabs-left > li.active > a,
+.nav-tabs-left > li.active > a:hover,
+.nav-tabs-left > li.active > a:focus {
+  border: 1px solid #ddd;
+  border-right-color: transparent;
+}
+.row > .nav-tabs-left {
+  position: relative;
+  z-index: 1;
+  padding-right: 0;
+  padding-left: 15px;
+  margin-right: -1px;
+}
+.row > .nav-tabs-left + .tab-content {
+  border-left: 1px solid #ddd;
+}
+.nav-tabs-right {
+  border-bottom: 0;
+  border-left: 1px solid #ddd;
+}
+.nav-tabs-right > li {
+  float: none;
+  margin-bottom: 0;
+  margin-left: -1px;
+}
+.nav-tabs-right > li > a {
+  margin-bottom: 2px;
+  margin-left: 0;
+  border-radius: 0 4px 4px 0;
+}
+.nav-tabs-right > li > a:hover,
+.nav-tabs-right > li > a:focus,
+.nav-tabs-right > li.active > a,
+.nav-tabs-right > li.active > a:hover,
+.nav-tabs-right > li.active > a:focus {
+  border: 1px solid #ddd;
+  border-left-color: transparent;
+}
+.row > .nav-tabs-right {
+  padding-right: 15px;
+  padding-left: 0;
+}
+.navmenu,
+.navbar-offcanvas {
+  width: 300px;
+  height: auto;
+  border-style: solid;
+  border-width: 1px;
+  border-radius: 4px;
+}
+.navmenu-fixed-left,
+.navmenu-fixed-right,
+.navbar-offcanvas {
+  position: fixed;
+  top: 0;
+  bottom: 0;
+  z-index: 1050;
+  overflow-y: auto;
+  border-radius: 0;
+}
+.navmenu-fixed-left,
+.navbar-offcanvas.navmenu-fixed-left {
+  right: auto;
+  left: 0;
+  border-width: 0 1px 0 0;
+}
+.navmenu-fixed-right,
+.navbar-offcanvas {
+  right: 0;
+  left: auto;
+  border-width: 0 0 0 1px;
+}
+.navmenu-nav {
+  margin-bottom: 10px;
+}
+.navmenu-nav.dropdown-menu {
+  position: static;
+  float: none;
+  padding-top: 0;
+  margin: 0;
+  border: none;
+  border-radius: 0;
+  -webkit-box-shadow: none;
+          box-shadow: none;
+}
+.navbar-offcanvas .navbar-nav {
+  margin: 0;
+}
+@media (min-width: 768px) {
+  .navbar-offcanvas {
+    width: auto;
+    border-top: 0;
+    box-shadow: none;
+  }
+  .navbar-offcanvas.offcanvas {
+    position: static;
+    display: block !important;
+    height: auto !important;
+    padding-bottom: 0;
+    overflow: visible !important;
+  }
+  .navbar-offcanvas .navbar-nav.navbar-left:first-child {
+    margin-left: -15px;
+  }
+  .navbar-offcanvas .navbar-nav.navbar-right:last-child {
+    margin-right: -15px;
+  }
+  .navbar-offcanvas .navmenu-brand {
+    display: none;
+  }
+}
+.navmenu-brand {
+  display: block;
+  padding: 10px 15px;
+  margin: 10px 0;
+  font-size: 18px;
+  line-height: 20px;
+}
+.navmenu-brand:hover,
+.navmenu-brand:focus {
+  text-decoration: none;
+}
+.navmenu-default,
+.navbar-default .navbar-offcanvas {
+  background-color: #f8f8f8;
+  border-color: #e7e7e7;
+}
+.navmenu-default .navmenu-brand,
+.navbar-default .navbar-offcanvas .navmenu-brand {
+  color: #777;
+}
+.navmenu-default .navmenu-brand:hover,
+.navbar-default .navbar-offcanvas .navmenu-brand:hover,
+.navmenu-default .navmenu-brand:focus,
+.navbar-default .navbar-offcanvas .navmenu-brand:focus {
+  color: #5e5e5e;
+  background-color: transparent;
+}
+.navmenu-default .navmenu-text,
+.navbar-default .navbar-offcanvas .navmenu-text {
+  color: #777;
+}
+.navmenu-default .navmenu-nav > .dropdown > a:hover .caret,
+.navbar-default .navbar-offcanvas .navmenu-nav > .dropdown > a:hover .caret,
+.navmenu-default .navmenu-nav > .dropdown > a:focus .caret,
+.navbar-default .navbar-offcanvas .navmenu-nav > .dropdown > a:focus .caret {
+  border-top-color: #333;
+  border-bottom-color: #333;
+}
+.navmenu-default .navmenu-nav > .open > a,
+.navbar-default .navbar-offcanvas .navmenu-nav > .open > a,
+.navmenu-default .navmenu-nav > .open > a:hover,
+.navbar-default .navbar-offcanvas .navmenu-nav > .open > a:hover,
+.navmenu-default .navmenu-nav > .open > a:focus,
+.navbar-default .navbar-offcanvas .navmenu-nav > .open > a:focus {
+  color: #555;
+  background-color: #e7e7e7;
+}
+.navmenu-default .navmenu-nav > .open > a .caret,
+.navbar-default .navbar-offcanvas .navmenu-nav > .open > a .caret,
+.navmenu-default .navmenu-nav > .open > a:hover .caret,
+.navbar-default .navbar-offcanvas .navmenu-nav > .open > a:hover .caret,
+.navmenu-default .navmenu-nav > .open > a:focus .caret,
+.navbar-default .navbar-offcanvas .navmenu-nav > .open > a:focus .caret {
+  border-top-color: #555;
+  border-bottom-color: #555;
+}
+.navmenu-default .navmenu-nav > .dropdown > a .caret,
+.navbar-default .navbar-offcanvas .navmenu-nav > .dropdown > a .caret {
+  border-top-color: #777;
+  border-bottom-color: #777;
+}
+.navmenu-default .navmenu-nav.dropdown-menu,
+.navbar-default .navbar-offcanvas .navmenu-nav.dropdown-menu {
+  background-color: #e7e7e7;
+}
+.navmenu-default .navmenu-nav.dropdown-menu > .divider,
+.navbar-default .navbar-offcanvas .navmenu-nav.dropdown-menu > .divider {
+  background-color: #f8f8f8;
+}
+.navmenu-default .navmenu-nav.dropdown-menu > .active > a,
+.navbar-default .navbar-offcanvas .navmenu-nav.dropdown-menu > .active > a,
+.navmenu-default .navmenu-nav.dropdown-menu > .active > a:hover,
+.navbar-default .navbar-offcanvas .navmenu-nav.dropdown-menu > .active > a:hover,
+.navmenu-default .navmenu-nav.dropdown-menu > .active > a:focus,
+.navbar-default .navbar-offcanvas .navmenu-nav.dropdown-menu > .active > a:focus {
+  background-color: #d7d7d7;
+}
+.navmenu-default .navmenu-nav > li > a,
+.navbar-default .navbar-offcanvas .navmenu-nav > li > a {
+  color: #777;
+}
+.navmenu-default .navmenu-nav > li > a:hover,
+.navbar-default .navbar-offcanvas .navmenu-nav > li > a:hover,
+.navmenu-default .navmenu-nav > li > a:focus,
+.navbar-default .navbar-offcanvas .navmenu-nav > li > a:focus {
+  color: #333;
+  background-color: transparent;
+}
+.navmenu-default .navmenu-nav > .active > a,
+.navbar-default .navbar-offcanvas .navmenu-nav > .active > a,
+.navmenu-default .navmenu-nav > .active > a:hover,
+.navbar-default .navbar-offcanvas .navmenu-nav > .active > a:hover,
+.navmenu-default .navmenu-nav > .active > a:focus,
+.navbar-default .navbar-offcanvas .navmenu-nav > .active > a:focus {
+  color: #555;
+  background-color: #e7e7e7;
+}
+.navmenu-default .navmenu-nav > .disabled > a,
+.navbar-default .navbar-offcanvas .navmenu-nav > .disabled > a,
+.navmenu-default .navmenu-nav > .disabled > a:hover,
+.navbar-default .navbar-offcanvas .navmenu-nav > .disabled > a:hover,
+.navmenu-default .navmenu-nav > .disabled > a:focus,
+.navbar-default .navbar-offcanvas .navmenu-nav > .disabled > a:focus {
+  color: #ccc;
+  background-color: transparent;
+}
+.navmenu-inverse,
+.navbar-inverse .navbar-offcanvas {
+  background-color: #222;
+  border-color: #080808;
+}
+.navmenu-inverse .navmenu-brand,
+.navbar-inverse .navbar-offcanvas .navmenu-brand {
+  color: #999;
+}
+.navmenu-inverse .navmenu-brand:hover,
+.navbar-inverse .navbar-offcanvas .navmenu-brand:hover,
+.navmenu-inverse .navmenu-brand:focus,
+.navbar-inverse .navbar-offcanvas .navmenu-brand:focus {
+  color: #fff;
+  background-color: transparent;
+}
+.navmenu-inverse .navmenu-text,
+.navbar-inverse .navbar-offcanvas .navmenu-text {
+  color: #999;
+}
+.navmenu-inverse .navmenu-nav > .dropdown > a:hover .caret,
+.navbar-inverse .navbar-offcanvas .navmenu-nav > .dropdown > a:hover .caret,
+.navmenu-inverse .navmenu-nav > .dropdown > a:focus .caret,
+.navbar-inverse .navbar-offcanvas .navmenu-nav > .dropdown > a:focus .caret {
+  border-top-color: #fff;
+  border-bottom-color: #fff;
+}
+.navmenu-inverse .navmenu-nav > .open > a,
+.navbar-inverse .navbar-offcanvas .navmenu-nav > .open > a,
+.navmenu-inverse .navmenu-nav > .open > a:hover,
+.navbar-inverse .navbar-offcanvas .navmenu-nav > .open > a:hover,
+.navmenu-inverse .navmenu-nav > .open > a:focus,
+.navbar-inverse .navbar-offcanvas .navmenu-nav > .open > a:focus {
+  color: #fff;
+  background-color: #080808;
+}
+.navmenu-inverse .navmenu-nav > .open > a .caret,
+.navbar-inverse .navbar-offcanvas .navmenu-nav > .open > a .caret,
+.navmenu-inverse .navmenu-nav > .open > a:hover .caret,
+.navbar-inverse .navbar-offcanvas .navmenu-nav > .open > a:hover .caret,
+.navmenu-inverse .navmenu-nav > .open > a:focus .caret,
+.navbar-inverse .navbar-offcanvas .navmenu-nav > .open > a:focus .caret {
+  border-top-color: #fff;
+  border-bottom-color: #fff;
+}
+.navmenu-inverse .navmenu-nav > .dropdown > a .caret,
+.navbar-inverse .navbar-offcanvas .navmenu-nav > .dropdown > a .caret {
+  border-top-color: #999;
+  border-bottom-color: #999;
+}
+.navmenu-inverse .navmenu-nav.dropdown-menu,
+.navbar-inverse .navbar-offcanvas .navmenu-nav.dropdown-menu {
+  background-color: #080808;
+}
+.navmenu-inverse .navmenu-nav.dropdown-menu > .divider,
+.navbar-inverse .navbar-offcanvas .navmenu-nav.dropdown-menu > .divider {
+  background-color: #222;
+}
+.navmenu-inverse .navmenu-nav.dropdown-menu > .active > a,
+.navbar-inverse .navbar-offcanvas .navmenu-nav.dropdown-menu > .active > a,
+.navmenu-inverse .navmenu-nav.dropdown-menu > .active > a:hover,
+.navbar-inverse .navbar-offcanvas .navmenu-nav.dropdown-menu > .active > a:hover,
+.navmenu-inverse .navmenu-nav.dropdown-menu > .active > a:focus,
+.navbar-inverse .navbar-offcanvas .navmenu-nav.dropdown-menu > .active > a:focus {
+  background-color: #000;
+}
+.navmenu-inverse .navmenu-nav > li > a,
+.navbar-inverse .navbar-offcanvas .navmenu-nav > li > a {
+  color: #999;
+}
+.navmenu-inverse .navmenu-nav > li > a:hover,
+.navbar-inverse .navbar-offcanvas .navmenu-nav > li > a:hover,
+.navmenu-inverse .navmenu-nav > li > a:focus,
+.navbar-inverse .navbar-offcanvas .navmenu-nav > li > a:focus {
+  color: #fff;
+  background-color: transparent;
+}
+.navmenu-inverse .navmenu-nav > .active > a,
+.navbar-inverse .navbar-offcanvas .navmenu-nav > .active > a,
+.navmenu-inverse .navmenu-nav > .active > a:hover,
+.navbar-inverse .navbar-offcanvas .navmenu-nav > .active > a:hover,
+.navmenu-inverse .navmenu-nav > .active > a:focus,
+.navbar-inverse .navbar-offcanvas .navmenu-nav > .active > a:focus {
+  color: #fff;
+  background-color: #080808;
+}
+.navmenu-inverse .navmenu-nav > .disabled > a,
+.navbar-inverse .navbar-offcanvas .navmenu-nav > .disabled > a,
+.navmenu-inverse .navmenu-nav > .disabled > a:hover,
+.navbar-inverse .navbar-offcanvas .navmenu-nav > .disabled > a:hover,
+.navmenu-inverse .navmenu-nav > .disabled > a:focus,
+.navbar-inverse .navbar-offcanvas .navmenu-nav > .disabled > a:focus {
+  color: #444;
+  background-color: transparent;
+}
+.alert-fixed-top,
+.alert-fixed-bottom {
+  position: fixed;
+  left: 0;
+  z-index: 1035;
+  width: 100%;
+  margin: 0;
+  border-radius: 0;
+}
+@media (min-width: 992px) {
+  .alert-fixed-top,
+  .alert-fixed-bottom {
+    left: 50%;
+    width: 992px;
+    margin-left: -496px;
+  }
+}
+.alert-fixed-top {
+  top: 0;
+  border-width: 0 0 1px 0;
+}
+@media (min-width: 992px) {
+  .alert-fixed-top {
+    border-width: 0 1px 1px 1px;
+    border-bottom-right-radius: 4px;
+    border-bottom-left-radius: 4px;
+  }
+}
+.alert-fixed-bottom {
+  bottom: 0;
+  border-width: 1px 0 0 0;
+}
+@media (min-width: 992px) {
+  .alert-fixed-bottom {
+    border-width: 1px 1px 0 1px;
+    border-top-left-radius: 4px;
+    border-top-right-radius: 4px;
+  }
+}
+.offcanvas {
+  display: none;
+}
+.offcanvas.in {
+  display: block;
+}
+@media (max-width: 767px) {
+  .offcanvas-xs {
+    display: none;
+  }
+  .offcanvas-xs.in {
+    display: block;
+  }
+}
+@media (max-width: 991px) {
+  .offcanvas-sm {
+    display: none;
+  }
+  .offcanvas-sm.in {
+    display: block;
+  }
+}
+@media (max-width: 1199px) {
+  .offcanvas-md {
+    display: none;
+  }
+  .offcanvas-md.in {
+    display: block;
+  }
+}
+.offcanvas-lg {
+  display: none;
+}
+.offcanvas-lg.in {
+  display: block;
+}
+.canvas-sliding {
+  -webkit-transition: top .35s, left .35s, bottom .35s, right .35s;
+          transition: top .35s, left .35s, bottom .35s, right .35s;
+}
+.offcanvas-clone {
+  position: absolute !important;
+  top: auto !important;
+  right: 0 !important;
+  bottom: 0 !important;
+  left: auto !important;
+  width: 0 !important;
+  height: 0 !important;
+  padding: 0 !important;
+  margin: 0 !important;
+  overflow: hidden !important;
+  border: none !important;
+  opacity: 0 !important;
+}
+.table.rowlink td:not(.rowlink-skip),
+.table .rowlink td:not(.rowlink-skip) {
+  cursor: pointer;
+}
+.table.rowlink td:not(.rowlink-skip) a,
+.table .rowlink td:not(.rowlink-skip) a {
+  font: inherit;
+  color: inherit;
+  text-decoration: inherit;
+}
+.table-hover.rowlink tr:hover td,
+.table-hover .rowlink tr:hover td {
+  background-color: #cfcfcf;
+}
+.btn-file {
+  position: relative;
+  overflow: hidden;
+  vertical-align: middle;
+}
+.btn-file > input {
+  position: absolute;
+  top: 0;
+  right: 0;
+  width: 100%;
+  height: 100%;
+  margin: 0;
+  font-size: 23px;
+  cursor: pointer;
+  filter: alpha(opacity=0);
+  opacity: 0;
+
+  direction: ltr;
+}
+.fileinput {
+  display: inline-block;
+  margin-bottom: 9px;
+}
+.fileinput .form-control {
+  display: inline-block;
+  padding-top: 7px;
+  padding-bottom: 5px;
+  margin-bottom: 0;
+  vertical-align: middle;
+  cursor: text;
+}
+.fileinput .thumbnail {
+  display: inline-block;
+  margin-bottom: 5px;
+  overflow: hidden;
+  text-align: center;
+  vertical-align: middle;
+}
+.fileinput .thumbnail > img {
+  max-height: 100%;
+}
+.fileinput .btn {
+  vertical-align: middle;
+}
+.fileinput-exists .fileinput-new,
+.fileinput-new .fileinput-exists {
+  display: none;
+}
+.fileinput-inline .fileinput-controls {
+  display: inline;
+}
+.fileinput-filename {
+  display: inline-block;
+  overflow: hidden;
+  vertical-align: middle;
+}
+.form-control .fileinput-filename {
+  vertical-align: bottom;
+}
+.fileinput.input-group {
+  display: table;
+}
+.fileinput.input-group > * {
+  position: relative;
+  z-index: 2;
+}
+.fileinput.input-group > .btn-file {
+  z-index: 1;
+}
+.fileinput-new.input-group .btn-file,
+.fileinput-new .input-group .btn-file {
+  border-radius: 0 4px 4px 0;
+}
+.fileinput-new.input-group .btn-file.btn-xs,
+.fileinput-new .input-group .btn-file.btn-xs,
+.fileinput-new.input-group .btn-file.btn-sm,
+.fileinput-new .input-group .btn-file.btn-sm {
+  border-radius: 0 3px 3px 0;
+}
+.fileinput-new.input-group .btn-file.btn-lg,
+.fileinput-new .input-group .btn-file.btn-lg {
+  border-radius: 0 6px 6px 0;
+}
+.form-group.has-warning .fileinput .fileinput-preview {
+  color: #8a6d3b;
+}
+.form-group.has-warning .fileinput .thumbnail {
+  border-color: #faebcc;
+}
+.form-group.has-error .fileinput .fileinput-preview {
+  color: #a94442;
+}
+.form-group.has-error .fileinput .thumbnail {
+  border-color: #ebccd1;
+}
+.form-group.has-success .fileinput .fileinput-preview {
+  color: #3c763d;
+}
+.form-group.has-success .fileinput .thumbnail {
+  border-color: #d6e9c6;
+}
+.input-group-addon:not(:first-child) {
+  border-left: 0;
+}
+/*# sourceMappingURL=jasny-bootstrap.css.map */

+ 43 - 37
functions.php

@@ -50,45 +50,47 @@ function dw_scripts() {
 		//wp_enqueue_style( 'boot', get_template_directory_uri() . '/css/boot.css');
 		//wp_enqueue_style( 'cal', get_template_directory_uri() . '/css/fullcalendar.css');
 		//wp_enqueue_style( 'ani', get_template_directory_uri() . '/css/animate.css');	
-		wp_enqueue_script('jquery', get_template_directory_uri() . '/js/jquery-2.1.1.min.js', array(), false, true);
-		wp_enqueue_script( 'modern', get_template_directory_uri() . '/js/modernizr.js', 'jquery', '', true );
-		wp_enqueue_script( 'boostrap', get_template_directory_uri() . '/js/bootstrap.min.js', 'jquery', '', true );
-		wp_enqueue_script( 'offcanvas', get_template_directory_uri() . '/js/jasny-bootstrap.js', 'jquery', '', true );
-		wp_enqueue_script( 'time', get_template_directory_uri() . '/js/moment.min.js', 'jquery', '', true );
-		wp_enqueue_script( 'cal', get_template_directory_uri() . '/js/fullcalendar.min.js', 'jquery', '', true );
-		wp_enqueue_script( 'valid', get_template_directory_uri() . '/js/validate.min.js', 'jquery', '', true );
-		wp_enqueue_script( 'smooth', get_template_directory_uri() . '/js/smooth.js', 'jquery', '', true );
-		wp_enqueue_script( 'scripts', get_template_directory_uri() . '/js/scripts.js', 'jquery', '', true );
-		//wp_enqueue_script( 'scriptmin', get_template_directory_uri() . '/js/script.min.js', 'jquery', '', true );
+		//wp_enqueue_script('jquery', get_template_directory_uri() . '/js/jquery-2.1.1.min.js', array(), false, true);
+		//wp_enqueue_script( 'modern', get_template_directory_uri() . '/js/modernizr.js', 'jquery', '', true );
+		//wp_enqueue_script( 'boostrap', get_template_directory_uri() . '/js/bootstrap.min.js', 'jquery', '', true );
+		//wp_enqueue_script( 'offcanvas', get_template_directory_uri() . '/js/jasny-bootstrap.js', 'jquery', '', true );
+		//wp_enqueue_script( 'time', get_template_directory_uri() . '/js/moment.min.js', 'jquery', '', true );
+		//wp_enqueue_script( 'cal', get_template_directory_uri() . '/js/fullcalendar.min.js', 'jquery', '', true );
+		//wp_enqueue_script( 'valid', get_template_directory_uri() . '/js/validate.min.js', 'jquery', '', true );
+		//wp_enqueue_script( 'scripts', get_template_directory_uri() . '/js/scripts.js', 'jquery', '', true );
+		wp_enqueue_script( 'scriptmin', get_template_directory_uri() . '/js/script.min.js', 'jquery', '', true );
 		wp_enqueue_script( 'init', get_template_directory_uri() . '/js/about.js', 'jquery', '', true );
 		//wp_enqueue_script( 'init', get_template_directory_uri() . '/js/init.min.js', 'jquery', '', true );
 	}
 	
 	elseif ( is_page('studio') ) {
 		//wp_enqueue_style( 'ani', get_template_directory_uri() . '/css/animate.css');
-		wp_enqueue_script('jquery', get_template_directory_uri() . '/js/jquery-2.1.1.min.js', array(), false, true);
-		wp_enqueue_script( 'modern', get_template_directory_uri() . '/js/modernizr.js', 'jquery', '', true );
-		wp_enqueue_script( 'boostrap', get_template_directory_uri() . '/js/bootstrap.min.js', 'jquery', '', true );
-		wp_enqueue_script( 'offcanvas', get_template_directory_uri() . '/js/jasny-bootstrap.js', 'jquery', '', true );
-		wp_enqueue_script( 'scripts', get_template_directory_uri() . '/js/scripts.js', 'jquery', '', true );
+		//wp_enqueue_script('jquery', get_template_directory_uri() . '/js/jquery-2.1.1.min.js', array(), false, true);
+		//wp_enqueue_script( 'modern', get_template_directory_uri() . '/js/modernizr.js', 'jquery', '', true );
+		//wp_enqueue_script( 'boostrap', get_template_directory_uri() . '/js/bootstrap.min.js', 'jquery', '', true );
+		//wp_enqueue_script( 'offcanvas', get_template_directory_uri() . '/js/jasny-bootstrap.js', 'jquery', '', true );
+		//wp_enqueue_script( 'scripts', get_template_directory_uri() . '/js/scripts.js', 'jquery', '', true );
+		wp_enqueue_script( 'scriptmin', get_template_directory_uri() . '/js/script.min.js', '', '', true );
 		wp_enqueue_script( 'init', get_template_directory_uri() . '/js/studio.js', 'jquery', '', true );
 	}
 	
 	elseif ( is_page('music') ) {
 		//wp_enqueue_script( 'script-o', get_template_directory_uri() . '/js/script-o.js', 'jquery', '', true );
-		wp_enqueue_script( 'script-o-min', get_template_directory_uri() . '/js/script-o.min.js', 'jquery', '', true );
-		wp_enqueue_script( 'amp', get_template_directory_uri() . '/js/amp.min.js', 'jquery', '', true );
-		wp_enqueue_script( 'chart', get_template_directory_uri() . '/js/chart.min.js', 'jquery', '', true );
-		wp_enqueue_script( 'last-fm', get_template_directory_uri() . '/js/fm.js', 'jquery', '', true );
+		//wp_enqueue_script( 'script-o-min', get_template_directory_uri() . '/js/scripts-o.js', 'jquery', '', true );
+		wp_enqueue_script( 'scriptmin', get_template_directory_uri() . '/js/script.min.js', '', '', true );
+		wp_enqueue_script( 'amp', get_template_directory_uri() . '/js/amp.min.js', '', '', true );
+		wp_enqueue_script( 'chart', get_template_directory_uri() . '/js/chart.min.js', '', '', true );
+		wp_enqueue_script( 'last-fm', get_template_directory_uri() . '/js/fm.js', '', '', true );
 	}
 	
 	elseif ( is_page('art') ) {
 		//wp_enqueue_style( 'ani', get_template_directory_uri() . '/css/animate.css');
-		wp_enqueue_script('jquery', get_template_directory_uri() . '/js/jquery-2.1.1.min.js', array(), false, true);
-		wp_enqueue_script( 'modern', get_template_directory_uri() . '/js/modernizr.js', 'jquery', '', true );
-		wp_enqueue_script( 'boostrap', get_template_directory_uri() . '/js/bootstrap.min.js', 'jquery', '', true );
-		wp_enqueue_script( 'offcanvas', get_template_directory_uri() . '/js/jasny-bootstrap.js', 'jquery', '', true );
-		wp_enqueue_script( 'scripts', get_template_directory_uri() . '/js/scripts.js', 'jquery', '', true );
+		//wp_enqueue_script('jquery', get_template_directory_uri() . '/js/jquery-2.1.1.min.js', array(), false, true);
+		//wp_enqueue_script( 'modern', get_template_directory_uri() . '/js/modernizr.js', 'jquery', '', true );
+		//wp_enqueue_script( 'boostrap', get_template_directory_uri() . '/js/bootstrap.min.js', 'jquery', '', true );
+		//wp_enqueue_script( 'offcanvas', get_template_directory_uri() . '/js/jasny-bootstrap.js', 'jquery', '', true );
+		//wp_enqueue_script( 'scripts', get_template_directory_uri() . '/js/scripts.js', 'jquery', '', true );
+		wp_enqueue_script( 'scriptmin', get_template_directory_uri() . '/js/script.min.js', '', '', true );
 		wp_enqueue_script( 'last-fm', get_template_directory_uri() . '/js/art.js', 'jquery', '', true );
 	}
 	
@@ -96,21 +98,24 @@ function dw_scripts() {
 		require( get_template_directory() . '/inc/form.php' );
 		//gravity_form_enqueue_scripts(1, false);
 		wp_enqueue_style( 'forms', get_template_directory_uri() . '/css/form.css');
-		wp_enqueue_script('jquery', get_template_directory_uri() . '/js/jquery-2.1.1.min.js', array(), false, true);
+		wp_enqueue_script('jquery', get_template_directory_uri() . '/js/jquery-2.1.4.min.js', array(), false, true);
+		//wp_enqueue_script( 'scriptmin', get_template_directory_uri() . '/js/script.min.js', 'jquery', '', true );
 		//wp_enqueue_script( 'script-o', get_template_directory_uri() . '/js/script-o.js', '', '', true );
-		wp_enqueue_script( 'form', get_template_directory_uri() . '/js/form.js', '', '', true );
+		wp_enqueue_script( 'form', get_template_directory_uri() . '/js/contact.js', '', '', true );
 	}
 	elseif ( is_page('analytics') ) {
 		require( get_template_directory() . '/inc/analytics.php' );
-		wp_enqueue_style( 'dashboard', get_template_directory_uri() . '/css/analytics.css');
-		wp_enqueue_script('jquery', get_template_directory_uri() . '/js/jquery-2.1.1.min.js', array(), false, true);
+		//wp_enqueue_style( 'dashboard', get_template_directory_uri() . '/css/analytics.css');
+		//wp_enqueue_script('jquery', get_template_directory_uri() . '/js/jquery-2.1.4.min.js', array(), false, true);
 		//wp_enqueue_script( 'script-o', get_template_directory_uri() . '/js/script-o.js', '', '', true );
+		wp_enqueue_script( 'scriptmin', get_template_directory_uri() . '/js/script.min.js', '', '', true );
 		wp_enqueue_script( 'dashboardjs', get_template_directory_uri() . '/js/analytics.js', '', '', true );
 	}
 	
 	elseif ( is_singular() && comments_open() && get_option( 'thread_comments' ) ) {
-		wp_enqueue_script( 'jquery', get_template_directory_uri() . '/js/script-o.js', '', '', true );
-		wp_enqueue_script( 'init-o', get_template_directory_uri() . '/js/init-o.js', '', '', true );
+		//wp_enqueue_script( 'jquery', get_template_directory_uri() . '/js/script-o.js', '', '', true );
+		wp_enqueue_script( 'scriptmin', get_template_directory_uri() . '/js/script.min.js', '', '', true );
+		wp_enqueue_script( 'init-o', get_template_directory_uri() . '/js/init-o.min.js', '', '', true );
 		wp_enqueue_script( 'comment-reply' );
 	}
 	
@@ -118,11 +123,12 @@ function dw_scripts() {
 		global $wp_rewrite;
 		//wp_enqueue_script( 'jquery', get_template_directory_uri() . '/js/jquery-2.1.1.min.js', array(), false, true); //jquery dependents
 		//wp_enqueue_style( 'ani', get_template_directory_uri() . '/css/animate.css');
-		wp_enqueue_script('jquery', get_template_directory_uri() . '/js/jquery-2.1.1.min.js', array(), false, true);
-		wp_enqueue_script( 'modern', get_template_directory_uri() . '/js/modernizr.js', 'jquery', '', true );
-		wp_enqueue_script( 'boostrap', get_template_directory_uri() . '/js/bootstrap.min.js', 'jquery', '', true );
-		wp_enqueue_script( 'offcanvas', get_template_directory_uri() . '/js/jasny-bootstrap.js', 'jquery', '', true );
-		wp_enqueue_script( 'scripts', get_template_directory_uri() . '/js/scripts.js', 'jquery', '', true );
+		//wp_enqueue_script('jquery', get_template_directory_uri() . '/js/jquery-2.1.4.min.js', array(), false, true);
+		//wp_enqueue_script( 'modern', get_template_directory_uri() . '/js/modernizr.js', 'jquery', '', true );
+		//wp_enqueue_script( 'boostrap', get_template_directory_uri() . '/js/bootstrap.min.js', 'jquery', '', true );
+		//wp_enqueue_script( 'offcanvas', get_template_directory_uri() . '/js/jasny-bootstrap.js', 'jquery', '', true );
+		//wp_enqueue_script( 'scripts', get_template_directory_uri() . '/js/scripts.js', 'jquery', '', true );
+		wp_enqueue_script( 'jquery', get_template_directory_uri() . '/js/script.min.js', '', '', true );
 		wp_enqueue_script( 'desk', get_template_directory_uri() . '/js/desk.js', '', '', true );
 		wp_enqueue_script( '_s_backbone-loop', get_template_directory_uri() . '/js/loop.js', array( 'jquery', 'backbone', 'underscore', 'wp-api'  ), '1.0', true );
 		$queried_object = get_queried_object();
@@ -153,9 +159,9 @@ function dw_scripts() {
 	}
 	
 	else {
-		wp_enqueue_script( 'script-o', get_template_directory_uri() . '/js/script-o.js', '', '', true );
+		wp_enqueue_script( 'scriptmin', get_template_directory_uri() . '/js/script.min.js', '', '', true );
 		//wp_enqueue_script( 'script-o-min', get_template_directory_uri() . '/js/script-o.min.js', 'jquery', '', true );
-		wp_enqueue_script( 'init-o', get_template_directory_uri() . '/js/init-o.js', '', '', true );
+		wp_enqueue_script( 'init-o', get_template_directory_uri() . '/js/init-o.min.js', '', '', true );
 		//wp_enqueue_script( 'init-o-min', get_template_directory_uri() . '/js/init-o.min.js', 'jquery', '', true );
 	}
 			

+ 3 - 10
gruntfile.js

@@ -4,13 +4,6 @@ module.exports = function(grunt) {
 	  pkg: grunt.file.readJSON('package.json'),
 		
 		cssmin: {
-		  css: {
-			  src: 'css/grid.css',
-			  dest: 'css/grid.min.css'
-		  }
-		},
-		
-		cssmin: {
 		  combine: {
 		    files: {
 		     'style.min.css': ['style.css', 'css/boot.css', 'css/fullcalendar.css', 'css/animate.css', 'css/fonts.css'],
@@ -24,12 +17,12 @@ module.exports = function(grunt) {
 				separator: ';',
 			},
 			dist: {
-				src: ['js/jquery-2.1.4.min.js', 'js/modernizr.js', 'js/bootstrap.min.js', 'js/jasny-bootstrap.js', 'js/moment.min.js', 'js/fullcalendar.min.js', 'js/validate.min.js', 'js/scripts.js'],
+				src: ['js/jquery-2.1.4.min.js', 'js/modernizr.js', 'js/bootstrap-3.3.5.min.js', 'js/jasny-bootstrap-3.1.3.min.js', 'js/moment.min.js', 'js/fullcalendar.min.js', 'js/validate.min.js', 'js/scripts.js'],
 				dest: 'js/script.js',
 			},
 			disto: {
-				src: ['js/jquery-2.1.4.min.js', 'js/modernizr.js', 'js/bootstrap.min.js', 'js/jasny-bootstrap.js', 'js/validate.min.js'],
-				dest: 'js/scripts-o.js',
+				src: ['js/jquery-2.1.4.min.js', 'js/modernizr.js', 'js/bootstrap-3.3.5.min.js', 'js/jasny-bootstrap-3.1.3.min.js'],
+				dest: 'js/script-o.js',
 			},
 			disto: {
 				src: ['js/jquery-2.1.4.min.js', 'js/svg-morpheus.js', 'js/messenger.min.js', 'js/bootstrap.js', 'js/terminal.js', 'js/front-page.js'],

File diff suppressed because it is too large
+ 3143 - 0
js/amplitude.js


File diff suppressed because it is too large
+ 0 - 8
js/analytics.js


File diff suppressed because it is too large
+ 2363 - 0
js/bootstrap-3.3.5.js


File diff suppressed because it is too large
+ 7 - 0
js/bootstrap-3.3.5.min.js


js/form.js → js/contact.js


+ 10 - 60
js/desk.js

@@ -5,7 +5,15 @@ jQuery(document).ready(function($) {
 	$(window).bind('load', function() {
 		$('#loader').fadeOut(100);
 	});
+	
+	$(function() {
+	    $("img.alignnone").lazyload();
+	});
 
+
+/*============================================
+		     Navigation 
+==============================================*/
 	$('.nav-toggle').on('touchstart click', function(e) {
 		e.preventDefault();
 		$( this ).toggleClass( 'active' );
@@ -31,64 +39,6 @@ jQuery(document).ready(function($) {
 			this.previousTop = currentTop;
 			}  
 		);
-	});
-	
-	$("#studio-caro").wallpaper({source: "../wp-content/themes/dw/img/clou.jpg"});
-
-	$('#caro').carousel({
-		interval: false,
-		wrap: true,
-	});
-	
-	$(document).bind('keyup', function(e) {
-	    if(e.which === 39){
-			$('#caro').carousel('next');
-	    }
-	    else if(e.which === 37){
-			$('#caro').carousel('prev');
-	    }
-	});
-	
-	$('.studio-subnav a').click(function (e) {
-	  e.preventDefault()
-	  $(this).tab('show')
-	})
-
-	$('#caro').on('slid.bs.carousel', function(event) {
-		var consta = $(event.target);
-		setTimeout(function() {
-			if (consta.find('.item.active').data('id') === 0) {
-				$('.studio-subnav a[href="#studio"]').tab('show')
-				$('#studio-caro').addClass('caro-grad5').removeClass('caro-grad caro-grad3 caro-grad2 caro-grad5');
-				$('.carousel-indicators li').addClass('darken-carousel-indicators');
-				$("#studio-caro").wallpaper("destroy");
-				$("#studio-caro").wallpaper({source: "../wp-content/themes/dw/img/desk2.jpg"});
-			}
-			if (consta.find('.item.active').data('id') === 1) {
-				$('.studio-subnav a[href="#webdev"]').tab('show')
-				$('.active #svg-imac.screen').delay(2500).queue(function(screenit){
-				    $(this).attr('class', 'bg');
-				    screenit();
-				});
-				$('#studio-caro').addClass('caro-grad').removeClass('caro-grad3 caro-grad2 caro-grad5');
-				$('.site-title a').addClass('light');
-				$('.carousel-indicators li').removeClass('darken-carousel-indicators');
-				$("#studio-caro").wallpaper("destroy");
-			}
-		}, 10);
-	});
-	
+	});			
+});
 
-	$('#caro').on('slid.bs.carousel', function() {
-		$('.active .animac').removeClass('hide-svg fade-svg');
-		var animac = new DrawFillSVG({elementId: 'svg-imac'});
-		var animac1 = new DrawFillSVG({elementId: 'sv'});
-		var animac2 = new DrawFillSVG({elementId: 'svg-mac'});
-		var animac3 = new DrawFillSVG({elementId: 'svg-device'});
-		animac.replay();
-		animac1.replay();
-		animac2.replay();
-		animac3.replay();
-	});
-			
-});

+ 2 - 2
js/fm.js

@@ -525,7 +525,7 @@ $('.music-typed').waypoint(function() {
 	$('.tracks').lfmt();
 	
 	$.fn.lfya = function(options){
-		var urla = "https://ws.audioscrobbler.com/2.0/?method=user.gettopartists&user=windhamdavid&api_key=e12ea1d0253898ee9a93edfe42ffdeab&period=1year&format=json&limit=50";
+		var urla = "https://ws.audioscrobbler.com/2.0/?method=user.gettopartists&user=windhamdavid&api_key=e12ea1d0253898ee9a93edfe42ffdeab&period=12month&format=json&limit=50";
 		var artists = [];
 		function isLoadeda (artistElement) {
 			for (var i = 0; i < artists.length; i++){
@@ -548,7 +548,7 @@ $('.music-typed').waypoint(function() {
 	};
 	
 	$.fn.lfyt = function(options){
-		var urla = "https://ws.audioscrobbler.com/2.0/?method=user.gettoptracks&user=windhamdavid&api_key=e12ea1d0253898ee9a93edfe42ffdeab&period=1year&format=json&limit=50";
+		var urla = "https://ws.audioscrobbler.com/2.0/?method=user.gettoptracks&user=windhamdavid&api_key=e12ea1d0253898ee9a93edfe42ffdeab&period=12month&format=json&limit=50";
 		var tracks = [];
 		function isLoadedt (tracksElement) {
 			for (var i = 0; i < tracks.length; i++){

File diff suppressed because it is too large
+ 6 - 0
js/jasny-bootstrap-3.1.3.min.js


+ 0 - 167
js/material-ripples.js

@@ -1,167 +0,0 @@
-/* Copyright 2014+, Federico Zivolo, LICENSE at https://github.com/FezVrasta/bootstrap-material-design/blob/master/LICENSE.md */
-/* globals jQuery, navigator */
-
-(function($) {
-
-  // Detect if the browser supports transitions
-  $.support.transition = (function(){
-    var thisBody = document.body || document.documentElement,
-        thisStyle = thisBody.style,
-        support = (
-          thisStyle.transition !== undefined ||
-          thisStyle.WebkitTransition !== undefined ||
-          thisStyle.MozTransition !== undefined ||
-          thisStyle.MsTransition !== undefined ||
-          thisStyle.OTransition !== undefined
-        );
-    return support;
-  })();
-
-  $.ripples = function(options) {
-
-    // Default options
-    var defaultOptions = {
-      "target": ".btn:not(.btn-link), .card-image, .navbar a:not(.withoutripple), .nav-tabs a:not(.withoutripple), .withripple"
-    };
-
-
-    function isTouch() {
-      return /Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent);
-    }
-
-
-    // Fade out the ripple and then destroy it
-    function rippleOut(ripple) {
-
-      // Unbind events from ripple
-      ripple.off();
-
-      // Start the out animation
-      if ($.support.transition) {
-        ripple.addClass("ripple-out");
-      } else {
-        ripple.animate({
-          "opacity": 0
-        }, 100, function() {
-          ripple.trigger("transitionend");
-        });
-      }
-
-      // This function is called when the transition "out" ends
-      ripple.on("transitionend webkitTransitionEnd oTransitionEnd MSTransitionEnd", function(){
-        ripple.remove();
-      });
-
-    }
-
-    // Apply custom options
-    options = $.extend(defaultOptions, options);
-
-
-    $(document)
-    .on("mousedown touchstart", options.target, function(e) {
-      if (isTouch() && e.type == "mousedown") {
-        return false;
-      }
-
-      var element = $(this);
-
-      // If the ripple wrapper does not exists, create it
-      if (!$(this).find(".ripple-wrapper").length) {
-        $(this).append("<div class=ripple-wrapper></div>");
-      }
-
-      var wrapper = $(this).find(".ripple-wrapper");
-
-
-      var wrapperOffset = wrapper.offset(),
-          relX,
-          relY;
-      if (!isTouch()) {
-        // Get the mouse position relative to the ripple wrapper
-        relX = e.pageX - wrapperOffset.left;
-        relY = e.pageY - wrapperOffset.top;
-      } else {
-        // Make sure the user is using only one finger and then get the touch position relative to the ripple wrapper
-        e = e.originalEvent;
-        if (e.touches.length === 1) {
-          relX = e.touches[0].pageX - wrapperOffset.left;
-          relY = e.touches[0].pageY - wrapperOffset.top;
-        } else {
-          return;
-        }
-      }
-
-      // Meet the new ripple
-      var ripple = $("<div></div>");
-
-      // Add to it the ripple class
-      ripple.addClass("ripple");
-
-      // Position it in the right place
-      ripple.css({"left": relX, "top": relY});
-
-      // Set the background color of the ripple
-      ripple.css({"background-color": window.getComputedStyle($(this)[0]).color});
-
-      // Spawn it
-      wrapper.append(ripple);
-
-      // Make sure the ripple has the styles applied (ugly hack but it works)
-      (function() { return window.getComputedStyle(ripple[0]).opacity; })();
-
-      // Set the new size
-      var size = (Math.max($(this).outerWidth(), $(this).outerHeight()) / ripple.outerWidth()) * 2.5;
-
-
-      // Decide if use CSS transitions or jQuery transitions
-      if ($.support.transition) {
-        // Start the transition
-        ripple.css({
-          "-ms-transform": "scale(" + size + ")",
-          "-moz-transform": "scale(" + size + ")",
-          "-webkit-transform": "scale(" + size + ")",
-          "transform": "scale(" + size + ")"
-        });
-        ripple.addClass("ripple-on");
-        ripple.data("animating", "on");
-        ripple.data("mousedown", "on");
-      } else {
-        // Start the transition
-        ripple.animate({
-          "width": Math.max($(this).outerWidth(), $(this).outerHeight()) * 2,
-          "height": Math.max($(this).outerWidth(), $(this).outerHeight()) * 2,
-          "margin-left": Math.max($(this).outerWidth(), $(this).outerHeight()) * -1,
-          "margin-top": Math.max($(this).outerWidth(), $(this).outerHeight()) * -1,
-          "opacity": 0.2
-        }, 500, function() {
-          ripple.trigger("transitionend");
-        });
-      }
-
-      // This function is called when the transition "on" ends
-      setTimeout(function() {
-        ripple.data("animating", "off");
-        if (ripple.data("mousedown") == "off") {
-          rippleOut(ripple);
-        }
-      }, 500);
-
-      // On mouseup or on mouseleave, set the mousedown flag to "off" and try to destroy the ripple
-      element.on("mouseup mouseleave", function() {
-        ripple.data("mousedown", "off");
-        // If the transition "on" is finished then we can destroy the ripple with transition "out"
-        if (ripple.data("animating") == "off") {
-          rippleOut(ripple);
-        }
-      });
-
-    });
-
-  };
-
-  $.fn.ripples = function() {
-    $.ripples({"target": $(this)});
-  };
-
-})(jQuery);

+ 0 - 209
js/material.js

@@ -1,209 +0,0 @@
-/* globals jQuery */
-
-(function($) {
-  // Selector to select only not already processed elements
-  $.expr[":"].notmdproc = function(obj){
-    if ($(obj).data("mdproc")) {
-      return false;
-    } else {
-      return true;
-    }
-  };
-
-  function _isChar(evt) {
-    if (typeof evt.which == "undefined") {
-      return true;
-    } else if (typeof evt.which == "number" && evt.which > 0) {
-      return !evt.ctrlKey && !evt.metaKey && !evt.altKey && evt.which != 8;
-    }
-    return false;
-  }
-
-  $.material =  {
-    "options": {
-      // These options set what will be started by $.material.init()
-      "input": true,
-      "ripples": true,
-      "checkbox": true,
-      "togglebutton": true,
-      "radio": true,
-      "arrive": true,
-      "autofill": true,
-
-      "withRipples": [
-        ".btn:not(.btn-link)",
-        ".card-image",
-        ".navbar a:not(.withoutripple)",
-        ".dropdown-menu a",
-        ".nav-tabs a:not(.withoutripple)",
-        ".withripple"
-      ].join(","),
-      "inputElements": "input.form-control, textarea.form-control, select.form-control",
-      "checkboxElements": ".checkbox > label > input[type=checkbox]",
-      "togglebuttonElements": ".togglebutton > label > input[type=checkbox]",
-      "radioElements": ".radio > label > input[type=radio]"
-    },
-    "checkbox": function(selector) {
-      // Add fake-checkbox to material checkboxes
-      $((selector) ? selector : this.options.checkboxElements)
-      .filter(":notmdproc")
-      .data("mdproc", true)
-      .after("<span class=ripple></span><span class=check></span>");
-    },
-    "togglebutton": function(selector) {
-      // Add fake-checkbox to material checkboxes
-      $((selector) ? selector : this.options.togglebuttonElements)
-      .filter(":notmdproc")
-      .data("mdproc", true)
-      .after("<span class=toggle></span>");
-    },
-    "radio": function(selector) {
-      // Add fake-radio to material radios
-      $((selector) ? selector : this.options.radioElements)
-      .filter(":notmdproc")
-      .data("mdproc", true)
-      .after("<span class=circle></span><span class=check></span>");
-    },
-    "input": function(selector) {
-      $((selector) ? selector : this.options.inputElements)
-      .filter(":notmdproc")
-      .data("mdproc", true)
-      .each( function() {
-        var $this = $(this);
-        $this.wrap("<div class=form-control-wrapper></div>");
-        $this.after("<span class=material-input></span>");
-
-        // Add floating label if required
-        if ($this.hasClass("floating-label")) {
-          var placeholder = $this.attr("placeholder");
-          $this.attr("placeholder", null).removeClass("floating-label");
-          $this.after("<div class=floating-label>" + placeholder + "</div>");
-        }
-
-        // Add hint label if required
-        if ($this.attr("data-hint")) {
-          $this.after("<div class=hint>" + $this.attr("data-hint") + "</div>");
-        }
-
-        // Set as empty if is empty (damn I must improve this...)
-        if ($this.val() === null || $this.val() == "undefined" || $this.val() === "") {
-          $this.addClass("empty");
-        }
-
-        // Support for file input
-        if ($this.parent().next().is("[type=file]")) {
-          $this.parent().addClass("fileinput");
-          var $input = $this.parent().next().detach();
-          $this.after($input);
-        }
-      });
-
-      $(document)
-      .on("change", ".checkbox input[type=checkbox]", function() { $(this).blur(); })
-      .on("keydown paste", ".form-control", function(e) {
-        if(_isChar(e)) {
-          $(this).removeClass("empty");
-        }
-      })
-      .on("keyup change", ".form-control", function() {
-        var $this = $(this);
-        if($this.val() === "") {
-          $this.addClass("empty");
-        } else {
-          $this.removeClass("empty");
-        }
-      })
-      .on("focus", ".form-control-wrapper.fileinput", function() {
-        $(this).find("input").addClass("focus");
-      })
-      .on("blur", ".form-control-wrapper.fileinput", function() {
-        $(this).find("input").removeClass("focus");
-      })
-      .on("change", ".form-control-wrapper.fileinput [type=file]", function() {
-        var value = "";
-        $.each($(this)[0].files, function(i, file) {
-          console.log(file);
-          value += file.name + ", ";
-        });
-        value = value.substring(0, value.length - 2);
-        if (value) {
-          $(this).prev().removeClass("empty");
-        } else {
-          $(this).prev().addClass("empty");
-        }
-        $(this).prev().val(value);
-      });
-    },
-    "ripples": function(selector) {
-      $.ripples({"target": (selector) ? selector : this.options.withRipples});
-    },
-    "autofill": function() {
-
-      // This part of code will detect autofill when the page is loading (username and password inputs for example)
-      var loading = setInterval(function() {
-        $("input[type!=checkbox]").each(function() {
-          if ($(this).val() && $(this).val() !== $(this).attr("value")) {
-            $(this).trigger("change");
-          }
-        });
-      }, 100);
-
-      // After 10 seconds we are quite sure all the needed inputs are autofilled then we can stop checking them
-      setTimeout(function() {
-        clearInterval(loading);
-      }, 10000);
-      // Now we just listen on inputs of the focused form (because user can select from the autofill dropdown only when the input has focus)
-      var focused;
-      $(document)
-      .on("focus", "input", function() {
-        var $inputs = $(this).parents("form").find("input").not("[type=file]");
-        focused = setInterval(function() {
-          $inputs.each(function() {
-            if ($(this).val() !== $(this).attr("value")) {
-              $(this).trigger("change");
-            }
-          });
-        }, 100);
-      })
-      .on("blur", "input", function() {
-        clearInterval(focused);
-      });
-    },
-    "init": function() {
-      if ($.ripples && this.options.ripples) {
-        this.ripples();
-      }
-      if (this.options.input) {
-        this.input();
-      }
-      if (this.options.checkbox) {
-        this.checkbox();
-      }
-      if (this.options.togglebutton) {
-        this.togglebutton();
-      }
-      if (this.options.radio) {
-        this.radio();
-      }
-      if (this.options.autofill) {
-        this.autofill();
-      }
-
-      if (document.arrive && this.options.arrive) {
-        $(document).arrive(this.options.inputElements, function() {
-          $.material.input($(this));
-        });
-        $(document).arrive(this.options.checkboxElements, function() {
-          $.material.checkbox($(this));
-        });
-        $(document).arrive(this.options.radioElements, function() {
-          $.material.radio($(this));
-        });
-        $(document).arrive(this.options.togglebuttonElements, function() {
-          $.material.togglebutton($(this));
-        });
-      }
-    }
-  };
-
-})(jQuery);

File diff suppressed because it is too large
+ 653 - 324
js/script.js


File diff suppressed because it is too large
+ 10 - 9
js/script.min.js


File diff suppressed because it is too large
+ 641 - 0
js/scripts.js


+ 0 - 568
js/smooth.js

@@ -1,568 +0,0 @@
-/**
- * smoothState.js is a jQuery plugin to stop page load jank.
- *
- * This jQuery plugin progressively enhances page loads to 
- * behave more like a single-page application.
- *
- * @author  Miguel Ángel Pérez   reachme@miguel-perez.com
- * @see     https://github.com/miguel-perez/jquery.smoothState.js
- * 
- */
-;(function ( $, window, document, undefined ) {
-    "use strict";
-
-    var
-        /** Used later to scroll page to the top */
-        $body       = $("html, body"),
-        
-        /** Used in development mode to console out useful warnings */
-        consl       = (window.console || false),
-        
-        /** Plugin default options */
-        defaults    = {
-
-            /** jquery element string to specify which anchors smoothstate should bind to */
-            anchors : "a",
-
-            /** If set to true, smoothState will prefetch a link's contents on hover */
-            prefetch : false,
-            
-            /** A selecor that deinfes with links should be ignored by smoothState */
-            blacklist : ".no-smoothstate, [target]",
-            
-            /** If set to true, smoothState will log useful debug information instead of aborting */
-            development : false,
-            
-            /** The number of pages smoothState will try to store in memory and not request again */
-            pageCacheSize : 0,
-            
-            /** A function that can be used to alter urls before they are used to request content */
-            alterRequestUrl : function (url) {
-                return url;
-            },
-            
-            /** Run when a link has been activated */
-            onStart : {
-                duration: 0,
-                render: function (url, $container) {
-                    $body.scrollTop(0);
-                }
-            },
-
-            /** Run if the page request is still pending and onStart has finished animating */
-            onProgress : {
-                duration: 0,
-                render: function (url, $container) {
-                    $body.css("cursor", "wait");
-                    $body.find("a").css("cursor", "wait");
-                }
-            },
-
-            /** Run when requested content is ready to be injected into the page  */
-            onEnd : {
-                duration: 0,
-                render: function (url, $container, $content) {
-                    $body.css("cursor", "auto");
-                    $body.find("a").css("cursor", "auto");
-                    $container.html($content);
-                }
-            },
-
-            /** Run when content has been injected and all animations are complete  */
-            callback : function(url, $container, $content) {
-
-            }
-        },
-        
-        /** Utility functions that are decoupled from SmoothState */
-        utility     = {
-
-            /**
-             * Checks to see if the url is external
-             * @param   {string}    url - url being evaluated
-             * @see     http://stackoverflow.com/questions/6238351/fastest-way-to-detect-external-urls
-             * 
-             */
-            isExternal: function (url) {
-                var match = url.match(/^([^:\/?#]+:)?(?:\/\/([^\/?#]*))?([^?#]+)?(\?[^#]*)?(#.*)?/);
-                if (typeof match[1] === "string" && match[1].length > 0 && match[1].toLowerCase() !== window.location.protocol) {
-                    return true;
-                }
-                if (typeof match[2] === "string" && match[2].length > 0 && match[2].replace(new RegExp(":(" + {"http:": 80, "https:": 443}[window.location.protocol] + ")?$"), "") !== window.location.host) {
-                    return true;
-                }
-                return false;
-            },
-
-            /**
-             * Checks to see if the url is an internal hash
-             * @param   {string}    url - url being evaluated
-             * 
-             */
-            isHash: function (url) {
-                var hasPathname = (url.indexOf(window.location.pathname) > 0) ? true : false,
-                    hasHash = (url.indexOf("#") > 0) ? true : false;
-                return (hasPathname && hasHash) ? true : false;
-            },
-
-            /**
-             * Checks to see if we should be loading this URL
-             * @param   {string}    url - url being evaluated
-             * @param   {string}    blacklist - jquery selector
-             * 
-             */
-            shouldLoad: function ($anchor, blacklist) {
-                var url = $anchor.prop("href");
-                // URL will only be loaded if it"s not an external link, hash, or blacklisted
-                return (!utility.isExternal(url) && !utility.isHash(url) && !$anchor.is(blacklist));
-            },
-
-            /**
-             * Prevents jQuery from stripping elements from $(html)
-             * @param   {string}    url - url being evaluated
-             * @author  Ben Alman   http://benalman.com/
-             * @see     https://gist.github.com/cowboy/742952
-             * 
-             */
-            htmlDoc: function (html) {
-                var parent,
-                    elems       = $(),
-                    matchTag    = /<(\/?)(html|head|body|title|base|meta)(\s+[^>]*)?>/ig,
-                    prefix      = "ss" + Math.round(Math.random() * 100000),
-                    htmlParsed  = html.replace(matchTag, function(tag, slash, name, attrs) {
-                        var obj = {};
-                        if (!slash) {
-                            elems = elems.add("<" + name + "/>");
-                            if (attrs) {
-                                $.each($("<div" + attrs + "/>")[0].attributes, function(i, attr) {
-                                obj[attr.name] = attr.value;
-                                });
-                            }
-                            elems.eq(-1).attr(obj);
-                        }
-                        return "<" + slash + "div" + (slash ? "" : " id='" + prefix + (elems.length - 1) + "'") + ">";
-                    });
-
-                // If no placeholder elements were necessary, just return normal
-                // jQuery-parsed HTML.
-                if (!elems.length) {
-                    return $(html);
-                }
-                // Create parent node if it hasn"t been created yet.
-                if (!parent) {
-                    parent = $("<div/>");
-                }
-                // Create the parent node and append the parsed, place-held HTML.
-                parent.html(htmlParsed);
-                
-                // Replace each placeholder element with its intended element.
-                $.each(elems, function(i) {
-                    var elem = parent.find("#" + prefix + i).before(elems[i]);
-                    elems.eq(i).html(elem.contents());
-                    elem.remove();
-                });
-
-                return parent.children().unwrap();
-            },
-
-            /**
-             * Resets an object if it has too many properties
-             *
-             * This is used to clear the "cache" object that stores
-             * all of the html. This would prevent the client from
-             * running out of memory and allow the user to hit the 
-             * server for a fresh copy of the content.
-             *
-             * @param   {object}    obj
-             * @param   {number}    cap
-             * 
-             */
-            clearIfOverCapacity: function (obj, cap) {
-                // Polyfill Object.keys if it doesn"t exist
-                if (!Object.keys) {
-                    Object.keys = function (obj) {
-                        var keys = [],
-                            k;
-                        for (k in obj) {
-                            if (Object.prototype.hasOwnProperty.call(obj, k)) {
-                                keys.push(k);
-                            }
-                        }
-                        return keys;
-                    };
-                }
-
-                if (Object.keys(obj).length > cap) {
-                    obj = {};
-                }
-
-                return obj;
-            },
-
-            /**
-             * Finds the inner content of an element, by an ID, from a jQuery object
-             * @param   {string}    id
-             * @param   {object}    $html
-             * 
-             */
-            getContentById: function (id, $html) {
-                $html = ($html instanceof jQuery) ? $html : utility.htmlDoc($html);
-                var $insideElem         = $html.find(id),
-                    updatedContainer    = ($insideElem.length) ? $.trim($insideElem.html()) : $html.filter(id).html(),
-                    newContent          = (updatedContainer.length) ? $(updatedContainer) : null;
-                return newContent;
-            },
-
-            /**
-             * Stores html content as jquery object in given object
-             * @param   {object}    object - object contents will be stored into
-             * @param   {string}    url - url to be used as the prop
-             * @param   {jquery}    html - contents to store
-             * 
-             */
-            storePageIn: function (object, url, $html) {
-                $html = ($html instanceof jQuery) ? $html : utility.htmlDoc($html);
-                object[url] = { // Content is indexed by the url
-                    status: "loaded",
-                    title: $html.find("title").text(), // Stores the title of the page
-                    html: $html // Stores the contents of the page
-                };
-                return object;
-            },
-
-            /**
-             * Triggers an "allanimationend" event when all animations are complete
-             * @param   {object}    $element - jQuery object that should trigger event
-             * @param   {string}    resetOn - which other events to trigger allanimationend on
-             * 
-             */
-             triggerAllAnimationEndEvent: function ($element, resetOn) {
-
-                resetOn = " " + resetOn || "";
-
-                var animationCount      = 0,
-                    animationstart      = "animationstart webkitAnimationStart oanimationstart MSAnimationStart",
-                    animationend        = "animationend webkitAnimationEnd oanimationend MSAnimationEnd",
-                    eventname           = "allanimationend",
-                    onAnimationStart    = function (e) {
-                        if ($(e.delegateTarget).is($element)) {
-                            e.stopPropagation();
-                            animationCount ++;
-                        }
-                    },
-                    onAnimationEnd      = function (e) {
-                        if ($(e.delegateTarget).is($element)) {
-                            e.stopPropagation();
-                            animationCount --;
-                            if(animationCount === 0) {
-                                $element.trigger(eventname);
-                            }
-                        }
-                    };
-
-                $element.on(animationstart, onAnimationStart);
-                $element.on(animationend, onAnimationEnd);
-
-                $element.on("allanimationend" + resetOn, function(){
-                    animationCount = 0;
-                    utility.redraw($element);
-                });
-            },
-
-            /** Forces browser to redraw elements */
-            redraw: function ($element) {
-                $element.height(0);
-			    setTimeout(function(){$element.height("auto");}, 0);
-            }
-        },
-
-        /** Handles the popstate event, like when the user hits "back" */
-        onPopState = function ( e ) {
-            if(e.state !== null) {
-                var url     = window.location.href,
-                    $page   = $("#" + e.state.id),
-                    page    = $page.data("smoothState");
-                
-                if(page.href !== url && !utility.isHash(url)) {
-                    page.load(url, true);
-                }
-            }
-        },
-
-        /** Constructor function */
-        SmoothState = function ( element, options ) {
-            var
-                /** Container element smoothState is run on */
-                $container  = $(element),
-                
-                /** Variable that stores pages after they are requested */
-                cache       = {},
-                
-                /** Url of the content that is currently displayed */
-                currentHref = window.location.href,
-
-                /**
-                 * Loads the contents of a url into our container 
-                 *
-                 * @param   {string}    url
-                 * @param   {bool}      isPopped - used to determine if whe should
-                 *                      add a new item into the history object
-                 * 
-                 */
-                load = function (url, isPopped) {
-                    
-                    /** Makes this an optional variable by setting a default */
-                    isPopped = isPopped || false;
-
-                    var
-                        /** Used to check if the onProgress function has been run */
-                        hasRunCallback  = false,
-
-                        callbBackEnded  = false,
-                        
-                        /** List of responses for the states of the page request */
-                        responses       = {
-
-                            /** Page is ready, update the content */
-                            loaded: function() {
-                                var eventName = hasRunCallback ? "ss.onProgressEnd" : "ss.onStartEnd";
-
-                                if(!callbBackEnded || !hasRunCallback) {
-                                    $container.one(eventName, function(){
-                                        updateContent(url);
-                                    });
-                                } else if(callbBackEnded) {
-                                    updateContent(url);
-                                }
-
-                                if(!isPopped) {
-                                    window.history.pushState({ id: $container.prop("id") }, cache[url].title, url);
-                                }
-                            },
-
-                            /** Loading, wait 10 ms and check again */
-                            fetching: function() {
-                                
-                                if(!hasRunCallback) {
-                                    
-                                    hasRunCallback = true;
-                                    
-                                    // Run the onProgress callback and set trigger
-                                    $container.one("ss.onStartEnd", function(){
-                                        options.onProgress.render(url, $container, null);
-                                        
-                                        setTimeout(function(){
-                                            $container.trigger("ss.onProgressEnd");
-                                            callbBackEnded = true;
-                                        }, options.onStart.duration);
-                                    
-                                    });
-                                }
-                                
-                                setTimeout(function () {
-                                    // Might of been canceled, better check!
-                                    if(cache.hasOwnProperty(url)){
-                                        responses[cache[url].status]();
-                                    }
-                                }, 10);
-                            },
-
-                            /** Error, abort and redirect */
-                            error: function(){
-                                window.location = url;
-                            }
-                        };
-                    
-                    if (!cache.hasOwnProperty(url)) {
-                        fetch(url);
-                    }
-                    
-                    // Run the onStart callback and set trigger
-                    options.onStart.render(url, $container, null);
-                    setTimeout(function(){
-                        $container.trigger("ss.onStartEnd");
-                    }, options.onStart.duration);
-
-                    // Start checking for the status of content
-                    responses[cache[url].status]();
-
-                },
-
-                /** Updates the contents from cache[url] */
-                updateContent = function (url) {
-                    // If the content has been requested and is done:
-                    var containerId = "#" + $container.prop("id"),
-                        $content    = cache[url] ? utility.getContentById(containerId, cache[url].html) : null;
-
-                    if($content) {
-                        document.title = cache[url].title;
-                        $container.data("smoothState").href = url;
-                        
-                        // Call the onEnd callback and set trigger
-                        options.onEnd.render(url, $container, $content);
-
-                        $container.one("ss.onEndEnd", function(){
-                            options.callback(url, $container, $content);
-                        });
-
-                        setTimeout(function(){
-                            $container.trigger("ss.onEndEnd");
-                        }, options.onEnd.duration);
-
-                    } else if (!$content && options.development && consl) {
-                        // Throw warning to help debug in development mode
-                        consl.warn("No element with an id of " + containerId + " in response from " + url + " in " + cache);
-                    } else {
-                        // No content availble to update with, aborting...
-                        window.location = url;
-                    }
-                },
-
-                /**
-                 * Fetches the contents of a url and stores it in the "cache" varible
-                 * @param   {string}    url
-                 * 
-                 */
-                fetch = function (url) {
-
-                    // Don"t fetch we have the content already
-                    if(cache.hasOwnProperty(url)) {
-                        return;
-                    }
-
-                    cache = utility.clearIfOverCapacity(cache, options.pageCacheSize);
-                    
-                    cache[url] = { status: "fetching" };
-
-                    var requestUrl  = options.alterRequestUrl(url) || url,
-                        request     = $.ajax(requestUrl);
-
-                    // Store contents in cache variable if successful
-                    request.success(function (html) {
-                        // Clear cache varible if it"s getting too big
-                        utility.storePageIn(cache, url, html);
-                        $container.data("smoothState").cache = cache;
-                    });
-
-                    // Mark as error
-                    request.error(function () {
-                        cache[url].status = "error";
-                    });
-                },
-                /**
-                 * Binds to the hover event of a link, used for prefetching content
-                 *
-                 * @param   {object}    event
-                 * 
-                 */
-                hoverAnchor = function (event) {
-                    var $anchor = $(event.currentTarget),
-                        url     = $anchor.prop("href");
-                    if (utility.shouldLoad($anchor, options.blacklist)) {
-                        event.stopPropagation();
-                        fetch(url);
-                    }
-                },
-
-                /**
-                 * Binds to the click event of a link, used to show the content
-                 *
-                 * @param   {object}    event
-                 * 
-                 */
-                clickAnchor = function (event) {
-                    var $anchor     = $(event.currentTarget),
-                        url         = $anchor.prop("href");
-
-                    // Ctrl (or Cmd) + click must open a new tab
-                    if (!event.metaKey && !event.ctrlKey && utility.shouldLoad($anchor, options.blacklist)) {
-                        // stopPropagation so that event doesn"t fire on parent containers.
-                        event.stopPropagation();
-                        event.preventDefault();
-                        load(url);
-                    }
-                },
-
-                /**
-                 * Binds all events and inits functionality
-                 *
-                 * @param   {object}    event
-                 * 
-                 */
-                bindEventHandlers = function ($element) {
-                    //@todo: Handle form submissions
-                    $element.on("click", options.anchors, clickAnchor);
-
-                    if (options.prefetch) {
-                        $element.on("mouseover touchstart", options.anchors, hoverAnchor);
-                    }
-
-                },
-
-                /** Used to restart css animations with a class */
-                toggleAnimationClass = function (classname) {
-                    var classes = $container.addClass(classname).prop("class");
-                    
-                    $container.removeClass(classes);
-                    
-                    setTimeout(function(){
-                        $container.addClass(classes);
-                    },0);
-
-                    $container.one("ss.onStartEnd ss.onProgressEnd ss.onEndEnd", function(){
-                        $container.removeClass(classname);
-                    });
-                    
-                };
-
-            /** Override defaults with options passed in */
-            options = $.extend(defaults, options);
-
-            /** Sets a default state */
-            if(window.history.state === null) {
-                window.history.replaceState({ id: $container.prop("id") }, document.title, currentHref);
-            }
-
-            /** Stores the current page in cache variable */
-            utility.storePageIn(cache, currentHref, document.documentElement.outerHTML);
-
-            /** Bind all of the event handlers on the container, not anchors */
-            utility.triggerAllAnimationEndEvent($container, "ss.onStartEnd ss.onProgressEnd ss.onEndEnd");
-
-            /** Bind all of the event handlers on the container, not anchors */
-            bindEventHandlers($container);
-
-            /** Public methods */
-            return {
-                href: currentHref,
-                cache: cache,
-                load: load,
-                fetch: fetch,
-                toggleAnimationClass: toggleAnimationClass
-            };
-        },
-
-        /** Returns elements with SmoothState attached to it */
-        declareSmoothState = function ( options ) {
-            return this.each(function () {
-                // Checks to make sure the smoothState element has an id and isn"t already bound
-                if(this.id && !$.data(this, "smoothState")) {
-                    // Makes public methods available via $("element").data("smoothState");
-                    $.data(this, "smoothState", new SmoothState(this, options));
-                } else if (!this.id && consl) {
-                    // Throw warning if in development mode
-                    consl.warn("Every smoothState container needs an id but the following one does not have one:", this);
-                }
-            });
-        };
-
-    /** Sets the popstate function */
-    window.onpopstate = onPopState;
-
-    /** Makes utility functions public for unit tests */
-    $.smoothStateUtility = utility;
-
-    /** Defines the smoothState plugin */
-    $.fn.smoothState = declareSmoothState;
-
-})(jQuery, window, document);

File diff suppressed because it is too large
+ 0 - 364
js/validate-chimp.js


File diff suppressed because it is too large
+ 0 - 1277
js/validate-form.js


File diff suppressed because it is too large
+ 1 - 1
js/validate.min.js