Simple Calendar – Google Calendar Plugin - Version 3.1.2

Version Description

  • July 13, 2016 =

  • Fix: Multi-day events do not stop short a day.

  • Fix: Events that end at midnight no longer duplicate on the next day.

  • Fix: Header shows correct date in list view when there are no events to show.

  • Tweak: Tightened up security a bit.

  • Dev: Tested up to WordPress 4.6.

Download this release

Release Info

Developer pderksen
Plugin Icon 128x128 Simple Calendar – Google Calendar Plugin
Version 3.1.2
Comparing to
See all releases

Code changes from version 3.1.1 to 3.1.2

Files changed (34) hide show
  1. assets/css/admin-activation.min.css +1 -1
  2. assets/css/admin-add-calendar.min.css +1 -1
  3. assets/css/admin.css +2 -15
  4. assets/css/admin.min.css +2 -2
  5. assets/css/default-calendar-grid.css +1 -13
  6. assets/css/default-calendar-grid.min.css +2 -2
  7. assets/css/default-calendar-list.css +1 -13
  8. assets/css/default-calendar-list.min.css +2 -2
  9. assets/js/admin-add-calendar.min.js +1 -1
  10. assets/js/admin.min.js +1 -1
  11. assets/js/default-calendar.js +9 -6
  12. assets/js/default-calendar.min.js +2 -2
  13. assets/js/vendor/moment.js +2028 -1873
  14. assets/js/vendor/moment.min.js +488 -3
  15. google-calendar-events.php +2 -2
  16. includes/admin/metaboxes/settings.php +1 -0
  17. includes/admin/pages/system-status.php +11 -5
  18. includes/calendars/default-calendar.php +1 -7
  19. includes/calendars/views/default-calendar-list.php +9 -7
  20. includes/feeds/google.php +2 -2
  21. readme.txt +12 -4
  22. vendor/composer/installed.json +59 -57
  23. vendor/composer/installers/README.md +5 -1
  24. vendor/composer/installers/composer.json +2 -0
  25. vendor/composer/installers/src/Composer/Installers/BitrixInstaller.php +9 -6
  26. vendor/composer/installers/src/Composer/Installers/DecibelInstaller.php +10 -0
  27. vendor/composer/installers/src/Composer/Installers/ExpressionEngineInstaller.php +29 -0
  28. vendor/composer/installers/src/Composer/Installers/Installer.php +5 -0
  29. vendor/composer/installers/src/Composer/Installers/PhiftyInstaller.php +11 -0
  30. vendor/composer/installers/src/Composer/Installers/RadPHPInstaller.php +24 -0
  31. vendor/composer/installers/tests/Composer/Installers/Test/InstallerTest.php +21 -0
  32. vendor/symfony/translation/Loader/MoFileLoader.php +1 -1
  33. vendor/symfony/translation/Tests/PluralizationRulesTest.php +1 -1
  34. vendor/symfony/translation/Tests/TranslatorTest.php +3 -3
assets/css/admin-activation.min.css CHANGED
@@ -1,4 +1,4 @@
1
- /*! Simple Calendar - 3.1.1
2
  * https://simplecalendar.io
3
  * Copyright (c) Moonstone Media 2016
4
  * Licensed GPLv2+ */
1
+ /*! Simple Calendar - 3.1.2
2
  * https://simplecalendar.io
3
  * Copyright (c) Moonstone Media 2016
4
  * Licensed GPLv2+ */
assets/css/admin-add-calendar.min.css CHANGED
@@ -1,4 +1,4 @@
1
- /*! Simple Calendar - 3.1.1
2
  * https://simplecalendar.io
3
  * Copyright (c) Moonstone Media 2016
4
  * Licensed GPLv2+ */
1
+ /*! Simple Calendar - 3.1.2
2
  * https://simplecalendar.io
3
  * Copyright (c) Moonstone Media 2016
4
  * Licensed GPLv2+ */
assets/css/admin.css CHANGED
@@ -23,32 +23,20 @@
23
  -moz-osx-font-smoothing: grayscale; }
24
 
25
  .simcal-icon-spin {
26
- -webkit-animation: spin 2s infinite linear;
27
  animation: spin 2s infinite linear;
28
  display: inline-block; }
29
 
30
- @-webkit-keyframes spin {
31
- 0% {
32
- -webkit-transform: rotate(0deg);
33
- transform: rotate(0deg); }
34
- 100% {
35
- -webkit-transform: rotate(359deg);
36
- transform: rotate(359deg); } }
37
-
38
  @keyframes spin {
39
  0% {
40
- -webkit-transform: rotate(0deg);
41
  transform: rotate(0deg); }
42
  100% {
43
- -webkit-transform: rotate(359deg);
44
  transform: rotate(359deg); } }
45
 
46
  .simcal-icon-animate:before {
47
  transition: all .2s ease-in-out; }
48
 
49
  .simcal-icon-rotate-180:before {
50
- -webkit-transform: rotate(180deg);
51
- transform: rotate(180deg); }
52
 
53
  .simcal-icon-calendar-empty:before {
54
  content: '\e800'; }
@@ -283,8 +271,7 @@ body .simcal-field-textarea {
283
  display: block; }
284
  .simcal-field-datetime-format .ui-sortable-helper {
285
  box-shadow: -2px 4px 8px rgba(0, 0, 0, 0.12);
286
- -webkit-transform: rotate(2deg);
287
- transform: rotate(2deg); }
288
 
289
  #simcal-settings-page .simcal-wide-text {
290
  width: 40em; }
23
  -moz-osx-font-smoothing: grayscale; }
24
 
25
  .simcal-icon-spin {
 
26
  animation: spin 2s infinite linear;
27
  display: inline-block; }
28
 
 
 
 
 
 
 
 
 
29
  @keyframes spin {
30
  0% {
 
31
  transform: rotate(0deg); }
32
  100% {
 
33
  transform: rotate(359deg); } }
34
 
35
  .simcal-icon-animate:before {
36
  transition: all .2s ease-in-out; }
37
 
38
  .simcal-icon-rotate-180:before {
39
+ transform: rotate(180deg); }
 
40
 
41
  .simcal-icon-calendar-empty:before {
42
  content: '\e800'; }
271
  display: block; }
272
  .simcal-field-datetime-format .ui-sortable-helper {
273
  box-shadow: -2px 4px 8px rgba(0, 0, 0, 0.12);
274
+ transform: rotate(2deg); }
 
275
 
276
  #simcal-settings-page .simcal-wide-text {
277
  width: 40em; }
assets/css/admin.min.css CHANGED
@@ -1,6 +1,6 @@
1
- /*! Simple Calendar - 3.1.1
2
  * https://simplecalendar.io
3
  * Copyright (c) Moonstone Media 2016
4
  * Licensed GPLv2+ */
5
 
6
- @font-face{font-family:simple-calendar;src:url(../fonts/simple-calendar.eot?43976014);src:url(../fonts/simple-calendar.eot?43976014#iefix) format("embedded-opentype"),url(../fonts/simple-calendar.woff?43976014) format("woff"),url(../fonts/simple-calendar.ttf?43976014) format("truetype"),url(../fonts/simple-calendar.svg?43976014#simple-calendar) format("svg");font-weight:400;font-style:normal}[class*=" simcal-icon-"]:before,[class^=simcal-icon-]:before{display:inline-block;font-family:simple-calendar;font-style:normal;font-weight:400;margin-right:.2em;speak:none;text-decoration:inherit;text-align:center;width:1em;font-variant:normal;text-transform:none;margin-left:.2em;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}#ui-datepicker-div.simcal-date-picker>table tr td a,#ui-datepicker-div.simcal-date-picker>table tr th a,.simcal-tabs a{text-decoration:none}.simcal-icon-spin{-webkit-animation:spin 2s infinite linear;animation:spin 2s infinite linear;display:inline-block}@-webkit-keyframes spin{0%{-webkit-transform:rotate(0);transform:rotate(0)}100%{-webkit-transform:rotate(359deg);transform:rotate(359deg)}}@keyframes spin{0%{-webkit-transform:rotate(0);transform:rotate(0)}100%{-webkit-transform:rotate(359deg);transform:rotate(359deg)}}.simcal-icon-animate:before{transition:all .2s ease-in-out}.simcal-icon-rotate-180:before{-webkit-transform:rotate(180deg);transform:rotate(180deg)}.simcal-icon-calendar-empty:before{content:'\e800'}.simcal-icon-calendar:before{content:'\e801'}.simcal-icon-calendar-logo:before{content:'\e802'}.simcal-icon-settings:before{content:'\e804'}.simcal-icon-toggles:before{content:'\e805'}.simcal-icon-list:before{content:'\e806'}.simcal-icon-event:before{content:'\e807'}.simcal-icon-help:before{content:'\e808'}.simcal-icon-panel:before{content:'\e80a'}.simcal-icon-grid:before{content:'\e80b'}.simcal-icon-google:before{content:'\e80c'}.simcal-icon-docs:before{content:'\e80f'}.simcal-icon-hourglass:before{content:'\e811'}.simcal-icon-globe:before{content:'\e812'}.simcal-icon-timezones:before{content:'\e813'}.simcal-icon-warning:before{content:'\e815'}.simcal-icon-wordpress:before{content:'\e814'}.simcal-icon-up:before{content:'\e80e'}.simcal-icon-right:before{content:'\e809'}.simcal-icon-down:before{content:'\e80d'}.simcal-icon-left:before{content:'\e803'}.simcal-icon-spinner:before{content:'\e810'}.simcal-help-tip{color:rgba(0,0,0,.46);cursor:help}#tiptip_holder{display:none;left:0;position:absolute;top:0;z-index:9999999}#tiptip_holder.tip_top{padding-bottom:5px}#tiptip_holder.tip_bottom{padding-top:5px}#tiptip_holder.tip_right{padding-left:5px}#tiptip_holder.tip_left{padding-right:5px}#tiptip_content{background-color:rgba(25,25,25,.92);border:1px solid rgba(255,255,255,.25);border-radius:3px;color:#fff;font-size:11px;padding:4px 8px}#tiptip_arrow,#tiptip_arrow_inner{border-color:transparent;border-style:solid;border-width:6px;height:0;position:absolute;width:0}#tiptip_holder.tip_top #tiptip_arrow_inner{border-top-color:rgba(25,25,25,.92);margin-left:-6px;margin-top:-7px}#tiptip_holder.tip_bottom #tiptip_arrow_inner{border-bottom-color:rgba(25,25,25,.92);margin-left:-6px;margin-top:-5px}#tiptip_holder.tip_right #tiptip_arrow_inner{border-right-color:rgba(25,25,25,.92);margin-left:-5px;margin-top:-6px}#tiptip_holder.tip_left #tiptip_arrow_inner{border-left-color:rgba(25,25,25,.92);margin-left:-7px;margin-top:-6px}@media screen and (-webkit-min-device-pixel-ratio:0){#tiptip_content{background-color:rgba(45,45,45,.88);padding:4px 8px 5px}#tiptip_holder.tip_bottom #tiptip_arrow_inner{border-bottom-color:rgba(45,45,45,.88)}#tiptip_holder.tip_top #tiptip_arrow_inner{border-top-color:rgba(20,20,20,.92)}}.simcal-dismiss-notice{color:#ccc;float:right;margin-top:9px;text-decoration:none}.simcal-dismiss-notice:hover{color:#aaa}.simcal-dismiss-notice:active,.simcal-dismiss-notice:focus{outline:0}.wp-admin .simcal-field-inline,.wp-admin .simcal-field-inline>input,.wp-admin .simcal-field-inline>select{display:inline-block;vertical-align:baseline}body .simcal-field-tiny,body .simcal-panel-field .simcal-field-tiny{max-width:60px}body .simcal-field-small,body .simcal-panel-field .simcal-field-small{max-width:100px}body .simcal-field-select-enhanced,body .simcal-field-textarea{max-width:500px;width:100%}.select2-container{z-index:999999}body .simcal-field-textarea{min-height:64px;vertical-align:top}.simcal-field-radios>i{margin-left:5px;vertical-align:middle}.simcal-field-radios-inline{display:inline-block;margin:0}.simcal-field-radios-inline>li{display:inline-block;margin-right:10px}.simcal-field-radios-inline>li:last-child{margin-right:0}.simcal-field-bool>input{line-height:2.4}.simcal-field-date-picker>input[type=text]{max-width:120px}#ui-datepicker-div.simcal-date-picker{background-color:#fff;box-shadow:0 2px 10px rgba(0,0,0,.1);padding:8px 10px}#ui-datepicker-div.simcal-date-picker .ui-datepicker-header>a{display:inline-block;cursor:pointer;margin-top:7px}#ui-datepicker-div.simcal-date-picker .ui-datepicker-header>a:first-of-type{float:left}#ui-datepicker-div.simcal-date-picker .ui-datepicker-header>a:last-of-type{float:right}#ui-datepicker-div.simcal-date-picker .ui-datepicker-header .ui-datepicker-title{margin:0 10% 4px}#ui-datepicker-div.simcal-date-picker .ui-datepicker-header .ui-datepicker-title>select{width:48.5%}#ui-datepicker-div.simcal-date-picker .ui-datepicker-today{background-color:#eee}#ui-datepicker-div.simcal-date-picker>table tr td,#ui-datepicker-div.simcal-date-picker>table tr th{padding:2px 4px;text-align:center}.simcal-field-datetime-format{padding:10px 0 5px}.simcal-field-datetime-format>div{background-color:rgba(0,0,0,.03);border:1px dashed rgba(0,0,0,.18);border-radius:3px;cursor:move;display:inline-block;float:left;margin:0 10px 15px 0;padding:10px}.simcal-field-datetime-format select{display:block}.simcal-field-datetime-format>span{clear:both;display:block}.simcal-field-datetime-format .ui-sortable-helper{box-shadow:-2px 4px 8px rgba(0,0,0,.12);-webkit-transform:rotate(2deg);transform:rotate(2deg)}#simcal-settings-page .select2-search__field,#simcal-settings-page .select2-search__field:focus{border:0!important;box-shadow:none!important}#simcal-settings-page .simcal-wide-text{width:40em}#simcal-settings-page .select2{max-width:500px}#simcal-settings-page .select2-search__field{margin:0}#simcal-settings-page .select2-selection{border:1px solid #ddd;border-radius:0}#simcal-settings-page .select2-container--open .select2-selection{border-color:#5b9dd9;box-shadow:0 0 2px rgba(30,140,190,.8)}.about-wrap .simcal-badge{position:absolute;top:0;right:0}.simcal-badge{background-image:url(../images/welcome/icon-185x185.png);height:185px;width:185px}#simcal-welcome .whats-new-wrap img{margin:1em 2em 1em 0;border:1px solid #d6d6d6;box-sizing:border-box;vertical-align:top}#simcal-system-status-report textarea{font-family:monospace;min-height:200px;padding:5px 20px;white-space:pre;width:100%}.simcal-system-status-report-panel{margin:20px 0}.simcal-system-status-report-panel thead th{font-weight:700}.simcal-system-status-report-panel tbody td,.simcal-system-status-report-panel thead th{font-size:14px;vertical-align:top}.simcal-system-status-report-panel tbody .tooltip{text-align:center;width:20px}.simcal-system-status-report-panel tbody .label{width:30%}.simcal-system-status-report-panel tbody tr:nth-child(odd) td{background-color:rgba(0,0,0,.02)}.simcal-system-status-report-panel dl{margin:0;padding:0}.simcal-system-status-report-panel dt{float:left;font-style:italic;margin:0 4px 0 0}.simcal-system-status-report-panel dd{margin:0}.simcal-system-status-report-panel mark{background-color:transparent;font-weight:700}.simcal-system-status-report-panel mark.ok{color:green}#simcal-reset-licenses,.simcal-system-status-report-panel mark.error{color:red}.ui-datepicker{left:-9999px;position:absolute}#simcal-clear-cache{float:right;margin:0 10px 10px}#simcal-get-shortcode .inside{padding:5px 15px 10px;text-align:center}#simcal-get-shortcode input,#simcal-newsletter input{width:100%}#simcal-newsletter{background-color:#fcf8e3}#simcal-calendar-settings{display:none}#simcal-calendar-settings .hndle{line-height:2;padding:10px}#simcal-calendar-settings .inside{margin:0;padding:0}#simcal-calendar-settings .select2-container{border-radius:0;max-width:500px}#simcal-calendar-settings .select2-search__field{border:0!important;box-shadow:none!important;margin:0}#simcal-calendar-settings .select2-search__field:focus{border:0!important;box-shadow:none!important}#simcal-calendar-settings .select2-selection{border:1px solid #ddd;border-radius:0}#simcal-calendar-settings .select2-container--open .select2-selection{border-color:#5b9dd9;box-shadow:0 0 2px rgba(30,140,190,.8)}#simcal-calendar-settings .select2-selection__choice{margin-bottom:0}#simcal-calendar-settings .wp-picker-container{vertical-align:inherit}.simcal-box-handle{display:inline-block;line-height:1;margin-left:8px}.simcal-box-handle:before{content:'\2014';display:inline-block;font-weight:400}.simcal-box-handle label{font-size:12px;font-weight:400;margin-right:10px;vertical-align:baseline}.simcal-box-handle select{font-weight:700;margin:-3px 0 0 .5em;vertical-align:middle}.simcal-tabs{background:#fafafa;border-right:1px solid #eee;box-sizing:border-box;float:left;line-height:1em;margin:0;padding:0 0 10px;position:relative;width:20%}.simcal-tabs a{border-bottom:1px solid #eee;display:block;line-height:20px!important;margin:0;padding:10px}.simcal-tabs a:focus{box-shadow:none}.simcal-tabs li{display:block;margin:0;padding:0}.simcal-tabs li.active a{background-color:#eee;color:#555;position:relative}.simcal-tabs:after{background-color:#fafafa;border-right:1px solid #eee;bottom:-9999em;content:"";display:block;height:9999em;left:0;position:absolute;width:100%}.simcal-panels-wrap{background:#fff;overflow:hidden}.simcal-panel{margin-left:20%;max-width:80%}.simcal-panel>table{padding-bottom:11px;width:100%}.simcal-panel>table thead th{border-bottom:1px solid #eee;font-size:14px;font-weight:700;padding:12px 0 15px 10px;text-align:left}.simcal-panel>table>tbody tr:first-child td,.simcal-panel>table>tbody tr:first-child th{padding-top:14px}.simcal-panel>table>tbody tr:last-child td,.simcal-panel>table>tbody tr:last-child th{border-bottom:1px solid #eee;padding-bottom:14px}.simcal-panel>table>tbody:last-of-type tr:last-child td,.simcal-panel>table>tbody:last-of-type tr:last-child th{border-bottom:0}.simcal-panel-field>td{width:82%}.simcal-panel-field>th{font-weight:400;min-width:100px;width:15%}.simcal-panel-field>td,.simcal-panel-field>th{padding:9px 3% 9px 10px;text-align:left;vertical-align:text-top}.simcal-panel-field .simcal-field-text{max-width:500px;width:90%}@media screen and (max-width:1023px){.simcal-box-handle{display:block;line-height:2;margin:16px 0 0}.simcal-box-handle:before{display:none}.simcal-box-handle label{display:table;margin-bottom:16px;width:100%}.simcal-box-handle label>span{display:table-cell;width:20%}.simcal-box-handle label>select{display:table-cell;width:80%}.simcal-box-handle .simcal-tabs{width:16%}.simcal-box-handle .simcal-tabs i{font-size:18px;line-height:1}.simcal-box-handle .simcal-tabs span{display:none}.simcal-box-handle .simcal-panel{margin-left:16%;max-width:84%}.simcal-box-handle .simcal-panel-section{display:block;overflow:hidden}.simcal-box-handle .simcal-panel-field th{display:block;width:100%}.simcal-box-handle .simcal-panel-field td{display:inline-block;width:100%}.simcal-box-handle .simcal-panel-field select{max-width:86%}}input.simcal-shortcode{border:1px dashed rgba(0,0,0,.3);color:rgba(0,0,0,.58);font-family:monospace;font-weight:700;text-align:center}
1
+ /*! Simple Calendar - 3.1.2
2
  * https://simplecalendar.io
3
  * Copyright (c) Moonstone Media 2016
4
  * Licensed GPLv2+ */
5
 
6
+ @font-face{font-family:simple-calendar;src:url(../fonts/simple-calendar.eot?43976014);src:url(../fonts/simple-calendar.eot?43976014#iefix) format("embedded-opentype"),url(../fonts/simple-calendar.woff?43976014) format("woff"),url(../fonts/simple-calendar.ttf?43976014) format("truetype"),url(../fonts/simple-calendar.svg?43976014#simple-calendar) format("svg");font-weight:400;font-style:normal}[class*=" simcal-icon-"]:before,[class^=simcal-icon-]:before{display:inline-block;font-family:simple-calendar;font-style:normal;font-weight:400;margin-right:.2em;speak:none;text-decoration:inherit;text-align:center;width:1em;font-variant:normal;text-transform:none;margin-left:.2em;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}#ui-datepicker-div.simcal-date-picker>table tr td a,#ui-datepicker-div.simcal-date-picker>table tr th a,.simcal-tabs a{text-decoration:none}.simcal-icon-spin{animation:spin 2s infinite linear;display:inline-block}@keyframes spin{0%{transform:rotate(0)}100%{transform:rotate(359deg)}}.simcal-icon-animate:before{transition:all .2s ease-in-out}.simcal-icon-rotate-180:before{transform:rotate(180deg)}.simcal-icon-calendar-empty:before{content:'\e800'}.simcal-icon-calendar:before{content:'\e801'}.simcal-icon-calendar-logo:before{content:'\e802'}.simcal-icon-settings:before{content:'\e804'}.simcal-icon-toggles:before{content:'\e805'}.simcal-icon-list:before{content:'\e806'}.simcal-icon-event:before{content:'\e807'}.simcal-icon-help:before{content:'\e808'}.simcal-icon-panel:before{content:'\e80a'}.simcal-icon-grid:before{content:'\e80b'}.simcal-icon-google:before{content:'\e80c'}.simcal-icon-docs:before{content:'\e80f'}.simcal-icon-hourglass:before{content:'\e811'}.simcal-icon-globe:before{content:'\e812'}.simcal-icon-timezones:before{content:'\e813'}.simcal-icon-warning:before{content:'\e815'}.simcal-icon-wordpress:before{content:'\e814'}.simcal-icon-up:before{content:'\e80e'}.simcal-icon-right:before{content:'\e809'}.simcal-icon-down:before{content:'\e80d'}.simcal-icon-left:before{content:'\e803'}.simcal-icon-spinner:before{content:'\e810'}.simcal-help-tip{color:rgba(0,0,0,.46);cursor:help}#tiptip_holder{display:none;left:0;position:absolute;top:0;z-index:9999999}#tiptip_holder.tip_top{padding-bottom:5px}#tiptip_holder.tip_bottom{padding-top:5px}#tiptip_holder.tip_right{padding-left:5px}#tiptip_holder.tip_left{padding-right:5px}#tiptip_content{background-color:rgba(25,25,25,.92);border:1px solid rgba(255,255,255,.25);border-radius:3px;color:#fff;font-size:11px;padding:4px 8px}#tiptip_arrow,#tiptip_arrow_inner{border-color:transparent;border-style:solid;border-width:6px;height:0;position:absolute;width:0}#tiptip_holder.tip_top #tiptip_arrow_inner{border-top-color:rgba(25,25,25,.92);margin-left:-6px;margin-top:-7px}#tiptip_holder.tip_bottom #tiptip_arrow_inner{border-bottom-color:rgba(25,25,25,.92);margin-left:-6px;margin-top:-5px}#tiptip_holder.tip_right #tiptip_arrow_inner{border-right-color:rgba(25,25,25,.92);margin-left:-5px;margin-top:-6px}#tiptip_holder.tip_left #tiptip_arrow_inner{border-left-color:rgba(25,25,25,.92);margin-left:-7px;margin-top:-6px}@media screen and (-webkit-min-device-pixel-ratio:0){#tiptip_content{background-color:rgba(45,45,45,.88);padding:4px 8px 5px}#tiptip_holder.tip_bottom #tiptip_arrow_inner{border-bottom-color:rgba(45,45,45,.88)}#tiptip_holder.tip_top #tiptip_arrow_inner{border-top-color:rgba(20,20,20,.92)}}.simcal-dismiss-notice{color:#ccc;float:right;margin-top:9px;text-decoration:none}.simcal-dismiss-notice:hover{color:#aaa}.simcal-dismiss-notice:active,.simcal-dismiss-notice:focus{outline:0}.wp-admin .simcal-field-inline,.wp-admin .simcal-field-inline>input,.wp-admin .simcal-field-inline>select{display:inline-block;vertical-align:baseline}body .simcal-field-tiny,body .simcal-panel-field .simcal-field-tiny{max-width:60px}body .simcal-field-small,body .simcal-panel-field .simcal-field-small{max-width:100px}body .simcal-field-select-enhanced,body .simcal-field-textarea{max-width:500px;width:100%}.select2-container{z-index:999999}body .simcal-field-textarea{min-height:64px;vertical-align:top}.simcal-field-radios>i{margin-left:5px;vertical-align:middle}.simcal-field-radios-inline{display:inline-block;margin:0}.simcal-field-radios-inline>li{display:inline-block;margin-right:10px}.simcal-field-radios-inline>li:last-child{margin-right:0}.simcal-field-bool>input{line-height:2.4}.simcal-field-date-picker>input[type=text]{max-width:120px}#ui-datepicker-div.simcal-date-picker{background-color:#fff;box-shadow:0 2px 10px rgba(0,0,0,.1);padding:8px 10px}#ui-datepicker-div.simcal-date-picker .ui-datepicker-header>a{display:inline-block;cursor:pointer;margin-top:7px}#ui-datepicker-div.simcal-date-picker .ui-datepicker-header>a:first-of-type{float:left}#ui-datepicker-div.simcal-date-picker .ui-datepicker-header>a:last-of-type{float:right}#ui-datepicker-div.simcal-date-picker .ui-datepicker-header .ui-datepicker-title{margin:0 10% 4px}#ui-datepicker-div.simcal-date-picker .ui-datepicker-header .ui-datepicker-title>select{width:48.5%}#ui-datepicker-div.simcal-date-picker .ui-datepicker-today{background-color:#eee}#ui-datepicker-div.simcal-date-picker>table tr td,#ui-datepicker-div.simcal-date-picker>table tr th{padding:2px 4px;text-align:center}.simcal-field-datetime-format{padding:10px 0 5px}.simcal-field-datetime-format>div{background-color:rgba(0,0,0,.03);border:1px dashed rgba(0,0,0,.18);border-radius:3px;cursor:move;display:inline-block;float:left;margin:0 10px 15px 0;padding:10px}.simcal-field-datetime-format select{display:block}.simcal-field-datetime-format>span{clear:both;display:block}.simcal-field-datetime-format .ui-sortable-helper{box-shadow:-2px 4px 8px rgba(0,0,0,.12);transform:rotate(2deg)}#simcal-settings-page .select2-search__field,#simcal-settings-page .select2-search__field:focus{border:0!important;box-shadow:none!important}#simcal-settings-page .simcal-wide-text{width:40em}#simcal-settings-page .select2{max-width:500px}#simcal-settings-page .select2-search__field{margin:0}#simcal-settings-page .select2-selection{border:1px solid #ddd;border-radius:0}#simcal-settings-page .select2-container--open .select2-selection{border-color:#5b9dd9;box-shadow:0 0 2px rgba(30,140,190,.8)}.about-wrap .simcal-badge{position:absolute;top:0;right:0}.simcal-badge{background-image:url(../images/welcome/icon-185x185.png);height:185px;width:185px}#simcal-welcome .whats-new-wrap img{margin:1em 2em 1em 0;border:1px solid #d6d6d6;box-sizing:border-box;vertical-align:top}#simcal-system-status-report textarea{font-family:monospace;min-height:200px;padding:5px 20px;white-space:pre;width:100%}.simcal-system-status-report-panel{margin:20px 0}.simcal-system-status-report-panel thead th{font-weight:700}.simcal-system-status-report-panel tbody td,.simcal-system-status-report-panel thead th{font-size:14px;vertical-align:top}.simcal-system-status-report-panel tbody .tooltip{text-align:center;width:20px}.simcal-system-status-report-panel tbody .label{width:30%}.simcal-system-status-report-panel tbody tr:nth-child(odd) td{background-color:rgba(0,0,0,.02)}.simcal-system-status-report-panel dl{margin:0;padding:0}.simcal-system-status-report-panel dt{float:left;font-style:italic;margin:0 4px 0 0}.simcal-system-status-report-panel dd{margin:0}.simcal-system-status-report-panel mark{background-color:transparent;font-weight:700}.simcal-system-status-report-panel mark.ok{color:green}#simcal-reset-licenses,.simcal-system-status-report-panel mark.error{color:red}.ui-datepicker{left:-9999px;position:absolute}#simcal-clear-cache{float:right;margin:0 10px 10px}#simcal-get-shortcode .inside{padding:5px 15px 10px;text-align:center}#simcal-get-shortcode input,#simcal-newsletter input{width:100%}#simcal-newsletter{background-color:#fcf8e3}#simcal-calendar-settings{display:none}#simcal-calendar-settings .hndle{line-height:2;padding:10px}#simcal-calendar-settings .inside{margin:0;padding:0}#simcal-calendar-settings .select2-container{border-radius:0;max-width:500px}#simcal-calendar-settings .select2-search__field{border:0!important;box-shadow:none!important;margin:0}#simcal-calendar-settings .select2-search__field:focus{border:0!important;box-shadow:none!important}#simcal-calendar-settings .select2-selection{border:1px solid #ddd;border-radius:0}#simcal-calendar-settings .select2-container--open .select2-selection{border-color:#5b9dd9;box-shadow:0 0 2px rgba(30,140,190,.8)}#simcal-calendar-settings .select2-selection__choice{margin-bottom:0}#simcal-calendar-settings .wp-picker-container{vertical-align:inherit}.simcal-box-handle{display:inline-block;line-height:1;margin-left:8px}.simcal-box-handle:before{content:'\2014';display:inline-block;font-weight:400}.simcal-box-handle label{font-size:12px;font-weight:400;margin-right:10px;vertical-align:baseline}.simcal-box-handle select{font-weight:700;margin:-3px 0 0 .5em;vertical-align:middle}.simcal-tabs{background:#fafafa;border-right:1px solid #eee;box-sizing:border-box;float:left;line-height:1em;margin:0;padding:0 0 10px;position:relative;width:20%}.simcal-tabs a{border-bottom:1px solid #eee;display:block;line-height:20px!important;margin:0;padding:10px}.simcal-tabs a:focus{box-shadow:none}.simcal-tabs li{display:block;margin:0;padding:0}.simcal-tabs li.active a{background-color:#eee;color:#555;position:relative}.simcal-tabs:after{background-color:#fafafa;border-right:1px solid #eee;bottom:-9999em;content:"";display:block;height:9999em;left:0;position:absolute;width:100%}.simcal-panels-wrap{background:#fff;overflow:hidden}.simcal-panel{margin-left:20%;max-width:80%}.simcal-panel>table{padding-bottom:11px;width:100%}.simcal-panel>table thead th{border-bottom:1px solid #eee;font-size:14px;font-weight:700;padding:12px 0 15px 10px;text-align:left}.simcal-panel>table>tbody tr:first-child td,.simcal-panel>table>tbody tr:first-child th{padding-top:14px}.simcal-panel>table>tbody tr:last-child td,.simcal-panel>table>tbody tr:last-child th{border-bottom:1px solid #eee;padding-bottom:14px}.simcal-panel>table>tbody:last-of-type tr:last-child td,.simcal-panel>table>tbody:last-of-type tr:last-child th{border-bottom:0}.simcal-panel-field>td{width:82%}.simcal-panel-field>th{font-weight:400;min-width:100px;width:15%}.simcal-panel-field>td,.simcal-panel-field>th{padding:9px 3% 9px 10px;text-align:left;vertical-align:text-top}.simcal-panel-field .simcal-field-text{max-width:500px;width:90%}@media screen and (max-width:1023px){.simcal-box-handle{display:block;line-height:2;margin:16px 0 0}.simcal-box-handle:before{display:none}.simcal-box-handle label{display:table;margin-bottom:16px;width:100%}.simcal-box-handle label>span{display:table-cell;width:20%}.simcal-box-handle label>select{display:table-cell;width:80%}.simcal-box-handle .simcal-tabs{width:16%}.simcal-box-handle .simcal-tabs i{font-size:18px;line-height:1}.simcal-box-handle .simcal-tabs span{display:none}.simcal-box-handle .simcal-panel{margin-left:16%;max-width:84%}.simcal-box-handle .simcal-panel-section{display:block;overflow:hidden}.simcal-box-handle .simcal-panel-field th{display:block;width:100%}.simcal-box-handle .simcal-panel-field td{display:inline-block;width:100%}.simcal-box-handle .simcal-panel-field select{max-width:86%}}input.simcal-shortcode{border:1px dashed rgba(0,0,0,.3);color:rgba(0,0,0,.58);font-family:monospace;font-weight:700;text-align:center}
assets/css/default-calendar-grid.css CHANGED
@@ -23,32 +23,20 @@
23
  -moz-osx-font-smoothing: grayscale; }
24
 
25
  .simcal-icon-spin {
26
- -webkit-animation: spin 2s infinite linear;
27
  animation: spin 2s infinite linear;
28
  display: inline-block; }
29
 
30
- @-webkit-keyframes spin {
31
- 0% {
32
- -webkit-transform: rotate(0deg);
33
- transform: rotate(0deg); }
34
- 100% {
35
- -webkit-transform: rotate(359deg);
36
- transform: rotate(359deg); } }
37
-
38
  @keyframes spin {
39
  0% {
40
- -webkit-transform: rotate(0deg);
41
  transform: rotate(0deg); }
42
  100% {
43
- -webkit-transform: rotate(359deg);
44
  transform: rotate(359deg); } }
45
 
46
  .simcal-icon-animate:before {
47
  transition: all .2s ease-in-out; }
48
 
49
  .simcal-icon-rotate-180:before {
50
- -webkit-transform: rotate(180deg);
51
- transform: rotate(180deg); }
52
 
53
  .simcal-icon-calendar-empty:before {
54
  content: '\e800'; }
23
  -moz-osx-font-smoothing: grayscale; }
24
 
25
  .simcal-icon-spin {
 
26
  animation: spin 2s infinite linear;
27
  display: inline-block; }
28
 
 
 
 
 
 
 
 
 
29
  @keyframes spin {
30
  0% {
 
31
  transform: rotate(0deg); }
32
  100% {
 
33
  transform: rotate(359deg); } }
34
 
35
  .simcal-icon-animate:before {
36
  transition: all .2s ease-in-out; }
37
 
38
  .simcal-icon-rotate-180:before {
39
+ transform: rotate(180deg); }
 
40
 
41
  .simcal-icon-calendar-empty:before {
42
  content: '\e800'; }
assets/css/default-calendar-grid.min.css CHANGED
@@ -1,6 +1,6 @@
1
- /*! Simple Calendar - 3.1.1
2
  * https://simplecalendar.io
3
  * Copyright (c) Moonstone Media 2016
4
  * Licensed GPLv2+ */
5
 
6
- .simcal-default-calendar .simcal-nav-button,.simcal-default-calendar .simcal-nav-button:focus,.simcal-default-calendar .simcal-nav-button:hover{background:0 0;border:0;box-shadow:none;outline:0}@font-face{font-family:simple-calendar;src:url(../fonts/simple-calendar.eot?43976014);src:url(../fonts/simple-calendar.eot?43976014#iefix) format("embedded-opentype"),url(../fonts/simple-calendar.woff?43976014) format("woff"),url(../fonts/simple-calendar.ttf?43976014) format("truetype"),url(../fonts/simple-calendar.svg?43976014#simple-calendar) format("svg");font-weight:400;font-style:normal}[class*=" simcal-icon-"]:before,[class^=simcal-icon-]:before{display:inline-block;font-family:simple-calendar;font-style:normal;font-weight:400;margin-right:.2em;speak:none;text-decoration:inherit;text-align:center;width:1em;font-variant:normal;text-transform:none;margin-left:.2em;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}.simcal-icon-spin{-webkit-animation:spin 2s infinite linear;animation:spin 2s infinite linear;display:inline-block}@-webkit-keyframes spin{0%{-webkit-transform:rotate(0);transform:rotate(0)}100%{-webkit-transform:rotate(359deg);transform:rotate(359deg)}}@keyframes spin{0%{-webkit-transform:rotate(0);transform:rotate(0)}100%{-webkit-transform:rotate(359deg);transform:rotate(359deg)}}.simcal-icon-animate:before{transition:all .2s ease-in-out}.simcal-icon-rotate-180:before{-webkit-transform:rotate(180deg);transform:rotate(180deg)}.simcal-icon-calendar-empty:before{content:'\e800'}.simcal-icon-calendar:before{content:'\e801'}.simcal-icon-calendar-logo:before{content:'\e802'}.simcal-icon-settings:before{content:'\e804'}.simcal-icon-toggles:before{content:'\e805'}.simcal-icon-list:before{content:'\e806'}.simcal-icon-event:before{content:'\e807'}.simcal-icon-help:before{content:'\e808'}.simcal-icon-panel:before{content:'\e80a'}.simcal-icon-grid:before{content:'\e80b'}.simcal-icon-google:before{content:'\e80c'}.simcal-icon-docs:before{content:'\e80f'}.simcal-icon-hourglass:before{content:'\e811'}.simcal-icon-globe:before{content:'\e812'}.simcal-icon-timezones:before{content:'\e813'}.simcal-icon-warning:before{content:'\e815'}.simcal-icon-wordpress:before{content:'\e814'}.simcal-icon-up:before{content:'\e80e'}.simcal-icon-right:before{content:'\e809'}.simcal-icon-down:before{content:'\e80d'}.simcal-icon-left:before{content:'\e803'}.simcal-icon-spinner:before{content:'\e810'}.simcal-calendar{position:relative}.simcal-powered{display:block;margin:-10px 0 20px}.simcal-align-left{text-align:left}.simcal-align-right{text-align:right}.simcal-default-calendar .simcal-current h3{margin:0;padding:0}.simcal-default-calendar .simcal-nav{vertical-align:middle}.simcal-default-calendar .simcal-nav-button{cursor:pointer;margin:0;padding:0;transition:margin .2s ease-out;width:100%}.simcal-default-calendar .simcal-nav-button.simcal-prev:hover{margin-left:-10px}.simcal-default-calendar .simcal-nav-button.simcal-next:hover{margin-right:-10px}.simcal-default-calendar .simcal-nav-button:disabled:hover,.simcal-default-calendar ul.simcal-attachments,.simcal-default-calendar ul.simcal-attendees{margin:0;padding:0}.simcal-default-calendar .simcal-nav-button:disabled{cursor:default}.simcal-default-calendar .simcal-events{list-style:none;margin-left:0}.simcal-default-calendar .simcal-events-toggle{border:0;box-shadow:none;text-align:center;width:100%}.simcal-default-calendar .simcal-events-toggle:active,.simcal-default-calendar .simcal-events-toggle:focus,.simcal-default-calendar .simcal-events-toggle:hover{border:0;box-shadow:none;outline:0}.simcal-default-calendar li.simcal-attachment,.simcal-default-calendar li.simcal-attendee{list-style:none;margin-bottom:4px}.simcal-default-calendar li.simcal-attachment:last-child,.simcal-default-calendar li.simcal-attendee:last-child{margin-bottom:0}.simcal-default-calendar li.simcal-attachment small,.simcal-default-calendar li.simcal-attendee small{opacity:.9;text-transform:lowercase}.simcal-default-calendar .simcal-organizer a,.simcal-default-calendar li.simcal-attachment a,.simcal-default-calendar li.simcal-attendee a{border-bottom:0;text-decoration:none}.simcal-default-calendar .simcal-organizer img,.simcal-default-calendar li.simcal-attachment img,.simcal-default-calendar li.simcal-attendee img{display:inline-block;margin:0 4px;max-height:24px;max-width:24px}.simcal-default-calendar .simcal-tooltip-content{font-size:1.2em;line-height:1.4;padding:5px}.simcal-default-calendar .simcal-ajax-loader{height:100%;left:0;position:absolute;top:0;width:100%}.simcal-default-calendar .simcal-ajax-loader>i{font-size:48px;left:50%;line-height:1;margin:-36px 0 0 -36px;position:absolute;top:50%}.simcal-default-calendar .simcal-ajax-loader.simcal-spinner-top>i{top:20%}.simcal-default-calendar .simcal-ajax-loader.simcal-spinner-bottom>i{bottom:20%;top:auto}.simcal-default-calendar-light .simcal-nav-button{color:rgba(0,0,0,.6)}.simcal-default-calendar-light .simcal-nav-button:disabled,.simcal-default-calendar-light .simcal-nav-button:disabled:hover{color:rgba(255,255,255,.9)!important}.simcal-default-calendar-light .simcal-nav-button:focus,.simcal-default-calendar-light .simcal-nav-button:hover{color:rgba(0,0,0,.9)}.simcal-default-calendar-light .simcal-events-toggle{color:rgba(0,0,0,.6)}.simcal-default-calendar-light .simcal-events-toggle:hover{background-color:rgba(0,0,0,.1);color:#fff}.simcal-default-calendar-light .simcal-ajax-loader{background-color:rgba(0,0,0,.1)}.simcal-default-calendar-light .simcal-ajax-loader>i{color:rgba(0,0,0,.3)}.simcal-default-calendar-dark .simcal-nav-button{color:rgba(255,255,255,.6)}.simcal-default-calendar-dark .simcal-nav-button:disabled,.simcal-default-calendar-dark .simcal-nav-button:disabled:hover{color:rgba(0,0,0,.9)!important}.simcal-default-calendar-dark .simcal-nav-button:focus,.simcal-default-calendar-dark .simcal-nav-button:hover{color:rgba(255,255,255,.9)}.simcal-default-calendar-dark .simcal-events-toggle{color:rgba(255,255,255,.6)}.simcal-default-calendar-dark .simcal-events-toggle:hover{background-color:rgba(255,255,255,.1);color:#000}.simcal-default-calendar-dark .simcal-ajax-loader{background-color:rgba(255,255,255,.1)}.simcal-default-calendar-dark .simcal-ajax-loader>i{color:rgba(255,255,255,.3)}.simcal-default-calendar-grid>table{table-layout:fixed;width:100%}.simcal-default-calendar-grid>table tbody td,.simcal-default-calendar-grid>table thead th{text-align:center;vertical-align:top}.simcal-default-calendar-grid>table tbody td{padding:0!important}.simcal-default-calendar-grid .simcal-calendar-head .simcal-nav{padding:10px 0;vertical-align:middle}.simcal-default-calendar-grid .simcal-calendar-head .simcal-nav.simcal-current,.simcal-default-calendar-grid .simcal-calendar-head .simcal-nav.simcal-prev-wrapper{border-right:0}.simcal-default-calendar-grid .simcal-day>div{box-sizing:content-box;display:block;height:100%}.simcal-default-calendar-grid .simcal-day-void{border-width:0 0 1px;height:100%;min-height:32px}.simcal-default-calendar-grid .simcal-day-void.simcal-day-void-last{border-right-width:1px}.simcal-default-calendar-grid .simcal-day-number{display:block;line-height:1;padding:2px 4px 3px;vertical-align:middle}.simcal-default-calendar-grid .simcal-no-events{display:block;min-height:32px}.simcal-default-calendar-grid.simcal-default-calendar-light .simcal-day:hover{background-color:rgba(0,0,0,.1)}.simcal-default-calendar-grid.simcal-default-calendar-light .simcal-day-void,.simcal-default-calendar-grid.simcal-default-calendar-light .simcal-day-void:hover{background-color:rgba(0,0,0,.04)}.simcal-default-calendar-grid.simcal-default-calendar-light .simcal-day-number{background:rgba(0,0,0,.1)}.simcal-default-calendar-grid.simcal-default-calendar-dark .simcal-day:hover{background-color:rgba(255,255,255,.18)}.simcal-default-calendar-grid.simcal-default-calendar-dark .simcal-day-void,.simcal-default-calendar-grid.simcal-default-calendar-dark .simcal-day-void:hover{background-color:rgba(255,255,255,.05)}.simcal-default-calendar-grid.simcal-default-calendar-dark .simcal-day-number{background:rgba(255,255,255,.1)}.simcal-default-calendar-grid .simcal-events{font-size:.68em;line-height:1.4;list-style:none;margin:0;padding:0;text-align:left}.simcal-default-calendar-grid .simcal-events>.simcal-event{border-bottom-style:solid;border-bottom-width:1px;cursor:pointer;list-style:none;margin:0 0 2px;padding:4px}.simcal-default-calendar-grid .simcal-events>.simcal-event:hover{text-decoration:underline}.simcal-default-calendar-grid .simcal-events>.simcal-event:last-child{border-bottom:0;margin-bottom:0}.simcal-default-calendar-grid.simcal-default-calendar-light .simcal-event{border-bottom-color:rgba(0,0,0,.1)}.simcal-default-calendar-grid.simcal-default-calendar-dark .simcal-event{border-bottom-color:rgba(255,255,255,.1)}.simcal-default-calendar-grid .simcal-events-dots{cursor:pointer;display:block;line-height:.7;margin:3px 0;text-align:center}.simcal-default-calendar-grid .simcal-events-toggle{background:0 0;display:block;font-size:10px;padding:2px 0}.simcal-event-bubble{background-color:#fff;border:1px solid rgba(0,0,0,.1);box-shadow:0 1px 2px rgba(0,0,0,.1)}.simcal-event-bubble .simcal-event-details .simcal-event-description,.simcal-event-bubble .simcal-event-details p{margin:0 0 1em}
1
+ /*! Simple Calendar - 3.1.2
2
  * https://simplecalendar.io
3
  * Copyright (c) Moonstone Media 2016
4
  * Licensed GPLv2+ */
5
 
6
+ .simcal-default-calendar .simcal-nav-button,.simcal-default-calendar .simcal-nav-button:focus,.simcal-default-calendar .simcal-nav-button:hover{background:0 0;border:0;box-shadow:none;outline:0}@font-face{font-family:simple-calendar;src:url(../fonts/simple-calendar.eot?43976014);src:url(../fonts/simple-calendar.eot?43976014#iefix) format("embedded-opentype"),url(../fonts/simple-calendar.woff?43976014) format("woff"),url(../fonts/simple-calendar.ttf?43976014) format("truetype"),url(../fonts/simple-calendar.svg?43976014#simple-calendar) format("svg");font-weight:400;font-style:normal}[class*=" simcal-icon-"]:before,[class^=simcal-icon-]:before{display:inline-block;font-family:simple-calendar;font-style:normal;font-weight:400;margin-right:.2em;speak:none;text-decoration:inherit;text-align:center;width:1em;font-variant:normal;text-transform:none;margin-left:.2em;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}.simcal-icon-spin{animation:spin 2s infinite linear;display:inline-block}@keyframes spin{0%{transform:rotate(0)}100%{transform:rotate(359deg)}}.simcal-icon-animate:before{transition:all .2s ease-in-out}.simcal-icon-rotate-180:before{transform:rotate(180deg)}.simcal-icon-calendar-empty:before{content:'\e800'}.simcal-icon-calendar:before{content:'\e801'}.simcal-icon-calendar-logo:before{content:'\e802'}.simcal-icon-settings:before{content:'\e804'}.simcal-icon-toggles:before{content:'\e805'}.simcal-icon-list:before{content:'\e806'}.simcal-icon-event:before{content:'\e807'}.simcal-icon-help:before{content:'\e808'}.simcal-icon-panel:before{content:'\e80a'}.simcal-icon-grid:before{content:'\e80b'}.simcal-icon-google:before{content:'\e80c'}.simcal-icon-docs:before{content:'\e80f'}.simcal-icon-hourglass:before{content:'\e811'}.simcal-icon-globe:before{content:'\e812'}.simcal-icon-timezones:before{content:'\e813'}.simcal-icon-warning:before{content:'\e815'}.simcal-icon-wordpress:before{content:'\e814'}.simcal-icon-up:before{content:'\e80e'}.simcal-icon-right:before{content:'\e809'}.simcal-icon-down:before{content:'\e80d'}.simcal-icon-left:before{content:'\e803'}.simcal-icon-spinner:before{content:'\e810'}.simcal-calendar{position:relative}.simcal-powered{display:block;margin:-10px 0 20px}.simcal-align-left{text-align:left}.simcal-align-right{text-align:right}.simcal-default-calendar .simcal-current h3{margin:0;padding:0}.simcal-default-calendar .simcal-nav{vertical-align:middle}.simcal-default-calendar .simcal-nav-button{cursor:pointer;margin:0;padding:0;transition:margin .2s ease-out;width:100%}.simcal-default-calendar .simcal-nav-button.simcal-prev:hover{margin-left:-10px}.simcal-default-calendar .simcal-nav-button.simcal-next:hover{margin-right:-10px}.simcal-default-calendar .simcal-nav-button:disabled:hover,.simcal-default-calendar ul.simcal-attachments,.simcal-default-calendar ul.simcal-attendees{margin:0;padding:0}.simcal-default-calendar .simcal-nav-button:disabled{cursor:default}.simcal-default-calendar .simcal-events{list-style:none;margin-left:0}.simcal-default-calendar .simcal-events-toggle{border:0;box-shadow:none;text-align:center;width:100%}.simcal-default-calendar .simcal-events-toggle:active,.simcal-default-calendar .simcal-events-toggle:focus,.simcal-default-calendar .simcal-events-toggle:hover{border:0;box-shadow:none;outline:0}.simcal-default-calendar li.simcal-attachment,.simcal-default-calendar li.simcal-attendee{list-style:none;margin-bottom:4px}.simcal-default-calendar li.simcal-attachment:last-child,.simcal-default-calendar li.simcal-attendee:last-child{margin-bottom:0}.simcal-default-calendar li.simcal-attachment small,.simcal-default-calendar li.simcal-attendee small{opacity:.9;text-transform:lowercase}.simcal-default-calendar .simcal-organizer a,.simcal-default-calendar li.simcal-attachment a,.simcal-default-calendar li.simcal-attendee a{border-bottom:0;text-decoration:none}.simcal-default-calendar .simcal-organizer img,.simcal-default-calendar li.simcal-attachment img,.simcal-default-calendar li.simcal-attendee img{display:inline-block;margin:0 4px;max-height:24px;max-width:24px}.simcal-default-calendar .simcal-tooltip-content{font-size:1.2em;line-height:1.4;padding:5px}.simcal-default-calendar .simcal-ajax-loader{height:100%;left:0;position:absolute;top:0;width:100%}.simcal-default-calendar .simcal-ajax-loader>i{font-size:48px;left:50%;line-height:1;margin:-36px 0 0 -36px;position:absolute;top:50%}.simcal-default-calendar .simcal-ajax-loader.simcal-spinner-top>i{top:20%}.simcal-default-calendar .simcal-ajax-loader.simcal-spinner-bottom>i{bottom:20%;top:auto}.simcal-default-calendar-light .simcal-nav-button{color:rgba(0,0,0,.6)}.simcal-default-calendar-light .simcal-nav-button:disabled,.simcal-default-calendar-light .simcal-nav-button:disabled:hover{color:rgba(255,255,255,.9)!important}.simcal-default-calendar-light .simcal-nav-button:focus,.simcal-default-calendar-light .simcal-nav-button:hover{color:rgba(0,0,0,.9)}.simcal-default-calendar-light .simcal-events-toggle{color:rgba(0,0,0,.6)}.simcal-default-calendar-light .simcal-events-toggle:hover{background-color:rgba(0,0,0,.1);color:#fff}.simcal-default-calendar-light .simcal-ajax-loader{background-color:rgba(0,0,0,.1)}.simcal-default-calendar-light .simcal-ajax-loader>i{color:rgba(0,0,0,.3)}.simcal-default-calendar-dark .simcal-nav-button{color:rgba(255,255,255,.6)}.simcal-default-calendar-dark .simcal-nav-button:disabled,.simcal-default-calendar-dark .simcal-nav-button:disabled:hover{color:rgba(0,0,0,.9)!important}.simcal-default-calendar-dark .simcal-nav-button:focus,.simcal-default-calendar-dark .simcal-nav-button:hover{color:rgba(255,255,255,.9)}.simcal-default-calendar-dark .simcal-events-toggle{color:rgba(255,255,255,.6)}.simcal-default-calendar-dark .simcal-events-toggle:hover{background-color:rgba(255,255,255,.1);color:#000}.simcal-default-calendar-dark .simcal-ajax-loader{background-color:rgba(255,255,255,.1)}.simcal-default-calendar-dark .simcal-ajax-loader>i{color:rgba(255,255,255,.3)}.simcal-default-calendar-grid>table{table-layout:fixed;width:100%}.simcal-default-calendar-grid>table tbody td,.simcal-default-calendar-grid>table thead th{text-align:center;vertical-align:top}.simcal-default-calendar-grid>table tbody td{padding:0!important}.simcal-default-calendar-grid .simcal-calendar-head .simcal-nav{padding:10px 0;vertical-align:middle}.simcal-default-calendar-grid .simcal-calendar-head .simcal-nav.simcal-current,.simcal-default-calendar-grid .simcal-calendar-head .simcal-nav.simcal-prev-wrapper{border-right:0}.simcal-default-calendar-grid .simcal-day>div{box-sizing:content-box;display:block;height:100%}.simcal-default-calendar-grid .simcal-day-void{border-width:0 0 1px;height:100%;min-height:32px}.simcal-default-calendar-grid .simcal-day-void.simcal-day-void-last{border-right-width:1px}.simcal-default-calendar-grid .simcal-day-number{display:block;line-height:1;padding:2px 4px 3px;vertical-align:middle}.simcal-default-calendar-grid .simcal-no-events{display:block;min-height:32px}.simcal-default-calendar-grid.simcal-default-calendar-light .simcal-day:hover{background-color:rgba(0,0,0,.1)}.simcal-default-calendar-grid.simcal-default-calendar-light .simcal-day-void,.simcal-default-calendar-grid.simcal-default-calendar-light .simcal-day-void:hover{background-color:rgba(0,0,0,.04)}.simcal-default-calendar-grid.simcal-default-calendar-light .simcal-day-number{background:rgba(0,0,0,.1)}.simcal-default-calendar-grid.simcal-default-calendar-dark .simcal-day:hover{background-color:rgba(255,255,255,.18)}.simcal-default-calendar-grid.simcal-default-calendar-dark .simcal-day-void,.simcal-default-calendar-grid.simcal-default-calendar-dark .simcal-day-void:hover{background-color:rgba(255,255,255,.05)}.simcal-default-calendar-grid.simcal-default-calendar-dark .simcal-day-number{background:rgba(255,255,255,.1)}.simcal-default-calendar-grid .simcal-events{font-size:.68em;line-height:1.4;list-style:none;margin:0;padding:0;text-align:left}.simcal-default-calendar-grid .simcal-events>.simcal-event{border-bottom-style:solid;border-bottom-width:1px;cursor:pointer;list-style:none;margin:0 0 2px;padding:4px}.simcal-default-calendar-grid .simcal-events>.simcal-event:hover{text-decoration:underline}.simcal-default-calendar-grid .simcal-events>.simcal-event:last-child{border-bottom:0;margin-bottom:0}.simcal-default-calendar-grid.simcal-default-calendar-light .simcal-event{border-bottom-color:rgba(0,0,0,.1)}.simcal-default-calendar-grid.simcal-default-calendar-dark .simcal-event{border-bottom-color:rgba(255,255,255,.1)}.simcal-default-calendar-grid .simcal-events-dots{cursor:pointer;display:block;line-height:.7;margin:3px 0;text-align:center}.simcal-default-calendar-grid .simcal-events-toggle{background:0 0;display:block;font-size:10px;padding:2px 0}.simcal-event-bubble{background-color:#fff;border:1px solid rgba(0,0,0,.1);box-shadow:0 1px 2px rgba(0,0,0,.1)}.simcal-event-bubble .simcal-event-details .simcal-event-description,.simcal-event-bubble .simcal-event-details p{margin:0 0 1em}
assets/css/default-calendar-list.css CHANGED
@@ -23,32 +23,20 @@
23
  -moz-osx-font-smoothing: grayscale; }
24
 
25
  .simcal-icon-spin {
26
- -webkit-animation: spin 2s infinite linear;
27
  animation: spin 2s infinite linear;
28
  display: inline-block; }
29
 
30
- @-webkit-keyframes spin {
31
- 0% {
32
- -webkit-transform: rotate(0deg);
33
- transform: rotate(0deg); }
34
- 100% {
35
- -webkit-transform: rotate(359deg);
36
- transform: rotate(359deg); } }
37
-
38
  @keyframes spin {
39
  0% {
40
- -webkit-transform: rotate(0deg);
41
  transform: rotate(0deg); }
42
  100% {
43
- -webkit-transform: rotate(359deg);
44
  transform: rotate(359deg); } }
45
 
46
  .simcal-icon-animate:before {
47
  transition: all .2s ease-in-out; }
48
 
49
  .simcal-icon-rotate-180:before {
50
- -webkit-transform: rotate(180deg);
51
- transform: rotate(180deg); }
52
 
53
  .simcal-icon-calendar-empty:before {
54
  content: '\e800'; }
23
  -moz-osx-font-smoothing: grayscale; }
24
 
25
  .simcal-icon-spin {
 
26
  animation: spin 2s infinite linear;
27
  display: inline-block; }
28
 
 
 
 
 
 
 
 
 
29
  @keyframes spin {
30
  0% {
 
31
  transform: rotate(0deg); }
32
  100% {
 
33
  transform: rotate(359deg); } }
34
 
35
  .simcal-icon-animate:before {
36
  transition: all .2s ease-in-out; }
37
 
38
  .simcal-icon-rotate-180:before {
39
+ transform: rotate(180deg); }
 
40
 
41
  .simcal-icon-calendar-empty:before {
42
  content: '\e800'; }
assets/css/default-calendar-list.min.css CHANGED
@@ -1,6 +1,6 @@
1
- /*! Simple Calendar - 3.1.1
2
  * https://simplecalendar.io
3
  * Copyright (c) Moonstone Media 2016
4
  * Licensed GPLv2+ */
5
 
6
- .simcal-default-calendar .simcal-nav-button,.simcal-default-calendar .simcal-nav-button:focus,.simcal-default-calendar .simcal-nav-button:hover{background:0 0;border:0;box-shadow:none;outline:0}@font-face{font-family:simple-calendar;src:url(../fonts/simple-calendar.eot?43976014);src:url(../fonts/simple-calendar.eot?43976014#iefix) format("embedded-opentype"),url(../fonts/simple-calendar.woff?43976014) format("woff"),url(../fonts/simple-calendar.ttf?43976014) format("truetype"),url(../fonts/simple-calendar.svg?43976014#simple-calendar) format("svg");font-weight:400;font-style:normal}[class*=" simcal-icon-"]:before,[class^=simcal-icon-]:before{display:inline-block;font-family:simple-calendar;font-style:normal;font-weight:400;margin-right:.2em;speak:none;text-decoration:inherit;text-align:center;width:1em;font-variant:normal;text-transform:none;margin-left:.2em;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}.simcal-icon-spin{-webkit-animation:spin 2s infinite linear;animation:spin 2s infinite linear;display:inline-block}@-webkit-keyframes spin{0%{-webkit-transform:rotate(0);transform:rotate(0)}100%{-webkit-transform:rotate(359deg);transform:rotate(359deg)}}@keyframes spin{0%{-webkit-transform:rotate(0);transform:rotate(0)}100%{-webkit-transform:rotate(359deg);transform:rotate(359deg)}}.simcal-icon-animate:before{transition:all .2s ease-in-out}.simcal-icon-rotate-180:before{-webkit-transform:rotate(180deg);transform:rotate(180deg)}.simcal-icon-calendar-empty:before{content:'\e800'}.simcal-icon-calendar:before{content:'\e801'}.simcal-icon-calendar-logo:before{content:'\e802'}.simcal-icon-settings:before{content:'\e804'}.simcal-icon-toggles:before{content:'\e805'}.simcal-icon-list:before{content:'\e806'}.simcal-icon-event:before{content:'\e807'}.simcal-icon-help:before{content:'\e808'}.simcal-icon-panel:before{content:'\e80a'}.simcal-icon-grid:before{content:'\e80b'}.simcal-icon-google:before{content:'\e80c'}.simcal-icon-docs:before{content:'\e80f'}.simcal-icon-hourglass:before{content:'\e811'}.simcal-icon-globe:before{content:'\e812'}.simcal-icon-timezones:before{content:'\e813'}.simcal-icon-warning:before{content:'\e815'}.simcal-icon-wordpress:before{content:'\e814'}.simcal-icon-up:before{content:'\e80e'}.simcal-icon-right:before{content:'\e809'}.simcal-icon-down:before{content:'\e80d'}.simcal-icon-left:before{content:'\e803'}.simcal-icon-spinner:before{content:'\e810'}.simcal-calendar{position:relative}.simcal-powered{display:block;margin:-10px 0 20px}.simcal-align-left{text-align:left}.simcal-align-right{text-align:right}.simcal-default-calendar .simcal-current h3{margin:0;padding:0}.simcal-default-calendar .simcal-nav{vertical-align:middle}.simcal-default-calendar .simcal-nav-button{cursor:pointer;margin:0;padding:0;transition:margin .2s ease-out;width:100%}.simcal-default-calendar .simcal-nav-button.simcal-prev:hover{margin-left:-10px}.simcal-default-calendar .simcal-nav-button.simcal-next:hover{margin-right:-10px}.simcal-default-calendar .simcal-nav-button:disabled:hover,.simcal-default-calendar ul.simcal-attachments,.simcal-default-calendar ul.simcal-attendees{margin:0;padding:0}.simcal-default-calendar .simcal-nav-button:disabled{cursor:default}.simcal-default-calendar .simcal-events{list-style:none;margin-left:0}.simcal-default-calendar .simcal-events-toggle{border:0;box-shadow:none;text-align:center;width:100%}.simcal-default-calendar .simcal-events-toggle:active,.simcal-default-calendar .simcal-events-toggle:focus,.simcal-default-calendar .simcal-events-toggle:hover{border:0;box-shadow:none;outline:0}.simcal-default-calendar li.simcal-attachment,.simcal-default-calendar li.simcal-attendee{list-style:none;margin-bottom:4px}.simcal-default-calendar li.simcal-attachment:last-child,.simcal-default-calendar li.simcal-attendee:last-child{margin-bottom:0}.simcal-default-calendar li.simcal-attachment small,.simcal-default-calendar li.simcal-attendee small{opacity:.9;text-transform:lowercase}.simcal-default-calendar .simcal-organizer a,.simcal-default-calendar li.simcal-attachment a,.simcal-default-calendar li.simcal-attendee a{border-bottom:0;text-decoration:none}.simcal-default-calendar .simcal-organizer img,.simcal-default-calendar li.simcal-attachment img,.simcal-default-calendar li.simcal-attendee img{display:inline-block;margin:0 4px;max-height:24px;max-width:24px}.simcal-default-calendar .simcal-tooltip-content{font-size:1.2em;line-height:1.4;padding:5px}.simcal-default-calendar .simcal-ajax-loader{height:100%;left:0;position:absolute;top:0;width:100%}.simcal-default-calendar .simcal-ajax-loader>i{font-size:48px;left:50%;line-height:1;margin:-36px 0 0 -36px;position:absolute;top:50%}.simcal-default-calendar .simcal-ajax-loader.simcal-spinner-top>i{top:20%}.simcal-default-calendar .simcal-ajax-loader.simcal-spinner-bottom>i{bottom:20%;top:auto}.simcal-default-calendar-light .simcal-nav-button{color:rgba(0,0,0,.6)}.simcal-default-calendar-light .simcal-nav-button:disabled,.simcal-default-calendar-light .simcal-nav-button:disabled:hover{color:rgba(255,255,255,.9)!important}.simcal-default-calendar-light .simcal-nav-button:focus,.simcal-default-calendar-light .simcal-nav-button:hover{color:rgba(0,0,0,.9)}.simcal-default-calendar-light .simcal-events-toggle{color:rgba(0,0,0,.6)}.simcal-default-calendar-light .simcal-events-toggle:hover{background-color:rgba(0,0,0,.1);color:#fff}.simcal-default-calendar-light .simcal-ajax-loader{background-color:rgba(0,0,0,.1)}.simcal-default-calendar-light .simcal-ajax-loader>i{color:rgba(0,0,0,.3)}.simcal-default-calendar-dark .simcal-nav-button{color:rgba(255,255,255,.6)}.simcal-default-calendar-dark .simcal-nav-button:disabled,.simcal-default-calendar-dark .simcal-nav-button:disabled:hover{color:rgba(0,0,0,.9)!important}.simcal-default-calendar-dark .simcal-nav-button:focus,.simcal-default-calendar-dark .simcal-nav-button:hover{color:rgba(255,255,255,.9)}.simcal-default-calendar-dark .simcal-events-toggle{color:rgba(255,255,255,.6)}.simcal-default-calendar-dark .simcal-events-toggle:hover{background-color:rgba(255,255,255,.1);color:#000}.simcal-default-calendar-dark .simcal-ajax-loader{background-color:rgba(255,255,255,.1)}.simcal-default-calendar-dark .simcal-ajax-loader>i{color:rgba(255,255,255,.3)}.simcal-default-calendar-list{min-height:100px;padding:10px 0;text-align:left}.simcal-default-calendar-list .simcal-calendar-head{display:table;padding-bottom:10px;width:100%}.simcal-default-calendar-list .simcal-calendar-head .simcal-nav{display:table-cell;text-align:center;vertical-align:middle;width:20%}.simcal-default-calendar-list .simcal-calendar-head .simcal-nav:nth-child(2){width:60%}.simcal-default-calendar-list .simcal-calendar-head .simcal-current span{display:inline-block}.simcal-default-calendar-list .simcal-calendar-head .simcal-hide-header{visibility:hidden}.simcal-default-calendar-list dl.simcal-month{margin-bottom:10px;padding:0 10px 10px}.simcal-default-calendar-list dd.simcal-day{list-style:none;margin:0}.simcal-default-calendar-list dt.simcal-day-label{font-size:.9em;list-style:none;margin:20px 0 10px}.simcal-default-calendar-list dt.simcal-day-label>span{display:inline-block;padding:4px 8px}.simcal-default-calendar-list ul.simcal-events{margin:10px 14px 0}.simcal-default-calendar-list ul.simcal-events li.simcal-event{list-style-type:none;margin-bottom:10px;word-wrap:break-word}.simcal-default-calendar-list .simcal-event-details{font-size:.84em;line-height:1.5;overflow:hidden}.simcal-default-calendar-list .simcal-event-details .simcal-event-description,.simcal-default-calendar-list .simcal-event-details p{margin:0 0 1em}.simcal-default-calendar-list .simcal-events-toggle{display:inline-block;padding:0}.simcal-default-calendar-list.simcal-default-calendar-light .simcal-events-toggle{background-color:rgba(0,0,0,.1)}.simcal-default-calendar-list.simcal-default-calendar-dark .simcal-events-toggle{background-color:rgba(255,255,255,.1)}.simcal-default-calendar-list .simcal-calendar-list-compact .simcal-calendar-head .simcal-nav h3{font-size:1em}
1
+ /*! Simple Calendar - 3.1.2
2
  * https://simplecalendar.io
3
  * Copyright (c) Moonstone Media 2016
4
  * Licensed GPLv2+ */
5
 
6
+ .simcal-default-calendar .simcal-nav-button,.simcal-default-calendar .simcal-nav-button:focus,.simcal-default-calendar .simcal-nav-button:hover{background:0 0;border:0;box-shadow:none;outline:0}@font-face{font-family:simple-calendar;src:url(../fonts/simple-calendar.eot?43976014);src:url(../fonts/simple-calendar.eot?43976014#iefix) format("embedded-opentype"),url(../fonts/simple-calendar.woff?43976014) format("woff"),url(../fonts/simple-calendar.ttf?43976014) format("truetype"),url(../fonts/simple-calendar.svg?43976014#simple-calendar) format("svg");font-weight:400;font-style:normal}[class*=" simcal-icon-"]:before,[class^=simcal-icon-]:before{display:inline-block;font-family:simple-calendar;font-style:normal;font-weight:400;margin-right:.2em;speak:none;text-decoration:inherit;text-align:center;width:1em;font-variant:normal;text-transform:none;margin-left:.2em;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}.simcal-icon-spin{animation:spin 2s infinite linear;display:inline-block}@keyframes spin{0%{transform:rotate(0)}100%{transform:rotate(359deg)}}.simcal-icon-animate:before{transition:all .2s ease-in-out}.simcal-icon-rotate-180:before{transform:rotate(180deg)}.simcal-icon-calendar-empty:before{content:'\e800'}.simcal-icon-calendar:before{content:'\e801'}.simcal-icon-calendar-logo:before{content:'\e802'}.simcal-icon-settings:before{content:'\e804'}.simcal-icon-toggles:before{content:'\e805'}.simcal-icon-list:before{content:'\e806'}.simcal-icon-event:before{content:'\e807'}.simcal-icon-help:before{content:'\e808'}.simcal-icon-panel:before{content:'\e80a'}.simcal-icon-grid:before{content:'\e80b'}.simcal-icon-google:before{content:'\e80c'}.simcal-icon-docs:before{content:'\e80f'}.simcal-icon-hourglass:before{content:'\e811'}.simcal-icon-globe:before{content:'\e812'}.simcal-icon-timezones:before{content:'\e813'}.simcal-icon-warning:before{content:'\e815'}.simcal-icon-wordpress:before{content:'\e814'}.simcal-icon-up:before{content:'\e80e'}.simcal-icon-right:before{content:'\e809'}.simcal-icon-down:before{content:'\e80d'}.simcal-icon-left:before{content:'\e803'}.simcal-icon-spinner:before{content:'\e810'}.simcal-calendar{position:relative}.simcal-powered{display:block;margin:-10px 0 20px}.simcal-align-left{text-align:left}.simcal-align-right{text-align:right}.simcal-default-calendar .simcal-current h3{margin:0;padding:0}.simcal-default-calendar .simcal-nav{vertical-align:middle}.simcal-default-calendar .simcal-nav-button{cursor:pointer;margin:0;padding:0;transition:margin .2s ease-out;width:100%}.simcal-default-calendar .simcal-nav-button.simcal-prev:hover{margin-left:-10px}.simcal-default-calendar .simcal-nav-button.simcal-next:hover{margin-right:-10px}.simcal-default-calendar .simcal-nav-button:disabled:hover,.simcal-default-calendar ul.simcal-attachments,.simcal-default-calendar ul.simcal-attendees{margin:0;padding:0}.simcal-default-calendar .simcal-nav-button:disabled{cursor:default}.simcal-default-calendar .simcal-events{list-style:none;margin-left:0}.simcal-default-calendar .simcal-events-toggle{border:0;box-shadow:none;text-align:center;width:100%}.simcal-default-calendar .simcal-events-toggle:active,.simcal-default-calendar .simcal-events-toggle:focus,.simcal-default-calendar .simcal-events-toggle:hover{border:0;box-shadow:none;outline:0}.simcal-default-calendar li.simcal-attachment,.simcal-default-calendar li.simcal-attendee{list-style:none;margin-bottom:4px}.simcal-default-calendar li.simcal-attachment:last-child,.simcal-default-calendar li.simcal-attendee:last-child{margin-bottom:0}.simcal-default-calendar li.simcal-attachment small,.simcal-default-calendar li.simcal-attendee small{opacity:.9;text-transform:lowercase}.simcal-default-calendar .simcal-organizer a,.simcal-default-calendar li.simcal-attachment a,.simcal-default-calendar li.simcal-attendee a{border-bottom:0;text-decoration:none}.simcal-default-calendar .simcal-organizer img,.simcal-default-calendar li.simcal-attachment img,.simcal-default-calendar li.simcal-attendee img{display:inline-block;margin:0 4px;max-height:24px;max-width:24px}.simcal-default-calendar .simcal-tooltip-content{font-size:1.2em;line-height:1.4;padding:5px}.simcal-default-calendar .simcal-ajax-loader{height:100%;left:0;position:absolute;top:0;width:100%}.simcal-default-calendar .simcal-ajax-loader>i{font-size:48px;left:50%;line-height:1;margin:-36px 0 0 -36px;position:absolute;top:50%}.simcal-default-calendar .simcal-ajax-loader.simcal-spinner-top>i{top:20%}.simcal-default-calendar .simcal-ajax-loader.simcal-spinner-bottom>i{bottom:20%;top:auto}.simcal-default-calendar-light .simcal-nav-button{color:rgba(0,0,0,.6)}.simcal-default-calendar-light .simcal-nav-button:disabled,.simcal-default-calendar-light .simcal-nav-button:disabled:hover{color:rgba(255,255,255,.9)!important}.simcal-default-calendar-light .simcal-nav-button:focus,.simcal-default-calendar-light .simcal-nav-button:hover{color:rgba(0,0,0,.9)}.simcal-default-calendar-light .simcal-events-toggle{color:rgba(0,0,0,.6)}.simcal-default-calendar-light .simcal-events-toggle:hover{background-color:rgba(0,0,0,.1);color:#fff}.simcal-default-calendar-light .simcal-ajax-loader{background-color:rgba(0,0,0,.1)}.simcal-default-calendar-light .simcal-ajax-loader>i{color:rgba(0,0,0,.3)}.simcal-default-calendar-dark .simcal-nav-button{color:rgba(255,255,255,.6)}.simcal-default-calendar-dark .simcal-nav-button:disabled,.simcal-default-calendar-dark .simcal-nav-button:disabled:hover{color:rgba(0,0,0,.9)!important}.simcal-default-calendar-dark .simcal-nav-button:focus,.simcal-default-calendar-dark .simcal-nav-button:hover{color:rgba(255,255,255,.9)}.simcal-default-calendar-dark .simcal-events-toggle{color:rgba(255,255,255,.6)}.simcal-default-calendar-dark .simcal-events-toggle:hover{background-color:rgba(255,255,255,.1);color:#000}.simcal-default-calendar-dark .simcal-ajax-loader{background-color:rgba(255,255,255,.1)}.simcal-default-calendar-dark .simcal-ajax-loader>i{color:rgba(255,255,255,.3)}.simcal-default-calendar-list{min-height:100px;padding:10px 0;text-align:left}.simcal-default-calendar-list .simcal-calendar-head{display:table;padding-bottom:10px;width:100%}.simcal-default-calendar-list .simcal-calendar-head .simcal-nav{display:table-cell;text-align:center;vertical-align:middle;width:20%}.simcal-default-calendar-list .simcal-calendar-head .simcal-nav:nth-child(2){width:60%}.simcal-default-calendar-list .simcal-calendar-head .simcal-current span{display:inline-block}.simcal-default-calendar-list .simcal-calendar-head .simcal-hide-header{visibility:hidden}.simcal-default-calendar-list dl.simcal-month{margin-bottom:10px;padding:0 10px 10px}.simcal-default-calendar-list dd.simcal-day{list-style:none;margin:0}.simcal-default-calendar-list dt.simcal-day-label{font-size:.9em;list-style:none;margin:20px 0 10px}.simcal-default-calendar-list dt.simcal-day-label>span{display:inline-block;padding:4px 8px}.simcal-default-calendar-list ul.simcal-events{margin:10px 14px 0}.simcal-default-calendar-list ul.simcal-events li.simcal-event{list-style-type:none;margin-bottom:10px;word-wrap:break-word}.simcal-default-calendar-list .simcal-event-details{font-size:.84em;line-height:1.5;overflow:hidden}.simcal-default-calendar-list .simcal-event-details .simcal-event-description,.simcal-default-calendar-list .simcal-event-details p{margin:0 0 1em}.simcal-default-calendar-list .simcal-events-toggle{display:inline-block;padding:0}.simcal-default-calendar-list.simcal-default-calendar-light .simcal-events-toggle{background-color:rgba(0,0,0,.1)}.simcal-default-calendar-list.simcal-default-calendar-dark .simcal-events-toggle{background-color:rgba(255,255,255,.1)}.simcal-default-calendar-list .simcal-calendar-list-compact .simcal-calendar-head .simcal-nav h3{font-size:1em}
assets/js/admin-add-calendar.min.js CHANGED
@@ -1,4 +1,4 @@
1
- /*! Simple Calendar - 3.1.1
2
  * https://simplecalendar.io
3
  * Copyright (c) Moonstone Media 2016
4
  * Licensed GPLv2+ */
1
+ /*! Simple Calendar - 3.1.2
2
  * https://simplecalendar.io
3
  * Copyright (c) Moonstone Media 2016
4
  * Licensed GPLv2+ */
assets/js/admin.min.js CHANGED
@@ -1,4 +1,4 @@
1
- /*! Simple Calendar - 3.1.1
2
  * https://simplecalendar.io
3
  * Copyright (c) Moonstone Media 2016
4
  * Licensed GPLv2+ */
1
+ /*! Simple Calendar - 3.1.2
2
  * https://simplecalendar.io
3
  * Copyright (c) Moonstone Media 2016
4
  * Licensed GPLv2+ */
assets/js/default-calendar.js CHANGED
@@ -253,16 +253,19 @@
253
  */
254
  function toggleListHeading( calendar ) {
255
 
256
- var current = $( calendar ).find( '.simcal-current' ),
257
- heading = $( calendar ).find( '.simcal-events-list-container' ),
258
- small = heading.data( 'heading-small' ),
259
- large = heading.data( 'heading-large' );
 
260
 
261
  if ( calendar.width() < 400 ) {
262
- current.html( '<h3>' + small + '</h3>' );
263
  } else {
264
- current.html( '<h3>' + large + '</h3>' );
265
  }
 
 
266
  }
267
 
268
  var gridCalendars = $( '.simcal-default-calendar-grid' );
253
  */
254
  function toggleListHeading( calendar ) {
255
 
256
+ var current = $( calendar ).find( '.simcal-current' ),
257
+ heading = $( calendar ).find( '.simcal-events-list-container' ),
258
+ small = heading.data( 'heading-small' ),
259
+ large = heading.data( 'heading-large' ),
260
+ newHeading = $( '<h3 />' );
261
 
262
  if ( calendar.width() < 400 ) {
263
+ newHeading.text( small );
264
  } else {
265
+ newHeading.text( large );
266
  }
267
+
268
+ current.html( newHeading );
269
  }
270
 
271
  var gridCalendars = $( '.simcal-default-calendar-grid' );
assets/js/default-calendar.min.js CHANGED
@@ -1,6 +1,6 @@
1
- /*! Simple Calendar - 3.1.1
2
  * https://simplecalendar.io
3
  * Copyright (c) Moonstone Media 2016
4
  * Licensed GPLv2+ */
5
 
6
- !function(a,b){"use strict";jQuery(function(b){function c(a,c,d,e){a.each(function(a,f){var g=b(f),h=new Date(1e3*c);g.hasClass("simcal-prev")?(h=new Date(h.setMonth(h.getMonth(),1)),h.setDate(0),h.getTime()/1e3<=d?g.attr("disabled","disabled"):g.removeAttr("disabled")):(h=new Date(h.setMonth(h.getMonth()+1,1)),h.setDate(0),h.setHours(23),h.setMinutes(59),h.setSeconds(59),h.getTime()/1e3>=e?g.attr("disabled","disabled"):g.removeAttr("disabled"))})}function d(a,c,d,e,f,g){var h=c.find(".simcal-events-list-container"),i=h.data("prev"),j=h.data("next"),k=h.find("li.simcal-event:last").data("start");a.each(function(a,c){var h=b(c);f?("prev"==f&&h.hasClass("simcal-prev")?d>=i&&d>=g&&h.attr("disabled","disabled"):h.hasClass("simcal-prev")&&h.removeAttr("disabled"),"next"==f&&h.hasClass("simcal-next")?(j>=e&&g>=e||k>=e)&&h.attr("disabled","disabled"):b(h).hasClass("simcal-next")&&h.removeAttr("disabled")):(d>=i&&h.hasClass("simcal-prev")&&d>=g&&h.attr("disabled","disabled"),(j>=e&&h.hasClass("simcal-next")&&g>=e||k>=e)&&h.attr("disabled","disabled"))})}function e(a){var c=b(a).find(".simcal-current"),d=b(a).find(".simcal-events-list-container"),e=d.data("heading-small"),f=d.data("heading-large");a.width()<400?c.html("<h3>"+e+"</h3>"):c.html("<h3>"+f+"</h3>")}function f(c){var d=b(c).find("> table"),e=d.find("thead"),f=e.find("th.simcal-week-day"),g=d.find("td.simcal-day > div"),h=d.find("ul.simcal-events"),i=h.find("> li > .simcal-event-title"),j=d.find(".simcal-events-toggle"),k=d.find("span.simcal-events-dots"),l=d.find(".simcal-tooltip-content"),m=d.find(".simcal-event-toggled"),n=d.data("event-bubble-trigger"),o=g.first().width();if(60>o){f.each(function(a,c){b(c).text(b(c).data("screen-small"))}),h.hide(),i.hide(),"undefined"!=j&&(j.hide(),"undefined"!=m&&m.show()),k.show(),n="click";var p=o-10+"px";g.css("min-height",p),d.find("span.simcal-events-dots:not(:empty)").css("min-height",p)}else 240>=o?f.each(function(a,c){b(c).text(b(c).data("screen-medium"))}):f.each(function(a,c){b(c).text(b(c).data("screen-large"))}),h.show(),i.show(),"undefined"!=j&&(j.show(),"undefined"!=m&&m.hide()),k.hide(),g.css("min-height",o+"px");g.each(function(c,d){var e,f,g=b(d).find("span.simcal-events-dots"),h=b(d).find(".simcal-tooltip");60>o?(l.show(),e=g):(l.hide(),e=h),e.each(function(c,e){b(e).qtip({content:60>o?b(d).find("ul.simcal-events"):b(e).find("> .simcal-tooltip-content"),position:{my:"top center",at:"bottom center",target:b(e),viewport:60>o?b(a):!0,adjust:{method:"shift",scroll:!1}},style:{def:!1,classes:"simcal-default-calendar simcal-event-bubble"},show:{solo:!0,effect:!1,event:"hover"==n?"mouseenter":"click"},hide:{fixed:!0,effect:!1,event:"click"==n?"unfocus":"mouseleave",delay:100},events:{show:function(a,b){f&&f.id&&f.id!=b.id&&f.hide(),f=b}}})})})}function g(){b(".simcal-events-toggle").each(function(a,c){var d=b(c).prev(".simcal-events"),e=d.find(".simcal-event-toggled"),f=b(c).find("i");b(c).on("click",function(){f.toggleClass("simcal-icon-rotate-180"),e.slideToggle()})})}b(".simcal-default-calendar").each(function(a,h){var i,j,k=b(h),l=k.data("calendar-id"),m=k.data("offset"),n=k.data("events-first"),o=k.data("calendar-end"),p=k.find(".simcal-calendar-head"),q=p.find(".simcal-nav-button"),r=k.find(".simcal-ajax-loader"),s=p.find(".simcal-current"),t=s.data("calendar-current"),u=s.find("span.simcal-current-month"),v=s.find("span.simcal-current-year"),w=moment.tz(1e3*t,k.data("timezone"));k.hasClass("simcal-default-calendar-grid")?(j="simcal_default_calendar_draw_grid",i=new Date(w.year(),w.month()),c(q,i.getTime()/1e3,n,o)):(j="simcal_default_calendar_draw_list",d(q,k,n,o,!1,t),e(k)),q.on("click",function(){var a=b(this).hasClass("simcal-next")?"next":"prev";if("simcal_default_calendar_draw_grid"==j){var h,p,t,w=k.find(".simcal-month");"prev"==a?h=new Date(i.setMonth(i.getMonth()-1,1)):(h=new Date(i.setMonth(i.getMonth()+2,1)),h.setDate(0),h.setHours(23),h.setMinutes(59),h.setSeconds(59)),p=h.getMonth(),t=h.getFullYear(),b.ajax({url:simcal_default_calendar.ajax_url,method:"POST",dataType:"json",cache:!1,data:{action:j,month:p+1,year:t,id:l},beforeSend:function(){r.fadeToggle()},success:function(a){u.text(simcal_default_calendar.months.full[p]),v.text(t),s.attr("data-calendar-current",h.getTime()/1e3+m+1),c(q,h.getTime()/1e3,n,o),r.fadeToggle(),i=h,w.replaceWith(a.data),f(k,x),g()},error:function(a){console.log(a)}})}else{var x=k.find(".simcal-events-list-container"),y=x.data("prev"),z=x.data("next"),A="prev"==a?y:z;b.ajax({url:simcal_default_calendar.ajax_url,method:"POST",dataType:"json",cache:!1,data:{action:j,ts:A,id:l},beforeSend:function(){r.fadeToggle()},success:function(b){x.replaceWith(b.data),s.attr("data-calendar-current",A),e(k),d(q,k,n,o,a,A),r.fadeToggle(),g()},error:function(a){console.log(a)}})}})});var h=b(".simcal-default-calendar-grid");h.each(function(a,c){f(c),b(c).on("change",function(){f(this)})}),a.onresize=function(){h.each(function(a,b){f(b)})},g()})}(this);
1
+ /*! Simple Calendar - 3.1.2
2
  * https://simplecalendar.io
3
  * Copyright (c) Moonstone Media 2016
4
  * Licensed GPLv2+ */
5
 
6
+ !function(a,b){"use strict";jQuery(function(b){function c(a,c,d,e){a.each(function(a,f){var g=b(f),h=new Date(1e3*c);g.hasClass("simcal-prev")?(h=new Date(h.setMonth(h.getMonth(),1)),h.setDate(0),h.getTime()/1e3<=d?g.attr("disabled","disabled"):g.removeAttr("disabled")):(h=new Date(h.setMonth(h.getMonth()+1,1)),h.setDate(0),h.setHours(23),h.setMinutes(59),h.setSeconds(59),h.getTime()/1e3>=e?g.attr("disabled","disabled"):g.removeAttr("disabled"))})}function d(a,c,d,e,f,g){var h=c.find(".simcal-events-list-container"),i=h.data("prev"),j=h.data("next"),k=h.find("li.simcal-event:last").data("start");a.each(function(a,c){var h=b(c);f?("prev"==f&&h.hasClass("simcal-prev")?d>=i&&d>=g&&h.attr("disabled","disabled"):h.hasClass("simcal-prev")&&h.removeAttr("disabled"),"next"==f&&h.hasClass("simcal-next")?(j>=e&&g>=e||k>=e)&&h.attr("disabled","disabled"):b(h).hasClass("simcal-next")&&h.removeAttr("disabled")):(d>=i&&h.hasClass("simcal-prev")&&d>=g&&h.attr("disabled","disabled"),(j>=e&&h.hasClass("simcal-next")&&g>=e||k>=e)&&h.attr("disabled","disabled"))})}function e(a){var c=b(a).find(".simcal-current"),d=b(a).find(".simcal-events-list-container"),e=d.data("heading-small"),f=d.data("heading-large"),g=b("<h3 />");a.width()<400?g.text(e):g.text(f),c.html(g)}function f(c){var d=b(c).find("> table"),e=d.find("thead"),f=e.find("th.simcal-week-day"),g=d.find("td.simcal-day > div"),h=d.find("ul.simcal-events"),i=h.find("> li > .simcal-event-title"),j=d.find(".simcal-events-toggle"),k=d.find("span.simcal-events-dots"),l=d.find(".simcal-tooltip-content"),m=d.find(".simcal-event-toggled"),n=d.data("event-bubble-trigger"),o=g.first().width();if(60>o){f.each(function(a,c){b(c).text(b(c).data("screen-small"))}),h.hide(),i.hide(),"undefined"!=j&&(j.hide(),"undefined"!=m&&m.show()),k.show(),n="click";var p=o-10+"px";g.css("min-height",p),d.find("span.simcal-events-dots:not(:empty)").css("min-height",p)}else 240>=o?f.each(function(a,c){b(c).text(b(c).data("screen-medium"))}):f.each(function(a,c){b(c).text(b(c).data("screen-large"))}),h.show(),i.show(),"undefined"!=j&&(j.show(),"undefined"!=m&&m.hide()),k.hide(),g.css("min-height",o+"px");g.each(function(c,d){var e,f,g=b(d).find("span.simcal-events-dots"),h=b(d).find(".simcal-tooltip");60>o?(l.show(),e=g):(l.hide(),e=h),e.each(function(c,e){b(e).qtip({content:60>o?b(d).find("ul.simcal-events"):b(e).find("> .simcal-tooltip-content"),position:{my:"top center",at:"bottom center",target:b(e),viewport:60>o?b(a):!0,adjust:{method:"shift",scroll:!1}},style:{def:!1,classes:"simcal-default-calendar simcal-event-bubble"},show:{solo:!0,effect:!1,event:"hover"==n?"mouseenter":"click"},hide:{fixed:!0,effect:!1,event:"click"==n?"unfocus":"mouseleave",delay:100},events:{show:function(a,b){f&&f.id&&f.id!=b.id&&f.hide(),f=b}}})})})}function g(){b(".simcal-events-toggle").each(function(a,c){var d=b(c).prev(".simcal-events"),e=d.find(".simcal-event-toggled"),f=b(c).find("i");b(c).on("click",function(){f.toggleClass("simcal-icon-rotate-180"),e.slideToggle()})})}b(".simcal-default-calendar").each(function(a,h){var i,j,k=b(h),l=k.data("calendar-id"),m=k.data("offset"),n=k.data("events-first"),o=k.data("calendar-end"),p=k.find(".simcal-calendar-head"),q=p.find(".simcal-nav-button"),r=k.find(".simcal-ajax-loader"),s=p.find(".simcal-current"),t=s.data("calendar-current"),u=s.find("span.simcal-current-month"),v=s.find("span.simcal-current-year"),w=moment.tz(1e3*t,k.data("timezone"));k.hasClass("simcal-default-calendar-grid")?(j="simcal_default_calendar_draw_grid",i=new Date(w.year(),w.month()),c(q,i.getTime()/1e3,n,o)):(j="simcal_default_calendar_draw_list",d(q,k,n,o,!1,t),e(k)),q.on("click",function(){var a=b(this).hasClass("simcal-next")?"next":"prev";if("simcal_default_calendar_draw_grid"==j){var h,p,t,w=k.find(".simcal-month");"prev"==a?h=new Date(i.setMonth(i.getMonth()-1,1)):(h=new Date(i.setMonth(i.getMonth()+2,1)),h.setDate(0),h.setHours(23),h.setMinutes(59),h.setSeconds(59)),p=h.getMonth(),t=h.getFullYear(),b.ajax({url:simcal_default_calendar.ajax_url,method:"POST",dataType:"json",cache:!1,data:{action:j,month:p+1,year:t,id:l},beforeSend:function(){r.fadeToggle()},success:function(a){u.text(simcal_default_calendar.months.full[p]),v.text(t),s.attr("data-calendar-current",h.getTime()/1e3+m+1),c(q,h.getTime()/1e3,n,o),r.fadeToggle(),i=h,w.replaceWith(a.data),f(k,x),g()},error:function(a){console.log(a)}})}else{var x=k.find(".simcal-events-list-container"),y=x.data("prev"),z=x.data("next"),A="prev"==a?y:z;b.ajax({url:simcal_default_calendar.ajax_url,method:"POST",dataType:"json",cache:!1,data:{action:j,ts:A,id:l},beforeSend:function(){r.fadeToggle()},success:function(b){x.replaceWith(b.data),s.attr("data-calendar-current",A),e(k),d(q,k,n,o,a,A),r.fadeToggle(),g()},error:function(a){console.log(a)}})}})});var h=b(".simcal-default-calendar-grid");h.each(function(a,c){f(c),b(c).on("change",function(){f(this)})}),a.onresize=function(){h.each(function(a,b){f(b)})},g()})}(this);
assets/js/vendor/moment.js CHANGED
@@ -1,5 +1,5 @@
1
  //! moment.js
2
- //! version : 2.13.0
3
  //! authors : Tim Wood, Iskren Chernev, Moment.js contributors
4
  //! license : MIT
5
  //! momentjs.com
@@ -26,6 +26,19 @@
26
  return input instanceof Array || Object.prototype.toString.call(input) === '[object Array]';
27
  }
28
 
 
 
 
 
 
 
 
 
 
 
 
 
 
29
  function isDate(input) {
30
  return input instanceof Date || Object.prototype.toString.call(input) === '[object Date]';
31
  }
@@ -221,7 +234,8 @@
221
 
222
  function absFloor (number) {
223
  if (number < 0) {
224
- return Math.ceil(number);
 
225
  } else {
226
  return Math.floor(number);
227
  }
@@ -294,10 +308,6 @@
294
  return input instanceof Function || Object.prototype.toString.call(input) === '[object Function]';
295
  }
296
 
297
- function isObject(input) {
298
- return Object.prototype.toString.call(input) === '[object Object]';
299
- }
300
-
301
  function locale_set__set (config) {
302
  var prop, i;
303
  for (i in config) {
@@ -329,6 +339,14 @@
329
  }
330
  }
331
  }
 
 
 
 
 
 
 
 
332
  return res;
333
  }
334
 
@@ -354,161 +372,83 @@
354
  };
355
  }
356
 
357
- // internal storage for locale config files
358
- var locales = {};
359
- var globalLocale;
 
 
 
 
 
360
 
361
- function normalizeLocale(key) {
362
- return key ? key.toLowerCase().replace('_', '-') : key;
 
363
  }
364
 
365
- // pick the locale from the array
366
- // try ['en-au', 'en-gb'] as 'en-au', 'en-gb', 'en', as in move through the list trying each
367
- // substring from most specific to least, but move to the next array item if it's a more specific variant than the current root
368
- function chooseLocale(names) {
369
- var i = 0, j, next, locale, split;
 
 
 
370
 
371
- while (i < names.length) {
372
- split = normalizeLocale(names[i]).split('-');
373
- j = split.length;
374
- next = normalizeLocale(names[i + 1]);
375
- next = next ? next.split('-') : null;
376
- while (j > 0) {
377
- locale = loadLocale(split.slice(0, j).join('-'));
378
- if (locale) {
379
- return locale;
380
- }
381
- if (next && next.length >= j && compareArrays(split, next, true) >= j - 1) {
382
- //the next array item is better than a shallower substring of this one
383
- break;
384
- }
385
- j--;
386
- }
387
- i++;
388
- }
389
- return null;
390
- }
391
 
392
- function loadLocale(name) {
393
- var oldLocale = null;
394
- // TODO: Find a better way to register and load all the locales in Node
395
- if (!locales[name] && (typeof module !== 'undefined') &&
396
- module && module.exports) {
397
- try {
398
- oldLocale = globalLocale._abbr;
399
- require('./locale/' + name);
400
- // because defineLocale currently also sets the global locale, we
401
- // want to undo that for lazy loaded locales
402
- locale_locales__getSetGlobalLocale(oldLocale);
403
- } catch (e) { }
404
  }
405
- return locales[name];
406
- }
407
-
408
- // This function will load locale and then set the global locale. If
409
- // no arguments are passed in, it will simply return the current global
410
- // locale key.
411
- function locale_locales__getSetGlobalLocale (key, values) {
412
- var data;
413
- if (key) {
414
- if (isUndefined(values)) {
415
- data = locale_locales__getLocale(key);
416
- }
417
- else {
418
- data = defineLocale(key, values);
419
- }
420
 
421
- if (data) {
422
- // moment.duration._locale = moment._locale = data;
423
- globalLocale = data;
424
- }
425
- }
426
 
427
- return globalLocale._abbr;
428
  }
429
 
430
- function defineLocale (name, config) {
431
- if (config !== null) {
432
- config.abbr = name;
433
- if (locales[name] != null) {
434
- deprecateSimple('defineLocaleOverride',
435
- 'use moment.updateLocale(localeName, config) to change ' +
436
- 'an existing locale. moment.defineLocale(localeName, ' +
437
- 'config) should only be used for creating a new locale');
438
- config = mergeConfigs(locales[name]._config, config);
439
- } else if (config.parentLocale != null) {
440
- if (locales[config.parentLocale] != null) {
441
- config = mergeConfigs(locales[config.parentLocale]._config, config);
442
- } else {
443
- // treat as if there is no base config
444
- deprecateSimple('parentLocaleUndefined',
445
- 'specified parentLocale is not defined yet');
446
- }
447
- }
448
- locales[name] = new Locale(config);
449
-
450
- // backwards compat for now: also set the locale
451
- locale_locales__getSetGlobalLocale(name);
452
 
453
- return locales[name];
454
- } else {
455
- // useful for testing
456
- delete locales[name];
457
- return null;
458
- }
459
  }
460
 
461
- function updateLocale(name, config) {
462
- if (config != null) {
463
- var locale;
464
- if (locales[name] != null) {
465
- config = mergeConfigs(locales[name]._config, config);
466
- }
467
- locale = new Locale(config);
468
- locale.parentLocale = locales[name];
469
- locales[name] = locale;
470
 
471
- // backwards compat for now: also set the locale
472
- locale_locales__getSetGlobalLocale(name);
473
- } else {
474
- // pass null for config to unupdate, useful for tests
475
- if (locales[name] != null) {
476
- if (locales[name].parentLocale != null) {
477
- locales[name] = locales[name].parentLocale;
478
- } else if (locales[name] != null) {
479
- delete locales[name];
480
- }
481
- }
482
- }
483
- return locales[name];
484
  }
485
 
486
- // returns locale data
487
- function locale_locales__getLocale (key) {
488
- var locale;
489
-
490
- if (key && key._locale && key._locale._abbr) {
491
- key = key._locale._abbr;
492
- }
493
-
494
- if (!key) {
495
- return globalLocale;
496
- }
497
-
498
- if (!isArray(key)) {
499
- //short-circuit everything else
500
- locale = loadLocale(key);
501
- if (locale) {
502
- return locale;
503
- }
504
- key = [key];
505
- }
506
 
507
- return chooseLocale(key);
 
 
 
 
508
  }
509
 
510
- function locale_locales__listLocales() {
511
- return keys(locales);
 
512
  }
513
 
514
  var aliases = {};
@@ -539,6 +479,23 @@
539
  return normalizedInput;
540
  }
541
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
542
  function makeGetSet (unit, keepTime) {
543
  return function (value) {
544
  if (value != null) {
@@ -564,11 +521,21 @@
564
 
565
  // MOMENTS
566
 
567
- function getSet (units, value) {
568
- var unit;
 
 
 
 
 
 
 
 
569
  if (typeof units === 'object') {
570
- for (unit in units) {
571
- this.set(unit, units[unit]);
 
 
572
  }
573
  } else {
574
  units = normalizeUnits(units);
@@ -808,6 +775,10 @@
808
 
809
  addUnitAlias('month', 'M');
810
 
 
 
 
 
811
  // PARSING
812
 
813
  addRegexToken('M', match1to2);
@@ -839,7 +810,7 @@
839
  var defaultLocaleMonths = 'January_February_March_April_May_June_July_August_September_October_November_December'.split('_');
840
  function localeMonths (m, format) {
841
  return isArray(this._months) ? this._months[m.month()] :
842
- this._months[MONTHS_IN_FORMAT.test(format) ? 'format' : 'standalone'][m.month()];
843
  }
844
 
845
  var defaultLocaleMonthsShort = 'Jan_Feb_Mar_Apr_May_Jun_Jul_Aug_Sep_Oct_Nov_Dec'.split('_');
@@ -980,6 +951,9 @@
980
  return this._monthsShortRegex;
981
  }
982
  } else {
 
 
 
983
  return this._monthsShortStrictRegex && isStrict ?
984
  this._monthsShortStrictRegex : this._monthsShortRegex;
985
  }
@@ -997,6 +971,9 @@
997
  return this._monthsRegex;
998
  }
999
  } else {
 
 
 
1000
  return this._monthsStrictRegex && isStrict ?
1001
  this._monthsStrictRegex : this._monthsRegex;
1002
  }
@@ -1025,6 +1002,8 @@
1025
  for (i = 0; i < 12; i++) {
1026
  shortPieces[i] = regexEscape(shortPieces[i]);
1027
  longPieces[i] = regexEscape(longPieces[i]);
 
 
1028
  mixedPieces[i] = regexEscape(mixedPieces[i]);
1029
  }
1030
 
@@ -1034,193 +1013,29 @@
1034
  this._monthsShortStrictRegex = new RegExp('^(' + shortPieces.join('|') + ')', 'i');
1035
  }
1036
 
1037
- function checkOverflow (m) {
1038
- var overflow;
1039
- var a = m._a;
1040
 
1041
- if (a && getParsingFlags(m).overflow === -2) {
1042
- overflow =
1043
- a[MONTH] < 0 || a[MONTH] > 11 ? MONTH :
1044
- a[DATE] < 1 || a[DATE] > daysInMonth(a[YEAR], a[MONTH]) ? DATE :
1045
- a[HOUR] < 0 || a[HOUR] > 24 || (a[HOUR] === 24 && (a[MINUTE] !== 0 || a[SECOND] !== 0 || a[MILLISECOND] !== 0)) ? HOUR :
1046
- a[MINUTE] < 0 || a[MINUTE] > 59 ? MINUTE :
1047
- a[SECOND] < 0 || a[SECOND] > 59 ? SECOND :
1048
- a[MILLISECOND] < 0 || a[MILLISECOND] > 999 ? MILLISECOND :
1049
- -1;
1050
 
1051
- if (getParsingFlags(m)._overflowDayOfYear && (overflow < YEAR || overflow > DATE)) {
1052
- overflow = DATE;
1053
- }
1054
- if (getParsingFlags(m)._overflowWeeks && overflow === -1) {
1055
- overflow = WEEK;
1056
- }
1057
- if (getParsingFlags(m)._overflowWeekday && overflow === -1) {
1058
- overflow = WEEKDAY;
1059
- }
1060
 
1061
- getParsingFlags(m).overflow = overflow;
1062
- }
1063
-
1064
- return m;
1065
- }
1066
-
1067
- // iso 8601 regex
1068
- // 0000-00-00 0000-W00 or 0000-W00-0 + T + 00 or 00:00 or 00:00:00 or 00:00:00.000 + +00:00 or +0000 or +00)
1069
- var extendedIsoRegex = /^\s*((?:[+-]\d{6}|\d{4})-(?:\d\d-\d\d|W\d\d-\d|W\d\d|\d\d\d|\d\d))(?:(T| )(\d\d(?::\d\d(?::\d\d(?:[.,]\d+)?)?)?)([\+\-]\d\d(?::?\d\d)?|\s*Z)?)?/;
1070
- var basicIsoRegex = /^\s*((?:[+-]\d{6}|\d{4})(?:\d\d\d\d|W\d\d\d|W\d\d|\d\d\d|\d\d))(?:(T| )(\d\d(?:\d\d(?:\d\d(?:[.,]\d+)?)?)?)([\+\-]\d\d(?::?\d\d)?|\s*Z)?)?/;
1071
-
1072
- var tzRegex = /Z|[+-]\d\d(?::?\d\d)?/;
1073
-
1074
- var isoDates = [
1075
- ['YYYYYY-MM-DD', /[+-]\d{6}-\d\d-\d\d/],
1076
- ['YYYY-MM-DD', /\d{4}-\d\d-\d\d/],
1077
- ['GGGG-[W]WW-E', /\d{4}-W\d\d-\d/],
1078
- ['GGGG-[W]WW', /\d{4}-W\d\d/, false],
1079
- ['YYYY-DDD', /\d{4}-\d{3}/],
1080
- ['YYYY-MM', /\d{4}-\d\d/, false],
1081
- ['YYYYYYMMDD', /[+-]\d{10}/],
1082
- ['YYYYMMDD', /\d{8}/],
1083
- // YYYYMM is NOT allowed by the standard
1084
- ['GGGG[W]WWE', /\d{4}W\d{3}/],
1085
- ['GGGG[W]WW', /\d{4}W\d{2}/, false],
1086
- ['YYYYDDD', /\d{7}/]
1087
- ];
1088
-
1089
- // iso time formats and regexes
1090
- var isoTimes = [
1091
- ['HH:mm:ss.SSSS', /\d\d:\d\d:\d\d\.\d+/],
1092
- ['HH:mm:ss,SSSS', /\d\d:\d\d:\d\d,\d+/],
1093
- ['HH:mm:ss', /\d\d:\d\d:\d\d/],
1094
- ['HH:mm', /\d\d:\d\d/],
1095
- ['HHmmss.SSSS', /\d\d\d\d\d\d\.\d+/],
1096
- ['HHmmss,SSSS', /\d\d\d\d\d\d,\d+/],
1097
- ['HHmmss', /\d\d\d\d\d\d/],
1098
- ['HHmm', /\d\d\d\d/],
1099
- ['HH', /\d\d/]
1100
- ];
1101
-
1102
- var aspNetJsonRegex = /^\/?Date\((\-?\d+)/i;
1103
-
1104
- // date from iso format
1105
- function configFromISO(config) {
1106
- var i, l,
1107
- string = config._i,
1108
- match = extendedIsoRegex.exec(string) || basicIsoRegex.exec(string),
1109
- allowTime, dateFormat, timeFormat, tzFormat;
1110
-
1111
- if (match) {
1112
- getParsingFlags(config).iso = true;
1113
-
1114
- for (i = 0, l = isoDates.length; i < l; i++) {
1115
- if (isoDates[i][1].exec(match[1])) {
1116
- dateFormat = isoDates[i][0];
1117
- allowTime = isoDates[i][2] !== false;
1118
- break;
1119
- }
1120
- }
1121
- if (dateFormat == null) {
1122
- config._isValid = false;
1123
- return;
1124
- }
1125
- if (match[3]) {
1126
- for (i = 0, l = isoTimes.length; i < l; i++) {
1127
- if (isoTimes[i][1].exec(match[3])) {
1128
- // match[2] should be 'T' or space
1129
- timeFormat = (match[2] || ' ') + isoTimes[i][0];
1130
- break;
1131
- }
1132
- }
1133
- if (timeFormat == null) {
1134
- config._isValid = false;
1135
- return;
1136
- }
1137
- }
1138
- if (!allowTime && timeFormat != null) {
1139
- config._isValid = false;
1140
- return;
1141
- }
1142
- if (match[4]) {
1143
- if (tzRegex.exec(match[4])) {
1144
- tzFormat = 'Z';
1145
- } else {
1146
- config._isValid = false;
1147
- return;
1148
- }
1149
- }
1150
- config._f = dateFormat + (timeFormat || '') + (tzFormat || '');
1151
- configFromStringAndFormat(config);
1152
- } else {
1153
- config._isValid = false;
1154
- }
1155
- }
1156
-
1157
- // date from iso format or fallback
1158
- function configFromString(config) {
1159
- var matched = aspNetJsonRegex.exec(config._i);
1160
-
1161
- if (matched !== null) {
1162
- config._d = new Date(+matched[1]);
1163
- return;
1164
- }
1165
-
1166
- configFromISO(config);
1167
- if (config._isValid === false) {
1168
- delete config._isValid;
1169
- utils_hooks__hooks.createFromInputFallback(config);
1170
- }
1171
- }
1172
-
1173
- utils_hooks__hooks.createFromInputFallback = deprecate(
1174
- 'moment construction falls back to js Date. This is ' +
1175
- 'discouraged and will be removed in upcoming major ' +
1176
- 'release. Please refer to ' +
1177
- 'https://github.com/moment/moment/issues/1407 for more info.',
1178
- function (config) {
1179
- config._d = new Date(config._i + (config._useUTC ? ' UTC' : ''));
1180
- }
1181
- );
1182
-
1183
- function createDate (y, m, d, h, M, s, ms) {
1184
- //can't just apply() to create a date:
1185
- //http://stackoverflow.com/questions/181348/instantiating-a-javascript-object-by-calling-prototype-constructor-apply
1186
- var date = new Date(y, m, d, h, M, s, ms);
1187
-
1188
- //the date constructor remaps years 0-99 to 1900-1999
1189
- if (y < 100 && y >= 0 && isFinite(date.getFullYear())) {
1190
- date.setFullYear(y);
1191
- }
1192
- return date;
1193
- }
1194
-
1195
- function createUTCDate (y) {
1196
- var date = new Date(Date.UTC.apply(null, arguments));
1197
-
1198
- //the Date.UTC function remaps years 0-99 to 1900-1999
1199
- if (y < 100 && y >= 0 && isFinite(date.getUTCFullYear())) {
1200
- date.setUTCFullYear(y);
1201
- }
1202
- return date;
1203
- }
1204
-
1205
- // FORMATTING
1206
-
1207
- addFormatToken('Y', 0, 0, function () {
1208
- var y = this.year();
1209
- return y <= 9999 ? '' + y : '+' + y;
1210
- });
1211
-
1212
- addFormatToken(0, ['YY', 2], 0, function () {
1213
- return this.year() % 100;
1214
- });
1215
-
1216
- addFormatToken(0, ['YYYY', 4], 0, 'year');
1217
- addFormatToken(0, ['YYYYY', 5], 0, 'year');
1218
- addFormatToken(0, ['YYYYYY', 6, true], 0, 'year');
1219
 
1220
  // ALIASES
1221
 
1222
  addUnitAlias('year', 'y');
1223
 
 
 
 
 
1224
  // PARSING
1225
 
1226
  addRegexToken('Y', matchSigned);
@@ -1264,6 +1079,28 @@
1264
  return isLeapYear(this.year());
1265
  }
1266
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1267
  // start-of-first-week - start-of-year
1268
  function firstWeekOffset(year, dow, doy) {
1269
  var // first-week day -- which january is always in the first week (4 for iso, 1 for other)
@@ -1326,1864 +1163,2253 @@
1326
  return (daysInYear(year) - weekOffset + weekOffsetNext) / 7;
1327
  }
1328
 
1329
- // Pick the first defined of two or three arguments.
1330
- function defaults(a, b, c) {
1331
- if (a != null) {
1332
- return a;
1333
- }
1334
- if (b != null) {
1335
- return b;
1336
- }
1337
- return c;
1338
- }
1339
 
1340
- function currentDateArray(config) {
1341
- // hooks is actually the exported moment object
1342
- var nowValue = new Date(utils_hooks__hooks.now());
1343
- if (config._useUTC) {
1344
- return [nowValue.getUTCFullYear(), nowValue.getUTCMonth(), nowValue.getUTCDate()];
1345
- }
1346
- return [nowValue.getFullYear(), nowValue.getMonth(), nowValue.getDate()];
1347
- }
1348
 
1349
- // convert an array to a date.
1350
- // the array should mirror the parameters below
1351
- // note: all values past the year are optional and will default to the lowest possible value.
1352
- // [year, month, day , hour, minute, second, millisecond]
1353
- function configFromArray (config) {
1354
- var i, date, input = [], currentDate, yearToUse;
1355
 
1356
- if (config._d) {
1357
- return;
1358
- }
1359
 
1360
- currentDate = currentDateArray(config);
1361
 
1362
- //compute day of the year from weeks and weekdays
1363
- if (config._w && config._a[DATE] == null && config._a[MONTH] == null) {
1364
- dayOfYearFromWeekInfo(config);
1365
- }
1366
 
1367
- //if the day of the year is set, figure out what it is
1368
- if (config._dayOfYear) {
1369
- yearToUse = defaults(config._a[YEAR], currentDate[YEAR]);
1370
 
1371
- if (config._dayOfYear > daysInYear(yearToUse)) {
1372
- getParsingFlags(config)._overflowDayOfYear = true;
1373
- }
 
1374
 
1375
- date = createUTCDate(yearToUse, 0, config._dayOfYear);
1376
- config._a[MONTH] = date.getUTCMonth();
1377
- config._a[DATE] = date.getUTCDate();
1378
- }
1379
 
1380
- // Default to current date.
1381
- // * if no year, month, day of month are given, default to today
1382
- // * if day of month is given, default month and year
1383
- // * if month is given, default only year
1384
- // * if year is given, don't default anything
1385
- for (i = 0; i < 3 && config._a[i] == null; ++i) {
1386
- config._a[i] = input[i] = currentDate[i];
1387
- }
1388
 
1389
- // Zero out whatever was not defaulted, including time
1390
- for (; i < 7; i++) {
1391
- config._a[i] = input[i] = (config._a[i] == null) ? (i === 2 ? 1 : 0) : config._a[i];
1392
- }
1393
 
1394
- // Check for 24:00:00.000
1395
- if (config._a[HOUR] === 24 &&
1396
- config._a[MINUTE] === 0 &&
1397
- config._a[SECOND] === 0 &&
1398
- config._a[MILLISECOND] === 0) {
1399
- config._nextDay = true;
1400
- config._a[HOUR] = 0;
1401
- }
1402
-
1403
- config._d = (config._useUTC ? createUTCDate : createDate).apply(null, input);
1404
- // Apply timezone offset from input. The actual utcOffset can be changed
1405
- // with parseZone.
1406
- if (config._tzm != null) {
1407
- config._d.setUTCMinutes(config._d.getUTCMinutes() - config._tzm);
1408
- }
1409
-
1410
- if (config._nextDay) {
1411
- config._a[HOUR] = 24;
1412
- }
1413
  }
1414
 
1415
- function dayOfYearFromWeekInfo(config) {
1416
- var w, weekYear, week, weekday, dow, doy, temp, weekdayOverflow;
 
 
1417
 
1418
- w = config._w;
1419
- if (w.GG != null || w.W != null || w.E != null) {
1420
- dow = 1;
1421
- doy = 4;
1422
 
1423
- // TODO: We need to take the current isoWeekYear, but that depends on
1424
- // how we interpret now (local, utc, fixed offset). So create
1425
- // a now version of current config (take local/utc/offset flags, and
1426
- // create now).
1427
- weekYear = defaults(w.GG, config._a[YEAR], weekOfYear(local__createLocal(), 1, 4).year);
1428
- week = defaults(w.W, 1);
1429
- weekday = defaults(w.E, 1);
1430
- if (weekday < 1 || weekday > 7) {
1431
- weekdayOverflow = true;
1432
- }
1433
- } else {
1434
- dow = config._locale._week.dow;
1435
- doy = config._locale._week.doy;
1436
 
1437
- weekYear = defaults(w.gg, config._a[YEAR], weekOfYear(local__createLocal(), dow, doy).year);
1438
- week = defaults(w.w, 1);
1439
 
1440
- if (w.d != null) {
1441
- // weekday -- low day numbers are considered next week
1442
- weekday = w.d;
1443
- if (weekday < 0 || weekday > 6) {
1444
- weekdayOverflow = true;
1445
- }
1446
- } else if (w.e != null) {
1447
- // local weekday -- counting starts from begining of week
1448
- weekday = w.e + dow;
1449
- if (w.e < 0 || w.e > 6) {
1450
- weekdayOverflow = true;
1451
- }
1452
- } else {
1453
- // default to begining of week
1454
- weekday = dow;
1455
- }
1456
- }
1457
- if (week < 1 || week > weeksInYear(weekYear, dow, doy)) {
1458
- getParsingFlags(config)._overflowWeeks = true;
1459
- } else if (weekdayOverflow != null) {
1460
- getParsingFlags(config)._overflowWeekday = true;
1461
- } else {
1462
- temp = dayOfYearFromWeeks(weekYear, week, weekday, dow, doy);
1463
- config._a[YEAR] = temp.year;
1464
- config._dayOfYear = temp.dayOfYear;
1465
- }
1466
  }
1467
 
1468
- // constant that refers to the ISO standard
1469
- utils_hooks__hooks.ISO_8601 = function () {};
 
 
1470
 
1471
- // date from string and format string
1472
- function configFromStringAndFormat(config) {
1473
- // TODO: Move this to another part of the creation flow to prevent circular deps
1474
- if (config._f === utils_hooks__hooks.ISO_8601) {
1475
- configFromISO(config);
1476
- return;
1477
- }
1478
 
1479
- config._a = [];
1480
- getParsingFlags(config).empty = true;
1481
 
1482
- // This array is used to make a Date, either with `new Date` or `Date.UTC`
1483
- var string = '' + config._i,
1484
- i, parsedInput, tokens, token, skipped,
1485
- stringLength = string.length,
1486
- totalParsedInputLength = 0;
1487
 
1488
- tokens = expandFormat(config._f, config._locale).match(formattingTokens) || [];
 
 
1489
 
1490
- for (i = 0; i < tokens.length; i++) {
1491
- token = tokens[i];
1492
- parsedInput = (string.match(getParseRegexForToken(token, config)) || [])[0];
1493
- // console.log('token', token, 'parsedInput', parsedInput,
1494
- // 'regex', getParseRegexForToken(token, config));
1495
- if (parsedInput) {
1496
- skipped = string.substr(0, string.indexOf(parsedInput));
1497
- if (skipped.length > 0) {
1498
- getParsingFlags(config).unusedInput.push(skipped);
1499
- }
1500
- string = string.slice(string.indexOf(parsedInput) + parsedInput.length);
1501
- totalParsedInputLength += parsedInput.length;
1502
- }
1503
- // don't parse if it's not a known token
1504
- if (formatTokenFunctions[token]) {
1505
- if (parsedInput) {
1506
- getParsingFlags(config).empty = false;
1507
- }
1508
- else {
1509
- getParsingFlags(config).unusedTokens.push(token);
1510
- }
1511
- addTimeToArrayFromToken(token, parsedInput, config);
1512
- }
1513
- else if (config._strict && !parsedInput) {
1514
- getParsingFlags(config).unusedTokens.push(token);
1515
- }
1516
- }
1517
 
1518
- // add remaining unparsed input length to the string
1519
- getParsingFlags(config).charsLeftOver = stringLength - totalParsedInputLength;
1520
- if (string.length > 0) {
1521
- getParsingFlags(config).unusedInput.push(string);
1522
- }
1523
 
1524
- // clear _12h flag if hour is <= 12
1525
- if (getParsingFlags(config).bigHour === true &&
1526
- config._a[HOUR] <= 12 &&
1527
- config._a[HOUR] > 0) {
1528
- getParsingFlags(config).bigHour = undefined;
1529
- }
1530
 
1531
- getParsingFlags(config).parsedDateParts = config._a.slice(0);
1532
- getParsingFlags(config).meridiem = config._meridiem;
1533
- // handle meridiem
1534
- config._a[HOUR] = meridiemFixWrap(config._locale, config._a[HOUR], config._meridiem);
1535
 
1536
- configFromArray(config);
1537
- checkOverflow(config);
1538
- }
 
1539
 
 
1540
 
1541
- function meridiemFixWrap (locale, hour, meridiem) {
1542
- var isPm;
 
 
 
 
 
 
 
 
 
 
1543
 
1544
- if (meridiem == null) {
1545
- // nothing to do
1546
- return hour;
1547
- }
1548
- if (locale.meridiemHour != null) {
1549
- return locale.meridiemHour(hour, meridiem);
1550
- } else if (locale.isPM != null) {
1551
- // Fallback
1552
- isPm = locale.isPM(meridiem);
1553
- if (isPm && hour < 12) {
1554
- hour += 12;
1555
- }
1556
- if (!isPm && hour === 12) {
1557
- hour = 0;
1558
- }
1559
- return hour;
1560
  } else {
1561
- // this is not supposed to happen
1562
- return hour;
1563
  }
1564
- }
1565
 
1566
- // date from string and array of format strings
1567
- function configFromStringAndArray(config) {
1568
- var tempConfig,
1569
- bestMoment,
1570
 
1571
- scoreToBeat,
1572
- i,
1573
- currentScore;
1574
 
1575
- if (config._f.length === 0) {
1576
- getParsingFlags(config).invalidFormat = true;
1577
- config._d = new Date(NaN);
1578
- return;
1579
  }
1580
 
1581
- for (i = 0; i < config._f.length; i++) {
1582
- currentScore = 0;
1583
- tempConfig = copyConfig({}, config);
1584
- if (config._useUTC != null) {
1585
- tempConfig._useUTC = config._useUTC;
1586
- }
1587
- tempConfig._f = config._f[i];
1588
- configFromStringAndFormat(tempConfig);
1589
-
1590
- if (!valid__isValid(tempConfig)) {
1591
- continue;
1592
- }
1593
-
1594
- // if there is any input that was not parsed add a penalty for that format
1595
- currentScore += getParsingFlags(tempConfig).charsLeftOver;
1596
-
1597
- //or tokens
1598
- currentScore += getParsingFlags(tempConfig).unusedTokens.length * 10;
1599
-
1600
- getParsingFlags(tempConfig).score = currentScore;
1601
 
1602
- if (scoreToBeat == null || currentScore < scoreToBeat) {
1603
- scoreToBeat = currentScore;
1604
- bestMoment = tempConfig;
1605
- }
1606
  }
1607
 
1608
- extend(config, bestMoment || tempConfig);
1609
  }
1610
 
1611
- function configFromObject(config) {
1612
- if (config._d) {
1613
- return;
1614
  }
1615
-
1616
- var i = normalizeObjectUnits(config._i);
1617
- config._a = map([i.year, i.month, i.day || i.date, i.hour, i.minute, i.second, i.millisecond], function (obj) {
1618
- return obj && parseInt(obj, 10);
1619
- });
1620
-
1621
- configFromArray(config);
1622
  }
1623
 
1624
- function createFromConfig (config) {
1625
- var res = new Moment(checkOverflow(prepareConfig(config)));
1626
- if (res._nextDay) {
1627
- // Adding is smart enough around DST
1628
- res.add(1, 'd');
1629
- res._nextDay = undefined;
1630
- }
1631
 
1632
- return res;
 
 
 
1633
  }
1634
 
1635
- function prepareConfig (config) {
1636
- var input = config._i,
1637
- format = config._f;
 
1638
 
1639
- config._locale = config._locale || locale_locales__getLocale(config._l);
 
 
 
1640
 
1641
- if (input === null || (format === undefined && input === '')) {
1642
- return valid__createInvalid({nullInput: true});
1643
- }
 
 
 
1644
 
1645
- if (typeof input === 'string') {
1646
- config._i = input = config._locale.preparse(input);
 
 
 
 
1647
  }
1648
 
1649
- if (isMoment(input)) {
1650
- return new Moment(checkOverflow(input));
1651
- } else if (isArray(format)) {
1652
- configFromStringAndArray(config);
1653
- } else if (format) {
1654
- configFromStringAndFormat(config);
1655
- } else if (isDate(input)) {
1656
- config._d = input;
 
 
 
1657
  } else {
1658
- configFromInput(config);
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1659
  }
 
1660
 
1661
- if (!valid__isValid(config)) {
1662
- config._d = null;
 
 
 
1663
  }
1664
 
1665
- return config;
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1666
  }
1667
 
1668
- function configFromInput(config) {
1669
- var input = config._i;
1670
- if (input === undefined) {
1671
- config._d = new Date(utils_hooks__hooks.now());
1672
- } else if (isDate(input)) {
1673
- config._d = new Date(input.valueOf());
1674
- } else if (typeof input === 'string') {
1675
- configFromString(config);
1676
- } else if (isArray(input)) {
1677
- config._a = map(input.slice(0), function (obj) {
1678
- return parseInt(obj, 10);
1679
- });
1680
- configFromArray(config);
1681
- } else if (typeof(input) === 'object') {
1682
- configFromObject(config);
1683
- } else if (typeof(input) === 'number') {
1684
- // from milliseconds
1685
- config._d = new Date(input);
1686
  } else {
1687
- utils_hooks__hooks.createFromInputFallback(config);
1688
  }
1689
  }
1690
 
1691
- function createLocalOrUTC (input, format, locale, strict, isUTC) {
1692
- var c = {};
 
 
 
 
 
1693
 
1694
- if (typeof(locale) === 'boolean') {
1695
- strict = locale;
1696
- locale = undefined;
1697
  }
1698
- // object construction must be done this way.
1699
- // https://github.com/moment/moment/issues/1423
1700
- c._isAMomentObject = true;
1701
- c._useUTC = c._isUTC = isUTC;
1702
- c._l = locale;
1703
- c._i = input;
1704
- c._f = format;
1705
- c._strict = strict;
1706
 
1707
- return createFromConfig(c);
1708
- }
 
1709
 
1710
- function local__createLocal (input, format, locale, strict) {
1711
- return createLocalOrUTC(input, format, locale, strict, false);
 
 
 
 
1712
  }
1713
 
1714
- var prototypeMin = deprecate(
1715
- 'moment().min is deprecated, use moment.max instead. https://github.com/moment/moment/issues/1548',
1716
- function () {
1717
- var other = local__createLocal.apply(null, arguments);
1718
- if (this.isValid() && other.isValid()) {
1719
- return other < this ? this : other;
1720
- } else {
1721
- return valid__createInvalid();
1722
- }
1723
- }
1724
- );
1725
-
1726
- var prototypeMax = deprecate(
1727
- 'moment().max is deprecated, use moment.min instead. https://github.com/moment/moment/issues/1548',
1728
- function () {
1729
- var other = local__createLocal.apply(null, arguments);
1730
- if (this.isValid() && other.isValid()) {
1731
- return other > this ? this : other;
1732
  } else {
1733
- return valid__createInvalid();
1734
  }
 
 
 
 
 
 
1735
  }
1736
- );
1737
 
1738
- // Pick a moment m from moments so that m[fn](other) is true for all
1739
- // other. This relies on the function fn to be transitive.
1740
- //
1741
- // moments should either be an array of moment objects or an array, whose
1742
- // first element is an array of moment objects.
1743
- function pickBy(fn, moments) {
1744
- var res, i;
1745
- if (moments.length === 1 && isArray(moments[0])) {
1746
- moments = moments[0];
1747
- }
1748
- if (!moments.length) {
1749
- return local__createLocal();
1750
- }
1751
- res = moments[0];
1752
- for (i = 1; i < moments.length; ++i) {
1753
- if (!moments[i].isValid() || moments[i][fn](res)) {
1754
- res = moments[i];
1755
  }
 
 
1756
  }
1757
- return res;
1758
  }
1759
 
1760
- // TODO: Use [].sort instead?
1761
- function min () {
1762
- var args = [].slice.call(arguments, 0);
1763
-
1764
- return pickBy('isBefore', args);
 
 
 
 
 
 
 
 
 
 
 
 
 
1765
  }
1766
 
1767
- function max () {
1768
- var args = [].slice.call(arguments, 0);
1769
-
1770
- return pickBy('isAfter', args);
1771
- }
1772
 
1773
- var now = function () {
1774
- return Date.now ? Date.now() : +(new Date());
1775
- };
 
1776
 
1777
- function Duration (duration) {
1778
- var normalizedInput = normalizeObjectUnits(duration),
1779
- years = normalizedInput.year || 0,
1780
- quarters = normalizedInput.quarter || 0,
1781
- months = normalizedInput.month || 0,
1782
- weeks = normalizedInput.week || 0,
1783
- days = normalizedInput.day || 0,
1784
- hours = normalizedInput.hour || 0,
1785
- minutes = normalizedInput.minute || 0,
1786
- seconds = normalizedInput.second || 0,
1787
- milliseconds = normalizedInput.millisecond || 0;
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1788
 
1789
- // representation for dateAddRemove
1790
- this._milliseconds = +milliseconds +
1791
- seconds * 1e3 + // 1000
1792
- minutes * 6e4 + // 1000 * 60
1793
- hours * 1000 * 60 * 60; //using 1000 * 60 * 60 instead of 36e5 to avoid floating point rounding errors https://github.com/moment/moment/issues/2978
1794
- // Because of dateAddRemove treats 24 hours as different from a
1795
- // day when working around DST, we need to store them separately
1796
- this._days = +days +
1797
- weeks * 7;
1798
- // It is impossible translate months into days without knowing
1799
- // which months you are are talking about, so we have to store
1800
- // it separately.
1801
- this._months = +months +
1802
- quarters * 3 +
1803
- years * 12;
1804
 
1805
- this._data = {};
 
 
 
1806
 
1807
- this._locale = locale_locales__getLocale();
1808
 
1809
- this._bubble();
 
1810
  }
1811
 
1812
- function isDuration (obj) {
1813
- return obj instanceof Duration;
1814
  }
1815
 
1816
- // FORMATTING
 
 
1817
 
1818
- function offset (token, separator) {
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1819
  addFormatToken(token, 0, 0, function () {
1820
- var offset = this.utcOffset();
1821
- var sign = '+';
1822
- if (offset < 0) {
1823
- offset = -offset;
1824
- sign = '-';
1825
- }
1826
- return sign + zeroFill(~~(offset / 60), 2) + separator + zeroFill(~~(offset) % 60, 2);
1827
  });
1828
  }
1829
 
1830
- offset('Z', ':');
1831
- offset('ZZ', '');
 
 
 
 
 
 
 
1832
 
1833
  // PARSING
1834
 
1835
- addRegexToken('Z', matchShortOffset);
1836
- addRegexToken('ZZ', matchShortOffset);
1837
- addParseToken(['Z', 'ZZ'], function (input, array, config) {
1838
- config._useUTC = true;
1839
- config._tzm = offsetFromString(matchShortOffset, input);
1840
- });
1841
 
1842
- // HELPERS
 
 
 
 
 
1843
 
1844
- // timezone chunker
1845
- // '+10:00' > ['10', '00']
1846
- // '-1530' > ['-15', '30']
1847
- var chunkOffset = /([\+\-]|\d\d)/gi;
1848
 
1849
- function offsetFromString(matcher, string) {
1850
- var matches = ((string || '').match(matcher) || []);
1851
- var chunk = matches[matches.length - 1] || [];
1852
- var parts = (chunk + '').match(chunkOffset) || ['-', 0, 0];
1853
- var minutes = +(parts[1] * 60) + toInt(parts[2]);
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1854
 
1855
- return parts[0] === '+' ? minutes : -minutes;
 
 
 
 
 
1856
  }
1857
 
1858
- // Return a moment from input, that is local/utc/zone equivalent to model.
1859
- function cloneWithOffset(input, model) {
1860
- var res, diff;
1861
- if (model._isUTC) {
1862
- res = model.clone();
1863
- diff = (isMoment(input) || isDate(input) ? input.valueOf() : local__createLocal(input).valueOf()) - res.valueOf();
1864
- // Use low-level api, because this fn is low-level api.
1865
- res._d.setTime(res._d.valueOf() + diff);
1866
- utils_hooks__hooks.updateOffset(res, false);
1867
- return res;
1868
  } else {
1869
- return local__createLocal(input).local();
1870
  }
1871
  }
1872
 
1873
- function getDateOffset (m) {
1874
- // On Firefox.24 Date#getTimezoneOffset returns a floating point.
1875
- // https://github.com/moment/moment/pull/1871
1876
- return -Math.round(m._d.getTimezoneOffset() / 15) * 15;
1877
- }
1878
 
1879
- // HOOKS
1880
 
1881
- // This function will be called whenever a moment is mutated.
1882
- // It is intended to keep the offset in sync with the timezone.
1883
- utils_hooks__hooks.updateOffset = function () {};
 
 
1884
 
1885
- // MOMENTS
 
 
 
 
 
 
1886
 
1887
- // keepLocalTime = true means only change the timezone, without
1888
- // affecting the local hour. So 5:31:26 +0300 --[utcOffset(2, true)]-->
1889
- // 5:31:26 +0200 It is possible that 5:31:26 doesn't exist with offset
1890
- // +0200, so we adjust the time as needed, to be valid.
1891
- //
1892
- // Keeping the time actually adds/subtracts (one hour)
1893
- // from the actual represented time. That is why we call updateOffset
1894
- // a second time. In case it wants us to change the offset again
1895
- // _changeInProgress == true case, then we have to adjust, because
1896
- // there is no such time in the given timezone.
1897
- function getSetOffset (input, keepLocalTime) {
1898
- var offset = this._offset || 0,
1899
- localAdjust;
1900
- if (!this.isValid()) {
1901
- return input != null ? this : NaN;
1902
- }
1903
- if (input != null) {
1904
- if (typeof input === 'string') {
1905
- input = offsetFromString(matchShortOffset, input);
1906
- } else if (Math.abs(input) < 16) {
1907
- input = input * 60;
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1908
  }
1909
- if (!this._isUTC && keepLocalTime) {
1910
- localAdjust = getDateOffset(this);
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1911
  }
1912
- this._offset = input;
1913
- this._isUTC = true;
1914
- if (localAdjust != null) {
1915
- this.add(localAdjust, 'm');
1916
  }
1917
- if (offset !== input) {
1918
- if (!keepLocalTime || this._changeInProgress) {
1919
- add_subtract__addSubtract(this, create__createDuration(input - offset, 'm'), 1, false);
1920
- } else if (!this._changeInProgress) {
1921
- this._changeInProgress = true;
1922
- utils_hooks__hooks.updateOffset(this, true);
1923
- this._changeInProgress = null;
1924
- }
1925
  }
1926
- return this;
1927
- } else {
1928
- return this._isUTC ? offset : getDateOffset(this);
1929
  }
 
 
1930
  }
1931
 
1932
- function getSetZone (input, keepLocalTime) {
1933
- if (input != null) {
1934
- if (typeof input !== 'string') {
1935
- input = -input;
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1936
  }
 
1937
 
1938
- this.utcOffset(input, keepLocalTime);
 
1939
 
1940
- return this;
1941
  } else {
1942
- return -this.utcOffset();
 
 
1943
  }
1944
  }
1945
 
1946
- function setOffsetToUTC (keepLocalTime) {
1947
- return this.utcOffset(0, keepLocalTime);
1948
- }
1949
-
1950
- function setOffsetToLocal (keepLocalTime) {
1951
- if (this._isUTC) {
1952
- this.utcOffset(0, keepLocalTime);
1953
- this._isUTC = false;
 
 
 
1954
 
1955
- if (keepLocalTime) {
1956
- this.subtract(getDateOffset(this), 'm');
 
 
 
 
 
 
 
 
1957
  }
1958
  }
1959
- return this;
1960
  }
1961
 
1962
- function setOffsetToParsedOffset () {
1963
- if (this._tzm) {
1964
- this.utcOffset(this._tzm);
1965
- } else if (typeof this._i === 'string') {
1966
- this.utcOffset(offsetFromString(matchOffset, this._i));
 
1967
  }
1968
- return this;
1969
- }
1970
 
1971
- function hasAlignedHourOffset (input) {
1972
- if (!this.isValid()) {
1973
- return false;
1974
  }
1975
- input = input ? local__createLocal(input).utcOffset() : 0;
1976
 
1977
- return (this.utcOffset() - input) % 60 === 0;
 
 
 
 
 
 
 
 
 
1978
  }
1979
 
1980
- function isDaylightSavingTime () {
1981
- return (
1982
- this.utcOffset() > this.clone().month(0).utcOffset() ||
1983
- this.utcOffset() > this.clone().month(5).utcOffset()
1984
- );
1985
  }
1986
 
1987
- function isDaylightSavingTimeShifted () {
1988
- if (!isUndefined(this._isDSTShifted)) {
1989
- return this._isDSTShifted;
1990
- }
1991
 
1992
- var c = {};
 
 
 
 
 
 
 
 
1993
 
1994
- copyConfig(c, this);
1995
- c = prepareConfig(c);
 
 
 
 
 
 
 
1996
 
1997
- if (c._a) {
1998
- var other = c._isUTC ? create_utc__createUTC(c._a) : local__createLocal(c._a);
1999
- this._isDSTShifted = this.isValid() &&
2000
- compareArrays(c._a, other.toArray()) > 0;
2001
- } else {
2002
- this._isDSTShifted = false;
2003
  }
2004
 
2005
- return this._isDSTShifted;
2006
  }
2007
 
2008
- function isLocal () {
2009
- return this.isValid() ? !this._isUTC : false;
2010
- }
 
2011
 
2012
- function isUtcOffset () {
2013
- return this.isValid() ? this._isUTC : false;
2014
- }
2015
 
2016
- function isUtc () {
2017
- return this.isValid() ? this._isUTC && this._offset === 0 : false;
2018
- }
 
 
 
 
 
 
 
 
 
 
 
2019
 
2020
- // ASP.NET json date format regex
2021
- var aspNetRegex = /^(\-)?(?:(\d*)[. ])?(\d+)\:(\d+)(?:\:(\d+)\.?(\d{3})?\d*)?$/;
 
 
 
 
 
 
 
 
 
 
2022
 
2023
- // from http://docs.closure-library.googlecode.com/git/closure_goog_date_date.js.source.html
2024
- // somewhat more in line with 4.4.3.2 2004 spec, but allows decimal anywhere
2025
- // and further modified to allow for strings containing both week and day
2026
- var isoRegex = /^(-)?P(?:(-?[0-9,.]*)Y)?(?:(-?[0-9,.]*)M)?(?:(-?[0-9,.]*)W)?(?:(-?[0-9,.]*)D)?(?:T(?:(-?[0-9,.]*)H)?(?:(-?[0-9,.]*)M)?(?:(-?[0-9,.]*)S)?)?$/;
2027
 
2028
- function create__createDuration (input, key) {
2029
- var duration = input,
2030
- // matching against regexp is expensive, do it on demand
2031
- match = null,
2032
- sign,
2033
- ret,
2034
- diffRes;
2035
 
2036
- if (isDuration(input)) {
2037
- duration = {
2038
- ms : input._milliseconds,
2039
- d : input._days,
2040
- M : input._months
2041
- };
2042
- } else if (typeof input === 'number') {
2043
- duration = {};
2044
- if (key) {
2045
- duration[key] = input;
2046
- } else {
2047
- duration.milliseconds = input;
2048
- }
2049
- } else if (!!(match = aspNetRegex.exec(input))) {
2050
- sign = (match[1] === '-') ? -1 : 1;
2051
- duration = {
2052
- y : 0,
2053
- d : toInt(match[DATE]) * sign,
2054
- h : toInt(match[HOUR]) * sign,
2055
- m : toInt(match[MINUTE]) * sign,
2056
- s : toInt(match[SECOND]) * sign,
2057
- ms : toInt(match[MILLISECOND]) * sign
2058
- };
2059
- } else if (!!(match = isoRegex.exec(input))) {
2060
- sign = (match[1] === '-') ? -1 : 1;
2061
- duration = {
2062
- y : parseIso(match[2], sign),
2063
- M : parseIso(match[3], sign),
2064
- w : parseIso(match[4], sign),
2065
- d : parseIso(match[5], sign),
2066
- h : parseIso(match[6], sign),
2067
- m : parseIso(match[7], sign),
2068
- s : parseIso(match[8], sign)
2069
- };
2070
- } else if (duration == null) {// checks for null or undefined
2071
- duration = {};
2072
- } else if (typeof duration === 'object' && ('from' in duration || 'to' in duration)) {
2073
- diffRes = momentsDifference(local__createLocal(duration.from), local__createLocal(duration.to));
2074
 
2075
- duration = {};
2076
- duration.ms = diffRes.milliseconds;
2077
- duration.M = diffRes.months;
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
2078
  }
 
2079
 
2080
- ret = new Duration(duration);
 
 
2081
 
2082
- if (isDuration(input) && hasOwnProp(input, '_locale')) {
2083
- ret._locale = input._locale;
 
2084
  }
2085
 
2086
- return ret;
 
 
 
 
2087
  }
2088
 
2089
- create__createDuration.fn = Duration.prototype;
 
 
 
 
 
 
 
 
2090
 
2091
- function parseIso (inp, sign) {
2092
- // We'd normally use ~~inp for this, but unfortunately it also
2093
- // converts floats to ints.
2094
- // inp may be undefined, so careful calling replace on it.
2095
- var res = inp && parseFloat(inp.replace(',', '.'));
2096
- // apply sign while we're at it
2097
- return (isNaN(res) ? 0 : res) * sign;
 
 
2098
  }
2099
 
2100
- function positiveMomentsDifference(base, other) {
2101
- var res = {milliseconds: 0, months: 0};
2102
-
2103
- res.months = other.month() - base.month() +
2104
- (other.year() - base.year()) * 12;
2105
- if (base.clone().add(res.months, 'M').isAfter(other)) {
2106
- --res.months;
2107
  }
2108
-
2109
- res.milliseconds = +other - +(base.clone().add(res.months, 'M'));
2110
-
2111
- return res;
2112
  }
2113
 
2114
- function momentsDifference(base, other) {
2115
- var res;
2116
- if (!(base.isValid() && other.isValid())) {
2117
- return {milliseconds: 0, months: 0};
2118
- }
 
2119
 
2120
- other = cloneWithOffset(other, base);
2121
- if (base.isBefore(other)) {
2122
- res = positiveMomentsDifference(base, other);
2123
- } else {
2124
- res = positiveMomentsDifference(other, base);
2125
- res.milliseconds = -res.milliseconds;
2126
- res.months = -res.months;
2127
  }
2128
 
2129
- return res;
2130
- }
2131
 
2132
- function absRound (number) {
2133
- if (number < 0) {
2134
- return Math.round(-1 * number) * -1;
2135
- } else {
2136
- return Math.round(number);
2137
  }
2138
- }
2139
 
2140
- // TODO: remove 'name' arg after deprecation is removed
2141
- function createAdder(direction, name) {
2142
- return function (val, period) {
2143
- var dur, tmp;
2144
- //invert the arguments, but complain about it
2145
- if (period !== null && !isNaN(+period)) {
2146
- deprecateSimple(name, 'moment().' + name + '(period, number) is deprecated. Please use moment().' + name + '(number, period).');
2147
- tmp = val; val = period; period = tmp;
2148
- }
2149
 
2150
- val = typeof val === 'string' ? +val : val;
2151
- dur = create__createDuration(val, period);
2152
- add_subtract__addSubtract(this, dur, direction);
2153
- return this;
2154
- };
2155
- }
2156
 
2157
- function add_subtract__addSubtract (mom, duration, isAdding, updateOffset) {
2158
- var milliseconds = duration._milliseconds,
2159
- days = absRound(duration._days),
2160
- months = absRound(duration._months);
2161
 
2162
- if (!mom.isValid()) {
2163
- // No op
2164
- return;
 
 
 
 
2165
  }
2166
 
2167
- updateOffset = updateOffset == null ? true : updateOffset;
 
 
 
2168
 
2169
- if (milliseconds) {
2170
- mom._d.setTime(mom._d.valueOf() + milliseconds * isAdding);
 
 
 
 
 
2171
  }
2172
- if (days) {
2173
- get_set__set(mom, 'Date', get_set__get(mom, 'Date') + days * isAdding);
2174
- }
2175
- if (months) {
2176
- setMonth(mom, get_set__get(mom, 'Month') + months * isAdding);
 
2177
  }
2178
- if (updateOffset) {
2179
- utils_hooks__hooks.updateOffset(mom, days || months);
 
2180
  }
2181
  }
2182
 
2183
- var add_subtract__add = createAdder(1, 'add');
2184
- var add_subtract__subtract = createAdder(-1, 'subtract');
2185
-
2186
- function moment_calendar__calendar (time, formats) {
2187
- // We want to compare the start of today, vs this.
2188
- // Getting start-of-today depends on whether we're local/utc/offset or not.
2189
- var now = time || local__createLocal(),
2190
- sod = cloneWithOffset(now, this).startOf('day'),
2191
- diff = this.diff(sod, 'days', true),
2192
- format = diff < -6 ? 'sameElse' :
2193
- diff < -1 ? 'lastWeek' :
2194
- diff < 0 ? 'lastDay' :
2195
- diff < 1 ? 'sameDay' :
2196
- diff < 2 ? 'nextDay' :
2197
- diff < 7 ? 'nextWeek' : 'sameElse';
2198
-
2199
- var output = formats && (isFunction(formats[format]) ? formats[format]() : formats[format]);
2200
-
2201
- return this.format(output || this.localeData().calendar(format, this, local__createLocal(now)));
2202
- }
2203
 
2204
- function clone () {
2205
- return new Moment(this);
2206
- }
 
2207
 
2208
- function isAfter (input, units) {
2209
- var localInput = isMoment(input) ? input : local__createLocal(input);
2210
- if (!(this.isValid() && localInput.isValid())) {
2211
- return false;
2212
- }
2213
- units = normalizeUnits(!isUndefined(units) ? units : 'millisecond');
2214
- if (units === 'millisecond') {
2215
- return this.valueOf() > localInput.valueOf();
 
 
2216
  } else {
2217
- return localInput.valueOf() < this.clone().startOf(units).valueOf();
2218
- }
2219
- }
2220
 
2221
- function isBefore (input, units) {
2222
- var localInput = isMoment(input) ? input : local__createLocal(input);
2223
- if (!(this.isValid() && localInput.isValid())) {
2224
- return false;
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
2225
  }
2226
- units = normalizeUnits(!isUndefined(units) ? units : 'millisecond');
2227
- if (units === 'millisecond') {
2228
- return this.valueOf() < localInput.valueOf();
 
2229
  } else {
2230
- return this.clone().endOf(units).valueOf() < localInput.valueOf();
 
 
2231
  }
2232
  }
2233
 
2234
- function isBetween (from, to, units, inclusivity) {
2235
- inclusivity = inclusivity || '()';
2236
- return (inclusivity[0] === '(' ? this.isAfter(from, units) : !this.isBefore(from, units)) &&
2237
- (inclusivity[1] === ')' ? this.isBefore(to, units) : !this.isAfter(to, units));
2238
- }
2239
 
2240
- function isSame (input, units) {
2241
- var localInput = isMoment(input) ? input : local__createLocal(input),
2242
- inputMs;
2243
- if (!(this.isValid() && localInput.isValid())) {
2244
- return false;
2245
- }
2246
- units = normalizeUnits(units || 'millisecond');
2247
- if (units === 'millisecond') {
2248
- return this.valueOf() === localInput.valueOf();
2249
- } else {
2250
- inputMs = localInput.valueOf();
2251
- return this.clone().startOf(units).valueOf() <= inputMs && inputMs <= this.clone().endOf(units).valueOf();
2252
  }
2253
- }
2254
 
2255
- function isSameOrAfter (input, units) {
2256
- return this.isSame(input, units) || this.isAfter(input,units);
2257
- }
2258
 
2259
- function isSameOrBefore (input, units) {
2260
- return this.isSame(input, units) || this.isBefore(input,units);
2261
- }
 
 
2262
 
2263
- function diff (input, units, asFloat) {
2264
- var that,
2265
- zoneDelta,
2266
- delta, output;
2267
 
2268
- if (!this.isValid()) {
2269
- return NaN;
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
2270
  }
2271
 
2272
- that = cloneWithOffset(input, this);
2273
-
2274
- if (!that.isValid()) {
2275
- return NaN;
2276
  }
2277
 
2278
- zoneDelta = (that.utcOffset() - this.utcOffset()) * 6e4;
 
 
 
 
 
2279
 
2280
- units = normalizeUnits(units);
 
 
 
2281
 
2282
- if (units === 'year' || units === 'month' || units === 'quarter') {
2283
- output = monthDiff(this, that);
2284
- if (units === 'quarter') {
2285
- output = output / 3;
2286
- } else if (units === 'year') {
2287
- output = output / 12;
2288
- }
2289
- } else {
2290
- delta = this - that;
2291
- output = units === 'second' ? delta / 1e3 : // 1000
2292
- units === 'minute' ? delta / 6e4 : // 1000 * 60
2293
- units === 'hour' ? delta / 36e5 : // 1000 * 60 * 60
2294
- units === 'day' ? (delta - zoneDelta) / 864e5 : // 1000 * 60 * 60 * 24, negate dst
2295
- units === 'week' ? (delta - zoneDelta) / 6048e5 : // 1000 * 60 * 60 * 24 * 7, negate dst
2296
- delta;
2297
- }
2298
- return asFloat ? output : absFloor(output);
2299
  }
2300
 
2301
- function monthDiff (a, b) {
2302
- // difference in months
2303
- var wholeMonthDiff = ((b.year() - a.year()) * 12) + (b.month() - a.month()),
2304
- // b is in (anchor - 1 month, anchor + 1 month)
2305
- anchor = a.clone().add(wholeMonthDiff, 'months'),
2306
- anchor2, adjust;
2307
 
2308
- if (b - anchor < 0) {
2309
- anchor2 = a.clone().add(wholeMonthDiff - 1, 'months');
2310
- // linear across the month
2311
- adjust = (b - anchor) / (anchor - anchor2);
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
2312
  } else {
2313
- anchor2 = a.clone().add(wholeMonthDiff + 1, 'months');
2314
- // linear across the month
2315
- adjust = (b - anchor) / (anchor2 - anchor);
2316
  }
2317
-
2318
- //check for negative zero, return zero if negative zero
2319
- return -(wholeMonthDiff + adjust) || 0;
2320
  }
2321
 
2322
- utils_hooks__hooks.defaultFormat = 'YYYY-MM-DDTHH:mm:ssZ';
2323
- utils_hooks__hooks.defaultFormatUtc = 'YYYY-MM-DDTHH:mm:ss[Z]';
 
 
2324
 
2325
- function toString () {
2326
- return this.clone().locale('en').format('ddd MMM DD YYYY HH:mm:ss [GMT]ZZ');
2327
- }
2328
 
2329
- function moment_format__toISOString () {
2330
- var m = this.clone().utc();
2331
- if (0 < m.year() && m.year() <= 9999) {
2332
- if (isFunction(Date.prototype.toISOString)) {
2333
- // native implementation is ~50x faster, use it when we can
2334
- return this.toDate().toISOString();
2335
- } else {
2336
- return formatMoment(m, 'YYYY-MM-DD[T]HH:mm:ss.SSS[Z]');
2337
- }
2338
- } else {
2339
- return formatMoment(m, 'YYYYYY-MM-DD[T]HH:mm:ss.SSS[Z]');
2340
  }
2341
- }
2342
 
2343
- function format (inputString) {
2344
- if (!inputString) {
2345
- inputString = this.isUtc() ? utils_hooks__hooks.defaultFormatUtc : utils_hooks__hooks.defaultFormat;
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
2346
  }
2347
- var output = formatMoment(this, inputString);
2348
- return this.localeData().postformat(output);
2349
  }
2350
 
2351
- function from (time, withoutSuffix) {
2352
- if (this.isValid() &&
2353
- ((isMoment(time) && time.isValid()) ||
2354
- local__createLocal(time).isValid())) {
2355
- return create__createDuration({to: this, from: time}).locale(this.locale()).humanize(!withoutSuffix);
2356
- } else {
2357
- return this.localeData().invalidDate();
2358
  }
2359
- }
2360
 
2361
- function fromNow (withoutSuffix) {
2362
- return this.from(local__createLocal(), withoutSuffix);
 
 
 
 
2363
  }
2364
 
2365
- function to (time, withoutSuffix) {
2366
- if (this.isValid() &&
2367
- ((isMoment(time) && time.isValid()) ||
2368
- local__createLocal(time).isValid())) {
2369
- return create__createDuration({from: this, to: time}).locale(this.locale()).humanize(!withoutSuffix);
2370
- } else {
2371
- return this.localeData().invalidDate();
2372
  }
2373
- }
2374
 
2375
- function toNow (withoutSuffix) {
2376
- return this.to(local__createLocal(), withoutSuffix);
2377
  }
2378
 
2379
- // If passed a locale key, it will set the locale for this
2380
- // instance. Otherwise, it will return the locale configuration
2381
- // variables for this instance.
2382
- function locale (key) {
2383
- var newLocaleData;
2384
 
2385
- if (key === undefined) {
2386
- return this._locale._abbr;
2387
- } else {
2388
- newLocaleData = locale_locales__getLocale(key);
2389
- if (newLocaleData != null) {
2390
- this._locale = newLocaleData;
2391
- }
2392
- return this;
2393
  }
2394
- }
2395
 
2396
- var lang = deprecate(
2397
- 'moment().lang() is deprecated. Instead, use moment().localeData() to get the language configuration. Use moment().locale() to change languages.',
2398
- function (key) {
2399
- if (key === undefined) {
2400
- return this.localeData();
2401
- } else {
2402
- return this.locale(key);
2403
- }
2404
  }
2405
- );
2406
 
2407
- function localeData () {
2408
- return this._locale;
2409
- }
 
 
 
 
 
 
 
 
2410
 
2411
- function startOf (units) {
2412
- units = normalizeUnits(units);
2413
- // the following switch intentionally omits break keywords
2414
- // to utilize falling through the cases.
2415
- switch (units) {
2416
- case 'year':
2417
- this.month(0);
2418
- /* falls through */
2419
- case 'quarter':
2420
- case 'month':
2421
- this.date(1);
2422
- /* falls through */
2423
- case 'week':
2424
- case 'isoWeek':
2425
- case 'day':
2426
- case 'date':
2427
- this.hours(0);
2428
- /* falls through */
2429
- case 'hour':
2430
- this.minutes(0);
2431
- /* falls through */
2432
- case 'minute':
2433
- this.seconds(0);
2434
- /* falls through */
2435
- case 'second':
2436
- this.milliseconds(0);
2437
  }
2438
 
2439
- // weeks are a special case
2440
- if (units === 'week') {
2441
- this.weekday(0);
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
2442
  }
2443
- if (units === 'isoWeek') {
2444
- this.isoWeekday(1);
 
 
 
 
 
 
2445
  }
2446
 
2447
- // quarters are also special
2448
- if (units === 'quarter') {
2449
- this.month(Math.floor(this.month() / 3) * 3);
2450
  }
 
 
 
 
 
 
 
 
2451
 
2452
- return this;
2453
  }
2454
 
2455
- function endOf (units) {
2456
- units = normalizeUnits(units);
2457
- if (units === undefined || units === 'millisecond') {
2458
- return this;
 
 
 
 
 
 
 
 
 
2459
  }
 
2460
 
2461
- // 'date' is an alias for 'day', so it should be considered as such.
2462
- if (units === 'date') {
2463
- units = 'day';
 
 
 
 
 
 
2464
  }
 
2465
 
2466
- return this.startOf(units).add(1, (units === 'isoWeek' ? 'week' : units)).subtract(1, 'ms');
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
2467
  }
2468
 
2469
- function to_type__valueOf () {
2470
- return this._d.valueOf() - ((this._offset || 0) * 60000);
2471
- }
2472
 
2473
- function unix () {
2474
- return Math.floor(this.valueOf() / 1000);
2475
  }
2476
 
2477
- function toDate () {
2478
- return this._offset ? new Date(this.valueOf()) : this._d;
2479
- }
2480
 
2481
- function toArray () {
2482
- var m = this;
2483
- return [m.year(), m.month(), m.date(), m.hour(), m.minute(), m.second(), m.millisecond()];
2484
  }
2485
 
2486
- function toObject () {
2487
- var m = this;
2488
- return {
2489
- years: m.year(),
2490
- months: m.month(),
2491
- date: m.date(),
2492
- hours: m.hours(),
2493
- minutes: m.minutes(),
2494
- seconds: m.seconds(),
2495
- milliseconds: m.milliseconds()
2496
- };
2497
- }
2498
 
2499
- function toJSON () {
2500
- // new Date(NaN).toJSON() === null
2501
- return this.isValid() ? this.toISOString() : null;
2502
- }
 
 
 
 
 
 
 
2503
 
2504
- function moment_valid__isValid () {
2505
- return valid__isValid(this);
2506
- }
 
 
 
 
 
 
 
 
 
 
 
 
2507
 
2508
- function parsingFlags () {
2509
- return extend({}, getParsingFlags(this));
2510
- }
2511
 
2512
- function invalidAt () {
2513
- return getParsingFlags(this).overflow;
 
2514
  }
2515
 
2516
- function creationData() {
2517
- return {
2518
- input: this._i,
2519
- format: this._f,
2520
- locale: this._locale,
2521
- isUTC: this._isUTC,
2522
- strict: this._strict
2523
- };
2524
  }
2525
 
2526
  // FORMATTING
2527
 
2528
- addFormatToken(0, ['gg', 2], 0, function () {
2529
- return this.weekYear() % 100;
2530
- });
2531
-
2532
- addFormatToken(0, ['GG', 2], 0, function () {
2533
- return this.isoWeekYear() % 100;
2534
- });
2535
-
2536
- function addWeekYearFormatToken (token, getter) {
2537
- addFormatToken(0, [token, token.length], 0, getter);
2538
  }
2539
 
2540
- addWeekYearFormatToken('gggg', 'weekYear');
2541
- addWeekYearFormatToken('ggggg', 'weekYear');
2542
- addWeekYearFormatToken('GGGG', 'isoWeekYear');
2543
- addWeekYearFormatToken('GGGGG', 'isoWeekYear');
2544
-
2545
- // ALIASES
2546
-
2547
- addUnitAlias('weekYear', 'gg');
2548
- addUnitAlias('isoWeekYear', 'GG');
2549
 
2550
  // PARSING
2551
 
2552
- addRegexToken('G', matchSigned);
2553
- addRegexToken('g', matchSigned);
2554
- addRegexToken('GG', match1to2, match2);
2555
- addRegexToken('gg', match1to2, match2);
2556
- addRegexToken('GGGG', match1to4, match4);
2557
- addRegexToken('gggg', match1to4, match4);
2558
- addRegexToken('GGGGG', match1to6, match6);
2559
- addRegexToken('ggggg', match1to6, match6);
2560
-
2561
- addWeekParseToken(['gggg', 'ggggg', 'GGGG', 'GGGGG'], function (input, week, config, token) {
2562
- week[token.substr(0, 2)] = toInt(input);
2563
- });
2564
-
2565
- addWeekParseToken(['gg', 'GG'], function (input, week, config, token) {
2566
- week[token] = utils_hooks__hooks.parseTwoDigitYear(input);
2567
  });
2568
 
2569
- // MOMENTS
2570
-
2571
- function getSetWeekYear (input) {
2572
- return getSetWeekYearHelper.call(this,
2573
- input,
2574
- this.week(),
2575
- this.weekday(),
2576
- this.localeData()._week.dow,
2577
- this.localeData()._week.doy);
2578
- }
2579
 
2580
- function getSetISOWeekYear (input) {
2581
- return getSetWeekYearHelper.call(this,
2582
- input, this.isoWeek(), this.isoWeekday(), 1, 4);
2583
- }
2584
 
2585
- function getISOWeeksInYear () {
2586
- return weeksInYear(this.year(), 1, 4);
2587
- }
 
 
2588
 
2589
- function getWeeksInYear () {
2590
- var weekInfo = this.localeData()._week;
2591
- return weeksInYear(this.year(), weekInfo.dow, weekInfo.doy);
2592
  }
2593
 
2594
- function getSetWeekYearHelper(input, week, weekday, dow, doy) {
2595
- var weeksTarget;
2596
- if (input == null) {
2597
- return weekOfYear(this, dow, doy).year;
 
 
 
 
 
 
2598
  } else {
2599
- weeksTarget = weeksInYear(input, dow, doy);
2600
- if (week > weeksTarget) {
2601
- week = weeksTarget;
2602
- }
2603
- return setWeekAll.call(this, input, week, weekday, dow, doy);
2604
  }
2605
  }
2606
 
2607
- function setWeekAll(weekYear, week, weekday, dow, doy) {
2608
- var dayOfYearData = dayOfYearFromWeeks(weekYear, week, weekday, dow, doy),
2609
- date = createUTCDate(dayOfYearData.year, 0, dayOfYearData.dayOfYear);
2610
-
2611
- this.year(date.getUTCFullYear());
2612
- this.month(date.getUTCMonth());
2613
- this.date(date.getUTCDate());
2614
- return this;
2615
  }
2616
 
2617
- // FORMATTING
2618
 
2619
- addFormatToken('Q', 0, 'Qo', 'quarter');
 
 
2620
 
2621
- // ALIASES
2622
 
2623
- addUnitAlias('quarter', 'Q');
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
2624
 
2625
- // PARSING
 
 
 
 
2626
 
2627
- addRegexToken('Q', match1);
2628
- addParseToken('Q', function (input, array) {
2629
- array[MONTH] = (toInt(input) - 1) * 3;
2630
- });
2631
 
2632
- // MOMENTS
 
 
 
 
2633
 
2634
- function getSetQuarter (input) {
2635
- return input == null ? Math.ceil((this.month() + 1) / 3) : this.month((input - 1) * 3 + this.month() % 3);
2636
  }
2637
 
2638
- // FORMATTING
 
 
 
2639
 
2640
- addFormatToken('w', ['ww', 2], 'wo', 'week');
2641
- addFormatToken('W', ['WW', 2], 'Wo', 'isoWeek');
2642
-
2643
- // ALIASES
2644
-
2645
- addUnitAlias('week', 'w');
2646
- addUnitAlias('isoWeek', 'W');
2647
-
2648
- // PARSING
2649
-
2650
- addRegexToken('w', match1to2);
2651
- addRegexToken('ww', match1to2, match2);
2652
- addRegexToken('W', match1to2);
2653
- addRegexToken('WW', match1to2, match2);
2654
-
2655
- addWeekParseToken(['w', 'ww', 'W', 'WW'], function (input, week, config, token) {
2656
- week[token.substr(0, 1)] = toInt(input);
2657
- });
2658
-
2659
- // HELPERS
2660
-
2661
- // LOCALES
2662
-
2663
- function localeWeek (mom) {
2664
- return weekOfYear(mom, this._week.dow, this._week.doy).week;
2665
- }
2666
-
2667
- var defaultLocaleWeek = {
2668
- dow : 0, // Sunday is the first day of the week.
2669
- doy : 6 // The week that contains Jan 1st is the first week of the year.
2670
- };
2671
-
2672
- function localeFirstDayOfWeek () {
2673
- return this._week.dow;
2674
  }
2675
 
2676
- function localeFirstDayOfYear () {
2677
- return this._week.doy;
 
 
 
 
 
2678
  }
2679
 
2680
- // MOMENTS
 
 
 
 
2681
 
2682
- function getSetWeek (input) {
2683
- var week = this.localeData().week(this);
2684
- return input == null ? week : this.add((input - week) * 7, 'd');
2685
  }
2686
 
2687
- function getSetISOWeek (input) {
2688
- var week = weekOfYear(this, 1, 4).week;
2689
- return input == null ? week : this.add((input - week) * 7, 'd');
 
 
2690
  }
2691
 
2692
- // FORMATTING
 
 
 
2693
 
2694
- addFormatToken('D', ['DD', 2], 'Do', 'date');
2695
 
2696
- // ALIASES
 
2697
 
2698
- addUnitAlias('date', 'D');
 
 
 
 
 
 
2699
 
2700
- // PARSING
 
2701
 
2702
- addRegexToken('D', match1to2);
2703
- addRegexToken('DD', match1to2, match2);
2704
- addRegexToken('Do', function (isStrict, locale) {
2705
- return isStrict ? locale._ordinalParse : locale._ordinalParseLenient;
2706
- });
2707
 
2708
- addParseToken(['D', 'DD'], DATE);
2709
- addParseToken('Do', function (input, array) {
2710
- array[DATE] = toInt(input.match(match1to2)[0], 10);
2711
- });
2712
 
2713
- // MOMENTS
 
 
2714
 
2715
- var getSetDayOfMonth = makeGetSet('Date', true);
 
2716
 
2717
- // FORMATTING
 
 
 
2718
 
2719
- addFormatToken('d', 0, 'do', 'day');
 
 
 
 
 
 
2720
 
2721
- addFormatToken('dd', 0, 0, function (format) {
2722
- return this.localeData().weekdaysMin(this, format);
2723
- });
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
2724
 
2725
- addFormatToken('ddd', 0, 0, function (format) {
2726
- return this.localeData().weekdaysShort(this, format);
2727
- });
 
2728
 
2729
- addFormatToken('dddd', 0, 0, function (format) {
2730
- return this.localeData().weekdays(this, format);
2731
- });
2732
 
2733
- addFormatToken('e', 0, 0, 'weekday');
2734
- addFormatToken('E', 0, 0, 'isoWeekday');
 
2735
 
2736
- // ALIASES
 
2737
 
2738
- addUnitAlias('day', 'd');
2739
- addUnitAlias('weekday', 'e');
2740
- addUnitAlias('isoWeekday', 'E');
2741
 
2742
- // PARSING
 
 
 
 
 
 
 
2743
 
2744
- addRegexToken('d', match1to2);
2745
- addRegexToken('e', match1to2);
2746
- addRegexToken('E', match1to2);
2747
- addRegexToken('dd', function (isStrict, locale) {
2748
- return locale.weekdaysMinRegex(isStrict);
2749
- });
2750
- addRegexToken('ddd', function (isStrict, locale) {
2751
- return locale.weekdaysShortRegex(isStrict);
2752
- });
2753
- addRegexToken('dddd', function (isStrict, locale) {
2754
- return locale.weekdaysRegex(isStrict);
2755
- });
2756
 
2757
- addWeekParseToken(['dd', 'ddd', 'dddd'], function (input, week, config, token) {
2758
- var weekday = config._locale.weekdaysParse(input, token, config._strict);
2759
- // if we didn't get a weekday name, mark the date as invalid
2760
- if (weekday != null) {
2761
- week.d = weekday;
2762
- } else {
2763
- getParsingFlags(config).invalidWeekday = input;
2764
  }
2765
- });
2766
 
2767
- addWeekParseToken(['d', 'e', 'E'], function (input, week, config, token) {
2768
- week[token] = toInt(input);
2769
- });
2770
 
2771
- // HELPERS
 
2772
 
2773
- function parseWeekday(input, locale) {
2774
- if (typeof input !== 'string') {
2775
- return input;
 
2776
  }
2777
 
2778
- if (!isNaN(input)) {
2779
- return parseInt(input, 10);
 
 
 
 
 
2780
  }
2781
 
2782
- input = locale.weekdaysParse(input);
2783
- if (typeof input === 'number') {
2784
- return input;
2785
- }
2786
 
2787
- return null;
 
 
 
 
 
2788
  }
2789
 
2790
- // LOCALES
 
 
 
 
 
 
 
 
 
2791
 
2792
- var defaultLocaleWeekdays = 'Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday'.split('_');
2793
- function localeWeekdays (m, format) {
2794
- return isArray(this._weekdays) ? this._weekdays[m.day()] :
2795
- this._weekdays[this._weekdays.isFormat.test(format) ? 'format' : 'standalone'][m.day()];
 
2796
  }
2797
 
2798
- var defaultLocaleWeekdaysShort = 'Sun_Mon_Tue_Wed_Thu_Fri_Sat'.split('_');
2799
- function localeWeekdaysShort (m) {
2800
- return this._weekdaysShort[m.day()];
2801
- }
2802
 
2803
- var defaultLocaleWeekdaysMin = 'Su_Mo_Tu_We_Th_Fr_Sa'.split('_');
2804
- function localeWeekdaysMin (m) {
2805
- return this._weekdaysMin[m.day()];
2806
- }
2807
 
2808
- function day_of_week__handleStrictParse(weekdayName, format, strict) {
2809
- var i, ii, mom, llc = weekdayName.toLocaleLowerCase();
2810
- if (!this._weekdaysParse) {
2811
- this._weekdaysParse = [];
2812
- this._shortWeekdaysParse = [];
2813
- this._minWeekdaysParse = [];
2814
 
2815
- for (i = 0; i < 7; ++i) {
2816
- mom = create_utc__createUTC([2000, 1]).day(i);
2817
- this._minWeekdaysParse[i] = this.weekdaysMin(mom, '').toLocaleLowerCase();
2818
- this._shortWeekdaysParse[i] = this.weekdaysShort(mom, '').toLocaleLowerCase();
2819
- this._weekdaysParse[i] = this.weekdays(mom, '').toLocaleLowerCase();
2820
- }
2821
  }
2822
-
2823
- if (strict) {
2824
- if (format === 'dddd') {
2825
- ii = indexOf.call(this._weekdaysParse, llc);
2826
- return ii !== -1 ? ii : null;
2827
- } else if (format === 'ddd') {
2828
- ii = indexOf.call(this._shortWeekdaysParse, llc);
2829
- return ii !== -1 ? ii : null;
2830
- } else {
2831
- ii = indexOf.call(this._minWeekdaysParse, llc);
2832
- return ii !== -1 ? ii : null;
2833
- }
2834
- } else {
2835
- if (format === 'dddd') {
2836
- ii = indexOf.call(this._weekdaysParse, llc);
2837
- if (ii !== -1) {
2838
- return ii;
2839
- }
2840
- ii = indexOf.call(this._shortWeekdaysParse, llc);
2841
- if (ii !== -1) {
2842
- return ii;
2843
- }
2844
- ii = indexOf.call(this._minWeekdaysParse, llc);
2845
- return ii !== -1 ? ii : null;
2846
- } else if (format === 'ddd') {
2847
- ii = indexOf.call(this._shortWeekdaysParse, llc);
2848
- if (ii !== -1) {
2849
- return ii;
2850
- }
2851
- ii = indexOf.call(this._weekdaysParse, llc);
2852
- if (ii !== -1) {
2853
- return ii;
2854
- }
2855
- ii = indexOf.call(this._minWeekdaysParse, llc);
2856
- return ii !== -1 ? ii : null;
2857
- } else {
2858
- ii = indexOf.call(this._minWeekdaysParse, llc);
2859
- if (ii !== -1) {
2860
- return ii;
2861
- }
2862
- ii = indexOf.call(this._weekdaysParse, llc);
2863
- if (ii !== -1) {
2864
- return ii;
2865
- }
2866
- ii = indexOf.call(this._shortWeekdaysParse, llc);
2867
- return ii !== -1 ? ii : null;
2868
- }
2869
  }
2870
  }
2871
 
2872
- function localeWeekdaysParse (weekdayName, format, strict) {
2873
- var i, mom, regex;
2874
 
2875
- if (this._weekdaysParseExact) {
2876
- return day_of_week__handleStrictParse.call(this, weekdayName, format, strict);
2877
- }
 
 
 
 
 
 
2878
 
2879
- if (!this._weekdaysParse) {
2880
- this._weekdaysParse = [];
2881
- this._minWeekdaysParse = [];
2882
- this._shortWeekdaysParse = [];
2883
- this._fullWeekdaysParse = [];
2884
- }
2885
 
2886
- for (i = 0; i < 7; i++) {
2887
- // make the regex if we don't have it already
2888
 
2889
- mom = create_utc__createUTC([2000, 1]).day(i);
2890
- if (strict && !this._fullWeekdaysParse[i]) {
2891
- this._fullWeekdaysParse[i] = new RegExp('^' + this.weekdays(mom, '').replace('.', '\.?') + '$', 'i');
2892
- this._shortWeekdaysParse[i] = new RegExp('^' + this.weekdaysShort(mom, '').replace('.', '\.?') + '$', 'i');
2893
- this._minWeekdaysParse[i] = new RegExp('^' + this.weekdaysMin(mom, '').replace('.', '\.?') + '$', 'i');
2894
- }
2895
- if (!this._weekdaysParse[i]) {
2896
- regex = '^' + this.weekdays(mom, '') + '|^' + this.weekdaysShort(mom, '') + '|^' + this.weekdaysMin(mom, '');
2897
- this._weekdaysParse[i] = new RegExp(regex.replace('.', ''), 'i');
2898
- }
2899
- // test the regex
2900
- if (strict && format === 'dddd' && this._fullWeekdaysParse[i].test(weekdayName)) {
2901
- return i;
2902
- } else if (strict && format === 'ddd' && this._shortWeekdaysParse[i].test(weekdayName)) {
2903
- return i;
2904
- } else if (strict && format === 'dd' && this._minWeekdaysParse[i].test(weekdayName)) {
2905
- return i;
2906
- } else if (!strict && this._weekdaysParse[i].test(weekdayName)) {
2907
- return i;
2908
- }
2909
- }
2910
  }
2911
 
2912
- // MOMENTS
 
 
2913
 
2914
- function getSetDayOfWeek (input) {
2915
- if (!this.isValid()) {
2916
- return input != null ? this : NaN;
 
2917
  }
2918
- var day = this._isUTC ? this._d.getUTCDay() : this._d.getDay();
2919
- if (input != null) {
2920
- input = parseWeekday(input, this.localeData());
2921
- return this.add(input - day, 'd');
2922
  } else {
2923
- return day;
2924
  }
2925
  }
2926
 
2927
- function getSetLocaleDayOfWeek (input) {
2928
- if (!this.isValid()) {
2929
- return input != null ? this : NaN;
 
 
 
 
 
 
 
2930
  }
2931
- var weekday = (this.day() + 7 - this.localeData()._week.dow) % 7;
2932
- return input == null ? weekday : this.add(input - weekday, 'd');
2933
  }
2934
 
2935
- function getSetISODayOfWeek (input) {
2936
- if (!this.isValid()) {
2937
- return input != null ? this : NaN;
2938
- }
2939
- // behaves the same as moment#day except
2940
- // as a getter, returns 7 instead of 0 (1-7 range instead of 0-6)
2941
- // as a setter, sunday should belong to the previous week.
2942
- return input == null ? this.day() || 7 : this.day(this.day() % 7 ? input : input - 7);
2943
  }
2944
 
2945
- var defaultWeekdaysRegex = matchWord;
2946
- function weekdaysRegex (isStrict) {
2947
- if (this._weekdaysParseExact) {
2948
- if (!hasOwnProp(this, '_weekdaysRegex')) {
2949
- computeWeekdaysParse.call(this);
2950
- }
2951
- if (isStrict) {
2952
- return this._weekdaysStrictRegex;
2953
- } else {
2954
- return this._weekdaysRegex;
2955
- }
2956
  } else {
2957
- return this._weekdaysStrictRegex && isStrict ?
2958
- this._weekdaysStrictRegex : this._weekdaysRegex;
2959
  }
2960
  }
2961
 
2962
- var defaultWeekdaysShortRegex = matchWord;
2963
- function weekdaysShortRegex (isStrict) {
2964
- if (this._weekdaysParseExact) {
2965
- if (!hasOwnProp(this, '_weekdaysRegex')) {
2966
- computeWeekdaysParse.call(this);
2967
- }
2968
- if (isStrict) {
2969
- return this._weekdaysShortStrictRegex;
2970
- } else {
2971
- return this._weekdaysShortRegex;
2972
- }
2973
- } else {
2974
- return this._weekdaysShortStrictRegex && isStrict ?
2975
- this._weekdaysShortStrictRegex : this._weekdaysShortRegex;
2976
- }
2977
  }
2978
 
2979
- var defaultWeekdaysMinRegex = matchWord;
2980
- function weekdaysMinRegex (isStrict) {
2981
- if (this._weekdaysParseExact) {
2982
- if (!hasOwnProp(this, '_weekdaysRegex')) {
2983
- computeWeekdaysParse.call(this);
2984
- }
2985
- if (isStrict) {
2986
- return this._weekdaysMinStrictRegex;
2987
- } else {
2988
- return this._weekdaysMinRegex;
2989
- }
2990
- } else {
2991
- return this._weekdaysMinStrictRegex && isStrict ?
2992
- this._weekdaysMinStrictRegex : this._weekdaysMinRegex;
2993
- }
2994
  }
2995
 
 
 
 
 
2996
 
2997
- function computeWeekdaysParse () {
2998
- function cmpLenRev(a, b) {
2999
- return b.length - a.length;
3000
  }
3001
 
3002
- var minPieces = [], shortPieces = [], longPieces = [], mixedPieces = [],
3003
- i, mom, minp, shortp, longp;
3004
- for (i = 0; i < 7; i++) {
3005
- // make the regex if we don't have it already
3006
- mom = create_utc__createUTC([2000, 1]).day(i);
3007
- minp = this.weekdaysMin(mom, '');
3008
- shortp = this.weekdaysShort(mom, '');
3009
- longp = this.weekdays(mom, '');
3010
- minPieces.push(minp);
3011
- shortPieces.push(shortp);
3012
- longPieces.push(longp);
3013
- mixedPieces.push(minp);
3014
- mixedPieces.push(shortp);
3015
- mixedPieces.push(longp);
3016
  }
3017
- // Sorting makes sure if one weekday (or abbr) is a prefix of another it
3018
- // will match the longer piece.
3019
- minPieces.sort(cmpLenRev);
3020
- shortPieces.sort(cmpLenRev);
3021
- longPieces.sort(cmpLenRev);
3022
- mixedPieces.sort(cmpLenRev);
3023
- for (i = 0; i < 7; i++) {
3024
- shortPieces[i] = regexEscape(shortPieces[i]);
3025
- longPieces[i] = regexEscape(longPieces[i]);
3026
- mixedPieces[i] = regexEscape(mixedPieces[i]);
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
3027
  }
 
3028
 
3029
- this._weekdaysRegex = new RegExp('^(' + mixedPieces.join('|') + ')', 'i');
3030
- this._weekdaysShortRegex = this._weekdaysRegex;
3031
- this._weekdaysMinRegex = this._weekdaysRegex;
3032
 
3033
- this._weekdaysStrictRegex = new RegExp('^(' + longPieces.join('|') + ')', 'i');
3034
- this._weekdaysShortStrictRegex = new RegExp('^(' + shortPieces.join('|') + ')', 'i');
3035
- this._weekdaysMinStrictRegex = new RegExp('^(' + minPieces.join('|') + ')', 'i');
 
3036
  }
3037
 
3038
  // FORMATTING
3039
 
3040
- addFormatToken('DDD', ['DDDD', 3], 'DDDo', 'dayOfYear');
3041
 
3042
  // ALIASES
3043
 
3044
- addUnitAlias('dayOfYear', 'DDD');
 
 
 
 
3045
 
3046
  // PARSING
3047
 
3048
- addRegexToken('DDD', match1to3);
3049
- addRegexToken('DDDD', match3);
3050
- addParseToken(['DDD', 'DDDD'], function (input, array, config) {
3051
- config._dayOfYear = toInt(input);
3052
  });
3053
 
3054
- // HELPERS
3055
-
3056
  // MOMENTS
3057
 
3058
- function getSetDayOfYear (input) {
3059
- var dayOfYear = Math.round((this.clone().startOf('day') - this.clone().startOf('year')) / 864e5) + 1;
3060
- return input == null ? dayOfYear : this.add((input - dayOfYear), 'd');
3061
  }
3062
 
3063
  // FORMATTING
3064
 
3065
- function hFormat() {
3066
- return this.hours() % 12 || 12;
3067
- }
3068
 
3069
- function kFormat() {
3070
- return this.hours() || 24;
3071
- }
3072
 
3073
- addFormatToken('H', ['HH', 2], 0, 'hour');
3074
- addFormatToken('h', ['hh', 2], 0, hFormat);
3075
- addFormatToken('k', ['kk', 2], 0, kFormat);
3076
 
3077
- addFormatToken('hmm', 0, 0, function () {
3078
- return '' + hFormat.apply(this) + zeroFill(this.minutes(), 2);
3079
- });
3080
 
3081
- addFormatToken('hmmss', 0, 0, function () {
3082
- return '' + hFormat.apply(this) + zeroFill(this.minutes(), 2) +
3083
- zeroFill(this.seconds(), 2);
3084
- });
3085
 
3086
- addFormatToken('Hmm', 0, 0, function () {
3087
- return '' + this.hours() + zeroFill(this.minutes(), 2);
 
 
3088
  });
3089
 
3090
- addFormatToken('Hmmss', 0, 0, function () {
3091
- return '' + this.hours() + zeroFill(this.minutes(), 2) +
3092
- zeroFill(this.seconds(), 2);
3093
  });
3094
 
3095
- function meridiem (token, lowercase) {
3096
- addFormatToken(token, 0, 0, function () {
3097
- return this.localeData().meridiem(this.hours(), this.minutes(), lowercase);
3098
- });
3099
- }
3100
 
3101
- meridiem('a', true);
3102
- meridiem('A', false);
3103
 
3104
- // ALIASES
3105
 
3106
- addUnitAlias('hour', 'h');
3107
 
3108
- // PARSING
3109
 
3110
- function matchMeridiem (isStrict, locale) {
3111
- return locale._meridiemParse;
3112
- }
3113
 
3114
- addRegexToken('a', matchMeridiem);
3115
- addRegexToken('A', matchMeridiem);
3116
- addRegexToken('H', match1to2);
3117
- addRegexToken('h', match1to2);
3118
- addRegexToken('HH', match1to2, match2);
3119
- addRegexToken('hh', match1to2, match2);
3120
 
3121
- addRegexToken('hmm', match3to4);
3122
- addRegexToken('hmmss', match5to6);
3123
- addRegexToken('Hmm', match3to4);
3124
- addRegexToken('Hmmss', match5to6);
3125
 
3126
- addParseToken(['H', 'HH'], HOUR);
3127
- addParseToken(['a', 'A'], function (input, array, config) {
3128
- config._isPm = config._locale.isPM(input);
3129
- config._meridiem = input;
3130
- });
3131
- addParseToken(['h', 'hh'], function (input, array, config) {
3132
- array[HOUR] = toInt(input);
3133
- getParsingFlags(config).bigHour = true;
3134
- });
3135
- addParseToken('hmm', function (input, array, config) {
3136
- var pos = input.length - 2;
3137
- array[HOUR] = toInt(input.substr(0, pos));
3138
- array[MINUTE] = toInt(input.substr(pos));
3139
- getParsingFlags(config).bigHour = true;
3140
- });
3141
- addParseToken('hmmss', function (input, array, config) {
3142
- var pos1 = input.length - 4;
3143
- var pos2 = input.length - 2;
3144
- array[HOUR] = toInt(input.substr(0, pos1));
3145
- array[MINUTE] = toInt(input.substr(pos1, 2));
3146
- array[SECOND] = toInt(input.substr(pos2));
3147
- getParsingFlags(config).bigHour = true;
3148
- });
3149
- addParseToken('Hmm', function (input, array, config) {
3150
- var pos = input.length - 2;
3151
- array[HOUR] = toInt(input.substr(0, pos));
3152
- array[MINUTE] = toInt(input.substr(pos));
3153
- });
3154
- addParseToken('Hmmss', function (input, array, config) {
3155
- var pos1 = input.length - 4;
3156
- var pos2 = input.length - 2;
3157
- array[HOUR] = toInt(input.substr(0, pos1));
3158
- array[MINUTE] = toInt(input.substr(pos1, 2));
3159
- array[SECOND] = toInt(input.substr(pos2));
3160
  });
3161
 
3162
- // LOCALES
3163
-
3164
- function localeIsPM (input) {
3165
- // IE8 Quirks Mode & IE7 Standards Mode do not allow accessing strings like arrays
3166
- // Using charAt should be more compatible.
3167
- return ((input + '').toLowerCase().charAt(0) === 'p');
3168
- }
3169
-
3170
- var defaultLocaleMeridiemParse = /[ap]\.?m?\.?/i;
3171
- function localeMeridiem (hours, minutes, isLower) {
3172
- if (hours > 11) {
3173
- return isLower ? 'pm' : 'PM';
3174
- } else {
3175
- return isLower ? 'am' : 'AM';
3176
- }
3177
- }
3178
-
3179
 
3180
  // MOMENTS
3181
 
3182
- // Setting the hour should keep the time, because the user explicitly
3183
- // specified which hour he wants. So trying to maintain the same hour (in
3184
- // a new timezone) makes sense. Adding/subtracting hours does not follow
3185
- // this rule.
3186
- var getSetHour = makeGetSet('Hours', true);
3187
 
3188
  // FORMATTING
3189
 
@@ -3193,6 +3419,10 @@
3193
 
3194
  addUnitAlias('minute', 'm');
3195
 
 
 
 
 
3196
  // PARSING
3197
 
3198
  addRegexToken('m', match1to2);
@@ -3211,6 +3441,10 @@
3211
 
3212
  addUnitAlias('second', 's');
3213
 
 
 
 
 
3214
  // PARSING
3215
 
3216
  addRegexToken('s', match1to2);
@@ -3256,6 +3490,10 @@
3256
 
3257
  addUnitAlias('millisecond', 'ms');
3258
 
 
 
 
 
3259
  // PARSING
3260
 
3261
  addRegexToken('S', match1to3, match1);
@@ -3305,7 +3543,7 @@
3305
  momentPrototype__proto.fromNow = fromNow;
3306
  momentPrototype__proto.to = to;
3307
  momentPrototype__proto.toNow = toNow;
3308
- momentPrototype__proto.get = getSet;
3309
  momentPrototype__proto.invalidAt = invalidAt;
3310
  momentPrototype__proto.isAfter = isAfter;
3311
  momentPrototype__proto.isBefore = isBefore;
@@ -3320,7 +3558,7 @@
3320
  momentPrototype__proto.max = prototypeMax;
3321
  momentPrototype__proto.min = prototypeMin;
3322
  momentPrototype__proto.parsingFlags = parsingFlags;
3323
- momentPrototype__proto.set = getSet;
3324
  momentPrototype__proto.startOf = startOf;
3325
  momentPrototype__proto.subtract = add_subtract__subtract;
3326
  momentPrototype__proto.toArray = toArray;
@@ -3380,7 +3618,6 @@
3380
  momentPrototype__proto.parseZone = setOffsetToParsedOffset;
3381
  momentPrototype__proto.hasAlignedHourOffset = hasAlignedHourOffset;
3382
  momentPrototype__proto.isDST = isDaylightSavingTime;
3383
- momentPrototype__proto.isDSTShifted = isDaylightSavingTimeShifted;
3384
  momentPrototype__proto.isLocal = isLocal;
3385
  momentPrototype__proto.isUtcOffset = isUtcOffset;
3386
  momentPrototype__proto.isUtc = isUtc;
@@ -3394,7 +3631,8 @@
3394
  momentPrototype__proto.dates = deprecate('dates accessor is deprecated. Use date instead.', getSetDayOfMonth);
3395
  momentPrototype__proto.months = deprecate('months accessor is deprecated. Use month instead', getSetMonth);
3396
  momentPrototype__proto.years = deprecate('years accessor is deprecated. Use year instead', getSetYear);
3397
- momentPrototype__proto.zone = deprecate('moment().zone is deprecated, use moment().utcOffset instead. https://github.com/moment/moment/issues/1779', getSetZone);
 
3398
 
3399
  var momentPrototype = momentPrototype__proto;
3400
 
@@ -3406,143 +3644,46 @@
3406
  return local__createLocal.apply(null, arguments).parseZone();
3407
  }
3408
 
3409
- var defaultCalendar = {
3410
- sameDay : '[Today at] LT',
3411
- nextDay : '[Tomorrow at] LT',
3412
- nextWeek : 'dddd [at] LT',
3413
- lastDay : '[Yesterday at] LT',
3414
- lastWeek : '[Last] dddd [at] LT',
3415
- sameElse : 'L'
3416
- };
3417
-
3418
- function locale_calendar__calendar (key, mom, now) {
3419
- var output = this._calendar[key];
3420
- return isFunction(output) ? output.call(mom, now) : output;
3421
- }
3422
-
3423
- var defaultLongDateFormat = {
3424
- LTS : 'h:mm:ss A',
3425
- LT : 'h:mm A',
3426
- L : 'MM/DD/YYYY',
3427
- LL : 'MMMM D, YYYY',
3428
- LLL : 'MMMM D, YYYY h:mm A',
3429
- LLLL : 'dddd, MMMM D, YYYY h:mm A'
3430
- };
3431
-
3432
- function longDateFormat (key) {
3433
- var format = this._longDateFormat[key],
3434
- formatUpper = this._longDateFormat[key.toUpperCase()];
3435
-
3436
- if (format || !formatUpper) {
3437
- return format;
3438
- }
3439
-
3440
- this._longDateFormat[key] = formatUpper.replace(/MMMM|MM|DD|dddd/g, function (val) {
3441
- return val.slice(1);
3442
- });
3443
-
3444
- return this._longDateFormat[key];
3445
- }
3446
-
3447
- var defaultInvalidDate = 'Invalid date';
3448
-
3449
- function invalidDate () {
3450
- return this._invalidDate;
3451
- }
3452
-
3453
- var defaultOrdinal = '%d';
3454
- var defaultOrdinalParse = /\d{1,2}/;
3455
-
3456
- function ordinal (number) {
3457
- return this._ordinal.replace('%d', number);
3458
- }
3459
-
3460
  function preParsePostFormat (string) {
3461
  return string;
3462
  }
3463
 
3464
- var defaultRelativeTime = {
3465
- future : 'in %s',
3466
- past : '%s ago',
3467
- s : 'a few seconds',
3468
- m : 'a minute',
3469
- mm : '%d minutes',
3470
- h : 'an hour',
3471
- hh : '%d hours',
3472
- d : 'a day',
3473
- dd : '%d days',
3474
- M : 'a month',
3475
- MM : '%d months',
3476
- y : 'a year',
3477
- yy : '%d years'
3478
- };
3479
-
3480
- function relative__relativeTime (number, withoutSuffix, string, isFuture) {
3481
- var output = this._relativeTime[string];
3482
- return (isFunction(output)) ?
3483
- output(number, withoutSuffix, string, isFuture) :
3484
- output.replace(/%d/i, number);
3485
- }
3486
-
3487
- function pastFuture (diff, output) {
3488
- var format = this._relativeTime[diff > 0 ? 'future' : 'past'];
3489
- return isFunction(format) ? format(output) : format.replace(/%s/i, output);
3490
- }
3491
-
3492
  var prototype__proto = Locale.prototype;
3493
 
3494
- prototype__proto._calendar = defaultCalendar;
3495
  prototype__proto.calendar = locale_calendar__calendar;
3496
- prototype__proto._longDateFormat = defaultLongDateFormat;
3497
  prototype__proto.longDateFormat = longDateFormat;
3498
- prototype__proto._invalidDate = defaultInvalidDate;
3499
  prototype__proto.invalidDate = invalidDate;
3500
- prototype__proto._ordinal = defaultOrdinal;
3501
  prototype__proto.ordinal = ordinal;
3502
- prototype__proto._ordinalParse = defaultOrdinalParse;
3503
  prototype__proto.preparse = preParsePostFormat;
3504
  prototype__proto.postformat = preParsePostFormat;
3505
- prototype__proto._relativeTime = defaultRelativeTime;
3506
  prototype__proto.relativeTime = relative__relativeTime;
3507
  prototype__proto.pastFuture = pastFuture;
3508
  prototype__proto.set = locale_set__set;
3509
 
3510
  // Month
3511
  prototype__proto.months = localeMonths;
3512
- prototype__proto._months = defaultLocaleMonths;
3513
  prototype__proto.monthsShort = localeMonthsShort;
3514
- prototype__proto._monthsShort = defaultLocaleMonthsShort;
3515
  prototype__proto.monthsParse = localeMonthsParse;
3516
- prototype__proto._monthsRegex = defaultMonthsRegex;
3517
  prototype__proto.monthsRegex = monthsRegex;
3518
- prototype__proto._monthsShortRegex = defaultMonthsShortRegex;
3519
  prototype__proto.monthsShortRegex = monthsShortRegex;
3520
 
3521
  // Week
3522
  prototype__proto.week = localeWeek;
3523
- prototype__proto._week = defaultLocaleWeek;
3524
  prototype__proto.firstDayOfYear = localeFirstDayOfYear;
3525
  prototype__proto.firstDayOfWeek = localeFirstDayOfWeek;
3526
 
3527
  // Day of Week
3528
  prototype__proto.weekdays = localeWeekdays;
3529
- prototype__proto._weekdays = defaultLocaleWeekdays;
3530
  prototype__proto.weekdaysMin = localeWeekdaysMin;
3531
- prototype__proto._weekdaysMin = defaultLocaleWeekdaysMin;
3532
  prototype__proto.weekdaysShort = localeWeekdaysShort;
3533
- prototype__proto._weekdaysShort = defaultLocaleWeekdaysShort;
3534
  prototype__proto.weekdaysParse = localeWeekdaysParse;
3535
 
3536
- prototype__proto._weekdaysRegex = defaultWeekdaysRegex;
3537
  prototype__proto.weekdaysRegex = weekdaysRegex;
3538
- prototype__proto._weekdaysShortRegex = defaultWeekdaysShortRegex;
3539
  prototype__proto.weekdaysShortRegex = weekdaysShortRegex;
3540
- prototype__proto._weekdaysMinRegex = defaultWeekdaysMinRegex;
3541
  prototype__proto.weekdaysMinRegex = weekdaysMinRegex;
3542
 
3543
  // Hours
3544
  prototype__proto.isPM = localeIsPM;
3545
- prototype__proto._meridiemParse = defaultLocaleMeridiemParse;
3546
  prototype__proto.meridiem = localeMeridiem;
3547
 
3548
  function lists__get (format, index, field, setter) {
@@ -3871,6 +4012,18 @@
3871
  return substituteTimeAgo.apply(null, a);
3872
  }
3873
 
 
 
 
 
 
 
 
 
 
 
 
 
3874
  // This function allows you to set a threshold for relative time strings
3875
  function duration_humanize__getSetRelativeTimeThreshold (threshold, limit) {
3876
  if (thresholds[threshold] === undefined) {
@@ -4003,7 +4156,7 @@
4003
  // Side effect imports
4004
 
4005
 
4006
- utils_hooks__hooks.version = '2.13.0';
4007
 
4008
  setHookCallback(local__createLocal);
4009
 
@@ -4030,7 +4183,9 @@
4030
  utils_hooks__hooks.locales = locale_locales__listLocales;
4031
  utils_hooks__hooks.weekdaysShort = lists__listWeekdaysShort;
4032
  utils_hooks__hooks.normalizeUnits = normalizeUnits;
 
4033
  utils_hooks__hooks.relativeTimeThreshold = duration_humanize__getSetRelativeTimeThreshold;
 
4034
  utils_hooks__hooks.prototype = momentPrototype;
4035
 
4036
  var _moment = utils_hooks__hooks;
1
  //! moment.js
2
+ //! version : 2.14.1
3
  //! authors : Tim Wood, Iskren Chernev, Moment.js contributors
4
  //! license : MIT
5
  //! momentjs.com
26
  return input instanceof Array || Object.prototype.toString.call(input) === '[object Array]';
27
  }
28
 
29
+ function isObject(input) {
30
+ return Object.prototype.toString.call(input) === '[object Object]';
31
+ }
32
+
33
+ function isObjectEmpty(obj) {
34
+ var k;
35
+ for (k in obj) {
36
+ // even if its not own property I'd still call it non-empty
37
+ return false;
38
+ }
39
+ return true;
40
+ }
41
+
42
  function isDate(input) {
43
  return input instanceof Date || Object.prototype.toString.call(input) === '[object Date]';
44
  }
234
 
235
  function absFloor (number) {
236
  if (number < 0) {
237
+ // -0 -> 0
238
+ return Math.ceil(number) || 0;
239
  } else {
240
  return Math.floor(number);
241
  }
308
  return input instanceof Function || Object.prototype.toString.call(input) === '[object Function]';
309
  }
310
 
 
 
 
 
311
  function locale_set__set (config) {
312
  var prop, i;
313
  for (i in config) {
339
  }
340
  }
341
  }
342
+ for (prop in parentConfig) {
343
+ if (hasOwnProp(parentConfig, prop) &&
344
+ !hasOwnProp(childConfig, prop) &&
345
+ isObject(parentConfig[prop])) {
346
+ // make sure changes to properties don't modify parent config
347
+ res[prop] = extend({}, res[prop]);
348
+ }
349
+ }
350
  return res;
351
  }
352
 
372
  };
373
  }
374
 
375
+ var defaultCalendar = {
376
+ sameDay : '[Today at] LT',
377
+ nextDay : '[Tomorrow at] LT',
378
+ nextWeek : 'dddd [at] LT',
379
+ lastDay : '[Yesterday at] LT',
380
+ lastWeek : '[Last] dddd [at] LT',
381
+ sameElse : 'L'
382
+ };
383
 
384
+ function locale_calendar__calendar (key, mom, now) {
385
+ var output = this._calendar[key] || this._calendar['sameElse'];
386
+ return isFunction(output) ? output.call(mom, now) : output;
387
  }
388
 
389
+ var defaultLongDateFormat = {
390
+ LTS : 'h:mm:ss A',
391
+ LT : 'h:mm A',
392
+ L : 'MM/DD/YYYY',
393
+ LL : 'MMMM D, YYYY',
394
+ LLL : 'MMMM D, YYYY h:mm A',
395
+ LLLL : 'dddd, MMMM D, YYYY h:mm A'
396
+ };
397
 
398
+ function longDateFormat (key) {
399
+ var format = this._longDateFormat[key],
400
+ formatUpper = this._longDateFormat[key.toUpperCase()];
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
401
 
402
+ if (format || !formatUpper) {
403
+ return format;
 
 
 
 
 
 
 
 
 
 
404
  }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
405
 
406
+ this._longDateFormat[key] = formatUpper.replace(/MMMM|MM|DD|dddd/g, function (val) {
407
+ return val.slice(1);
408
+ });
 
 
409
 
410
+ return this._longDateFormat[key];
411
  }
412
 
413
+ var defaultInvalidDate = 'Invalid date';
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
414
 
415
+ function invalidDate () {
416
+ return this._invalidDate;
 
 
 
 
417
  }
418
 
419
+ var defaultOrdinal = '%d';
420
+ var defaultOrdinalParse = /\d{1,2}/;
 
 
 
 
 
 
 
421
 
422
+ function ordinal (number) {
423
+ return this._ordinal.replace('%d', number);
 
 
 
 
 
 
 
 
 
 
 
424
  }
425
 
426
+ var defaultRelativeTime = {
427
+ future : 'in %s',
428
+ past : '%s ago',
429
+ s : 'a few seconds',
430
+ m : 'a minute',
431
+ mm : '%d minutes',
432
+ h : 'an hour',
433
+ hh : '%d hours',
434
+ d : 'a day',
435
+ dd : '%d days',
436
+ M : 'a month',
437
+ MM : '%d months',
438
+ y : 'a year',
439
+ yy : '%d years'
440
+ };
 
 
 
 
 
441
 
442
+ function relative__relativeTime (number, withoutSuffix, string, isFuture) {
443
+ var output = this._relativeTime[string];
444
+ return (isFunction(output)) ?
445
+ output(number, withoutSuffix, string, isFuture) :
446
+ output.replace(/%d/i, number);
447
  }
448
 
449
+ function pastFuture (diff, output) {
450
+ var format = this._relativeTime[diff > 0 ? 'future' : 'past'];
451
+ return isFunction(format) ? format(output) : format.replace(/%s/i, output);
452
  }
453
 
454
  var aliases = {};
479
  return normalizedInput;
480
  }
481
 
482
+ var priorities = {};
483
+
484
+ function addUnitPriority(unit, priority) {
485
+ priorities[unit] = priority;
486
+ }
487
+
488
+ function getPrioritizedUnits(unitsObj) {
489
+ var units = [];
490
+ for (var u in unitsObj) {
491
+ units.push({unit: u, priority: priorities[u]});
492
+ }
493
+ units.sort(function (a, b) {
494
+ return a.priority - b.priority;
495
+ });
496
+ return units;
497
+ }
498
+
499
  function makeGetSet (unit, keepTime) {
500
  return function (value) {
501
  if (value != null) {
521
 
522
  // MOMENTS
523
 
524
+ function stringGet (units) {
525
+ units = normalizeUnits(units);
526
+ if (isFunction(this[units])) {
527
+ return this[units]();
528
+ }
529
+ return this;
530
+ }
531
+
532
+
533
+ function stringSet (units, value) {
534
  if (typeof units === 'object') {
535
+ units = normalizeObjectUnits(units);
536
+ var prioritized = getPrioritizedUnits(units);
537
+ for (var i = 0; i < prioritized.length; i++) {
538
+ this[prioritized[i].unit](units[prioritized[i].unit]);
539
  }
540
  } else {
541
  units = normalizeUnits(units);
775
 
776
  addUnitAlias('month', 'M');
777
 
778
+ // PRIORITY
779
+
780
+ addUnitPriority('month', 8);
781
+
782
  // PARSING
783
 
784
  addRegexToken('M', match1to2);
810
  var defaultLocaleMonths = 'January_February_March_April_May_June_July_August_September_October_November_December'.split('_');
811
  function localeMonths (m, format) {
812
  return isArray(this._months) ? this._months[m.month()] :
813
+ this._months[(this._months.isFormat || MONTHS_IN_FORMAT).test(format) ? 'format' : 'standalone'][m.month()];
814
  }
815
 
816
  var defaultLocaleMonthsShort = 'Jan_Feb_Mar_Apr_May_Jun_Jul_Aug_Sep_Oct_Nov_Dec'.split('_');
951
  return this._monthsShortRegex;
952
  }
953
  } else {
954
+ if (!hasOwnProp(this, '_monthsShortRegex')) {
955
+ this._monthsShortRegex = defaultMonthsShortRegex;
956
+ }
957
  return this._monthsShortStrictRegex && isStrict ?
958
  this._monthsShortStrictRegex : this._monthsShortRegex;
959
  }
971
  return this._monthsRegex;
972
  }
973
  } else {
974
+ if (!hasOwnProp(this, '_monthsRegex')) {
975
+ this._monthsRegex = defaultMonthsRegex;
976
+ }
977
  return this._monthsStrictRegex && isStrict ?
978
  this._monthsStrictRegex : this._monthsRegex;
979
  }
1002
  for (i = 0; i < 12; i++) {
1003
  shortPieces[i] = regexEscape(shortPieces[i]);
1004
  longPieces[i] = regexEscape(longPieces[i]);
1005
+ }
1006
+ for (i = 0; i < 24; i++) {
1007
  mixedPieces[i] = regexEscape(mixedPieces[i]);
1008
  }
1009
 
1013
  this._monthsShortStrictRegex = new RegExp('^(' + shortPieces.join('|') + ')', 'i');
1014
  }
1015
 
1016
+ // FORMATTING
 
 
1017
 
1018
+ addFormatToken('Y', 0, 0, function () {
1019
+ var y = this.year();
1020
+ return y <= 9999 ? '' + y : '+' + y;
1021
+ });
 
 
 
 
 
1022
 
1023
+ addFormatToken(0, ['YY', 2], 0, function () {
1024
+ return this.year() % 100;
1025
+ });
 
 
 
 
 
 
1026
 
1027
+ addFormatToken(0, ['YYYY', 4], 0, 'year');
1028
+ addFormatToken(0, ['YYYYY', 5], 0, 'year');
1029
+ addFormatToken(0, ['YYYYYY', 6, true], 0, 'year');
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1030
 
1031
  // ALIASES
1032
 
1033
  addUnitAlias('year', 'y');
1034
 
1035
+ // PRIORITIES
1036
+
1037
+ addUnitPriority('year', 1);
1038
+
1039
  // PARSING
1040
 
1041
  addRegexToken('Y', matchSigned);
1079
  return isLeapYear(this.year());
1080
  }
1081
 
1082
+ function createDate (y, m, d, h, M, s, ms) {
1083
+ //can't just apply() to create a date:
1084
+ //http://stackoverflow.com/questions/181348/instantiating-a-javascript-object-by-calling-prototype-constructor-apply
1085
+ var date = new Date(y, m, d, h, M, s, ms);
1086
+
1087
+ //the date constructor remaps years 0-99 to 1900-1999
1088
+ if (y < 100 && y >= 0 && isFinite(date.getFullYear())) {
1089
+ date.setFullYear(y);
1090
+ }
1091
+ return date;
1092
+ }
1093
+
1094
+ function createUTCDate (y) {
1095
+ var date = new Date(Date.UTC.apply(null, arguments));
1096
+
1097
+ //the Date.UTC function remaps years 0-99 to 1900-1999
1098
+ if (y < 100 && y >= 0 && isFinite(date.getUTCFullYear())) {
1099
+ date.setUTCFullYear(y);
1100
+ }
1101
+ return date;
1102
+ }
1103
+
1104
  // start-of-first-week - start-of-year
1105
  function firstWeekOffset(year, dow, doy) {
1106
  var // first-week day -- which january is always in the first week (4 for iso, 1 for other)
1163
  return (daysInYear(year) - weekOffset + weekOffsetNext) / 7;
1164
  }
1165
 
1166
+ // FORMATTING
 
 
 
 
 
 
 
 
 
1167
 
1168
+ addFormatToken('w', ['ww', 2], 'wo', 'week');
1169
+ addFormatToken('W', ['WW', 2], 'Wo', 'isoWeek');
 
 
 
 
 
 
1170
 
1171
+ // ALIASES
 
 
 
 
 
1172
 
1173
+ addUnitAlias('week', 'w');
1174
+ addUnitAlias('isoWeek', 'W');
 
1175
 
1176
+ // PRIORITIES
1177
 
1178
+ addUnitPriority('week', 5);
1179
+ addUnitPriority('isoWeek', 5);
 
 
1180
 
1181
+ // PARSING
 
 
1182
 
1183
+ addRegexToken('w', match1to2);
1184
+ addRegexToken('ww', match1to2, match2);
1185
+ addRegexToken('W', match1to2);
1186
+ addRegexToken('WW', match1to2, match2);
1187
 
1188
+ addWeekParseToken(['w', 'ww', 'W', 'WW'], function (input, week, config, token) {
1189
+ week[token.substr(0, 1)] = toInt(input);
1190
+ });
 
1191
 
1192
+ // HELPERS
 
 
 
 
 
 
 
1193
 
1194
+ // LOCALES
 
 
 
1195
 
1196
+ function localeWeek (mom) {
1197
+ return weekOfYear(mom, this._week.dow, this._week.doy).week;
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1198
  }
1199
 
1200
+ var defaultLocaleWeek = {
1201
+ dow : 0, // Sunday is the first day of the week.
1202
+ doy : 6 // The week that contains Jan 1st is the first week of the year.
1203
+ };
1204
 
1205
+ function localeFirstDayOfWeek () {
1206
+ return this._week.dow;
1207
+ }
 
1208
 
1209
+ function localeFirstDayOfYear () {
1210
+ return this._week.doy;
1211
+ }
 
 
 
 
 
 
 
 
 
 
1212
 
1213
+ // MOMENTS
 
1214
 
1215
+ function getSetWeek (input) {
1216
+ var week = this.localeData().week(this);
1217
+ return input == null ? week : this.add((input - week) * 7, 'd');
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1218
  }
1219
 
1220
+ function getSetISOWeek (input) {
1221
+ var week = weekOfYear(this, 1, 4).week;
1222
+ return input == null ? week : this.add((input - week) * 7, 'd');
1223
+ }
1224
 
1225
+ // FORMATTING
 
 
 
 
 
 
1226
 
1227
+ addFormatToken('d', 0, 'do', 'day');
 
1228
 
1229
+ addFormatToken('dd', 0, 0, function (format) {
1230
+ return this.localeData().weekdaysMin(this, format);
1231
+ });
 
 
1232
 
1233
+ addFormatToken('ddd', 0, 0, function (format) {
1234
+ return this.localeData().weekdaysShort(this, format);
1235
+ });
1236
 
1237
+ addFormatToken('dddd', 0, 0, function (format) {
1238
+ return this.localeData().weekdays(this, format);
1239
+ });
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1240
 
1241
+ addFormatToken('e', 0, 0, 'weekday');
1242
+ addFormatToken('E', 0, 0, 'isoWeekday');
 
 
 
1243
 
1244
+ // ALIASES
 
 
 
 
 
1245
 
1246
+ addUnitAlias('day', 'd');
1247
+ addUnitAlias('weekday', 'e');
1248
+ addUnitAlias('isoWeekday', 'E');
 
1249
 
1250
+ // PRIORITY
1251
+ addUnitPriority('day', 11);
1252
+ addUnitPriority('weekday', 11);
1253
+ addUnitPriority('isoWeekday', 11);
1254
 
1255
+ // PARSING
1256
 
1257
+ addRegexToken('d', match1to2);
1258
+ addRegexToken('e', match1to2);
1259
+ addRegexToken('E', match1to2);
1260
+ addRegexToken('dd', function (isStrict, locale) {
1261
+ return locale.weekdaysMinRegex(isStrict);
1262
+ });
1263
+ addRegexToken('ddd', function (isStrict, locale) {
1264
+ return locale.weekdaysShortRegex(isStrict);
1265
+ });
1266
+ addRegexToken('dddd', function (isStrict, locale) {
1267
+ return locale.weekdaysRegex(isStrict);
1268
+ });
1269
 
1270
+ addWeekParseToken(['dd', 'ddd', 'dddd'], function (input, week, config, token) {
1271
+ var weekday = config._locale.weekdaysParse(input, token, config._strict);
1272
+ // if we didn't get a weekday name, mark the date as invalid
1273
+ if (weekday != null) {
1274
+ week.d = weekday;
 
 
 
 
 
 
 
 
 
 
 
1275
  } else {
1276
+ getParsingFlags(config).invalidWeekday = input;
 
1277
  }
1278
+ });
1279
 
1280
+ addWeekParseToken(['d', 'e', 'E'], function (input, week, config, token) {
1281
+ week[token] = toInt(input);
1282
+ });
 
1283
 
1284
+ // HELPERS
 
 
1285
 
1286
+ function parseWeekday(input, locale) {
1287
+ if (typeof input !== 'string') {
1288
+ return input;
 
1289
  }
1290
 
1291
+ if (!isNaN(input)) {
1292
+ return parseInt(input, 10);
1293
+ }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1294
 
1295
+ input = locale.weekdaysParse(input);
1296
+ if (typeof input === 'number') {
1297
+ return input;
 
1298
  }
1299
 
1300
+ return null;
1301
  }
1302
 
1303
+ function parseIsoWeekday(input, locale) {
1304
+ if (typeof input === 'string') {
1305
+ return locale.weekdaysParse(input) % 7 || 7;
1306
  }
1307
+ return isNaN(input) ? null : input;
 
 
 
 
 
 
1308
  }
1309
 
1310
+ // LOCALES
 
 
 
 
 
 
1311
 
1312
+ var defaultLocaleWeekdays = 'Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday'.split('_');
1313
+ function localeWeekdays (m, format) {
1314
+ return isArray(this._weekdays) ? this._weekdays[m.day()] :
1315
+ this._weekdays[this._weekdays.isFormat.test(format) ? 'format' : 'standalone'][m.day()];
1316
  }
1317
 
1318
+ var defaultLocaleWeekdaysShort = 'Sun_Mon_Tue_Wed_Thu_Fri_Sat'.split('_');
1319
+ function localeWeekdaysShort (m) {
1320
+ return this._weekdaysShort[m.day()];
1321
+ }
1322
 
1323
+ var defaultLocaleWeekdaysMin = 'Su_Mo_Tu_We_Th_Fr_Sa'.split('_');
1324
+ function localeWeekdaysMin (m) {
1325
+ return this._weekdaysMin[m.day()];
1326
+ }
1327
 
1328
+ function day_of_week__handleStrictParse(weekdayName, format, strict) {
1329
+ var i, ii, mom, llc = weekdayName.toLocaleLowerCase();
1330
+ if (!this._weekdaysParse) {
1331
+ this._weekdaysParse = [];
1332
+ this._shortWeekdaysParse = [];
1333
+ this._minWeekdaysParse = [];
1334
 
1335
+ for (i = 0; i < 7; ++i) {
1336
+ mom = create_utc__createUTC([2000, 1]).day(i);
1337
+ this._minWeekdaysParse[i] = this.weekdaysMin(mom, '').toLocaleLowerCase();
1338
+ this._shortWeekdaysParse[i] = this.weekdaysShort(mom, '').toLocaleLowerCase();
1339
+ this._weekdaysParse[i] = this.weekdays(mom, '').toLocaleLowerCase();
1340
+ }
1341
  }
1342
 
1343
+ if (strict) {
1344
+ if (format === 'dddd') {
1345
+ ii = indexOf.call(this._weekdaysParse, llc);
1346
+ return ii !== -1 ? ii : null;
1347
+ } else if (format === 'ddd') {
1348
+ ii = indexOf.call(this._shortWeekdaysParse, llc);
1349
+ return ii !== -1 ? ii : null;
1350
+ } else {
1351
+ ii = indexOf.call(this._minWeekdaysParse, llc);
1352
+ return ii !== -1 ? ii : null;
1353
+ }
1354
  } else {
1355
+ if (format === 'dddd') {
1356
+ ii = indexOf.call(this._weekdaysParse, llc);
1357
+ if (ii !== -1) {
1358
+ return ii;
1359
+ }
1360
+ ii = indexOf.call(this._shortWeekdaysParse, llc);
1361
+ if (ii !== -1) {
1362
+ return ii;
1363
+ }
1364
+ ii = indexOf.call(this._minWeekdaysParse, llc);
1365
+ return ii !== -1 ? ii : null;
1366
+ } else if (format === 'ddd') {
1367
+ ii = indexOf.call(this._shortWeekdaysParse, llc);
1368
+ if (ii !== -1) {
1369
+ return ii;
1370
+ }
1371
+ ii = indexOf.call(this._weekdaysParse, llc);
1372
+ if (ii !== -1) {
1373
+ return ii;
1374
+ }
1375
+ ii = indexOf.call(this._minWeekdaysParse, llc);
1376
+ return ii !== -1 ? ii : null;
1377
+ } else {
1378
+ ii = indexOf.call(this._minWeekdaysParse, llc);
1379
+ if (ii !== -1) {
1380
+ return ii;
1381
+ }
1382
+ ii = indexOf.call(this._weekdaysParse, llc);
1383
+ if (ii !== -1) {
1384
+ return ii;
1385
+ }
1386
+ ii = indexOf.call(this._shortWeekdaysParse, llc);
1387
+ return ii !== -1 ? ii : null;
1388
+ }
1389
  }
1390
+ }
1391
 
1392
+ function localeWeekdaysParse (weekdayName, format, strict) {
1393
+ var i, mom, regex;
1394
+
1395
+ if (this._weekdaysParseExact) {
1396
+ return day_of_week__handleStrictParse.call(this, weekdayName, format, strict);
1397
  }
1398
 
1399
+ if (!this._weekdaysParse) {
1400
+ this._weekdaysParse = [];
1401
+ this._minWeekdaysParse = [];
1402
+ this._shortWeekdaysParse = [];
1403
+ this._fullWeekdaysParse = [];
1404
+ }
1405
+
1406
+ for (i = 0; i < 7; i++) {
1407
+ // make the regex if we don't have it already
1408
+
1409
+ mom = create_utc__createUTC([2000, 1]).day(i);
1410
+ if (strict && !this._fullWeekdaysParse[i]) {
1411
+ this._fullWeekdaysParse[i] = new RegExp('^' + this.weekdays(mom, '').replace('.', '\.?') + '$', 'i');
1412
+ this._shortWeekdaysParse[i] = new RegExp('^' + this.weekdaysShort(mom, '').replace('.', '\.?') + '$', 'i');
1413
+ this._minWeekdaysParse[i] = new RegExp('^' + this.weekdaysMin(mom, '').replace('.', '\.?') + '$', 'i');
1414
+ }
1415
+ if (!this._weekdaysParse[i]) {
1416
+ regex = '^' + this.weekdays(mom, '') + '|^' + this.weekdaysShort(mom, '') + '|^' + this.weekdaysMin(mom, '');
1417
+ this._weekdaysParse[i] = new RegExp(regex.replace('.', ''), 'i');
1418
+ }
1419
+ // test the regex
1420
+ if (strict && format === 'dddd' && this._fullWeekdaysParse[i].test(weekdayName)) {
1421
+ return i;
1422
+ } else if (strict && format === 'ddd' && this._shortWeekdaysParse[i].test(weekdayName)) {
1423
+ return i;
1424
+ } else if (strict && format === 'dd' && this._minWeekdaysParse[i].test(weekdayName)) {
1425
+ return i;
1426
+ } else if (!strict && this._weekdaysParse[i].test(weekdayName)) {
1427
+ return i;
1428
+ }
1429
+ }
1430
  }
1431
 
1432
+ // MOMENTS
1433
+
1434
+ function getSetDayOfWeek (input) {
1435
+ if (!this.isValid()) {
1436
+ return input != null ? this : NaN;
1437
+ }
1438
+ var day = this._isUTC ? this._d.getUTCDay() : this._d.getDay();
1439
+ if (input != null) {
1440
+ input = parseWeekday(input, this.localeData());
1441
+ return this.add(input - day, 'd');
 
 
 
 
 
 
 
 
1442
  } else {
1443
+ return day;
1444
  }
1445
  }
1446
 
1447
+ function getSetLocaleDayOfWeek (input) {
1448
+ if (!this.isValid()) {
1449
+ return input != null ? this : NaN;
1450
+ }
1451
+ var weekday = (this.day() + 7 - this.localeData()._week.dow) % 7;
1452
+ return input == null ? weekday : this.add(input - weekday, 'd');
1453
+ }
1454
 
1455
+ function getSetISODayOfWeek (input) {
1456
+ if (!this.isValid()) {
1457
+ return input != null ? this : NaN;
1458
  }
 
 
 
 
 
 
 
 
1459
 
1460
+ // behaves the same as moment#day except
1461
+ // as a getter, returns 7 instead of 0 (1-7 range instead of 0-6)
1462
+ // as a setter, sunday should belong to the previous week.
1463
 
1464
+ if (input != null) {
1465
+ var weekday = parseIsoWeekday(input, this.localeData());
1466
+ return this.day(this.day() % 7 ? weekday : weekday - 7);
1467
+ } else {
1468
+ return this.day() || 7;
1469
+ }
1470
  }
1471
 
1472
+ var defaultWeekdaysRegex = matchWord;
1473
+ function weekdaysRegex (isStrict) {
1474
+ if (this._weekdaysParseExact) {
1475
+ if (!hasOwnProp(this, '_weekdaysRegex')) {
1476
+ computeWeekdaysParse.call(this);
1477
+ }
1478
+ if (isStrict) {
1479
+ return this._weekdaysStrictRegex;
 
 
 
 
 
 
 
 
 
 
1480
  } else {
1481
+ return this._weekdaysRegex;
1482
  }
1483
+ } else {
1484
+ if (!hasOwnProp(this, '_weekdaysRegex')) {
1485
+ this._weekdaysRegex = defaultWeekdaysRegex;
1486
+ }
1487
+ return this._weekdaysStrictRegex && isStrict ?
1488
+ this._weekdaysStrictRegex : this._weekdaysRegex;
1489
  }
1490
+ }
1491
 
1492
+ var defaultWeekdaysShortRegex = matchWord;
1493
+ function weekdaysShortRegex (isStrict) {
1494
+ if (this._weekdaysParseExact) {
1495
+ if (!hasOwnProp(this, '_weekdaysRegex')) {
1496
+ computeWeekdaysParse.call(this);
1497
+ }
1498
+ if (isStrict) {
1499
+ return this._weekdaysShortStrictRegex;
1500
+ } else {
1501
+ return this._weekdaysShortRegex;
1502
+ }
1503
+ } else {
1504
+ if (!hasOwnProp(this, '_weekdaysShortRegex')) {
1505
+ this._weekdaysShortRegex = defaultWeekdaysShortRegex;
 
 
 
1506
  }
1507
+ return this._weekdaysShortStrictRegex && isStrict ?
1508
+ this._weekdaysShortStrictRegex : this._weekdaysShortRegex;
1509
  }
 
1510
  }
1511
 
1512
+ var defaultWeekdaysMinRegex = matchWord;
1513
+ function weekdaysMinRegex (isStrict) {
1514
+ if (this._weekdaysParseExact) {
1515
+ if (!hasOwnProp(this, '_weekdaysRegex')) {
1516
+ computeWeekdaysParse.call(this);
1517
+ }
1518
+ if (isStrict) {
1519
+ return this._weekdaysMinStrictRegex;
1520
+ } else {
1521
+ return this._weekdaysMinRegex;
1522
+ }
1523
+ } else {
1524
+ if (!hasOwnProp(this, '_weekdaysMinRegex')) {
1525
+ this._weekdaysMinRegex = defaultWeekdaysMinRegex;
1526
+ }
1527
+ return this._weekdaysMinStrictRegex && isStrict ?
1528
+ this._weekdaysMinStrictRegex : this._weekdaysMinRegex;
1529
+ }
1530
  }
1531
 
 
 
 
 
 
1532
 
1533
+ function computeWeekdaysParse () {
1534
+ function cmpLenRev(a, b) {
1535
+ return b.length - a.length;
1536
+ }
1537
 
1538
+ var minPieces = [], shortPieces = [], longPieces = [], mixedPieces = [],
1539
+ i, mom, minp, shortp, longp;
1540
+ for (i = 0; i < 7; i++) {
1541
+ // make the regex if we don't have it already
1542
+ mom = create_utc__createUTC([2000, 1]).day(i);
1543
+ minp = this.weekdaysMin(mom, '');
1544
+ shortp = this.weekdaysShort(mom, '');
1545
+ longp = this.weekdays(mom, '');
1546
+ minPieces.push(minp);
1547
+ shortPieces.push(shortp);
1548
+ longPieces.push(longp);
1549
+ mixedPieces.push(minp);
1550
+ mixedPieces.push(shortp);
1551
+ mixedPieces.push(longp);
1552
+ }
1553
+ // Sorting makes sure if one weekday (or abbr) is a prefix of another it
1554
+ // will match the longer piece.
1555
+ minPieces.sort(cmpLenRev);
1556
+ shortPieces.sort(cmpLenRev);
1557
+ longPieces.sort(cmpLenRev);
1558
+ mixedPieces.sort(cmpLenRev);
1559
+ for (i = 0; i < 7; i++) {
1560
+ shortPieces[i] = regexEscape(shortPieces[i]);
1561
+ longPieces[i] = regexEscape(longPieces[i]);
1562
+ mixedPieces[i] = regexEscape(mixedPieces[i]);
1563
+ }
1564
 
1565
+ this._weekdaysRegex = new RegExp('^(' + mixedPieces.join('|') + ')', 'i');
1566
+ this._weekdaysShortRegex = this._weekdaysRegex;
1567
+ this._weekdaysMinRegex = this._weekdaysRegex;
 
 
 
 
 
 
 
 
 
 
 
 
1568
 
1569
+ this._weekdaysStrictRegex = new RegExp('^(' + longPieces.join('|') + ')', 'i');
1570
+ this._weekdaysShortStrictRegex = new RegExp('^(' + shortPieces.join('|') + ')', 'i');
1571
+ this._weekdaysMinStrictRegex = new RegExp('^(' + minPieces.join('|') + ')', 'i');
1572
+ }
1573
 
1574
+ // FORMATTING
1575
 
1576
+ function hFormat() {
1577
+ return this.hours() % 12 || 12;
1578
  }
1579
 
1580
+ function kFormat() {
1581
+ return this.hours() || 24;
1582
  }
1583
 
1584
+ addFormatToken('H', ['HH', 2], 0, 'hour');
1585
+ addFormatToken('h', ['hh', 2], 0, hFormat);
1586
+ addFormatToken('k', ['kk', 2], 0, kFormat);
1587
 
1588
+ addFormatToken('hmm', 0, 0, function () {
1589
+ return '' + hFormat.apply(this) + zeroFill(this.minutes(), 2);
1590
+ });
1591
+
1592
+ addFormatToken('hmmss', 0, 0, function () {
1593
+ return '' + hFormat.apply(this) + zeroFill(this.minutes(), 2) +
1594
+ zeroFill(this.seconds(), 2);
1595
+ });
1596
+
1597
+ addFormatToken('Hmm', 0, 0, function () {
1598
+ return '' + this.hours() + zeroFill(this.minutes(), 2);
1599
+ });
1600
+
1601
+ addFormatToken('Hmmss', 0, 0, function () {
1602
+ return '' + this.hours() + zeroFill(this.minutes(), 2) +
1603
+ zeroFill(this.seconds(), 2);
1604
+ });
1605
+
1606
+ function meridiem (token, lowercase) {
1607
  addFormatToken(token, 0, 0, function () {
1608
+ return this.localeData().meridiem(this.hours(), this.minutes(), lowercase);
 
 
 
 
 
 
1609
  });
1610
  }
1611
 
1612
+ meridiem('a', true);
1613
+ meridiem('A', false);
1614
+
1615
+ // ALIASES
1616
+
1617
+ addUnitAlias('hour', 'h');
1618
+
1619
+ // PRIORITY
1620
+ addUnitPriority('hour', 13);
1621
 
1622
  // PARSING
1623
 
1624
+ function matchMeridiem (isStrict, locale) {
1625
+ return locale._meridiemParse;
1626
+ }
 
 
 
1627
 
1628
+ addRegexToken('a', matchMeridiem);
1629
+ addRegexToken('A', matchMeridiem);
1630
+ addRegexToken('H', match1to2);
1631
+ addRegexToken('h', match1to2);
1632
+ addRegexToken('HH', match1to2, match2);
1633
+ addRegexToken('hh', match1to2, match2);
1634
 
1635
+ addRegexToken('hmm', match3to4);
1636
+ addRegexToken('hmmss', match5to6);
1637
+ addRegexToken('Hmm', match3to4);
1638
+ addRegexToken('Hmmss', match5to6);
1639
 
1640
+ addParseToken(['H', 'HH'], HOUR);
1641
+ addParseToken(['a', 'A'], function (input, array, config) {
1642
+ config._isPm = config._locale.isPM(input);
1643
+ config._meridiem = input;
1644
+ });
1645
+ addParseToken(['h', 'hh'], function (input, array, config) {
1646
+ array[HOUR] = toInt(input);
1647
+ getParsingFlags(config).bigHour = true;
1648
+ });
1649
+ addParseToken('hmm', function (input, array, config) {
1650
+ var pos = input.length - 2;
1651
+ array[HOUR] = toInt(input.substr(0, pos));
1652
+ array[MINUTE] = toInt(input.substr(pos));
1653
+ getParsingFlags(config).bigHour = true;
1654
+ });
1655
+ addParseToken('hmmss', function (input, array, config) {
1656
+ var pos1 = input.length - 4;
1657
+ var pos2 = input.length - 2;
1658
+ array[HOUR] = toInt(input.substr(0, pos1));
1659
+ array[MINUTE] = toInt(input.substr(pos1, 2));
1660
+ array[SECOND] = toInt(input.substr(pos2));
1661
+ getParsingFlags(config).bigHour = true;
1662
+ });
1663
+ addParseToken('Hmm', function (input, array, config) {
1664
+ var pos = input.length - 2;
1665
+ array[HOUR] = toInt(input.substr(0, pos));
1666
+ array[MINUTE] = toInt(input.substr(pos));
1667
+ });
1668
+ addParseToken('Hmmss', function (input, array, config) {
1669
+ var pos1 = input.length - 4;
1670
+ var pos2 = input.length - 2;
1671
+ array[HOUR] = toInt(input.substr(0, pos1));
1672
+ array[MINUTE] = toInt(input.substr(pos1, 2));
1673
+ array[SECOND] = toInt(input.substr(pos2));
1674
+ });
1675
 
1676
+ // LOCALES
1677
+
1678
+ function localeIsPM (input) {
1679
+ // IE8 Quirks Mode & IE7 Standards Mode do not allow accessing strings like arrays
1680
+ // Using charAt should be more compatible.
1681
+ return ((input + '').toLowerCase().charAt(0) === 'p');
1682
  }
1683
 
1684
+ var defaultLocaleMeridiemParse = /[ap]\.?m?\.?/i;
1685
+ function localeMeridiem (hours, minutes, isLower) {
1686
+ if (hours > 11) {
1687
+ return isLower ? 'pm' : 'PM';
 
 
 
 
 
 
1688
  } else {
1689
+ return isLower ? 'am' : 'AM';
1690
  }
1691
  }
1692
 
 
 
 
 
 
1693
 
1694
+ // MOMENTS
1695
 
1696
+ // Setting the hour should keep the time, because the user explicitly
1697
+ // specified which hour he wants. So trying to maintain the same hour (in
1698
+ // a new timezone) makes sense. Adding/subtracting hours does not follow
1699
+ // this rule.
1700
+ var getSetHour = makeGetSet('Hours', true);
1701
 
1702
+ var baseConfig = {
1703
+ calendar: defaultCalendar,
1704
+ longDateFormat: defaultLongDateFormat,
1705
+ invalidDate: defaultInvalidDate,
1706
+ ordinal: defaultOrdinal,
1707
+ ordinalParse: defaultOrdinalParse,
1708
+ relativeTime: defaultRelativeTime,
1709
 
1710
+ months: defaultLocaleMonths,
1711
+ monthsShort: defaultLocaleMonthsShort,
1712
+
1713
+ week: defaultLocaleWeek,
1714
+
1715
+ weekdays: defaultLocaleWeekdays,
1716
+ weekdaysMin: defaultLocaleWeekdaysMin,
1717
+ weekdaysShort: defaultLocaleWeekdaysShort,
1718
+
1719
+ meridiemParse: defaultLocaleMeridiemParse
1720
+ };
1721
+
1722
+ // internal storage for locale config files
1723
+ var locales = {};
1724
+ var globalLocale;
1725
+
1726
+ function normalizeLocale(key) {
1727
+ return key ? key.toLowerCase().replace('_', '-') : key;
1728
+ }
1729
+
1730
+ // pick the locale from the array
1731
+ // try ['en-au', 'en-gb'] as 'en-au', 'en-gb', 'en', as in move through the list trying each
1732
+ // substring from most specific to least, but move to the next array item if it's a more specific variant than the current root
1733
+ function chooseLocale(names) {
1734
+ var i = 0, j, next, locale, split;
1735
+
1736
+ while (i < names.length) {
1737
+ split = normalizeLocale(names[i]).split('-');
1738
+ j = split.length;
1739
+ next = normalizeLocale(names[i + 1]);
1740
+ next = next ? next.split('-') : null;
1741
+ while (j > 0) {
1742
+ locale = loadLocale(split.slice(0, j).join('-'));
1743
+ if (locale) {
1744
+ return locale;
1745
+ }
1746
+ if (next && next.length >= j && compareArrays(split, next, true) >= j - 1) {
1747
+ //the next array item is better than a shallower substring of this one
1748
+ break;
1749
+ }
1750
+ j--;
1751
  }
1752
+ i++;
1753
+ }
1754
+ return null;
1755
+ }
1756
+
1757
+ function loadLocale(name) {
1758
+ var oldLocale = null;
1759
+ // TODO: Find a better way to register and load all the locales in Node
1760
+ if (!locales[name] && (typeof module !== 'undefined') &&
1761
+ module && module.exports) {
1762
+ try {
1763
+ oldLocale = globalLocale._abbr;
1764
+ require('./locale/' + name);
1765
+ // because defineLocale currently also sets the global locale, we
1766
+ // want to undo that for lazy loaded locales
1767
+ locale_locales__getSetGlobalLocale(oldLocale);
1768
+ } catch (e) { }
1769
+ }
1770
+ return locales[name];
1771
+ }
1772
+
1773
+ // This function will load locale and then set the global locale. If
1774
+ // no arguments are passed in, it will simply return the current global
1775
+ // locale key.
1776
+ function locale_locales__getSetGlobalLocale (key, values) {
1777
+ var data;
1778
+ if (key) {
1779
+ if (isUndefined(values)) {
1780
+ data = locale_locales__getLocale(key);
1781
  }
1782
+ else {
1783
+ data = defineLocale(key, values);
 
 
1784
  }
1785
+
1786
+ if (data) {
1787
+ // moment.duration._locale = moment._locale = data;
1788
+ globalLocale = data;
 
 
 
 
1789
  }
 
 
 
1790
  }
1791
+
1792
+ return globalLocale._abbr;
1793
  }
1794
 
1795
+ function defineLocale (name, config) {
1796
+ if (config !== null) {
1797
+ var parentConfig = baseConfig;
1798
+ config.abbr = name;
1799
+ if (locales[name] != null) {
1800
+ deprecateSimple('defineLocaleOverride',
1801
+ 'use moment.updateLocale(localeName, config) to change ' +
1802
+ 'an existing locale. moment.defineLocale(localeName, ' +
1803
+ 'config) should only be used for creating a new locale ' +
1804
+ 'See http://momentjs.com/guides/#/warnings/define-locale/ for more info.');
1805
+ parentConfig = locales[name]._config;
1806
+ } else if (config.parentLocale != null) {
1807
+ if (locales[config.parentLocale] != null) {
1808
+ parentConfig = locales[config.parentLocale]._config;
1809
+ } else {
1810
+ // treat as if there is no base config
1811
+ deprecateSimple('parentLocaleUndefined',
1812
+ 'specified parentLocale is not defined yet. See http://momentjs.com/guides/#/warnings/parent-locale/');
1813
+ }
1814
  }
1815
+ locales[name] = new Locale(mergeConfigs(parentConfig, config));
1816
 
1817
+ // backwards compat for now: also set the locale
1818
+ locale_locales__getSetGlobalLocale(name);
1819
 
1820
+ return locales[name];
1821
  } else {
1822
+ // useful for testing
1823
+ delete locales[name];
1824
+ return null;
1825
  }
1826
  }
1827
 
1828
+ function updateLocale(name, config) {
1829
+ if (config != null) {
1830
+ var locale, parentConfig = baseConfig;
1831
+ // MERGE
1832
+ if (locales[name] != null) {
1833
+ parentConfig = locales[name]._config;
1834
+ }
1835
+ config = mergeConfigs(parentConfig, config);
1836
+ locale = new Locale(config);
1837
+ locale.parentLocale = locales[name];
1838
+ locales[name] = locale;
1839
 
1840
+ // backwards compat for now: also set the locale
1841
+ locale_locales__getSetGlobalLocale(name);
1842
+ } else {
1843
+ // pass null for config to unupdate, useful for tests
1844
+ if (locales[name] != null) {
1845
+ if (locales[name].parentLocale != null) {
1846
+ locales[name] = locales[name].parentLocale;
1847
+ } else if (locales[name] != null) {
1848
+ delete locales[name];
1849
+ }
1850
  }
1851
  }
1852
+ return locales[name];
1853
  }
1854
 
1855
+ // returns locale data
1856
+ function locale_locales__getLocale (key) {
1857
+ var locale;
1858
+
1859
+ if (key && key._locale && key._locale._abbr) {
1860
+ key = key._locale._abbr;
1861
  }
 
 
1862
 
1863
+ if (!key) {
1864
+ return globalLocale;
 
1865
  }
 
1866
 
1867
+ if (!isArray(key)) {
1868
+ //short-circuit everything else
1869
+ locale = loadLocale(key);
1870
+ if (locale) {
1871
+ return locale;
1872
+ }
1873
+ key = [key];
1874
+ }
1875
+
1876
+ return chooseLocale(key);
1877
  }
1878
 
1879
+ function locale_locales__listLocales() {
1880
+ return keys(locales);
 
 
 
1881
  }
1882
 
1883
+ function checkOverflow (m) {
1884
+ var overflow;
1885
+ var a = m._a;
 
1886
 
1887
+ if (a && getParsingFlags(m).overflow === -2) {
1888
+ overflow =
1889
+ a[MONTH] < 0 || a[MONTH] > 11 ? MONTH :
1890
+ a[DATE] < 1 || a[DATE] > daysInMonth(a[YEAR], a[MONTH]) ? DATE :
1891
+ a[HOUR] < 0 || a[HOUR] > 24 || (a[HOUR] === 24 && (a[MINUTE] !== 0 || a[SECOND] !== 0 || a[MILLISECOND] !== 0)) ? HOUR :
1892
+ a[MINUTE] < 0 || a[MINUTE] > 59 ? MINUTE :
1893
+ a[SECOND] < 0 || a[SECOND] > 59 ? SECOND :
1894
+ a[MILLISECOND] < 0 || a[MILLISECOND] > 999 ? MILLISECOND :
1895
+ -1;
1896
 
1897
+ if (getParsingFlags(m)._overflowDayOfYear && (overflow < YEAR || overflow > DATE)) {
1898
+ overflow = DATE;
1899
+ }
1900
+ if (getParsingFlags(m)._overflowWeeks && overflow === -1) {
1901
+ overflow = WEEK;
1902
+ }
1903
+ if (getParsingFlags(m)._overflowWeekday && overflow === -1) {
1904
+ overflow = WEEKDAY;
1905
+ }
1906
 
1907
+ getParsingFlags(m).overflow = overflow;
 
 
 
 
 
1908
  }
1909
 
1910
+ return m;
1911
  }
1912
 
1913
+ // iso 8601 regex
1914
+ // 0000-00-00 0000-W00 or 0000-W00-0 + T + 00 or 00:00 or 00:00:00 or 00:00:00.000 + +00:00 or +0000 or +00)
1915
+ var extendedIsoRegex = /^\s*((?:[+-]\d{6}|\d{4})-(?:\d\d-\d\d|W\d\d-\d|W\d\d|\d\d\d|\d\d))(?:(T| )(\d\d(?::\d\d(?::\d\d(?:[.,]\d+)?)?)?)([\+\-]\d\d(?::?\d\d)?|\s*Z)?)?/;
1916
+ var basicIsoRegex = /^\s*((?:[+-]\d{6}|\d{4})(?:\d\d\d\d|W\d\d\d|W\d\d|\d\d\d|\d\d))(?:(T| )(\d\d(?:\d\d(?:\d\d(?:[.,]\d+)?)?)?)([\+\-]\d\d(?::?\d\d)?|\s*Z)?)?/;
1917
 
1918
+ var tzRegex = /Z|[+-]\d\d(?::?\d\d)?/;
 
 
1919
 
1920
+ var isoDates = [
1921
+ ['YYYYYY-MM-DD', /[+-]\d{6}-\d\d-\d\d/],
1922
+ ['YYYY-MM-DD', /\d{4}-\d\d-\d\d/],
1923
+ ['GGGG-[W]WW-E', /\d{4}-W\d\d-\d/],
1924
+ ['GGGG-[W]WW', /\d{4}-W\d\d/, false],
1925
+ ['YYYY-DDD', /\d{4}-\d{3}/],
1926
+ ['YYYY-MM', /\d{4}-\d\d/, false],
1927
+ ['YYYYYYMMDD', /[+-]\d{10}/],
1928
+ ['YYYYMMDD', /\d{8}/],
1929
+ // YYYYMM is NOT allowed by the standard
1930
+ ['GGGG[W]WWE', /\d{4}W\d{3}/],
1931
+ ['GGGG[W]WW', /\d{4}W\d{2}/, false],
1932
+ ['YYYYDDD', /\d{7}/]
1933
+ ];
1934
 
1935
+ // iso time formats and regexes
1936
+ var isoTimes = [
1937
+ ['HH:mm:ss.SSSS', /\d\d:\d\d:\d\d\.\d+/],
1938
+ ['HH:mm:ss,SSSS', /\d\d:\d\d:\d\d,\d+/],
1939
+ ['HH:mm:ss', /\d\d:\d\d:\d\d/],
1940
+ ['HH:mm', /\d\d:\d\d/],
1941
+ ['HHmmss.SSSS', /\d\d\d\d\d\d\.\d+/],
1942
+ ['HHmmss,SSSS', /\d\d\d\d\d\d,\d+/],
1943
+ ['HHmmss', /\d\d\d\d\d\d/],
1944
+ ['HHmm', /\d\d\d\d/],
1945
+ ['HH', /\d\d/]
1946
+ ];
1947
 
1948
+ var aspNetJsonRegex = /^\/?Date\((\-?\d+)/i;
 
 
 
1949
 
1950
+ // date from iso format
1951
+ function configFromISO(config) {
1952
+ var i, l,
1953
+ string = config._i,
1954
+ match = extendedIsoRegex.exec(string) || basicIsoRegex.exec(string),
1955
+ allowTime, dateFormat, timeFormat, tzFormat;
 
1956
 
1957
+ if (match) {
1958
+ getParsingFlags(config).iso = true;
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1959
 
1960
+ for (i = 0, l = isoDates.length; i < l; i++) {
1961
+ if (isoDates[i][1].exec(match[1])) {
1962
+ dateFormat = isoDates[i][0];
1963
+ allowTime = isoDates[i][2] !== false;
1964
+ break;
1965
+ }
1966
+ }
1967
+ if (dateFormat == null) {
1968
+ config._isValid = false;
1969
+ return;
1970
+ }
1971
+ if (match[3]) {
1972
+ for (i = 0, l = isoTimes.length; i < l; i++) {
1973
+ if (isoTimes[i][1].exec(match[3])) {
1974
+ // match[2] should be 'T' or space
1975
+ timeFormat = (match[2] || ' ') + isoTimes[i][0];
1976
+ break;
1977
+ }
1978
+ }
1979
+ if (timeFormat == null) {
1980
+ config._isValid = false;
1981
+ return;
1982
+ }
1983
+ }
1984
+ if (!allowTime && timeFormat != null) {
1985
+ config._isValid = false;
1986
+ return;
1987
+ }
1988
+ if (match[4]) {
1989
+ if (tzRegex.exec(match[4])) {
1990
+ tzFormat = 'Z';
1991
+ } else {
1992
+ config._isValid = false;
1993
+ return;
1994
+ }
1995
+ }
1996
+ config._f = dateFormat + (timeFormat || '') + (tzFormat || '');
1997
+ configFromStringAndFormat(config);
1998
+ } else {
1999
+ config._isValid = false;
2000
  }
2001
+ }
2002
 
2003
+ // date from iso format or fallback
2004
+ function configFromString(config) {
2005
+ var matched = aspNetJsonRegex.exec(config._i);
2006
 
2007
+ if (matched !== null) {
2008
+ config._d = new Date(+matched[1]);
2009
+ return;
2010
  }
2011
 
2012
+ configFromISO(config);
2013
+ if (config._isValid === false) {
2014
+ delete config._isValid;
2015
+ utils_hooks__hooks.createFromInputFallback(config);
2016
+ }
2017
  }
2018
 
2019
+ utils_hooks__hooks.createFromInputFallback = deprecate(
2020
+ 'moment construction falls back to js Date. This is ' +
2021
+ 'discouraged and will be removed in upcoming major ' +
2022
+ 'release. Please refer to ' +
2023
+ 'http://momentjs.com/guides/#/warnings/js-date/ for more info.',
2024
+ function (config) {
2025
+ config._d = new Date(config._i + (config._useUTC ? ' UTC' : ''));
2026
+ }
2027
+ );
2028
 
2029
+ // Pick the first defined of two or three arguments.
2030
+ function defaults(a, b, c) {
2031
+ if (a != null) {
2032
+ return a;
2033
+ }
2034
+ if (b != null) {
2035
+ return b;
2036
+ }
2037
+ return c;
2038
  }
2039
 
2040
+ function currentDateArray(config) {
2041
+ // hooks is actually the exported moment object
2042
+ var nowValue = new Date(utils_hooks__hooks.now());
2043
+ if (config._useUTC) {
2044
+ return [nowValue.getUTCFullYear(), nowValue.getUTCMonth(), nowValue.getUTCDate()];
 
 
2045
  }
2046
+ return [nowValue.getFullYear(), nowValue.getMonth(), nowValue.getDate()];
 
 
 
2047
  }
2048
 
2049
+ // convert an array to a date.
2050
+ // the array should mirror the parameters below
2051
+ // note: all values past the year are optional and will default to the lowest possible value.
2052
+ // [year, month, day , hour, minute, second, millisecond]
2053
+ function configFromArray (config) {
2054
+ var i, date, input = [], currentDate, yearToUse;
2055
 
2056
+ if (config._d) {
2057
+ return;
 
 
 
 
 
2058
  }
2059
 
2060
+ currentDate = currentDateArray(config);
 
2061
 
2062
+ //compute day of the year from weeks and weekdays
2063
+ if (config._w && config._a[DATE] == null && config._a[MONTH] == null) {
2064
+ dayOfYearFromWeekInfo(config);
 
 
2065
  }
 
2066
 
2067
+ //if the day of the year is set, figure out what it is
2068
+ if (config._dayOfYear) {
2069
+ yearToUse = defaults(config._a[YEAR], currentDate[YEAR]);
 
 
 
 
 
 
2070
 
2071
+ if (config._dayOfYear > daysInYear(yearToUse)) {
2072
+ getParsingFlags(config)._overflowDayOfYear = true;
2073
+ }
 
 
 
2074
 
2075
+ date = createUTCDate(yearToUse, 0, config._dayOfYear);
2076
+ config._a[MONTH] = date.getUTCMonth();
2077
+ config._a[DATE] = date.getUTCDate();
2078
+ }
2079
 
2080
+ // Default to current date.
2081
+ // * if no year, month, day of month are given, default to today
2082
+ // * if day of month is given, default month and year
2083
+ // * if month is given, default only year
2084
+ // * if year is given, don't default anything
2085
+ for (i = 0; i < 3 && config._a[i] == null; ++i) {
2086
+ config._a[i] = input[i] = currentDate[i];
2087
  }
2088
 
2089
+ // Zero out whatever was not defaulted, including time
2090
+ for (; i < 7; i++) {
2091
+ config._a[i] = input[i] = (config._a[i] == null) ? (i === 2 ? 1 : 0) : config._a[i];
2092
+ }
2093
 
2094
+ // Check for 24:00:00.000
2095
+ if (config._a[HOUR] === 24 &&
2096
+ config._a[MINUTE] === 0 &&
2097
+ config._a[SECOND] === 0 &&
2098
+ config._a[MILLISECOND] === 0) {
2099
+ config._nextDay = true;
2100
+ config._a[HOUR] = 0;
2101
  }
2102
+
2103
+ config._d = (config._useUTC ? createUTCDate : createDate).apply(null, input);
2104
+ // Apply timezone offset from input. The actual utcOffset can be changed
2105
+ // with parseZone.
2106
+ if (config._tzm != null) {
2107
+ config._d.setUTCMinutes(config._d.getUTCMinutes() - config._tzm);
2108
  }
2109
+
2110
+ if (config._nextDay) {
2111
+ config._a[HOUR] = 24;
2112
  }
2113
  }
2114
 
2115
+ function dayOfYearFromWeekInfo(config) {
2116
+ var w, weekYear, week, weekday, dow, doy, temp, weekdayOverflow;
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
2117
 
2118
+ w = config._w;
2119
+ if (w.GG != null || w.W != null || w.E != null) {
2120
+ dow = 1;
2121
+ doy = 4;
2122
 
2123
+ // TODO: We need to take the current isoWeekYear, but that depends on
2124
+ // how we interpret now (local, utc, fixed offset). So create
2125
+ // a now version of current config (take local/utc/offset flags, and
2126
+ // create now).
2127
+ weekYear = defaults(w.GG, config._a[YEAR], weekOfYear(local__createLocal(), 1, 4).year);
2128
+ week = defaults(w.W, 1);
2129
+ weekday = defaults(w.E, 1);
2130
+ if (weekday < 1 || weekday > 7) {
2131
+ weekdayOverflow = true;
2132
+ }
2133
  } else {
2134
+ dow = config._locale._week.dow;
2135
+ doy = config._locale._week.doy;
 
2136
 
2137
+ weekYear = defaults(w.gg, config._a[YEAR], weekOfYear(local__createLocal(), dow, doy).year);
2138
+ week = defaults(w.w, 1);
2139
+
2140
+ if (w.d != null) {
2141
+ // weekday -- low day numbers are considered next week
2142
+ weekday = w.d;
2143
+ if (weekday < 0 || weekday > 6) {
2144
+ weekdayOverflow = true;
2145
+ }
2146
+ } else if (w.e != null) {
2147
+ // local weekday -- counting starts from begining of week
2148
+ weekday = w.e + dow;
2149
+ if (w.e < 0 || w.e > 6) {
2150
+ weekdayOverflow = true;
2151
+ }
2152
+ } else {
2153
+ // default to begining of week
2154
+ weekday = dow;
2155
+ }
2156
  }
2157
+ if (week < 1 || week > weeksInYear(weekYear, dow, doy)) {
2158
+ getParsingFlags(config)._overflowWeeks = true;
2159
+ } else if (weekdayOverflow != null) {
2160
+ getParsingFlags(config)._overflowWeekday = true;
2161
  } else {
2162
+ temp = dayOfYearFromWeeks(weekYear, week, weekday, dow, doy);
2163
+ config._a[YEAR] = temp.year;
2164
+ config._dayOfYear = temp.dayOfYear;
2165
  }
2166
  }
2167
 
2168
+ // constant that refers to the ISO standard
2169
+ utils_hooks__hooks.ISO_8601 = function () {};
 
 
 
2170
 
2171
+ // date from string and format string
2172
+ function configFromStringAndFormat(config) {
2173
+ // TODO: Move this to another part of the creation flow to prevent circular deps
2174
+ if (config._f === utils_hooks__hooks.ISO_8601) {
2175
+ configFromISO(config);
2176
+ return;
 
 
 
 
 
 
2177
  }
 
2178
 
2179
+ config._a = [];
2180
+ getParsingFlags(config).empty = true;
 
2181
 
2182
+ // This array is used to make a Date, either with `new Date` or `Date.UTC`
2183
+ var string = '' + config._i,
2184
+ i, parsedInput, tokens, token, skipped,
2185
+ stringLength = string.length,
2186
+ totalParsedInputLength = 0;
2187
 
2188
+ tokens = expandFormat(config._f, config._locale).match(formattingTokens) || [];
 
 
 
2189
 
2190
+ for (i = 0; i < tokens.length; i++) {
2191
+ token = tokens[i];
2192
+ parsedInput = (string.match(getParseRegexForToken(token, config)) || [])[0];
2193
+ // console.log('token', token, 'parsedInput', parsedInput,
2194
+ // 'regex', getParseRegexForToken(token, config));
2195
+ if (parsedInput) {
2196
+ skipped = string.substr(0, string.indexOf(parsedInput));
2197
+ if (skipped.length > 0) {
2198
+ getParsingFlags(config).unusedInput.push(skipped);
2199
+ }
2200
+ string = string.slice(string.indexOf(parsedInput) + parsedInput.length);
2201
+ totalParsedInputLength += parsedInput.length;
2202
+ }
2203
+ // don't parse if it's not a known token
2204
+ if (formatTokenFunctions[token]) {
2205
+ if (parsedInput) {
2206
+ getParsingFlags(config).empty = false;
2207
+ }
2208
+ else {
2209
+ getParsingFlags(config).unusedTokens.push(token);
2210
+ }
2211
+ addTimeToArrayFromToken(token, parsedInput, config);
2212
+ }
2213
+ else if (config._strict && !parsedInput) {
2214
+ getParsingFlags(config).unusedTokens.push(token);
2215
+ }
2216
  }
2217
 
2218
+ // add remaining unparsed input length to the string
2219
+ getParsingFlags(config).charsLeftOver = stringLength - totalParsedInputLength;
2220
+ if (string.length > 0) {
2221
+ getParsingFlags(config).unusedInput.push(string);
2222
  }
2223
 
2224
+ // clear _12h flag if hour is <= 12
2225
+ if (config._a[HOUR] <= 12 &&
2226
+ getParsingFlags(config).bigHour === true &&
2227
+ config._a[HOUR] > 0) {
2228
+ getParsingFlags(config).bigHour = undefined;
2229
+ }
2230
 
2231
+ getParsingFlags(config).parsedDateParts = config._a.slice(0);
2232
+ getParsingFlags(config).meridiem = config._meridiem;
2233
+ // handle meridiem
2234
+ config._a[HOUR] = meridiemFixWrap(config._locale, config._a[HOUR], config._meridiem);
2235
 
2236
+ configFromArray(config);
2237
+ checkOverflow(config);
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
2238
  }
2239
 
 
 
 
 
 
 
2240
 
2241
+ function meridiemFixWrap (locale, hour, meridiem) {
2242
+ var isPm;
2243
+
2244
+ if (meridiem == null) {
2245
+ // nothing to do
2246
+ return hour;
2247
+ }
2248
+ if (locale.meridiemHour != null) {
2249
+ return locale.meridiemHour(hour, meridiem);
2250
+ } else if (locale.isPM != null) {
2251
+ // Fallback
2252
+ isPm = locale.isPM(meridiem);
2253
+ if (isPm && hour < 12) {
2254
+ hour += 12;
2255
+ }
2256
+ if (!isPm && hour === 12) {
2257
+ hour = 0;
2258
+ }
2259
+ return hour;
2260
  } else {
2261
+ // this is not supposed to happen
2262
+ return hour;
 
2263
  }
 
 
 
2264
  }
2265
 
2266
+ // date from string and array of format strings
2267
+ function configFromStringAndArray(config) {
2268
+ var tempConfig,
2269
+ bestMoment,
2270
 
2271
+ scoreToBeat,
2272
+ i,
2273
+ currentScore;
2274
 
2275
+ if (config._f.length === 0) {
2276
+ getParsingFlags(config).invalidFormat = true;
2277
+ config._d = new Date(NaN);
2278
+ return;
 
 
 
 
 
 
 
2279
  }
 
2280
 
2281
+ for (i = 0; i < config._f.length; i++) {
2282
+ currentScore = 0;
2283
+ tempConfig = copyConfig({}, config);
2284
+ if (config._useUTC != null) {
2285
+ tempConfig._useUTC = config._useUTC;
2286
+ }
2287
+ tempConfig._f = config._f[i];
2288
+ configFromStringAndFormat(tempConfig);
2289
+
2290
+ if (!valid__isValid(tempConfig)) {
2291
+ continue;
2292
+ }
2293
+
2294
+ // if there is any input that was not parsed add a penalty for that format
2295
+ currentScore += getParsingFlags(tempConfig).charsLeftOver;
2296
+
2297
+ //or tokens
2298
+ currentScore += getParsingFlags(tempConfig).unusedTokens.length * 10;
2299
+
2300
+ getParsingFlags(tempConfig).score = currentScore;
2301
+
2302
+ if (scoreToBeat == null || currentScore < scoreToBeat) {
2303
+ scoreToBeat = currentScore;
2304
+ bestMoment = tempConfig;
2305
+ }
2306
  }
2307
+
2308
+ extend(config, bestMoment || tempConfig);
2309
  }
2310
 
2311
+ function configFromObject(config) {
2312
+ if (config._d) {
2313
+ return;
 
 
 
 
2314
  }
 
2315
 
2316
+ var i = normalizeObjectUnits(config._i);
2317
+ config._a = map([i.year, i.month, i.day || i.date, i.hour, i.minute, i.second, i.millisecond], function (obj) {
2318
+ return obj && parseInt(obj, 10);
2319
+ });
2320
+
2321
+ configFromArray(config);
2322
  }
2323
 
2324
+ function createFromConfig (config) {
2325
+ var res = new Moment(checkOverflow(prepareConfig(config)));
2326
+ if (res._nextDay) {
2327
+ // Adding is smart enough around DST
2328
+ res.add(1, 'd');
2329
+ res._nextDay = undefined;
 
2330
  }
 
2331
 
2332
+ return res;
 
2333
  }
2334
 
2335
+ function prepareConfig (config) {
2336
+ var input = config._i,
2337
+ format = config._f;
 
 
2338
 
2339
+ config._locale = config._locale || locale_locales__getLocale(config._l);
2340
+
2341
+ if (input === null || (format === undefined && input === '')) {
2342
+ return valid__createInvalid({nullInput: true});
 
 
 
 
2343
  }
 
2344
 
2345
+ if (typeof input === 'string') {
2346
+ config._i = input = config._locale.preparse(input);
 
 
 
 
 
 
2347
  }
 
2348
 
2349
+ if (isMoment(input)) {
2350
+ return new Moment(checkOverflow(input));
2351
+ } else if (isArray(format)) {
2352
+ configFromStringAndArray(config);
2353
+ } else if (isDate(input)) {
2354
+ config._d = input;
2355
+ } else if (format) {
2356
+ configFromStringAndFormat(config);
2357
+ } else {
2358
+ configFromInput(config);
2359
+ }
2360
 
2361
+ if (!valid__isValid(config)) {
2362
+ config._d = null;
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
2363
  }
2364
 
2365
+ return config;
2366
+ }
2367
+
2368
+ function configFromInput(config) {
2369
+ var input = config._i;
2370
+ if (input === undefined) {
2371
+ config._d = new Date(utils_hooks__hooks.now());
2372
+ } else if (isDate(input)) {
2373
+ config._d = new Date(input.valueOf());
2374
+ } else if (typeof input === 'string') {
2375
+ configFromString(config);
2376
+ } else if (isArray(input)) {
2377
+ config._a = map(input.slice(0), function (obj) {
2378
+ return parseInt(obj, 10);
2379
+ });
2380
+ configFromArray(config);
2381
+ } else if (typeof(input) === 'object') {
2382
+ configFromObject(config);
2383
+ } else if (typeof(input) === 'number') {
2384
+ // from milliseconds
2385
+ config._d = new Date(input);
2386
+ } else {
2387
+ utils_hooks__hooks.createFromInputFallback(config);
2388
  }
2389
+ }
2390
+
2391
+ function createLocalOrUTC (input, format, locale, strict, isUTC) {
2392
+ var c = {};
2393
+
2394
+ if (typeof(locale) === 'boolean') {
2395
+ strict = locale;
2396
+ locale = undefined;
2397
  }
2398
 
2399
+ if ((isObject(input) && isObjectEmpty(input)) ||
2400
+ (isArray(input) && input.length === 0)) {
2401
+ input = undefined;
2402
  }
2403
+ // object construction must be done this way.
2404
+ // https://github.com/moment/moment/issues/1423
2405
+ c._isAMomentObject = true;
2406
+ c._useUTC = c._isUTC = isUTC;
2407
+ c._l = locale;
2408
+ c._i = input;
2409
+ c._f = format;
2410
+ c._strict = strict;
2411
 
2412
+ return createFromConfig(c);
2413
  }
2414
 
2415
+ function local__createLocal (input, format, locale, strict) {
2416
+ return createLocalOrUTC(input, format, locale, strict, false);
2417
+ }
2418
+
2419
+ var prototypeMin = deprecate(
2420
+ 'moment().min is deprecated, use moment.max instead. http://momentjs.com/guides/#/warnings/min-max/',
2421
+ function () {
2422
+ var other = local__createLocal.apply(null, arguments);
2423
+ if (this.isValid() && other.isValid()) {
2424
+ return other < this ? this : other;
2425
+ } else {
2426
+ return valid__createInvalid();
2427
+ }
2428
  }
2429
+ );
2430
 
2431
+ var prototypeMax = deprecate(
2432
+ 'moment().max is deprecated, use moment.min instead. http://momentjs.com/guides/#/warnings/min-max/',
2433
+ function () {
2434
+ var other = local__createLocal.apply(null, arguments);
2435
+ if (this.isValid() && other.isValid()) {
2436
+ return other > this ? this : other;
2437
+ } else {
2438
+ return valid__createInvalid();
2439
+ }
2440
  }
2441
+ );
2442
 
2443
+ // Pick a moment m from moments so that m[fn](other) is true for all
2444
+ // other. This relies on the function fn to be transitive.
2445
+ //
2446
+ // moments should either be an array of moment objects or an array, whose
2447
+ // first element is an array of moment objects.
2448
+ function pickBy(fn, moments) {
2449
+ var res, i;
2450
+ if (moments.length === 1 && isArray(moments[0])) {
2451
+ moments = moments[0];
2452
+ }
2453
+ if (!moments.length) {
2454
+ return local__createLocal();
2455
+ }
2456
+ res = moments[0];
2457
+ for (i = 1; i < moments.length; ++i) {
2458
+ if (!moments[i].isValid() || moments[i][fn](res)) {
2459
+ res = moments[i];
2460
+ }
2461
+ }
2462
+ return res;
2463
  }
2464
 
2465
+ // TODO: Use [].sort instead?
2466
+ function min () {
2467
+ var args = [].slice.call(arguments, 0);
2468
 
2469
+ return pickBy('isBefore', args);
 
2470
  }
2471
 
2472
+ function max () {
2473
+ var args = [].slice.call(arguments, 0);
 
2474
 
2475
+ return pickBy('isAfter', args);
 
 
2476
  }
2477
 
2478
+ var now = function () {
2479
+ return Date.now ? Date.now() : +(new Date());
2480
+ };
 
 
 
 
 
 
 
 
 
2481
 
2482
+ function Duration (duration) {
2483
+ var normalizedInput = normalizeObjectUnits(duration),
2484
+ years = normalizedInput.year || 0,
2485
+ quarters = normalizedInput.quarter || 0,
2486
+ months = normalizedInput.month || 0,
2487
+ weeks = normalizedInput.week || 0,
2488
+ days = normalizedInput.day || 0,
2489
+ hours = normalizedInput.hour || 0,
2490
+ minutes = normalizedInput.minute || 0,
2491
+ seconds = normalizedInput.second || 0,
2492
+ milliseconds = normalizedInput.millisecond || 0;
2493
 
2494
+ // representation for dateAddRemove
2495
+ this._milliseconds = +milliseconds +
2496
+ seconds * 1e3 + // 1000
2497
+ minutes * 6e4 + // 1000 * 60
2498
+ hours * 1000 * 60 * 60; //using 1000 * 60 * 60 instead of 36e5 to avoid floating point rounding errors https://github.com/moment/moment/issues/2978
2499
+ // Because of dateAddRemove treats 24 hours as different from a
2500
+ // day when working around DST, we need to store them separately
2501
+ this._days = +days +
2502
+ weeks * 7;
2503
+ // It is impossible translate months into days without knowing
2504
+ // which months you are are talking about, so we have to store
2505
+ // it separately.
2506
+ this._months = +months +
2507
+ quarters * 3 +
2508
+ years * 12;
2509
 
2510
+ this._data = {};
 
 
2511
 
2512
+ this._locale = locale_locales__getLocale();
2513
+
2514
+ this._bubble();
2515
  }
2516
 
2517
+ function isDuration (obj) {
2518
+ return obj instanceof Duration;
 
 
 
 
 
 
2519
  }
2520
 
2521
  // FORMATTING
2522
 
2523
+ function offset (token, separator) {
2524
+ addFormatToken(token, 0, 0, function () {
2525
+ var offset = this.utcOffset();
2526
+ var sign = '+';
2527
+ if (offset < 0) {
2528
+ offset = -offset;
2529
+ sign = '-';
2530
+ }
2531
+ return sign + zeroFill(~~(offset / 60), 2) + separator + zeroFill(~~(offset) % 60, 2);
2532
+ });
2533
  }
2534
 
2535
+ offset('Z', ':');
2536
+ offset('ZZ', '');
 
 
 
 
 
 
 
2537
 
2538
  // PARSING
2539
 
2540
+ addRegexToken('Z', matchShortOffset);
2541
+ addRegexToken('ZZ', matchShortOffset);
2542
+ addParseToken(['Z', 'ZZ'], function (input, array, config) {
2543
+ config._useUTC = true;
2544
+ config._tzm = offsetFromString(matchShortOffset, input);
 
 
 
 
 
 
 
 
 
 
2545
  });
2546
 
2547
+ // HELPERS
 
 
 
 
 
 
 
 
 
2548
 
2549
+ // timezone chunker
2550
+ // '+10:00' > ['10', '00']
2551
+ // '-1530' > ['-15', '30']
2552
+ var chunkOffset = /([\+\-]|\d\d)/gi;
2553
 
2554
+ function offsetFromString(matcher, string) {
2555
+ var matches = ((string || '').match(matcher) || []);
2556
+ var chunk = matches[matches.length - 1] || [];
2557
+ var parts = (chunk + '').match(chunkOffset) || ['-', 0, 0];
2558
+ var minutes = +(parts[1] * 60) + toInt(parts[2]);
2559
 
2560
+ return parts[0] === '+' ? minutes : -minutes;
 
 
2561
  }
2562
 
2563
+ // Return a moment from input, that is local/utc/zone equivalent to model.
2564
+ function cloneWithOffset(input, model) {
2565
+ var res, diff;
2566
+ if (model._isUTC) {
2567
+ res = model.clone();
2568
+ diff = (isMoment(input) || isDate(input) ? input.valueOf() : local__createLocal(input).valueOf()) - res.valueOf();
2569
+ // Use low-level api, because this fn is low-level api.
2570
+ res._d.setTime(res._d.valueOf() + diff);
2571
+ utils_hooks__hooks.updateOffset(res, false);
2572
+ return res;
2573
  } else {
2574
+ return local__createLocal(input).local();
 
 
 
 
2575
  }
2576
  }
2577
 
2578
+ function getDateOffset (m) {
2579
+ // On Firefox.24 Date#getTimezoneOffset returns a floating point.
2580
+ // https://github.com/moment/moment/pull/1871
2581
+ return -Math.round(m._d.getTimezoneOffset() / 15) * 15;
 
 
 
 
2582
  }
2583
 
2584
+ // HOOKS
2585
 
2586
+ // This function will be called whenever a moment is mutated.
2587
+ // It is intended to keep the offset in sync with the timezone.
2588
+ utils_hooks__hooks.updateOffset = function () {};
2589
 
2590
+ // MOMENTS
2591
 
2592
+ // keepLocalTime = true means only change the timezone, without
2593
+ // affecting the local hour. So 5:31:26 +0300 --[utcOffset(2, true)]-->
2594
+ // 5:31:26 +0200 It is possible that 5:31:26 doesn't exist with offset
2595
+ // +0200, so we adjust the time as needed, to be valid.
2596
+ //
2597
+ // Keeping the time actually adds/subtracts (one hour)
2598
+ // from the actual represented time. That is why we call updateOffset
2599
+ // a second time. In case it wants us to change the offset again
2600
+ // _changeInProgress == true case, then we have to adjust, because
2601
+ // there is no such time in the given timezone.
2602
+ function getSetOffset (input, keepLocalTime) {
2603
+ var offset = this._offset || 0,
2604
+ localAdjust;
2605
+ if (!this.isValid()) {
2606
+ return input != null ? this : NaN;
2607
+ }
2608
+ if (input != null) {
2609
+ if (typeof input === 'string') {
2610
+ input = offsetFromString(matchShortOffset, input);
2611
+ } else if (Math.abs(input) < 16) {
2612
+ input = input * 60;
2613
+ }
2614
+ if (!this._isUTC && keepLocalTime) {
2615
+ localAdjust = getDateOffset(this);
2616
+ }
2617
+ this._offset = input;
2618
+ this._isUTC = true;
2619
+ if (localAdjust != null) {
2620
+ this.add(localAdjust, 'm');
2621
+ }
2622
+ if (offset !== input) {
2623
+ if (!keepLocalTime || this._changeInProgress) {
2624
+ add_subtract__addSubtract(this, create__createDuration(input - offset, 'm'), 1, false);
2625
+ } else if (!this._changeInProgress) {
2626
+ this._changeInProgress = true;
2627
+ utils_hooks__hooks.updateOffset(this, true);
2628
+ this._changeInProgress = null;
2629
+ }
2630
+ }
2631
+ return this;
2632
+ } else {
2633
+ return this._isUTC ? offset : getDateOffset(this);
2634
+ }
2635
+ }
2636
 
2637
+ function getSetZone (input, keepLocalTime) {
2638
+ if (input != null) {
2639
+ if (typeof input !== 'string') {
2640
+ input = -input;
2641
+ }
2642
 
2643
+ this.utcOffset(input, keepLocalTime);
 
 
 
2644
 
2645
+ return this;
2646
+ } else {
2647
+ return -this.utcOffset();
2648
+ }
2649
+ }
2650
 
2651
+ function setOffsetToUTC (keepLocalTime) {
2652
+ return this.utcOffset(0, keepLocalTime);
2653
  }
2654
 
2655
+ function setOffsetToLocal (keepLocalTime) {
2656
+ if (this._isUTC) {
2657
+ this.utcOffset(0, keepLocalTime);
2658
+ this._isUTC = false;
2659
 
2660
+ if (keepLocalTime) {
2661
+ this.subtract(getDateOffset(this), 'm');
2662
+ }
2663
+ }
2664
+ return this;
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
2665
  }
2666
 
2667
+ function setOffsetToParsedOffset () {
2668
+ if (this._tzm) {
2669
+ this.utcOffset(this._tzm);
2670
+ } else if (typeof this._i === 'string') {
2671
+ this.utcOffset(offsetFromString(matchOffset, this._i));
2672
+ }
2673
+ return this;
2674
  }
2675
 
2676
+ function hasAlignedHourOffset (input) {
2677
+ if (!this.isValid()) {
2678
+ return false;
2679
+ }
2680
+ input = input ? local__createLocal(input).utcOffset() : 0;
2681
 
2682
+ return (this.utcOffset() - input) % 60 === 0;
 
 
2683
  }
2684
 
2685
+ function isDaylightSavingTime () {
2686
+ return (
2687
+ this.utcOffset() > this.clone().month(0).utcOffset() ||
2688
+ this.utcOffset() > this.clone().month(5).utcOffset()
2689
+ );
2690
  }
2691
 
2692
+ function isDaylightSavingTimeShifted () {
2693
+ if (!isUndefined(this._isDSTShifted)) {
2694
+ return this._isDSTShifted;
2695
+ }
2696
 
2697
+ var c = {};
2698
 
2699
+ copyConfig(c, this);
2700
+ c = prepareConfig(c);
2701
 
2702
+ if (c._a) {
2703
+ var other = c._isUTC ? create_utc__createUTC(c._a) : local__createLocal(c._a);
2704
+ this._isDSTShifted = this.isValid() &&
2705
+ compareArrays(c._a, other.toArray()) > 0;
2706
+ } else {
2707
+ this._isDSTShifted = false;
2708
+ }
2709
 
2710
+ return this._isDSTShifted;
2711
+ }
2712
 
2713
+ function isLocal () {
2714
+ return this.isValid() ? !this._isUTC : false;
2715
+ }
 
 
2716
 
2717
+ function isUtcOffset () {
2718
+ return this.isValid() ? this._isUTC : false;
2719
+ }
 
2720
 
2721
+ function isUtc () {
2722
+ return this.isValid() ? this._isUTC && this._offset === 0 : false;
2723
+ }
2724
 
2725
+ // ASP.NET json date format regex
2726
+ var aspNetRegex = /^(\-)?(?:(\d*)[. ])?(\d+)\:(\d+)(?:\:(\d+)\.?(\d{3})?\d*)?$/;
2727
 
2728
+ // from http://docs.closure-library.googlecode.com/git/closure_goog_date_date.js.source.html
2729
+ // somewhat more in line with 4.4.3.2 2004 spec, but allows decimal anywhere
2730
+ // and further modified to allow for strings containing both week and day
2731
+ var isoRegex = /^(-)?P(?:(-?[0-9,.]*)Y)?(?:(-?[0-9,.]*)M)?(?:(-?[0-9,.]*)W)?(?:(-?[0-9,.]*)D)?(?:T(?:(-?[0-9,.]*)H)?(?:(-?[0-9,.]*)M)?(?:(-?[0-9,.]*)S)?)?$/;
2732
 
2733
+ function create__createDuration (input, key) {
2734
+ var duration = input,
2735
+ // matching against regexp is expensive, do it on demand
2736
+ match = null,
2737
+ sign,
2738
+ ret,
2739
+ diffRes;
2740
 
2741
+ if (isDuration(input)) {
2742
+ duration = {
2743
+ ms : input._milliseconds,
2744
+ d : input._days,
2745
+ M : input._months
2746
+ };
2747
+ } else if (typeof input === 'number') {
2748
+ duration = {};
2749
+ if (key) {
2750
+ duration[key] = input;
2751
+ } else {
2752
+ duration.milliseconds = input;
2753
+ }
2754
+ } else if (!!(match = aspNetRegex.exec(input))) {
2755
+ sign = (match[1] === '-') ? -1 : 1;
2756
+ duration = {
2757
+ y : 0,
2758
+ d : toInt(match[DATE]) * sign,
2759
+ h : toInt(match[HOUR]) * sign,
2760
+ m : toInt(match[MINUTE]) * sign,
2761
+ s : toInt(match[SECOND]) * sign,
2762
+ ms : toInt(match[MILLISECOND]) * sign
2763
+ };
2764
+ } else if (!!(match = isoRegex.exec(input))) {
2765
+ sign = (match[1] === '-') ? -1 : 1;
2766
+ duration = {
2767
+ y : parseIso(match[2], sign),
2768
+ M : parseIso(match[3], sign),
2769
+ w : parseIso(match[4], sign),
2770
+ d : parseIso(match[5], sign),
2771
+ h : parseIso(match[6], sign),
2772
+ m : parseIso(match[7], sign),
2773
+ s : parseIso(match[8], sign)
2774
+ };
2775
+ } else if (duration == null) {// checks for null or undefined
2776
+ duration = {};
2777
+ } else if (typeof duration === 'object' && ('from' in duration || 'to' in duration)) {
2778
+ diffRes = momentsDifference(local__createLocal(duration.from), local__createLocal(duration.to));
2779
 
2780
+ duration = {};
2781
+ duration.ms = diffRes.milliseconds;
2782
+ duration.M = diffRes.months;
2783
+ }
2784
 
2785
+ ret = new Duration(duration);
 
 
2786
 
2787
+ if (isDuration(input) && hasOwnProp(input, '_locale')) {
2788
+ ret._locale = input._locale;
2789
+ }
2790
 
2791
+ return ret;
2792
+ }
2793
 
2794
+ create__createDuration.fn = Duration.prototype;
 
 
2795
 
2796
+ function parseIso (inp, sign) {
2797
+ // We'd normally use ~~inp for this, but unfortunately it also
2798
+ // converts floats to ints.
2799
+ // inp may be undefined, so careful calling replace on it.
2800
+ var res = inp && parseFloat(inp.replace(',', '.'));
2801
+ // apply sign while we're at it
2802
+ return (isNaN(res) ? 0 : res) * sign;
2803
+ }
2804
 
2805
+ function positiveMomentsDifference(base, other) {
2806
+ var res = {milliseconds: 0, months: 0};
 
 
 
 
 
 
 
 
 
 
2807
 
2808
+ res.months = other.month() - base.month() +
2809
+ (other.year() - base.year()) * 12;
2810
+ if (base.clone().add(res.months, 'M').isAfter(other)) {
2811
+ --res.months;
 
 
 
2812
  }
 
2813
 
2814
+ res.milliseconds = +other - +(base.clone().add(res.months, 'M'));
 
 
2815
 
2816
+ return res;
2817
+ }
2818
 
2819
+ function momentsDifference(base, other) {
2820
+ var res;
2821
+ if (!(base.isValid() && other.isValid())) {
2822
+ return {milliseconds: 0, months: 0};
2823
  }
2824
 
2825
+ other = cloneWithOffset(other, base);
2826
+ if (base.isBefore(other)) {
2827
+ res = positiveMomentsDifference(base, other);
2828
+ } else {
2829
+ res = positiveMomentsDifference(other, base);
2830
+ res.milliseconds = -res.milliseconds;
2831
+ res.months = -res.months;
2832
  }
2833
 
2834
+ return res;
2835
+ }
 
 
2836
 
2837
+ function absRound (number) {
2838
+ if (number < 0) {
2839
+ return Math.round(-1 * number) * -1;
2840
+ } else {
2841
+ return Math.round(number);
2842
+ }
2843
  }
2844
 
2845
+ // TODO: remove 'name' arg after deprecation is removed
2846
+ function createAdder(direction, name) {
2847
+ return function (val, period) {
2848
+ var dur, tmp;
2849
+ //invert the arguments, but complain about it
2850
+ if (period !== null && !isNaN(+period)) {
2851
+ deprecateSimple(name, 'moment().' + name + '(period, number) is deprecated. Please use moment().' + name + '(number, period). ' +
2852
+ 'See http://momentjs.com/guides/#/warnings/add-inverted-param/ for more info.');
2853
+ tmp = val; val = period; period = tmp;
2854
+ }
2855
 
2856
+ val = typeof val === 'string' ? +val : val;
2857
+ dur = create__createDuration(val, period);
2858
+ add_subtract__addSubtract(this, dur, direction);
2859
+ return this;
2860
+ };
2861
  }
2862
 
2863
+ function add_subtract__addSubtract (mom, duration, isAdding, updateOffset) {
2864
+ var milliseconds = duration._milliseconds,
2865
+ days = absRound(duration._days),
2866
+ months = absRound(duration._months);
2867
 
2868
+ if (!mom.isValid()) {
2869
+ // No op
2870
+ return;
2871
+ }
2872
 
2873
+ updateOffset = updateOffset == null ? true : updateOffset;
 
 
 
 
 
2874
 
2875
+ if (milliseconds) {
2876
+ mom._d.setTime(mom._d.valueOf() + milliseconds * isAdding);
 
 
 
 
2877
  }
2878
+ if (days) {
2879
+ get_set__set(mom, 'Date', get_set__get(mom, 'Date') + days * isAdding);
2880
+ }
2881
+ if (months) {
2882
+ setMonth(mom, get_set__get(mom, 'Month') + months * isAdding);
2883
+ }
2884
+ if (updateOffset) {
2885
+ utils_hooks__hooks.updateOffset(mom, days || months);
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
2886
  }
2887
  }
2888
 
2889
+ var add_subtract__add = createAdder(1, 'add');
2890
+ var add_subtract__subtract = createAdder(-1, 'subtract');
2891
 
2892
+ function getCalendarFormat(myMoment, now) {
2893
+ var diff = myMoment.diff(now, 'days', true);
2894
+ return diff < -6 ? 'sameElse' :
2895
+ diff < -1 ? 'lastWeek' :
2896
+ diff < 0 ? 'lastDay' :
2897
+ diff < 1 ? 'sameDay' :
2898
+ diff < 2 ? 'nextDay' :
2899
+ diff < 7 ? 'nextWeek' : 'sameElse';
2900
+ }
2901
 
2902
+ function moment_calendar__calendar (time, formats) {
2903
+ // We want to compare the start of today, vs this.
2904
+ // Getting start-of-today depends on whether we're local/utc/offset or not.
2905
+ var now = time || local__createLocal(),
2906
+ sod = cloneWithOffset(now, this).startOf('day'),
2907
+ format = utils_hooks__hooks.calendarFormat(this, sod) || 'sameElse';
2908
 
2909
+ var output = formats && (isFunction(formats[format]) ? formats[format].call(this, now) : formats[format]);
 
2910
 
2911
+ return this.format(output || this.localeData().calendar(format, this, local__createLocal(now)));
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
2912
  }
2913
 
2914
+ function clone () {
2915
+ return new Moment(this);
2916
+ }
2917
 
2918
+ function isAfter (input, units) {
2919
+ var localInput = isMoment(input) ? input : local__createLocal(input);
2920
+ if (!(this.isValid() && localInput.isValid())) {
2921
+ return false;
2922
  }
2923
+ units = normalizeUnits(!isUndefined(units) ? units : 'millisecond');
2924
+ if (units === 'millisecond') {
2925
+ return this.valueOf() > localInput.valueOf();
 
2926
  } else {
2927
+ return localInput.valueOf() < this.clone().startOf(units).valueOf();
2928
  }
2929
  }
2930
 
2931
+ function isBefore (input, units) {
2932
+ var localInput = isMoment(input) ? input : local__createLocal(input);
2933
+ if (!(this.isValid() && localInput.isValid())) {
2934
+ return false;
2935
+ }
2936
+ units = normalizeUnits(!isUndefined(units) ? units : 'millisecond');
2937
+ if (units === 'millisecond') {
2938
+ return this.valueOf() < localInput.valueOf();
2939
+ } else {
2940
+ return this.clone().endOf(units).valueOf() < localInput.valueOf();
2941
  }
 
 
2942
  }
2943
 
2944
+ function isBetween (from, to, units, inclusivity) {
2945
+ inclusivity = inclusivity || '()';
2946
+ return (inclusivity[0] === '(' ? this.isAfter(from, units) : !this.isBefore(from, units)) &&
2947
+ (inclusivity[1] === ')' ? this.isBefore(to, units) : !this.isAfter(to, units));
 
 
 
 
2948
  }
2949
 
2950
+ function isSame (input, units) {
2951
+ var localInput = isMoment(input) ? input : local__createLocal(input),
2952
+ inputMs;
2953
+ if (!(this.isValid() && localInput.isValid())) {
2954
+ return false;
2955
+ }
2956
+ units = normalizeUnits(units || 'millisecond');
2957
+ if (units === 'millisecond') {
2958
+ return this.valueOf() === localInput.valueOf();
 
 
2959
  } else {
2960
+ inputMs = localInput.valueOf();
2961
+ return this.clone().startOf(units).valueOf() <= inputMs && inputMs <= this.clone().endOf(units).valueOf();
2962
  }
2963
  }
2964
 
2965
+ function isSameOrAfter (input, units) {
2966
+ return this.isSame(input, units) || this.isAfter(input,units);
 
 
 
 
 
 
 
 
 
 
 
 
 
2967
  }
2968
 
2969
+ function isSameOrBefore (input, units) {
2970
+ return this.isSame(input, units) || this.isBefore(input,units);
 
 
 
 
 
 
 
 
 
 
 
 
 
2971
  }
2972
 
2973
+ function diff (input, units, asFloat) {
2974
+ var that,
2975
+ zoneDelta,
2976
+ delta, output;
2977
 
2978
+ if (!this.isValid()) {
2979
+ return NaN;
 
2980
  }
2981
 
2982
+ that = cloneWithOffset(input, this);
2983
+
2984
+ if (!that.isValid()) {
2985
+ return NaN;
 
 
 
 
 
 
 
 
 
 
2986
  }
2987
+
2988
+ zoneDelta = (that.utcOffset() - this.utcOffset()) * 6e4;
2989
+
2990
+ units = normalizeUnits(units);
2991
+
2992
+ if (units === 'year' || units === 'month' || units === 'quarter') {
2993
+ output = monthDiff(this, that);
2994
+ if (units === 'quarter') {
2995
+ output = output / 3;
2996
+ } else if (units === 'year') {
2997
+ output = output / 12;
2998
+ }
2999
+ } else {
3000
+ delta = this - that;
3001
+ output = units === 'second' ? delta / 1e3 : // 1000
3002
+ units === 'minute' ? delta / 6e4 : // 1000 * 60
3003
+ units === 'hour' ? delta / 36e5 : // 1000 * 60 * 60
3004
+ units === 'day' ? (delta - zoneDelta) / 864e5 : // 1000 * 60 * 60 * 24, negate dst
3005
+ units === 'week' ? (delta - zoneDelta) / 6048e5 : // 1000 * 60 * 60 * 24 * 7, negate dst
3006
+ delta;
3007
+ }
3008
+ return asFloat ? output : absFloor(output);
3009
+ }
3010
+
3011
+ function monthDiff (a, b) {
3012
+ // difference in months
3013
+ var wholeMonthDiff = ((b.year() - a.year()) * 12) + (b.month() - a.month()),
3014
+ // b is in (anchor - 1 month, anchor + 1 month)
3015
+ anchor = a.clone().add(wholeMonthDiff, 'months'),
3016
+ anchor2, adjust;
3017
+
3018
+ if (b - anchor < 0) {
3019
+ anchor2 = a.clone().add(wholeMonthDiff - 1, 'months');
3020
+ // linear across the month
3021
+ adjust = (b - anchor) / (anchor - anchor2);
3022
+ } else {
3023
+ anchor2 = a.clone().add(wholeMonthDiff + 1, 'months');
3024
+ // linear across the month
3025
+ adjust = (b - anchor) / (anchor2 - anchor);
3026
+ }
3027
+
3028
+ //check for negative zero, return zero if negative zero
3029
+ return -(wholeMonthDiff + adjust) || 0;
3030
+ }
3031
+
3032
+ utils_hooks__hooks.defaultFormat = 'YYYY-MM-DDTHH:mm:ssZ';
3033
+ utils_hooks__hooks.defaultFormatUtc = 'YYYY-MM-DDTHH:mm:ss[Z]';
3034
+
3035
+ function toString () {
3036
+ return this.clone().locale('en').format('ddd MMM DD YYYY HH:mm:ss [GMT]ZZ');
3037
+ }
3038
+
3039
+ function moment_format__toISOString () {
3040
+ var m = this.clone().utc();
3041
+ if (0 < m.year() && m.year() <= 9999) {
3042
+ if (isFunction(Date.prototype.toISOString)) {
3043
+ // native implementation is ~50x faster, use it when we can
3044
+ return this.toDate().toISOString();
3045
+ } else {
3046
+ return formatMoment(m, 'YYYY-MM-DD[T]HH:mm:ss.SSS[Z]');
3047
+ }
3048
+ } else {
3049
+ return formatMoment(m, 'YYYYYY-MM-DD[T]HH:mm:ss.SSS[Z]');
3050
+ }
3051
+ }
3052
+
3053
+ function format (inputString) {
3054
+ if (!inputString) {
3055
+ inputString = this.isUtc() ? utils_hooks__hooks.defaultFormatUtc : utils_hooks__hooks.defaultFormat;
3056
+ }
3057
+ var output = formatMoment(this, inputString);
3058
+ return this.localeData().postformat(output);
3059
+ }
3060
+
3061
+ function from (time, withoutSuffix) {
3062
+ if (this.isValid() &&
3063
+ ((isMoment(time) && time.isValid()) ||
3064
+ local__createLocal(time).isValid())) {
3065
+ return create__createDuration({to: this, from: time}).locale(this.locale()).humanize(!withoutSuffix);
3066
+ } else {
3067
+ return this.localeData().invalidDate();
3068
+ }
3069
+ }
3070
+
3071
+ function fromNow (withoutSuffix) {
3072
+ return this.from(local__createLocal(), withoutSuffix);
3073
+ }
3074
+
3075
+ function to (time, withoutSuffix) {
3076
+ if (this.isValid() &&
3077
+ ((isMoment(time) && time.isValid()) ||
3078
+ local__createLocal(time).isValid())) {
3079
+ return create__createDuration({from: this, to: time}).locale(this.locale()).humanize(!withoutSuffix);
3080
+ } else {
3081
+ return this.localeData().invalidDate();
3082
+ }
3083
+ }
3084
+
3085
+ function toNow (withoutSuffix) {
3086
+ return this.to(local__createLocal(), withoutSuffix);
3087
+ }
3088
+
3089
+ // If passed a locale key, it will set the locale for this
3090
+ // instance. Otherwise, it will return the locale configuration
3091
+ // variables for this instance.
3092
+ function locale (key) {
3093
+ var newLocaleData;
3094
+
3095
+ if (key === undefined) {
3096
+ return this._locale._abbr;
3097
+ } else {
3098
+ newLocaleData = locale_locales__getLocale(key);
3099
+ if (newLocaleData != null) {
3100
+ this._locale = newLocaleData;
3101
+ }
3102
+ return this;
3103
+ }
3104
+ }
3105
+
3106
+ var lang = deprecate(
3107
+ 'moment().lang() is deprecated. Instead, use moment().localeData() to get the language configuration. Use moment().locale() to change languages.',
3108
+ function (key) {
3109
+ if (key === undefined) {
3110
+ return this.localeData();
3111
+ } else {
3112
+ return this.locale(key);
3113
+ }
3114
+ }
3115
+ );
3116
+
3117
+ function localeData () {
3118
+ return this._locale;
3119
+ }
3120
+
3121
+ function startOf (units) {
3122
+ units = normalizeUnits(units);
3123
+ // the following switch intentionally omits break keywords
3124
+ // to utilize falling through the cases.
3125
+ switch (units) {
3126
+ case 'year':
3127
+ this.month(0);
3128
+ /* falls through */
3129
+ case 'quarter':
3130
+ case 'month':
3131
+ this.date(1);
3132
+ /* falls through */
3133
+ case 'week':
3134
+ case 'isoWeek':
3135
+ case 'day':
3136
+ case 'date':
3137
+ this.hours(0);
3138
+ /* falls through */
3139
+ case 'hour':
3140
+ this.minutes(0);
3141
+ /* falls through */
3142
+ case 'minute':
3143
+ this.seconds(0);
3144
+ /* falls through */
3145
+ case 'second':
3146
+ this.milliseconds(0);
3147
+ }
3148
+
3149
+ // weeks are a special case
3150
+ if (units === 'week') {
3151
+ this.weekday(0);
3152
+ }
3153
+ if (units === 'isoWeek') {
3154
+ this.isoWeekday(1);
3155
+ }
3156
+
3157
+ // quarters are also special
3158
+ if (units === 'quarter') {
3159
+ this.month(Math.floor(this.month() / 3) * 3);
3160
+ }
3161
+
3162
+ return this;
3163
+ }
3164
+
3165
+ function endOf (units) {
3166
+ units = normalizeUnits(units);
3167
+ if (units === undefined || units === 'millisecond') {
3168
+ return this;
3169
+ }
3170
+
3171
+ // 'date' is an alias for 'day', so it should be considered as such.
3172
+ if (units === 'date') {
3173
+ units = 'day';
3174
+ }
3175
+
3176
+ return this.startOf(units).add(1, (units === 'isoWeek' ? 'week' : units)).subtract(1, 'ms');
3177
+ }
3178
+
3179
+ function to_type__valueOf () {
3180
+ return this._d.valueOf() - ((this._offset || 0) * 60000);
3181
+ }
3182
+
3183
+ function unix () {
3184
+ return Math.floor(this.valueOf() / 1000);
3185
+ }
3186
+
3187
+ function toDate () {
3188
+ return new Date(this.valueOf());
3189
+ }
3190
+
3191
+ function toArray () {
3192
+ var m = this;
3193
+ return [m.year(), m.month(), m.date(), m.hour(), m.minute(), m.second(), m.millisecond()];
3194
+ }
3195
+
3196
+ function toObject () {
3197
+ var m = this;
3198
+ return {
3199
+ years: m.year(),
3200
+ months: m.month(),
3201
+ date: m.date(),
3202
+ hours: m.hours(),
3203
+ minutes: m.minutes(),
3204
+ seconds: m.seconds(),
3205
+ milliseconds: m.milliseconds()
3206
+ };
3207
+ }
3208
+
3209
+ function toJSON () {
3210
+ // new Date(NaN).toJSON() === null
3211
+ return this.isValid() ? this.toISOString() : null;
3212
+ }
3213
+
3214
+ function moment_valid__isValid () {
3215
+ return valid__isValid(this);
3216
+ }
3217
+
3218
+ function parsingFlags () {
3219
+ return extend({}, getParsingFlags(this));
3220
+ }
3221
+
3222
+ function invalidAt () {
3223
+ return getParsingFlags(this).overflow;
3224
+ }
3225
+
3226
+ function creationData() {
3227
+ return {
3228
+ input: this._i,
3229
+ format: this._f,
3230
+ locale: this._locale,
3231
+ isUTC: this._isUTC,
3232
+ strict: this._strict
3233
+ };
3234
+ }
3235
+
3236
+ // FORMATTING
3237
+
3238
+ addFormatToken(0, ['gg', 2], 0, function () {
3239
+ return this.weekYear() % 100;
3240
+ });
3241
+
3242
+ addFormatToken(0, ['GG', 2], 0, function () {
3243
+ return this.isoWeekYear() % 100;
3244
+ });
3245
+
3246
+ function addWeekYearFormatToken (token, getter) {
3247
+ addFormatToken(0, [token, token.length], 0, getter);
3248
+ }
3249
+
3250
+ addWeekYearFormatToken('gggg', 'weekYear');
3251
+ addWeekYearFormatToken('ggggg', 'weekYear');
3252
+ addWeekYearFormatToken('GGGG', 'isoWeekYear');
3253
+ addWeekYearFormatToken('GGGGG', 'isoWeekYear');
3254
+
3255
+ // ALIASES
3256
+
3257
+ addUnitAlias('weekYear', 'gg');
3258
+ addUnitAlias('isoWeekYear', 'GG');
3259
+
3260
+ // PRIORITY
3261
+
3262
+ addUnitPriority('weekYear', 1);
3263
+ addUnitPriority('isoWeekYear', 1);
3264
+
3265
+
3266
+ // PARSING
3267
+
3268
+ addRegexToken('G', matchSigned);
3269
+ addRegexToken('g', matchSigned);
3270
+ addRegexToken('GG', match1to2, match2);
3271
+ addRegexToken('gg', match1to2, match2);
3272
+ addRegexToken('GGGG', match1to4, match4);
3273
+ addRegexToken('gggg', match1to4, match4);
3274
+ addRegexToken('GGGGG', match1to6, match6);
3275
+ addRegexToken('ggggg', match1to6, match6);
3276
+
3277
+ addWeekParseToken(['gggg', 'ggggg', 'GGGG', 'GGGGG'], function (input, week, config, token) {
3278
+ week[token.substr(0, 2)] = toInt(input);
3279
+ });
3280
+
3281
+ addWeekParseToken(['gg', 'GG'], function (input, week, config, token) {
3282
+ week[token] = utils_hooks__hooks.parseTwoDigitYear(input);
3283
+ });
3284
+
3285
+ // MOMENTS
3286
+
3287
+ function getSetWeekYear (input) {
3288
+ return getSetWeekYearHelper.call(this,
3289
+ input,
3290
+ this.week(),
3291
+ this.weekday(),
3292
+ this.localeData()._week.dow,
3293
+ this.localeData()._week.doy);
3294
+ }
3295
+
3296
+ function getSetISOWeekYear (input) {
3297
+ return getSetWeekYearHelper.call(this,
3298
+ input, this.isoWeek(), this.isoWeekday(), 1, 4);
3299
+ }
3300
+
3301
+ function getISOWeeksInYear () {
3302
+ return weeksInYear(this.year(), 1, 4);
3303
+ }
3304
+
3305
+ function getWeeksInYear () {
3306
+ var weekInfo = this.localeData()._week;
3307
+ return weeksInYear(this.year(), weekInfo.dow, weekInfo.doy);
3308
+ }
3309
+
3310
+ function getSetWeekYearHelper(input, week, weekday, dow, doy) {
3311
+ var weeksTarget;
3312
+ if (input == null) {
3313
+ return weekOfYear(this, dow, doy).year;
3314
+ } else {
3315
+ weeksTarget = weeksInYear(input, dow, doy);
3316
+ if (week > weeksTarget) {
3317
+ week = weeksTarget;
3318
+ }
3319
+ return setWeekAll.call(this, input, week, weekday, dow, doy);
3320
  }
3321
+ }
3322
 
3323
+ function setWeekAll(weekYear, week, weekday, dow, doy) {
3324
+ var dayOfYearData = dayOfYearFromWeeks(weekYear, week, weekday, dow, doy),
3325
+ date = createUTCDate(dayOfYearData.year, 0, dayOfYearData.dayOfYear);
3326
 
3327
+ this.year(date.getUTCFullYear());
3328
+ this.month(date.getUTCMonth());
3329
+ this.date(date.getUTCDate());
3330
+ return this;
3331
  }
3332
 
3333
  // FORMATTING
3334
 
3335
+ addFormatToken('Q', 0, 'Qo', 'quarter');
3336
 
3337
  // ALIASES
3338
 
3339
+ addUnitAlias('quarter', 'Q');
3340
+
3341
+ // PRIORITY
3342
+
3343
+ addUnitPriority('quarter', 7);
3344
 
3345
  // PARSING
3346
 
3347
+ addRegexToken('Q', match1);
3348
+ addParseToken('Q', function (input, array) {
3349
+ array[MONTH] = (toInt(input) - 1) * 3;
 
3350
  });
3351
 
 
 
3352
  // MOMENTS
3353
 
3354
+ function getSetQuarter (input) {
3355
+ return input == null ? Math.ceil((this.month() + 1) / 3) : this.month((input - 1) * 3 + this.month() % 3);
 
3356
  }
3357
 
3358
  // FORMATTING
3359
 
3360
+ addFormatToken('D', ['DD', 2], 'Do', 'date');
 
 
3361
 
3362
+ // ALIASES
 
 
3363
 
3364
+ addUnitAlias('date', 'D');
 
 
3365
 
3366
+ // PRIOROITY
3367
+ addUnitPriority('date', 9);
 
3368
 
3369
+ // PARSING
 
 
 
3370
 
3371
+ addRegexToken('D', match1to2);
3372
+ addRegexToken('DD', match1to2, match2);
3373
+ addRegexToken('Do', function (isStrict, locale) {
3374
+ return isStrict ? locale._ordinalParse : locale._ordinalParseLenient;
3375
  });
3376
 
3377
+ addParseToken(['D', 'DD'], DATE);
3378
+ addParseToken('Do', function (input, array) {
3379
+ array[DATE] = toInt(input.match(match1to2)[0], 10);
3380
  });
3381
 
3382
+ // MOMENTS
 
 
 
 
3383
 
3384
+ var getSetDayOfMonth = makeGetSet('Date', true);
 
3385
 
3386
+ // FORMATTING
3387
 
3388
+ addFormatToken('DDD', ['DDDD', 3], 'DDDo', 'dayOfYear');
3389
 
3390
+ // ALIASES
3391
 
3392
+ addUnitAlias('dayOfYear', 'DDD');
 
 
3393
 
3394
+ // PRIORITY
3395
+ addUnitPriority('dayOfYear', 4);
 
 
 
 
3396
 
3397
+ // PARSING
 
 
 
3398
 
3399
+ addRegexToken('DDD', match1to3);
3400
+ addRegexToken('DDDD', match3);
3401
+ addParseToken(['DDD', 'DDDD'], function (input, array, config) {
3402
+ config._dayOfYear = toInt(input);
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
3403
  });
3404
 
3405
+ // HELPERS
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
3406
 
3407
  // MOMENTS
3408
 
3409
+ function getSetDayOfYear (input) {
3410
+ var dayOfYear = Math.round((this.clone().startOf('day') - this.clone().startOf('year')) / 864e5) + 1;
3411
+ return input == null ? dayOfYear : this.add((input - dayOfYear), 'd');
3412
+ }
 
3413
 
3414
  // FORMATTING
3415
 
3419
 
3420
  addUnitAlias('minute', 'm');
3421
 
3422
+ // PRIORITY
3423
+
3424
+ addUnitPriority('minute', 14);
3425
+
3426
  // PARSING
3427
 
3428
  addRegexToken('m', match1to2);
3441
 
3442
  addUnitAlias('second', 's');
3443
 
3444
+ // PRIORITY
3445
+
3446
+ addUnitPriority('second', 15);
3447
+
3448
  // PARSING
3449
 
3450
  addRegexToken('s', match1to2);
3490
 
3491
  addUnitAlias('millisecond', 'ms');
3492
 
3493
+ // PRIORITY
3494
+
3495
+ addUnitPriority('millisecond', 16);
3496
+
3497
  // PARSING
3498
 
3499
  addRegexToken('S', match1to3, match1);
3543
  momentPrototype__proto.fromNow = fromNow;
3544
  momentPrototype__proto.to = to;
3545
  momentPrototype__proto.toNow = toNow;
3546
+ momentPrototype__proto.get = stringGet;
3547
  momentPrototype__proto.invalidAt = invalidAt;
3548
  momentPrototype__proto.isAfter = isAfter;
3549
  momentPrototype__proto.isBefore = isBefore;
3558
  momentPrototype__proto.max = prototypeMax;
3559
  momentPrototype__proto.min = prototypeMin;
3560
  momentPrototype__proto.parsingFlags = parsingFlags;
3561
+ momentPrototype__proto.set = stringSet;
3562
  momentPrototype__proto.startOf = startOf;
3563
  momentPrototype__proto.subtract = add_subtract__subtract;
3564
  momentPrototype__proto.toArray = toArray;
3618
  momentPrototype__proto.parseZone = setOffsetToParsedOffset;
3619
  momentPrototype__proto.hasAlignedHourOffset = hasAlignedHourOffset;
3620
  momentPrototype__proto.isDST = isDaylightSavingTime;
 
3621
  momentPrototype__proto.isLocal = isLocal;
3622
  momentPrototype__proto.isUtcOffset = isUtcOffset;
3623
  momentPrototype__proto.isUtc = isUtc;
3631
  momentPrototype__proto.dates = deprecate('dates accessor is deprecated. Use date instead.', getSetDayOfMonth);
3632
  momentPrototype__proto.months = deprecate('months accessor is deprecated. Use month instead', getSetMonth);
3633
  momentPrototype__proto.years = deprecate('years accessor is deprecated. Use year instead', getSetYear);
3634
+ momentPrototype__proto.zone = deprecate('moment().zone is deprecated, use moment().utcOffset instead. http://momentjs.com/guides/#/warnings/zone/', getSetZone);
3635
+ momentPrototype__proto.isDSTShifted = deprecate('isDSTShifted is deprecated. See http://momentjs.com/guides/#/warnings/dst-shifted/ for more information', isDaylightSavingTimeShifted);
3636
 
3637
  var momentPrototype = momentPrototype__proto;
3638
 
3644
  return local__createLocal.apply(null, arguments).parseZone();
3645
  }
3646
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
3647
  function preParsePostFormat (string) {
3648
  return string;
3649
  }
3650
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
3651
  var prototype__proto = Locale.prototype;
3652
 
 
3653
  prototype__proto.calendar = locale_calendar__calendar;
 
3654
  prototype__proto.longDateFormat = longDateFormat;
 
3655
  prototype__proto.invalidDate = invalidDate;
 
3656
  prototype__proto.ordinal = ordinal;
 
3657
  prototype__proto.preparse = preParsePostFormat;
3658
  prototype__proto.postformat = preParsePostFormat;
 
3659
  prototype__proto.relativeTime = relative__relativeTime;
3660
  prototype__proto.pastFuture = pastFuture;
3661
  prototype__proto.set = locale_set__set;
3662
 
3663
  // Month
3664
  prototype__proto.months = localeMonths;
 
3665
  prototype__proto.monthsShort = localeMonthsShort;
 
3666
  prototype__proto.monthsParse = localeMonthsParse;
 
3667
  prototype__proto.monthsRegex = monthsRegex;
 
3668
  prototype__proto.monthsShortRegex = monthsShortRegex;
3669
 
3670
  // Week
3671
  prototype__proto.week = localeWeek;
 
3672
  prototype__proto.firstDayOfYear = localeFirstDayOfYear;
3673
  prototype__proto.firstDayOfWeek = localeFirstDayOfWeek;
3674
 
3675
  // Day of Week
3676
  prototype__proto.weekdays = localeWeekdays;
 
3677
  prototype__proto.weekdaysMin = localeWeekdaysMin;
 
3678
  prototype__proto.weekdaysShort = localeWeekdaysShort;
 
3679
  prototype__proto.weekdaysParse = localeWeekdaysParse;
3680
 
 
3681
  prototype__proto.weekdaysRegex = weekdaysRegex;
 
3682
  prototype__proto.weekdaysShortRegex = weekdaysShortRegex;
 
3683
  prototype__proto.weekdaysMinRegex = weekdaysMinRegex;
3684
 
3685
  // Hours
3686
  prototype__proto.isPM = localeIsPM;
 
3687
  prototype__proto.meridiem = localeMeridiem;
3688
 
3689
  function lists__get (format, index, field, setter) {
4012
  return substituteTimeAgo.apply(null, a);
4013
  }
4014
 
4015
+ // This function allows you to set the rounding function for relative time strings
4016
+ function duration_humanize__getSetRelativeTimeRounding (roundingFunction) {
4017
+ if (roundingFunction === undefined) {
4018
+ return round;
4019
+ }
4020
+ if (typeof(roundingFunction) === 'function') {
4021
+ round = roundingFunction;
4022
+ return true;
4023
+ }
4024
+ return false;
4025
+ }
4026
+
4027
  // This function allows you to set a threshold for relative time strings
4028
  function duration_humanize__getSetRelativeTimeThreshold (threshold, limit) {
4029
  if (thresholds[threshold] === undefined) {
4156
  // Side effect imports
4157
 
4158
 
4159
+ utils_hooks__hooks.version = '2.14.1';
4160
 
4161
  setHookCallback(local__createLocal);
4162
 
4183
  utils_hooks__hooks.locales = locale_locales__listLocales;
4184
  utils_hooks__hooks.weekdaysShort = lists__listWeekdaysShort;
4185
  utils_hooks__hooks.normalizeUnits = normalizeUnits;
4186
+ utils_hooks__hooks.relativeTimeRounding = duration_humanize__getSetRelativeTimeRounding;
4187
  utils_hooks__hooks.relativeTimeThreshold = duration_humanize__getSetRelativeTimeThreshold;
4188
+ utils_hooks__hooks.calendarFormat = getCalendarFormat;
4189
  utils_hooks__hooks.prototype = momentPrototype;
4190
 
4191
  var _moment = utils_hooks__hooks;
assets/js/vendor/moment.min.js CHANGED
@@ -1,7 +1,492 @@
1
  //! moment.js
2
- //! version : 2.13.0
3
  //! authors : Tim Wood, Iskren Chernev, Moment.js contributors
4
  //! license : MIT
5
  //! momentjs.com
6
- !function(a,b){"object"==typeof exports&&"undefined"!=typeof module?module.exports=b():"function"==typeof define&&define.amd?define(b):a.moment=b()}(this,function(){"use strict";function a(){return fd.apply(null,arguments)}function b(a){fd=a}function c(a){return a instanceof Array||"[object Array]"===Object.prototype.toString.call(a)}function d(a){return a instanceof Date||"[object Date]"===Object.prototype.toString.call(a)}function e(a,b){var c,d=[];for(c=0;c<a.length;++c)d.push(b(a[c],c));return d}function f(a,b){return Object.prototype.hasOwnProperty.call(a,b)}function g(a,b){for(var c in b)f(b,c)&&(a[c]=b[c]);return f(b,"toString")&&(a.toString=b.toString),f(b,"valueOf")&&(a.valueOf=b.valueOf),a}function h(a,b,c,d){return Ja(a,b,c,d,!0).utc()}function i(){return{empty:!1,unusedTokens:[],unusedInput:[],overflow:-2,charsLeftOver:0,nullInput:!1,invalidMonth:null,invalidFormat:!1,userInvalidated:!1,iso:!1,parsedDateParts:[],meridiem:null}}function j(a){return null==a._pf&&(a._pf=i()),a._pf}function k(a){if(null==a._isValid){var b=j(a),c=gd.call(b.parsedDateParts,function(a){return null!=a});a._isValid=!isNaN(a._d.getTime())&&b.overflow<0&&!b.empty&&!b.invalidMonth&&!b.invalidWeekday&&!b.nullInput&&!b.invalidFormat&&!b.userInvalidated&&(!b.meridiem||b.meridiem&&c),a._strict&&(a._isValid=a._isValid&&0===b.charsLeftOver&&0===b.unusedTokens.length&&void 0===b.bigHour)}return a._isValid}function l(a){var b=h(NaN);return null!=a?g(j(b),a):j(b).userInvalidated=!0,b}function m(a){return void 0===a}function n(a,b){var c,d,e;if(m(b._isAMomentObject)||(a._isAMomentObject=b._isAMomentObject),m(b._i)||(a._i=b._i),m(b._f)||(a._f=b._f),m(b._l)||(a._l=b._l),m(b._strict)||(a._strict=b._strict),m(b._tzm)||(a._tzm=b._tzm),m(b._isUTC)||(a._isUTC=b._isUTC),m(b._offset)||(a._offset=b._offset),m(b._pf)||(a._pf=j(b)),m(b._locale)||(a._locale=b._locale),hd.length>0)for(c in hd)d=hd[c],e=b[d],m(e)||(a[d]=e);return a}function o(b){n(this,b),this._d=new Date(null!=b._d?b._d.getTime():NaN),id===!1&&(id=!0,a.updateOffset(this),id=!1)}function p(a){return a instanceof o||null!=a&&null!=a._isAMomentObject}function q(a){return 0>a?Math.ceil(a):Math.floor(a)}function r(a){var b=+a,c=0;return 0!==b&&isFinite(b)&&(c=q(b)),c}function s(a,b,c){var d,e=Math.min(a.length,b.length),f=Math.abs(a.length-b.length),g=0;for(d=0;e>d;d++)(c&&a[d]!==b[d]||!c&&r(a[d])!==r(b[d]))&&g++;return g+f}function t(b){a.suppressDeprecationWarnings===!1&&"undefined"!=typeof console&&console.warn&&console.warn("Deprecation warning: "+b)}function u(b,c){var d=!0;return g(function(){return null!=a.deprecationHandler&&a.deprecationHandler(null,b),d&&(t(b+"\nArguments: "+Array.prototype.slice.call(arguments).join(", ")+"\n"+(new Error).stack),d=!1),c.apply(this,arguments)},c)}function v(b,c){null!=a.deprecationHandler&&a.deprecationHandler(b,c),jd[b]||(t(c),jd[b]=!0)}function w(a){return a instanceof Function||"[object Function]"===Object.prototype.toString.call(a)}function x(a){return"[object Object]"===Object.prototype.toString.call(a)}function y(a){var b,c;for(c in a)b=a[c],w(b)?this[c]=b:this["_"+c]=b;this._config=a,this._ordinalParseLenient=new RegExp(this._ordinalParse.source+"|"+/\d{1,2}/.source)}function z(a,b){var c,d=g({},a);for(c in b)f(b,c)&&(x(a[c])&&x(b[c])?(d[c]={},g(d[c],a[c]),g(d[c],b[c])):null!=b[c]?d[c]=b[c]:delete d[c]);return d}function A(a){null!=a&&this.set(a)}function B(a){return a?a.toLowerCase().replace("_","-"):a}function C(a){for(var b,c,d,e,f=0;f<a.length;){for(e=B(a[f]).split("-"),b=e.length,c=B(a[f+1]),c=c?c.split("-"):null;b>0;){if(d=D(e.slice(0,b).join("-")))return d;if(c&&c.length>=b&&s(e,c,!0)>=b-1)break;b--}f++}return null}function D(a){var b=null;if(!nd[a]&&"undefined"!=typeof module&&module&&module.exports)try{b=ld._abbr,require("./locale/"+a),E(b)}catch(c){}return nd[a]}function E(a,b){var c;return a&&(c=m(b)?H(a):F(a,b),c&&(ld=c)),ld._abbr}function F(a,b){return null!==b?(b.abbr=a,null!=nd[a]?(v("defineLocaleOverride","use moment.updateLocale(localeName, config) to change an existing locale. moment.defineLocale(localeName, config) should only be used for creating a new locale"),b=z(nd[a]._config,b)):null!=b.parentLocale&&(null!=nd[b.parentLocale]?b=z(nd[b.parentLocale]._config,b):v("parentLocaleUndefined","specified parentLocale is not defined yet")),nd[a]=new A(b),E(a),nd[a]):(delete nd[a],null)}function G(a,b){if(null!=b){var c;null!=nd[a]&&(b=z(nd[a]._config,b)),c=new A(b),c.parentLocale=nd[a],nd[a]=c,E(a)}else null!=nd[a]&&(null!=nd[a].parentLocale?nd[a]=nd[a].parentLocale:null!=nd[a]&&delete nd[a]);return nd[a]}function H(a){var b;if(a&&a._locale&&a._locale._abbr&&(a=a._locale._abbr),!a)return ld;if(!c(a)){if(b=D(a))return b;a=[a]}return C(a)}function I(){return kd(nd)}function J(a,b){var c=a.toLowerCase();od[c]=od[c+"s"]=od[b]=a}function K(a){return"string"==typeof a?od[a]||od[a.toLowerCase()]:void 0}function L(a){var b,c,d={};for(c in a)f(a,c)&&(b=K(c),b&&(d[b]=a[c]));return d}function M(b,c){return function(d){return null!=d?(O(this,b,d),a.updateOffset(this,c),this):N(this,b)}}function N(a,b){return a.isValid()?a._d["get"+(a._isUTC?"UTC":"")+b]():NaN}function O(a,b,c){a.isValid()&&a._d["set"+(a._isUTC?"UTC":"")+b](c)}function P(a,b){var c;if("object"==typeof a)for(c in a)this.set(c,a[c]);else if(a=K(a),w(this[a]))return this[a](b);return this}function Q(a,b,c){var d=""+Math.abs(a),e=b-d.length,f=a>=0;return(f?c?"+":"":"-")+Math.pow(10,Math.max(0,e)).toString().substr(1)+d}function R(a,b,c,d){var e=d;"string"==typeof d&&(e=function(){return this[d]()}),a&&(sd[a]=e),b&&(sd[b[0]]=function(){return Q(e.apply(this,arguments),b[1],b[2])}),c&&(sd[c]=function(){return this.localeData().ordinal(e.apply(this,arguments),a)})}function S(a){return a.match(/\[[\s\S]/)?a.replace(/^\[|\]$/g,""):a.replace(/\\/g,"")}function T(a){var b,c,d=a.match(pd);for(b=0,c=d.length;c>b;b++)sd[d[b]]?d[b]=sd[d[b]]:d[b]=S(d[b]);return function(b){var e,f="";for(e=0;c>e;e++)f+=d[e]instanceof Function?d[e].call(b,a):d[e];return f}}function U(a,b){return a.isValid()?(b=V(b,a.localeData()),rd[b]=rd[b]||T(b),rd[b](a)):a.localeData().invalidDate()}function V(a,b){function c(a){return b.longDateFormat(a)||a}var d=5;for(qd.lastIndex=0;d>=0&&qd.test(a);)a=a.replace(qd,c),qd.lastIndex=0,d-=1;return a}function W(a,b,c){Kd[a]=w(b)?b:function(a,d){return a&&c?c:b}}function X(a,b){return f(Kd,a)?Kd[a](b._strict,b._locale):new RegExp(Y(a))}function Y(a){return Z(a.replace("\\","").replace(/\\(\[)|\\(\])|\[([^\]\[]*)\]|\\(.)/g,function(a,b,c,d,e){return b||c||d||e}))}function Z(a){return a.replace(/[-\/\\^$*+?.()|[\]{}]/g,"\\$&")}function $(a,b){var c,d=b;for("string"==typeof a&&(a=[a]),"number"==typeof b&&(d=function(a,c){c[b]=r(a)}),c=0;c<a.length;c++)Ld[a[c]]=d}function _(a,b){$(a,function(a,c,d,e){d._w=d._w||{},b(a,d._w,d,e)})}function aa(a,b,c){null!=b&&f(Ld,a)&&Ld[a](b,c._a,c,a)}function ba(a,b){return new Date(Date.UTC(a,b+1,0)).getUTCDate()}function ca(a,b){return c(this._months)?this._months[a.month()]:this._months[Vd.test(b)?"format":"standalone"][a.month()]}function da(a,b){return c(this._monthsShort)?this._monthsShort[a.month()]:this._monthsShort[Vd.test(b)?"format":"standalone"][a.month()]}function ea(a,b,c){var d,e,f,g=a.toLocaleLowerCase();if(!this._monthsParse)for(this._monthsParse=[],this._longMonthsParse=[],this._shortMonthsParse=[],d=0;12>d;++d)f=h([2e3,d]),this._shortMonthsParse[d]=this.monthsShort(f,"").toLocaleLowerCase(),this._longMonthsParse[d]=this.months(f,"").toLocaleLowerCase();return c?"MMM"===b?(e=md.call(this._shortMonthsParse,g),-1!==e?e:null):(e=md.call(this._longMonthsParse,g),-1!==e?e:null):"MMM"===b?(e=md.call(this._shortMonthsParse,g),-1!==e?e:(e=md.call(this._longMonthsParse,g),-1!==e?e:null)):(e=md.call(this._longMonthsParse,g),-1!==e?e:(e=md.call(this._shortMonthsParse,g),-1!==e?e:null))}function fa(a,b,c){var d,e,f;if(this._monthsParseExact)return ea.call(this,a,b,c);for(this._monthsParse||(this._monthsParse=[],this._longMonthsParse=[],this._shortMonthsParse=[]),d=0;12>d;d++){if(e=h([2e3,d]),c&&!this._longMonthsParse[d]&&(this._longMonthsParse[d]=new RegExp("^"+this.months(e,"").replace(".","")+"$","i"),this._shortMonthsParse[d]=new RegExp("^"+this.monthsShort(e,"").replace(".","")+"$","i")),c||this._monthsParse[d]||(f="^"+this.months(e,"")+"|^"+this.monthsShort(e,""),this._monthsParse[d]=new RegExp(f.replace(".",""),"i")),c&&"MMMM"===b&&this._longMonthsParse[d].test(a))return d;if(c&&"MMM"===b&&this._shortMonthsParse[d].test(a))return d;if(!c&&this._monthsParse[d].test(a))return d}}function ga(a,b){var c;if(!a.isValid())return a;if("string"==typeof b)if(/^\d+$/.test(b))b=r(b);else if(b=a.localeData().monthsParse(b),"number"!=typeof b)return a;return c=Math.min(a.date(),ba(a.year(),b)),a._d["set"+(a._isUTC?"UTC":"")+"Month"](b,c),a}function ha(b){return null!=b?(ga(this,b),a.updateOffset(this,!0),this):N(this,"Month")}function ia(){return ba(this.year(),this.month())}function ja(a){return this._monthsParseExact?(f(this,"_monthsRegex")||la.call(this),a?this._monthsShortStrictRegex:this._monthsShortRegex):this._monthsShortStrictRegex&&a?this._monthsShortStrictRegex:this._monthsShortRegex}function ka(a){return this._monthsParseExact?(f(this,"_monthsRegex")||la.call(this),a?this._monthsStrictRegex:this._monthsRegex):this._monthsStrictRegex&&a?this._monthsStrictRegex:this._monthsRegex}function la(){function a(a,b){return b.length-a.length}var b,c,d=[],e=[],f=[];for(b=0;12>b;b++)c=h([2e3,b]),d.push(this.monthsShort(c,"")),e.push(this.months(c,"")),f.push(this.months(c,"")),f.push(this.monthsShort(c,""));for(d.sort(a),e.sort(a),f.sort(a),b=0;12>b;b++)d[b]=Z(d[b]),e[b]=Z(e[b]),f[b]=Z(f[b]);this._monthsRegex=new RegExp("^("+f.join("|")+")","i"),this._monthsShortRegex=this._monthsRegex,this._monthsStrictRegex=new RegExp("^("+e.join("|")+")","i"),this._monthsShortStrictRegex=new RegExp("^("+d.join("|")+")","i")}function ma(a){var b,c=a._a;return c&&-2===j(a).overflow&&(b=c[Nd]<0||c[Nd]>11?Nd:c[Od]<1||c[Od]>ba(c[Md],c[Nd])?Od:c[Pd]<0||c[Pd]>24||24===c[Pd]&&(0!==c[Qd]||0!==c[Rd]||0!==c[Sd])?Pd:c[Qd]<0||c[Qd]>59?Qd:c[Rd]<0||c[Rd]>59?Rd:c[Sd]<0||c[Sd]>999?Sd:-1,j(a)._overflowDayOfYear&&(Md>b||b>Od)&&(b=Od),j(a)._overflowWeeks&&-1===b&&(b=Td),j(a)._overflowWeekday&&-1===b&&(b=Ud),j(a).overflow=b),a}function na(a){var b,c,d,e,f,g,h=a._i,i=$d.exec(h)||_d.exec(h);if(i){for(j(a).iso=!0,b=0,c=be.length;c>b;b++)if(be[b][1].exec(i[1])){e=be[b][0],d=be[b][2]!==!1;break}if(null==e)return void(a._isValid=!1);if(i[3]){for(b=0,c=ce.length;c>b;b++)if(ce[b][1].exec(i[3])){f=(i[2]||" ")+ce[b][0];break}if(null==f)return void(a._isValid=!1)}if(!d&&null!=f)return void(a._isValid=!1);if(i[4]){if(!ae.exec(i[4]))return void(a._isValid=!1);g="Z"}a._f=e+(f||"")+(g||""),Ca(a)}else a._isValid=!1}function oa(b){var c=de.exec(b._i);return null!==c?void(b._d=new Date(+c[1])):(na(b),void(b._isValid===!1&&(delete b._isValid,a.createFromInputFallback(b))))}function pa(a,b,c,d,e,f,g){var h=new Date(a,b,c,d,e,f,g);return 100>a&&a>=0&&isFinite(h.getFullYear())&&h.setFullYear(a),h}function qa(a){var b=new Date(Date.UTC.apply(null,arguments));return 100>a&&a>=0&&isFinite(b.getUTCFullYear())&&b.setUTCFullYear(a),b}function ra(a){return sa(a)?366:365}function sa(a){return a%4===0&&a%100!==0||a%400===0}function ta(){return sa(this.year())}function ua(a,b,c){var d=7+b-c,e=(7+qa(a,0,d).getUTCDay()-b)%7;return-e+d-1}function va(a,b,c,d,e){var f,g,h=(7+c-d)%7,i=ua(a,d,e),j=1+7*(b-1)+h+i;return 0>=j?(f=a-1,g=ra(f)+j):j>ra(a)?(f=a+1,g=j-ra(a)):(f=a,g=j),{year:f,dayOfYear:g}}function wa(a,b,c){var d,e,f=ua(a.year(),b,c),g=Math.floor((a.dayOfYear()-f-1)/7)+1;return 1>g?(e=a.year()-1,d=g+xa(e,b,c)):g>xa(a.year(),b,c)?(d=g-xa(a.year(),b,c),e=a.year()+1):(e=a.year(),d=g),{week:d,year:e}}function xa(a,b,c){var d=ua(a,b,c),e=ua(a+1,b,c);return(ra(a)-d+e)/7}function ya(a,b,c){return null!=a?a:null!=b?b:c}function za(b){var c=new Date(a.now());return b._useUTC?[c.getUTCFullYear(),c.getUTCMonth(),c.getUTCDate()]:[c.getFullYear(),c.getMonth(),c.getDate()]}function Aa(a){var b,c,d,e,f=[];if(!a._d){for(d=za(a),a._w&&null==a._a[Od]&&null==a._a[Nd]&&Ba(a),a._dayOfYear&&(e=ya(a._a[Md],d[Md]),a._dayOfYear>ra(e)&&(j(a)._overflowDayOfYear=!0),c=qa(e,0,a._dayOfYear),a._a[Nd]=c.getUTCMonth(),a._a[Od]=c.getUTCDate()),b=0;3>b&&null==a._a[b];++b)a._a[b]=f[b]=d[b];for(;7>b;b++)a._a[b]=f[b]=null==a._a[b]?2===b?1:0:a._a[b];24===a._a[Pd]&&0===a._a[Qd]&&0===a._a[Rd]&&0===a._a[Sd]&&(a._nextDay=!0,a._a[Pd]=0),a._d=(a._useUTC?qa:pa).apply(null,f),null!=a._tzm&&a._d.setUTCMinutes(a._d.getUTCMinutes()-a._tzm),a._nextDay&&(a._a[Pd]=24)}}function Ba(a){var b,c,d,e,f,g,h,i;b=a._w,null!=b.GG||null!=b.W||null!=b.E?(f=1,g=4,c=ya(b.GG,a._a[Md],wa(Ka(),1,4).year),d=ya(b.W,1),e=ya(b.E,1),(1>e||e>7)&&(i=!0)):(f=a._locale._week.dow,g=a._locale._week.doy,c=ya(b.gg,a._a[Md],wa(Ka(),f,g).year),d=ya(b.w,1),null!=b.d?(e=b.d,(0>e||e>6)&&(i=!0)):null!=b.e?(e=b.e+f,(b.e<0||b.e>6)&&(i=!0)):e=f),1>d||d>xa(c,f,g)?j(a)._overflowWeeks=!0:null!=i?j(a)._overflowWeekday=!0:(h=va(c,d,e,f,g),a._a[Md]=h.year,a._dayOfYear=h.dayOfYear)}function Ca(b){if(b._f===a.ISO_8601)return void na(b);b._a=[],j(b).empty=!0;var c,d,e,f,g,h=""+b._i,i=h.length,k=0;for(e=V(b._f,b._locale).match(pd)||[],c=0;c<e.length;c++)f=e[c],d=(h.match(X(f,b))||[])[0],d&&(g=h.substr(0,h.indexOf(d)),g.length>0&&j(b).unusedInput.push(g),h=h.slice(h.indexOf(d)+d.length),k+=d.length),sd[f]?(d?j(b).empty=!1:j(b).unusedTokens.push(f),aa(f,d,b)):b._strict&&!d&&j(b).unusedTokens.push(f);j(b).charsLeftOver=i-k,h.length>0&&j(b).unusedInput.push(h),j(b).bigHour===!0&&b._a[Pd]<=12&&b._a[Pd]>0&&(j(b).bigHour=void 0),j(b).parsedDateParts=b._a.slice(0),j(b).meridiem=b._meridiem,b._a[Pd]=Da(b._locale,b._a[Pd],b._meridiem),Aa(b),ma(b)}function Da(a,b,c){var d;return null==c?b:null!=a.meridiemHour?a.meridiemHour(b,c):null!=a.isPM?(d=a.isPM(c),d&&12>b&&(b+=12),d||12!==b||(b=0),b):b}function Ea(a){var b,c,d,e,f;if(0===a._f.length)return j(a).invalidFormat=!0,void(a._d=new Date(NaN));for(e=0;e<a._f.length;e++)f=0,b=n({},a),null!=a._useUTC&&(b._useUTC=a._useUTC),b._f=a._f[e],Ca(b),k(b)&&(f+=j(b).charsLeftOver,f+=10*j(b).unusedTokens.length,j(b).score=f,(null==d||d>f)&&(d=f,c=b));g(a,c||b)}function Fa(a){if(!a._d){var b=L(a._i);a._a=e([b.year,b.month,b.day||b.date,b.hour,b.minute,b.second,b.millisecond],function(a){return a&&parseInt(a,10)}),Aa(a)}}function Ga(a){var b=new o(ma(Ha(a)));return b._nextDay&&(b.add(1,"d"),b._nextDay=void 0),b}function Ha(a){var b=a._i,e=a._f;return a._locale=a._locale||H(a._l),null===b||void 0===e&&""===b?l({nullInput:!0}):("string"==typeof b&&(a._i=b=a._locale.preparse(b)),p(b)?new o(ma(b)):(c(e)?Ea(a):e?Ca(a):d(b)?a._d=b:Ia(a),k(a)||(a._d=null),a))}function Ia(b){var f=b._i;void 0===f?b._d=new Date(a.now()):d(f)?b._d=new Date(f.valueOf()):"string"==typeof f?oa(b):c(f)?(b._a=e(f.slice(0),function(a){return parseInt(a,10)}),Aa(b)):"object"==typeof f?Fa(b):"number"==typeof f?b._d=new Date(f):a.createFromInputFallback(b)}function Ja(a,b,c,d,e){var f={};return"boolean"==typeof c&&(d=c,c=void 0),f._isAMomentObject=!0,f._useUTC=f._isUTC=e,f._l=c,f._i=a,f._f=b,f._strict=d,Ga(f)}function Ka(a,b,c,d){return Ja(a,b,c,d,!1)}function La(a,b){var d,e;if(1===b.length&&c(b[0])&&(b=b[0]),!b.length)return Ka();for(d=b[0],e=1;e<b.length;++e)(!b[e].isValid()||b[e][a](d))&&(d=b[e]);return d}function Ma(){var a=[].slice.call(arguments,0);return La("isBefore",a)}function Na(){var a=[].slice.call(arguments,0);return La("isAfter",a)}function Oa(a){var b=L(a),c=b.year||0,d=b.quarter||0,e=b.month||0,f=b.week||0,g=b.day||0,h=b.hour||0,i=b.minute||0,j=b.second||0,k=b.millisecond||0;this._milliseconds=+k+1e3*j+6e4*i+1e3*h*60*60,this._days=+g+7*f,this._months=+e+3*d+12*c,this._data={},this._locale=H(),this._bubble()}function Pa(a){return a instanceof Oa}function Qa(a,b){R(a,0,0,function(){var a=this.utcOffset(),c="+";return 0>a&&(a=-a,c="-"),c+Q(~~(a/60),2)+b+Q(~~a%60,2)})}function Ra(a,b){var c=(b||"").match(a)||[],d=c[c.length-1]||[],e=(d+"").match(ie)||["-",0,0],f=+(60*e[1])+r(e[2]);return"+"===e[0]?f:-f}function Sa(b,c){var e,f;return c._isUTC?(e=c.clone(),f=(p(b)||d(b)?b.valueOf():Ka(b).valueOf())-e.valueOf(),e._d.setTime(e._d.valueOf()+f),a.updateOffset(e,!1),e):Ka(b).local()}function Ta(a){return 15*-Math.round(a._d.getTimezoneOffset()/15)}function Ua(b,c){var d,e=this._offset||0;return this.isValid()?null!=b?("string"==typeof b?b=Ra(Hd,b):Math.abs(b)<16&&(b=60*b),!this._isUTC&&c&&(d=Ta(this)),this._offset=b,this._isUTC=!0,null!=d&&this.add(d,"m"),e!==b&&(!c||this._changeInProgress?jb(this,db(b-e,"m"),1,!1):this._changeInProgress||(this._changeInProgress=!0,a.updateOffset(this,!0),this._changeInProgress=null)),this):this._isUTC?e:Ta(this):null!=b?this:NaN}function Va(a,b){return null!=a?("string"!=typeof a&&(a=-a),this.utcOffset(a,b),this):-this.utcOffset()}function Wa(a){return this.utcOffset(0,a)}function Xa(a){return this._isUTC&&(this.utcOffset(0,a),this._isUTC=!1,a&&this.subtract(Ta(this),"m")),this}function Ya(){return this._tzm?this.utcOffset(this._tzm):"string"==typeof this._i&&this.utcOffset(Ra(Gd,this._i)),this}function Za(a){return this.isValid()?(a=a?Ka(a).utcOffset():0,(this.utcOffset()-a)%60===0):!1}function $a(){return this.utcOffset()>this.clone().month(0).utcOffset()||this.utcOffset()>this.clone().month(5).utcOffset()}function _a(){if(!m(this._isDSTShifted))return this._isDSTShifted;var a={};if(n(a,this),a=Ha(a),a._a){var b=a._isUTC?h(a._a):Ka(a._a);this._isDSTShifted=this.isValid()&&s(a._a,b.toArray())>0}else this._isDSTShifted=!1;return this._isDSTShifted}function ab(){return this.isValid()?!this._isUTC:!1}function bb(){return this.isValid()?this._isUTC:!1}function cb(){return this.isValid()?this._isUTC&&0===this._offset:!1}function db(a,b){var c,d,e,g=a,h=null;return Pa(a)?g={ms:a._milliseconds,d:a._days,M:a._months}:"number"==typeof a?(g={},b?g[b]=a:g.milliseconds=a):(h=je.exec(a))?(c="-"===h[1]?-1:1,g={y:0,d:r(h[Od])*c,h:r(h[Pd])*c,m:r(h[Qd])*c,s:r(h[Rd])*c,ms:r(h[Sd])*c}):(h=ke.exec(a))?(c="-"===h[1]?-1:1,g={y:eb(h[2],c),M:eb(h[3],c),w:eb(h[4],c),d:eb(h[5],c),h:eb(h[6],c),m:eb(h[7],c),s:eb(h[8],c)}):null==g?g={}:"object"==typeof g&&("from"in g||"to"in g)&&(e=gb(Ka(g.from),Ka(g.to)),g={},g.ms=e.milliseconds,g.M=e.months),d=new Oa(g),Pa(a)&&f(a,"_locale")&&(d._locale=a._locale),d}function eb(a,b){var c=a&&parseFloat(a.replace(",","."));return(isNaN(c)?0:c)*b}function fb(a,b){var c={milliseconds:0,months:0};return c.months=b.month()-a.month()+12*(b.year()-a.year()),a.clone().add(c.months,"M").isAfter(b)&&--c.months,c.milliseconds=+b-+a.clone().add(c.months,"M"),c}function gb(a,b){var c;return a.isValid()&&b.isValid()?(b=Sa(b,a),a.isBefore(b)?c=fb(a,b):(c=fb(b,a),c.milliseconds=-c.milliseconds,c.months=-c.months),c):{milliseconds:0,months:0}}function hb(a){return 0>a?-1*Math.round(-1*a):Math.round(a)}function ib(a,b){return function(c,d){var e,f;return null===d||isNaN(+d)||(v(b,"moment()."+b+"(period, number) is deprecated. Please use moment()."+b+"(number, period)."),f=c,c=d,d=f),c="string"==typeof c?+c:c,e=db(c,d),jb(this,e,a),this}}function jb(b,c,d,e){var f=c._milliseconds,g=hb(c._days),h=hb(c._months);b.isValid()&&(e=null==e?!0:e,f&&b._d.setTime(b._d.valueOf()+f*d),g&&O(b,"Date",N(b,"Date")+g*d),h&&ga(b,N(b,"Month")+h*d),e&&a.updateOffset(b,g||h))}function kb(a,b){var c=a||Ka(),d=Sa(c,this).startOf("day"),e=this.diff(d,"days",!0),f=-6>e?"sameElse":-1>e?"lastWeek":0>e?"lastDay":1>e?"sameDay":2>e?"nextDay":7>e?"nextWeek":"sameElse",g=b&&(w(b[f])?b[f]():b[f]);return this.format(g||this.localeData().calendar(f,this,Ka(c)))}function lb(){return new o(this)}function mb(a,b){var c=p(a)?a:Ka(a);return this.isValid()&&c.isValid()?(b=K(m(b)?"millisecond":b),"millisecond"===b?this.valueOf()>c.valueOf():c.valueOf()<this.clone().startOf(b).valueOf()):!1}function nb(a,b){var c=p(a)?a:Ka(a);return this.isValid()&&c.isValid()?(b=K(m(b)?"millisecond":b),"millisecond"===b?this.valueOf()<c.valueOf():this.clone().endOf(b).valueOf()<c.valueOf()):!1}function ob(a,b,c,d){return d=d||"()",("("===d[0]?this.isAfter(a,c):!this.isBefore(a,c))&&(")"===d[1]?this.isBefore(b,c):!this.isAfter(b,c))}function pb(a,b){var c,d=p(a)?a:Ka(a);return this.isValid()&&d.isValid()?(b=K(b||"millisecond"),"millisecond"===b?this.valueOf()===d.valueOf():(c=d.valueOf(),this.clone().startOf(b).valueOf()<=c&&c<=this.clone().endOf(b).valueOf())):!1}function qb(a,b){return this.isSame(a,b)||this.isAfter(a,b)}function rb(a,b){return this.isSame(a,b)||this.isBefore(a,b)}function sb(a,b,c){var d,e,f,g;return this.isValid()?(d=Sa(a,this),d.isValid()?(e=6e4*(d.utcOffset()-this.utcOffset()),b=K(b),"year"===b||"month"===b||"quarter"===b?(g=tb(this,d),"quarter"===b?g/=3:"year"===b&&(g/=12)):(f=this-d,g="second"===b?f/1e3:"minute"===b?f/6e4:"hour"===b?f/36e5:"day"===b?(f-e)/864e5:"week"===b?(f-e)/6048e5:f),c?g:q(g)):NaN):NaN}function tb(a,b){var c,d,e=12*(b.year()-a.year())+(b.month()-a.month()),f=a.clone().add(e,"months");return 0>b-f?(c=a.clone().add(e-1,"months"),d=(b-f)/(f-c)):(c=a.clone().add(e+1,"months"),d=(b-f)/(c-f)),-(e+d)||0}function ub(){return this.clone().locale("en").format("ddd MMM DD YYYY HH:mm:ss [GMT]ZZ")}function vb(){var a=this.clone().utc();return 0<a.year()&&a.year()<=9999?w(Date.prototype.toISOString)?this.toDate().toISOString():U(a,"YYYY-MM-DD[T]HH:mm:ss.SSS[Z]"):U(a,"YYYYYY-MM-DD[T]HH:mm:ss.SSS[Z]")}function wb(b){b||(b=this.isUtc()?a.defaultFormatUtc:a.defaultFormat);var c=U(this,b);return this.localeData().postformat(c)}function xb(a,b){return this.isValid()&&(p(a)&&a.isValid()||Ka(a).isValid())?db({to:this,from:a}).locale(this.locale()).humanize(!b):this.localeData().invalidDate()}function yb(a){return this.from(Ka(),a)}function zb(a,b){return this.isValid()&&(p(a)&&a.isValid()||Ka(a).isValid())?db({from:this,to:a}).locale(this.locale()).humanize(!b):this.localeData().invalidDate()}function Ab(a){return this.to(Ka(),a)}function Bb(a){var b;return void 0===a?this._locale._abbr:(b=H(a),null!=b&&(this._locale=b),this)}function Cb(){return this._locale}function Db(a){switch(a=K(a)){case"year":this.month(0);case"quarter":case"month":this.date(1);case"week":case"isoWeek":case"day":case"date":this.hours(0);case"hour":this.minutes(0);case"minute":this.seconds(0);case"second":this.milliseconds(0)}return"week"===a&&this.weekday(0),"isoWeek"===a&&this.isoWeekday(1),"quarter"===a&&this.month(3*Math.floor(this.month()/3)),this}function Eb(a){return a=K(a),void 0===a||"millisecond"===a?this:("date"===a&&(a="day"),this.startOf(a).add(1,"isoWeek"===a?"week":a).subtract(1,"ms"))}function Fb(){return this._d.valueOf()-6e4*(this._offset||0)}function Gb(){return Math.floor(this.valueOf()/1e3)}function Hb(){return this._offset?new Date(this.valueOf()):this._d}function Ib(){var a=this;return[a.year(),a.month(),a.date(),a.hour(),a.minute(),a.second(),a.millisecond()]}function Jb(){var a=this;return{years:a.year(),months:a.month(),date:a.date(),hours:a.hours(),minutes:a.minutes(),seconds:a.seconds(),milliseconds:a.milliseconds()}}function Kb(){return this.isValid()?this.toISOString():null}function Lb(){return k(this)}function Mb(){return g({},j(this))}function Nb(){return j(this).overflow}function Ob(){return{input:this._i,format:this._f,locale:this._locale,isUTC:this._isUTC,strict:this._strict}}function Pb(a,b){R(0,[a,a.length],0,b)}function Qb(a){return Ub.call(this,a,this.week(),this.weekday(),this.localeData()._week.dow,this.localeData()._week.doy)}function Rb(a){return Ub.call(this,a,this.isoWeek(),this.isoWeekday(),1,4)}function Sb(){return xa(this.year(),1,4)}function Tb(){var a=this.localeData()._week;return xa(this.year(),a.dow,a.doy)}function Ub(a,b,c,d,e){var f;return null==a?wa(this,d,e).year:(f=xa(a,d,e),b>f&&(b=f),Vb.call(this,a,b,c,d,e))}function Vb(a,b,c,d,e){var f=va(a,b,c,d,e),g=qa(f.year,0,f.dayOfYear);return this.year(g.getUTCFullYear()),this.month(g.getUTCMonth()),this.date(g.getUTCDate()),this}function Wb(a){return null==a?Math.ceil((this.month()+1)/3):this.month(3*(a-1)+this.month()%3)}function Xb(a){return wa(a,this._week.dow,this._week.doy).week}function Yb(){return this._week.dow}function Zb(){return this._week.doy}function $b(a){var b=this.localeData().week(this);return null==a?b:this.add(7*(a-b),"d")}function _b(a){var b=wa(this,1,4).week;return null==a?b:this.add(7*(a-b),"d")}function ac(a,b){return"string"!=typeof a?a:isNaN(a)?(a=b.weekdaysParse(a),"number"==typeof a?a:null):parseInt(a,10)}function bc(a,b){return c(this._weekdays)?this._weekdays[a.day()]:this._weekdays[this._weekdays.isFormat.test(b)?"format":"standalone"][a.day()]}function cc(a){return this._weekdaysShort[a.day()]}function dc(a){return this._weekdaysMin[a.day()]}function ec(a,b,c){var d,e,f,g=a.toLocaleLowerCase();if(!this._weekdaysParse)for(this._weekdaysParse=[],this._shortWeekdaysParse=[],this._minWeekdaysParse=[],d=0;7>d;++d)f=h([2e3,1]).day(d),this._minWeekdaysParse[d]=this.weekdaysMin(f,"").toLocaleLowerCase(),this._shortWeekdaysParse[d]=this.weekdaysShort(f,"").toLocaleLowerCase(),this._weekdaysParse[d]=this.weekdays(f,"").toLocaleLowerCase();return c?"dddd"===b?(e=md.call(this._weekdaysParse,g),-1!==e?e:null):"ddd"===b?(e=md.call(this._shortWeekdaysParse,g),-1!==e?e:null):(e=md.call(this._minWeekdaysParse,g),-1!==e?e:null):"dddd"===b?(e=md.call(this._weekdaysParse,g),-1!==e?e:(e=md.call(this._shortWeekdaysParse,g),-1!==e?e:(e=md.call(this._minWeekdaysParse,g),-1!==e?e:null))):"ddd"===b?(e=md.call(this._shortWeekdaysParse,g),-1!==e?e:(e=md.call(this._weekdaysParse,g),-1!==e?e:(e=md.call(this._minWeekdaysParse,g),-1!==e?e:null))):(e=md.call(this._minWeekdaysParse,g),-1!==e?e:(e=md.call(this._weekdaysParse,g),-1!==e?e:(e=md.call(this._shortWeekdaysParse,g),-1!==e?e:null)))}function fc(a,b,c){var d,e,f;if(this._weekdaysParseExact)return ec.call(this,a,b,c);for(this._weekdaysParse||(this._weekdaysParse=[],this._minWeekdaysParse=[],this._shortWeekdaysParse=[],this._fullWeekdaysParse=[]),d=0;7>d;d++){if(e=h([2e3,1]).day(d),c&&!this._fullWeekdaysParse[d]&&(this._fullWeekdaysParse[d]=new RegExp("^"+this.weekdays(e,"").replace(".",".?")+"$","i"),this._shortWeekdaysParse[d]=new RegExp("^"+this.weekdaysShort(e,"").replace(".",".?")+"$","i"),this._minWeekdaysParse[d]=new RegExp("^"+this.weekdaysMin(e,"").replace(".",".?")+"$","i")),this._weekdaysParse[d]||(f="^"+this.weekdays(e,"")+"|^"+this.weekdaysShort(e,"")+"|^"+this.weekdaysMin(e,""),this._weekdaysParse[d]=new RegExp(f.replace(".",""),"i")),c&&"dddd"===b&&this._fullWeekdaysParse[d].test(a))return d;if(c&&"ddd"===b&&this._shortWeekdaysParse[d].test(a))return d;if(c&&"dd"===b&&this._minWeekdaysParse[d].test(a))return d;if(!c&&this._weekdaysParse[d].test(a))return d}}function gc(a){if(!this.isValid())return null!=a?this:NaN;var b=this._isUTC?this._d.getUTCDay():this._d.getDay();return null!=a?(a=ac(a,this.localeData()),this.add(a-b,"d")):b}function hc(a){if(!this.isValid())return null!=a?this:NaN;var b=(this.day()+7-this.localeData()._week.dow)%7;return null==a?b:this.add(a-b,"d")}function ic(a){return this.isValid()?null==a?this.day()||7:this.day(this.day()%7?a:a-7):null!=a?this:NaN}function jc(a){return this._weekdaysParseExact?(f(this,"_weekdaysRegex")||mc.call(this),a?this._weekdaysStrictRegex:this._weekdaysRegex):this._weekdaysStrictRegex&&a?this._weekdaysStrictRegex:this._weekdaysRegex}function kc(a){return this._weekdaysParseExact?(f(this,"_weekdaysRegex")||mc.call(this),a?this._weekdaysShortStrictRegex:this._weekdaysShortRegex):this._weekdaysShortStrictRegex&&a?this._weekdaysShortStrictRegex:this._weekdaysShortRegex}function lc(a){return this._weekdaysParseExact?(f(this,"_weekdaysRegex")||mc.call(this),a?this._weekdaysMinStrictRegex:this._weekdaysMinRegex):this._weekdaysMinStrictRegex&&a?this._weekdaysMinStrictRegex:this._weekdaysMinRegex}function mc(){function a(a,b){return b.length-a.length}var b,c,d,e,f,g=[],i=[],j=[],k=[];for(b=0;7>b;b++)c=h([2e3,1]).day(b),d=this.weekdaysMin(c,""),e=this.weekdaysShort(c,""),f=this.weekdays(c,""),g.push(d),i.push(e),j.push(f),k.push(d),k.push(e),k.push(f);for(g.sort(a),i.sort(a),j.sort(a),k.sort(a),b=0;7>b;b++)i[b]=Z(i[b]),j[b]=Z(j[b]),k[b]=Z(k[b]);this._weekdaysRegex=new RegExp("^("+k.join("|")+")","i"),this._weekdaysShortRegex=this._weekdaysRegex,this._weekdaysMinRegex=this._weekdaysRegex,this._weekdaysStrictRegex=new RegExp("^("+j.join("|")+")","i"),this._weekdaysShortStrictRegex=new RegExp("^("+i.join("|")+")","i"),this._weekdaysMinStrictRegex=new RegExp("^("+g.join("|")+")","i")}function nc(a){var b=Math.round((this.clone().startOf("day")-this.clone().startOf("year"))/864e5)+1;return null==a?b:this.add(a-b,"d")}function oc(){return this.hours()%12||12}function pc(){return this.hours()||24}function qc(a,b){R(a,0,0,function(){return this.localeData().meridiem(this.hours(),this.minutes(),b)})}function rc(a,b){return b._meridiemParse}function sc(a){return"p"===(a+"").toLowerCase().charAt(0)}function tc(a,b,c){return a>11?c?"pm":"PM":c?"am":"AM"}function uc(a,b){b[Sd]=r(1e3*("0."+a))}function vc(){return this._isUTC?"UTC":""}function wc(){return this._isUTC?"Coordinated Universal Time":""}function xc(a){return Ka(1e3*a)}function yc(){return Ka.apply(null,arguments).parseZone()}function zc(a,b,c){var d=this._calendar[a];return w(d)?d.call(b,c):d}function Ac(a){var b=this._longDateFormat[a],c=this._longDateFormat[a.toUpperCase()];return b||!c?b:(this._longDateFormat[a]=c.replace(/MMMM|MM|DD|dddd/g,function(a){return a.slice(1)}),this._longDateFormat[a])}function Bc(){return this._invalidDate}function Cc(a){return this._ordinal.replace("%d",a)}function Dc(a){return a}function Ec(a,b,c,d){var e=this._relativeTime[c];return w(e)?e(a,b,c,d):e.replace(/%d/i,a)}function Fc(a,b){var c=this._relativeTime[a>0?"future":"past"];return w(c)?c(b):c.replace(/%s/i,b)}function Gc(a,b,c,d){var e=H(),f=h().set(d,b);return e[c](f,a)}function Hc(a,b,c){if("number"==typeof a&&(b=a,a=void 0),a=a||"",null!=b)return Gc(a,b,c,"month");var d,e=[];for(d=0;12>d;d++)e[d]=Gc(a,d,c,"month");return e}function Ic(a,b,c,d){"boolean"==typeof a?("number"==typeof b&&(c=b,b=void 0),b=b||""):(b=a,c=b,a=!1,"number"==typeof b&&(c=b,b=void 0),b=b||"");var e=H(),f=a?e._week.dow:0;if(null!=c)return Gc(b,(c+f)%7,d,"day");var g,h=[];for(g=0;7>g;g++)h[g]=Gc(b,(g+f)%7,d,"day");return h}function Jc(a,b){return Hc(a,b,"months")}function Kc(a,b){return Hc(a,b,"monthsShort")}function Lc(a,b,c){return Ic(a,b,c,"weekdays")}function Mc(a,b,c){return Ic(a,b,c,"weekdaysShort")}function Nc(a,b,c){return Ic(a,b,c,"weekdaysMin")}function Oc(){var a=this._data;return this._milliseconds=Le(this._milliseconds),this._days=Le(this._days),this._months=Le(this._months),a.milliseconds=Le(a.milliseconds),a.seconds=Le(a.seconds),a.minutes=Le(a.minutes),a.hours=Le(a.hours),a.months=Le(a.months),a.years=Le(a.years),this}function Pc(a,b,c,d){var e=db(b,c);return a._milliseconds+=d*e._milliseconds,a._days+=d*e._days,a._months+=d*e._months,a._bubble()}function Qc(a,b){return Pc(this,a,b,1)}function Rc(a,b){return Pc(this,a,b,-1)}function Sc(a){return 0>a?Math.floor(a):Math.ceil(a)}function Tc(){var a,b,c,d,e,f=this._milliseconds,g=this._days,h=this._months,i=this._data;return f>=0&&g>=0&&h>=0||0>=f&&0>=g&&0>=h||(f+=864e5*Sc(Vc(h)+g),g=0,h=0),i.milliseconds=f%1e3,a=q(f/1e3),i.seconds=a%60,b=q(a/60),i.minutes=b%60,c=q(b/60),i.hours=c%24,g+=q(c/24),e=q(Uc(g)),h+=e,g-=Sc(Vc(e)),d=q(h/12),h%=12,i.days=g,i.months=h,i.years=d,this}function Uc(a){return 4800*a/146097}function Vc(a){return 146097*a/4800}function Wc(a){var b,c,d=this._milliseconds;if(a=K(a),"month"===a||"year"===a)return b=this._days+d/864e5,c=this._months+Uc(b),"month"===a?c:c/12;switch(b=this._days+Math.round(Vc(this._months)),a){case"week":return b/7+d/6048e5;case"day":return b+d/864e5;case"hour":return 24*b+d/36e5;case"minute":return 1440*b+d/6e4;case"second":return 86400*b+d/1e3;case"millisecond":return Math.floor(864e5*b)+d;default:throw new Error("Unknown unit "+a)}}function Xc(){return this._milliseconds+864e5*this._days+this._months%12*2592e6+31536e6*r(this._months/12)}function Yc(a){return function(){return this.as(a)}}function Zc(a){
7
- return a=K(a),this[a+"s"]()}function $c(a){return function(){return this._data[a]}}function _c(){return q(this.days()/7)}function ad(a,b,c,d,e){return e.relativeTime(b||1,!!c,a,d)}function bd(a,b,c){var d=db(a).abs(),e=_e(d.as("s")),f=_e(d.as("m")),g=_e(d.as("h")),h=_e(d.as("d")),i=_e(d.as("M")),j=_e(d.as("y")),k=e<af.s&&["s",e]||1>=f&&["m"]||f<af.m&&["mm",f]||1>=g&&["h"]||g<af.h&&["hh",g]||1>=h&&["d"]||h<af.d&&["dd",h]||1>=i&&["M"]||i<af.M&&["MM",i]||1>=j&&["y"]||["yy",j];return k[2]=b,k[3]=+a>0,k[4]=c,ad.apply(null,k)}function cd(a,b){return void 0===af[a]?!1:void 0===b?af[a]:(af[a]=b,!0)}function dd(a){var b=this.localeData(),c=bd(this,!a,b);return a&&(c=b.pastFuture(+this,c)),b.postformat(c)}function ed(){var a,b,c,d=bf(this._milliseconds)/1e3,e=bf(this._days),f=bf(this._months);a=q(d/60),b=q(a/60),d%=60,a%=60,c=q(f/12),f%=12;var g=c,h=f,i=e,j=b,k=a,l=d,m=this.asSeconds();return m?(0>m?"-":"")+"P"+(g?g+"Y":"")+(h?h+"M":"")+(i?i+"D":"")+(j||k||l?"T":"")+(j?j+"H":"")+(k?k+"M":"")+(l?l+"S":""):"P0D"}var fd,gd;gd=Array.prototype.some?Array.prototype.some:function(a){for(var b=Object(this),c=b.length>>>0,d=0;c>d;d++)if(d in b&&a.call(this,b[d],d,b))return!0;return!1};var hd=a.momentProperties=[],id=!1,jd={};a.suppressDeprecationWarnings=!1,a.deprecationHandler=null;var kd;kd=Object.keys?Object.keys:function(a){var b,c=[];for(b in a)f(a,b)&&c.push(b);return c};var ld,md,nd={},od={},pd=/(\[[^\[]*\])|(\\)?([Hh]mm(ss)?|Mo|MM?M?M?|Do|DDDo|DD?D?D?|ddd?d?|do?|w[o|w]?|W[o|W]?|Qo?|YYYYYY|YYYYY|YYYY|YY|gg(ggg?)?|GG(GGG?)?|e|E|a|A|hh?|HH?|kk?|mm?|ss?|S{1,9}|x|X|zz?|ZZ?|.)/g,qd=/(\[[^\[]*\])|(\\)?(LTS|LT|LL?L?L?|l{1,4})/g,rd={},sd={},td=/\d/,ud=/\d\d/,vd=/\d{3}/,wd=/\d{4}/,xd=/[+-]?\d{6}/,yd=/\d\d?/,zd=/\d\d\d\d?/,Ad=/\d\d\d\d\d\d?/,Bd=/\d{1,3}/,Cd=/\d{1,4}/,Dd=/[+-]?\d{1,6}/,Ed=/\d+/,Fd=/[+-]?\d+/,Gd=/Z|[+-]\d\d:?\d\d/gi,Hd=/Z|[+-]\d\d(?::?\d\d)?/gi,Id=/[+-]?\d+(\.\d{1,3})?/,Jd=/[0-9]*['a-z\u00A0-\u05FF\u0700-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF]+|[\u0600-\u06FF\/]+(\s*?[\u0600-\u06FF]+){1,2}/i,Kd={},Ld={},Md=0,Nd=1,Od=2,Pd=3,Qd=4,Rd=5,Sd=6,Td=7,Ud=8;md=Array.prototype.indexOf?Array.prototype.indexOf:function(a){var b;for(b=0;b<this.length;++b)if(this[b]===a)return b;return-1},R("M",["MM",2],"Mo",function(){return this.month()+1}),R("MMM",0,0,function(a){return this.localeData().monthsShort(this,a)}),R("MMMM",0,0,function(a){return this.localeData().months(this,a)}),J("month","M"),W("M",yd),W("MM",yd,ud),W("MMM",function(a,b){return b.monthsShortRegex(a)}),W("MMMM",function(a,b){return b.monthsRegex(a)}),$(["M","MM"],function(a,b){b[Nd]=r(a)-1}),$(["MMM","MMMM"],function(a,b,c,d){var e=c._locale.monthsParse(a,d,c._strict);null!=e?b[Nd]=e:j(c).invalidMonth=a});var Vd=/D[oD]?(\[[^\[\]]*\]|\s+)+MMMM?/,Wd="January_February_March_April_May_June_July_August_September_October_November_December".split("_"),Xd="Jan_Feb_Mar_Apr_May_Jun_Jul_Aug_Sep_Oct_Nov_Dec".split("_"),Yd=Jd,Zd=Jd,$d=/^\s*((?:[+-]\d{6}|\d{4})-(?:\d\d-\d\d|W\d\d-\d|W\d\d|\d\d\d|\d\d))(?:(T| )(\d\d(?::\d\d(?::\d\d(?:[.,]\d+)?)?)?)([\+\-]\d\d(?::?\d\d)?|\s*Z)?)?/,_d=/^\s*((?:[+-]\d{6}|\d{4})(?:\d\d\d\d|W\d\d\d|W\d\d|\d\d\d|\d\d))(?:(T| )(\d\d(?:\d\d(?:\d\d(?:[.,]\d+)?)?)?)([\+\-]\d\d(?::?\d\d)?|\s*Z)?)?/,ae=/Z|[+-]\d\d(?::?\d\d)?/,be=[["YYYYYY-MM-DD",/[+-]\d{6}-\d\d-\d\d/],["YYYY-MM-DD",/\d{4}-\d\d-\d\d/],["GGGG-[W]WW-E",/\d{4}-W\d\d-\d/],["GGGG-[W]WW",/\d{4}-W\d\d/,!1],["YYYY-DDD",/\d{4}-\d{3}/],["YYYY-MM",/\d{4}-\d\d/,!1],["YYYYYYMMDD",/[+-]\d{10}/],["YYYYMMDD",/\d{8}/],["GGGG[W]WWE",/\d{4}W\d{3}/],["GGGG[W]WW",/\d{4}W\d{2}/,!1],["YYYYDDD",/\d{7}/]],ce=[["HH:mm:ss.SSSS",/\d\d:\d\d:\d\d\.\d+/],["HH:mm:ss,SSSS",/\d\d:\d\d:\d\d,\d+/],["HH:mm:ss",/\d\d:\d\d:\d\d/],["HH:mm",/\d\d:\d\d/],["HHmmss.SSSS",/\d\d\d\d\d\d\.\d+/],["HHmmss,SSSS",/\d\d\d\d\d\d,\d+/],["HHmmss",/\d\d\d\d\d\d/],["HHmm",/\d\d\d\d/],["HH",/\d\d/]],de=/^\/?Date\((\-?\d+)/i;a.createFromInputFallback=u("moment construction falls back to js Date. This is discouraged and will be removed in upcoming major release. Please refer to https://github.com/moment/moment/issues/1407 for more info.",function(a){a._d=new Date(a._i+(a._useUTC?" UTC":""))}),R("Y",0,0,function(){var a=this.year();return 9999>=a?""+a:"+"+a}),R(0,["YY",2],0,function(){return this.year()%100}),R(0,["YYYY",4],0,"year"),R(0,["YYYYY",5],0,"year"),R(0,["YYYYYY",6,!0],0,"year"),J("year","y"),W("Y",Fd),W("YY",yd,ud),W("YYYY",Cd,wd),W("YYYYY",Dd,xd),W("YYYYYY",Dd,xd),$(["YYYYY","YYYYYY"],Md),$("YYYY",function(b,c){c[Md]=2===b.length?a.parseTwoDigitYear(b):r(b)}),$("YY",function(b,c){c[Md]=a.parseTwoDigitYear(b)}),$("Y",function(a,b){b[Md]=parseInt(a,10)}),a.parseTwoDigitYear=function(a){return r(a)+(r(a)>68?1900:2e3)};var ee=M("FullYear",!0);a.ISO_8601=function(){};var fe=u("moment().min is deprecated, use moment.max instead. https://github.com/moment/moment/issues/1548",function(){var a=Ka.apply(null,arguments);return this.isValid()&&a.isValid()?this>a?this:a:l()}),ge=u("moment().max is deprecated, use moment.min instead. https://github.com/moment/moment/issues/1548",function(){var a=Ka.apply(null,arguments);return this.isValid()&&a.isValid()?a>this?this:a:l()}),he=function(){return Date.now?Date.now():+new Date};Qa("Z",":"),Qa("ZZ",""),W("Z",Hd),W("ZZ",Hd),$(["Z","ZZ"],function(a,b,c){c._useUTC=!0,c._tzm=Ra(Hd,a)});var ie=/([\+\-]|\d\d)/gi;a.updateOffset=function(){};var je=/^(\-)?(?:(\d*)[. ])?(\d+)\:(\d+)(?:\:(\d+)\.?(\d{3})?\d*)?$/,ke=/^(-)?P(?:(-?[0-9,.]*)Y)?(?:(-?[0-9,.]*)M)?(?:(-?[0-9,.]*)W)?(?:(-?[0-9,.]*)D)?(?:T(?:(-?[0-9,.]*)H)?(?:(-?[0-9,.]*)M)?(?:(-?[0-9,.]*)S)?)?$/;db.fn=Oa.prototype;var le=ib(1,"add"),me=ib(-1,"subtract");a.defaultFormat="YYYY-MM-DDTHH:mm:ssZ",a.defaultFormatUtc="YYYY-MM-DDTHH:mm:ss[Z]";var ne=u("moment().lang() is deprecated. Instead, use moment().localeData() to get the language configuration. Use moment().locale() to change languages.",function(a){return void 0===a?this.localeData():this.locale(a)});R(0,["gg",2],0,function(){return this.weekYear()%100}),R(0,["GG",2],0,function(){return this.isoWeekYear()%100}),Pb("gggg","weekYear"),Pb("ggggg","weekYear"),Pb("GGGG","isoWeekYear"),Pb("GGGGG","isoWeekYear"),J("weekYear","gg"),J("isoWeekYear","GG"),W("G",Fd),W("g",Fd),W("GG",yd,ud),W("gg",yd,ud),W("GGGG",Cd,wd),W("gggg",Cd,wd),W("GGGGG",Dd,xd),W("ggggg",Dd,xd),_(["gggg","ggggg","GGGG","GGGGG"],function(a,b,c,d){b[d.substr(0,2)]=r(a)}),_(["gg","GG"],function(b,c,d,e){c[e]=a.parseTwoDigitYear(b)}),R("Q",0,"Qo","quarter"),J("quarter","Q"),W("Q",td),$("Q",function(a,b){b[Nd]=3*(r(a)-1)}),R("w",["ww",2],"wo","week"),R("W",["WW",2],"Wo","isoWeek"),J("week","w"),J("isoWeek","W"),W("w",yd),W("ww",yd,ud),W("W",yd),W("WW",yd,ud),_(["w","ww","W","WW"],function(a,b,c,d){b[d.substr(0,1)]=r(a)});var oe={dow:0,doy:6};R("D",["DD",2],"Do","date"),J("date","D"),W("D",yd),W("DD",yd,ud),W("Do",function(a,b){return a?b._ordinalParse:b._ordinalParseLenient}),$(["D","DD"],Od),$("Do",function(a,b){b[Od]=r(a.match(yd)[0],10)});var pe=M("Date",!0);R("d",0,"do","day"),R("dd",0,0,function(a){return this.localeData().weekdaysMin(this,a)}),R("ddd",0,0,function(a){return this.localeData().weekdaysShort(this,a)}),R("dddd",0,0,function(a){return this.localeData().weekdays(this,a)}),R("e",0,0,"weekday"),R("E",0,0,"isoWeekday"),J("day","d"),J("weekday","e"),J("isoWeekday","E"),W("d",yd),W("e",yd),W("E",yd),W("dd",function(a,b){return b.weekdaysMinRegex(a)}),W("ddd",function(a,b){return b.weekdaysShortRegex(a)}),W("dddd",function(a,b){return b.weekdaysRegex(a)}),_(["dd","ddd","dddd"],function(a,b,c,d){var e=c._locale.weekdaysParse(a,d,c._strict);null!=e?b.d=e:j(c).invalidWeekday=a}),_(["d","e","E"],function(a,b,c,d){b[d]=r(a)});var qe="Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),re="Sun_Mon_Tue_Wed_Thu_Fri_Sat".split("_"),se="Su_Mo_Tu_We_Th_Fr_Sa".split("_"),te=Jd,ue=Jd,ve=Jd;R("DDD",["DDDD",3],"DDDo","dayOfYear"),J("dayOfYear","DDD"),W("DDD",Bd),W("DDDD",vd),$(["DDD","DDDD"],function(a,b,c){c._dayOfYear=r(a)}),R("H",["HH",2],0,"hour"),R("h",["hh",2],0,oc),R("k",["kk",2],0,pc),R("hmm",0,0,function(){return""+oc.apply(this)+Q(this.minutes(),2)}),R("hmmss",0,0,function(){return""+oc.apply(this)+Q(this.minutes(),2)+Q(this.seconds(),2)}),R("Hmm",0,0,function(){return""+this.hours()+Q(this.minutes(),2)}),R("Hmmss",0,0,function(){return""+this.hours()+Q(this.minutes(),2)+Q(this.seconds(),2)}),qc("a",!0),qc("A",!1),J("hour","h"),W("a",rc),W("A",rc),W("H",yd),W("h",yd),W("HH",yd,ud),W("hh",yd,ud),W("hmm",zd),W("hmmss",Ad),W("Hmm",zd),W("Hmmss",Ad),$(["H","HH"],Pd),$(["a","A"],function(a,b,c){c._isPm=c._locale.isPM(a),c._meridiem=a}),$(["h","hh"],function(a,b,c){b[Pd]=r(a),j(c).bigHour=!0}),$("hmm",function(a,b,c){var d=a.length-2;b[Pd]=r(a.substr(0,d)),b[Qd]=r(a.substr(d)),j(c).bigHour=!0}),$("hmmss",function(a,b,c){var d=a.length-4,e=a.length-2;b[Pd]=r(a.substr(0,d)),b[Qd]=r(a.substr(d,2)),b[Rd]=r(a.substr(e)),j(c).bigHour=!0}),$("Hmm",function(a,b,c){var d=a.length-2;b[Pd]=r(a.substr(0,d)),b[Qd]=r(a.substr(d))}),$("Hmmss",function(a,b,c){var d=a.length-4,e=a.length-2;b[Pd]=r(a.substr(0,d)),b[Qd]=r(a.substr(d,2)),b[Rd]=r(a.substr(e))});var we=/[ap]\.?m?\.?/i,xe=M("Hours",!0);R("m",["mm",2],0,"minute"),J("minute","m"),W("m",yd),W("mm",yd,ud),$(["m","mm"],Qd);var ye=M("Minutes",!1);R("s",["ss",2],0,"second"),J("second","s"),W("s",yd),W("ss",yd,ud),$(["s","ss"],Rd);var ze=M("Seconds",!1);R("S",0,0,function(){return~~(this.millisecond()/100)}),R(0,["SS",2],0,function(){return~~(this.millisecond()/10)}),R(0,["SSS",3],0,"millisecond"),R(0,["SSSS",4],0,function(){return 10*this.millisecond()}),R(0,["SSSSS",5],0,function(){return 100*this.millisecond()}),R(0,["SSSSSS",6],0,function(){return 1e3*this.millisecond()}),R(0,["SSSSSSS",7],0,function(){return 1e4*this.millisecond()}),R(0,["SSSSSSSS",8],0,function(){return 1e5*this.millisecond()}),R(0,["SSSSSSSSS",9],0,function(){return 1e6*this.millisecond()}),J("millisecond","ms"),W("S",Bd,td),W("SS",Bd,ud),W("SSS",Bd,vd);var Ae;for(Ae="SSSS";Ae.length<=9;Ae+="S")W(Ae,Ed);for(Ae="S";Ae.length<=9;Ae+="S")$(Ae,uc);var Be=M("Milliseconds",!1);R("z",0,0,"zoneAbbr"),R("zz",0,0,"zoneName");var Ce=o.prototype;Ce.add=le,Ce.calendar=kb,Ce.clone=lb,Ce.diff=sb,Ce.endOf=Eb,Ce.format=wb,Ce.from=xb,Ce.fromNow=yb,Ce.to=zb,Ce.toNow=Ab,Ce.get=P,Ce.invalidAt=Nb,Ce.isAfter=mb,Ce.isBefore=nb,Ce.isBetween=ob,Ce.isSame=pb,Ce.isSameOrAfter=qb,Ce.isSameOrBefore=rb,Ce.isValid=Lb,Ce.lang=ne,Ce.locale=Bb,Ce.localeData=Cb,Ce.max=ge,Ce.min=fe,Ce.parsingFlags=Mb,Ce.set=P,Ce.startOf=Db,Ce.subtract=me,Ce.toArray=Ib,Ce.toObject=Jb,Ce.toDate=Hb,Ce.toISOString=vb,Ce.toJSON=Kb,Ce.toString=ub,Ce.unix=Gb,Ce.valueOf=Fb,Ce.creationData=Ob,Ce.year=ee,Ce.isLeapYear=ta,Ce.weekYear=Qb,Ce.isoWeekYear=Rb,Ce.quarter=Ce.quarters=Wb,Ce.month=ha,Ce.daysInMonth=ia,Ce.week=Ce.weeks=$b,Ce.isoWeek=Ce.isoWeeks=_b,Ce.weeksInYear=Tb,Ce.isoWeeksInYear=Sb,Ce.date=pe,Ce.day=Ce.days=gc,Ce.weekday=hc,Ce.isoWeekday=ic,Ce.dayOfYear=nc,Ce.hour=Ce.hours=xe,Ce.minute=Ce.minutes=ye,Ce.second=Ce.seconds=ze,Ce.millisecond=Ce.milliseconds=Be,Ce.utcOffset=Ua,Ce.utc=Wa,Ce.local=Xa,Ce.parseZone=Ya,Ce.hasAlignedHourOffset=Za,Ce.isDST=$a,Ce.isDSTShifted=_a,Ce.isLocal=ab,Ce.isUtcOffset=bb,Ce.isUtc=cb,Ce.isUTC=cb,Ce.zoneAbbr=vc,Ce.zoneName=wc,Ce.dates=u("dates accessor is deprecated. Use date instead.",pe),Ce.months=u("months accessor is deprecated. Use month instead",ha),Ce.years=u("years accessor is deprecated. Use year instead",ee),Ce.zone=u("moment().zone is deprecated, use moment().utcOffset instead. https://github.com/moment/moment/issues/1779",Va);var De=Ce,Ee={sameDay:"[Today at] LT",nextDay:"[Tomorrow at] LT",nextWeek:"dddd [at] LT",lastDay:"[Yesterday at] LT",lastWeek:"[Last] dddd [at] LT",sameElse:"L"},Fe={LTS:"h:mm:ss A",LT:"h:mm A",L:"MM/DD/YYYY",LL:"MMMM D, YYYY",LLL:"MMMM D, YYYY h:mm A",LLLL:"dddd, MMMM D, YYYY h:mm A"},Ge="Invalid date",He="%d",Ie=/\d{1,2}/,Je={future:"in %s",past:"%s ago",s:"a few seconds",m:"a minute",mm:"%d minutes",h:"an hour",hh:"%d hours",d:"a day",dd:"%d days",M:"a month",MM:"%d months",y:"a year",yy:"%d years"},Ke=A.prototype;Ke._calendar=Ee,Ke.calendar=zc,Ke._longDateFormat=Fe,Ke.longDateFormat=Ac,Ke._invalidDate=Ge,Ke.invalidDate=Bc,Ke._ordinal=He,Ke.ordinal=Cc,Ke._ordinalParse=Ie,Ke.preparse=Dc,Ke.postformat=Dc,Ke._relativeTime=Je,Ke.relativeTime=Ec,Ke.pastFuture=Fc,Ke.set=y,Ke.months=ca,Ke._months=Wd,Ke.monthsShort=da,Ke._monthsShort=Xd,Ke.monthsParse=fa,Ke._monthsRegex=Zd,Ke.monthsRegex=ka,Ke._monthsShortRegex=Yd,Ke.monthsShortRegex=ja,Ke.week=Xb,Ke._week=oe,Ke.firstDayOfYear=Zb,Ke.firstDayOfWeek=Yb,Ke.weekdays=bc,Ke._weekdays=qe,Ke.weekdaysMin=dc,Ke._weekdaysMin=se,Ke.weekdaysShort=cc,Ke._weekdaysShort=re,Ke.weekdaysParse=fc,Ke._weekdaysRegex=te,Ke.weekdaysRegex=jc,Ke._weekdaysShortRegex=ue,Ke.weekdaysShortRegex=kc,Ke._weekdaysMinRegex=ve,Ke.weekdaysMinRegex=lc,Ke.isPM=sc,Ke._meridiemParse=we,Ke.meridiem=tc,E("en",{ordinalParse:/\d{1,2}(th|st|nd|rd)/,ordinal:function(a){var b=a%10,c=1===r(a%100/10)?"th":1===b?"st":2===b?"nd":3===b?"rd":"th";return a+c}}),a.lang=u("moment.lang is deprecated. Use moment.locale instead.",E),a.langData=u("moment.langData is deprecated. Use moment.localeData instead.",H);var Le=Math.abs,Me=Yc("ms"),Ne=Yc("s"),Oe=Yc("m"),Pe=Yc("h"),Qe=Yc("d"),Re=Yc("w"),Se=Yc("M"),Te=Yc("y"),Ue=$c("milliseconds"),Ve=$c("seconds"),We=$c("minutes"),Xe=$c("hours"),Ye=$c("days"),Ze=$c("months"),$e=$c("years"),_e=Math.round,af={s:45,m:45,h:22,d:26,M:11},bf=Math.abs,cf=Oa.prototype;cf.abs=Oc,cf.add=Qc,cf.subtract=Rc,cf.as=Wc,cf.asMilliseconds=Me,cf.asSeconds=Ne,cf.asMinutes=Oe,cf.asHours=Pe,cf.asDays=Qe,cf.asWeeks=Re,cf.asMonths=Se,cf.asYears=Te,cf.valueOf=Xc,cf._bubble=Tc,cf.get=Zc,cf.milliseconds=Ue,cf.seconds=Ve,cf.minutes=We,cf.hours=Xe,cf.days=Ye,cf.weeks=_c,cf.months=Ze,cf.years=$e,cf.humanize=dd,cf.toISOString=ed,cf.toString=ed,cf.toJSON=ed,cf.locale=Bb,cf.localeData=Cb,cf.toIsoString=u("toIsoString() is deprecated. Please use toISOString() instead (notice the capitals)",ed),cf.lang=ne,R("X",0,0,"unix"),R("x",0,0,"valueOf"),W("x",Fd),W("X",Id),$("X",function(a,b,c){c._d=new Date(1e3*parseFloat(a,10))}),$("x",function(a,b,c){c._d=new Date(r(a))}),a.version="2.13.0",b(Ka),a.fn=De,a.min=Ma,a.max=Na,a.now=he,a.utc=h,a.unix=xc,a.months=Jc,a.isDate=d,a.locale=E,a.invalid=l,a.duration=db,a.isMoment=p,a.weekdays=Lc,a.parseZone=yc,a.localeData=H,a.isDuration=Pa,a.monthsShort=Kc,a.weekdaysMin=Nc,a.defineLocale=F,a.updateLocale=G,a.locales=I,a.weekdaysShort=Mc,a.normalizeUnits=K,a.relativeTimeThreshold=cd,a.prototype=De;var df=a;return df});
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
  //! moment.js
2
+ //! version : 2.14.1
3
  //! authors : Tim Wood, Iskren Chernev, Moment.js contributors
4
  //! license : MIT
5
  //! momentjs.com
6
+ !function(a,b){"object"==typeof exports&&"undefined"!=typeof module?module.exports=b():"function"==typeof define&&define.amd?define(b):a.moment=b()}(this,function(){"use strict";function a(){return md.apply(null,arguments)}
7
+ // This is done to register the method called with moment()
8
+ // without creating circular dependencies.
9
+ function b(a){md=a}function c(a){return a instanceof Array||"[object Array]"===Object.prototype.toString.call(a)}function d(a){return"[object Object]"===Object.prototype.toString.call(a)}function e(a){var b;for(b in a)
10
+ // even if its not own property I'd still call it non-empty
11
+ return!1;return!0}function f(a){return a instanceof Date||"[object Date]"===Object.prototype.toString.call(a)}function g(a,b){var c,d=[];for(c=0;c<a.length;++c)d.push(b(a[c],c));return d}function h(a,b){return Object.prototype.hasOwnProperty.call(a,b)}function i(a,b){for(var c in b)h(b,c)&&(a[c]=b[c]);return h(b,"toString")&&(a.toString=b.toString),h(b,"valueOf")&&(a.valueOf=b.valueOf),a}function j(a,b,c,d){return qb(a,b,c,d,!0).utc()}function k(){
12
+ // We need to deep clone this object.
13
+ return{empty:!1,unusedTokens:[],unusedInput:[],overflow:-2,charsLeftOver:0,nullInput:!1,invalidMonth:null,invalidFormat:!1,userInvalidated:!1,iso:!1,parsedDateParts:[],meridiem:null}}function l(a){return null==a._pf&&(a._pf=k()),a._pf}function m(a){if(null==a._isValid){var b=l(a),c=nd.call(b.parsedDateParts,function(a){return null!=a});a._isValid=!isNaN(a._d.getTime())&&b.overflow<0&&!b.empty&&!b.invalidMonth&&!b.invalidWeekday&&!b.nullInput&&!b.invalidFormat&&!b.userInvalidated&&(!b.meridiem||b.meridiem&&c),a._strict&&(a._isValid=a._isValid&&0===b.charsLeftOver&&0===b.unusedTokens.length&&void 0===b.bigHour)}return a._isValid}function n(a){var b=j(NaN);return null!=a?i(l(b),a):l(b).userInvalidated=!0,b}function o(a){return void 0===a}function p(a,b){var c,d,e;if(o(b._isAMomentObject)||(a._isAMomentObject=b._isAMomentObject),o(b._i)||(a._i=b._i),o(b._f)||(a._f=b._f),o(b._l)||(a._l=b._l),o(b._strict)||(a._strict=b._strict),o(b._tzm)||(a._tzm=b._tzm),o(b._isUTC)||(a._isUTC=b._isUTC),o(b._offset)||(a._offset=b._offset),o(b._pf)||(a._pf=l(b)),o(b._locale)||(a._locale=b._locale),od.length>0)for(c in od)d=od[c],e=b[d],o(e)||(a[d]=e);return a}
14
+ // Moment prototype object
15
+ function q(b){p(this,b),this._d=new Date(null!=b._d?b._d.getTime():NaN),pd===!1&&(pd=!0,a.updateOffset(this),pd=!1)}function r(a){return a instanceof q||null!=a&&null!=a._isAMomentObject}function s(a){return 0>a?Math.ceil(a)||0:Math.floor(a)}function t(a){var b=+a,c=0;return 0!==b&&isFinite(b)&&(c=s(b)),c}
16
+ // compare two arrays, return the number of differences
17
+ function u(a,b,c){var d,e=Math.min(a.length,b.length),f=Math.abs(a.length-b.length),g=0;for(d=0;e>d;d++)(c&&a[d]!==b[d]||!c&&t(a[d])!==t(b[d]))&&g++;return g+f}function v(b){a.suppressDeprecationWarnings===!1&&"undefined"!=typeof console&&console.warn&&console.warn("Deprecation warning: "+b)}function w(b,c){var d=!0;return i(function(){return null!=a.deprecationHandler&&a.deprecationHandler(null,b),d&&(v(b+"\nArguments: "+Array.prototype.slice.call(arguments).join(", ")+"\n"+(new Error).stack),d=!1),c.apply(this,arguments)},c)}function x(b,c){null!=a.deprecationHandler&&a.deprecationHandler(b,c),qd[b]||(v(c),qd[b]=!0)}function y(a){return a instanceof Function||"[object Function]"===Object.prototype.toString.call(a)}function z(a){var b,c;for(c in a)b=a[c],y(b)?this[c]=b:this["_"+c]=b;this._config=a,
18
+ // Lenient ordinal parsing accepts just a number in addition to
19
+ // number + (possibly) stuff coming from _ordinalParseLenient.
20
+ this._ordinalParseLenient=new RegExp(this._ordinalParse.source+"|"+/\d{1,2}/.source)}function A(a,b){var c,e=i({},a);for(c in b)h(b,c)&&(d(a[c])&&d(b[c])?(e[c]={},i(e[c],a[c]),i(e[c],b[c])):null!=b[c]?e[c]=b[c]:delete e[c]);for(c in a)h(a,c)&&!h(b,c)&&d(a[c])&&(
21
+ // make sure changes to properties don't modify parent config
22
+ e[c]=i({},e[c]));return e}function B(a){null!=a&&this.set(a)}function C(a,b,c){var d=this._calendar[a]||this._calendar.sameElse;return y(d)?d.call(b,c):d}function D(a){var b=this._longDateFormat[a],c=this._longDateFormat[a.toUpperCase()];return b||!c?b:(this._longDateFormat[a]=c.replace(/MMMM|MM|DD|dddd/g,function(a){return a.slice(1)}),this._longDateFormat[a])}function E(){return this._invalidDate}function F(a){return this._ordinal.replace("%d",a)}function G(a,b,c,d){var e=this._relativeTime[c];return y(e)?e(a,b,c,d):e.replace(/%d/i,a)}function H(a,b){var c=this._relativeTime[a>0?"future":"past"];return y(c)?c(b):c.replace(/%s/i,b)}function I(a,b){var c=a.toLowerCase();zd[c]=zd[c+"s"]=zd[b]=a}function J(a){return"string"==typeof a?zd[a]||zd[a.toLowerCase()]:void 0}function K(a){var b,c,d={};for(c in a)h(a,c)&&(b=J(c),b&&(d[b]=a[c]));return d}function L(a,b){Ad[a]=b}function M(a){var b=[];for(var c in a)b.push({unit:c,priority:Ad[c]});return b.sort(function(a,b){return a.priority-b.priority}),b}function N(b,c){return function(d){return null!=d?(P(this,b,d),a.updateOffset(this,c),this):O(this,b)}}function O(a,b){return a.isValid()?a._d["get"+(a._isUTC?"UTC":"")+b]():NaN}function P(a,b,c){a.isValid()&&a._d["set"+(a._isUTC?"UTC":"")+b](c)}
23
+ // MOMENTS
24
+ function Q(a){return a=J(a),y(this[a])?this[a]():this}function R(a,b){if("object"==typeof a){a=K(a);for(var c=M(a),d=0;d<c.length;d++)this[c[d].unit](a[c[d].unit])}else if(a=J(a),y(this[a]))return this[a](b);return this}function S(a,b,c){var d=""+Math.abs(a),e=b-d.length,f=a>=0;return(f?c?"+":"":"-")+Math.pow(10,Math.max(0,e)).toString().substr(1)+d}
25
+ // token: 'M'
26
+ // padded: ['MM', 2]
27
+ // ordinal: 'Mo'
28
+ // callback: function () { this.month() + 1 }
29
+ function T(a,b,c,d){var e=d;"string"==typeof d&&(e=function(){return this[d]()}),a&&(Ed[a]=e),b&&(Ed[b[0]]=function(){return S(e.apply(this,arguments),b[1],b[2])}),c&&(Ed[c]=function(){return this.localeData().ordinal(e.apply(this,arguments),a)})}function U(a){return a.match(/\[[\s\S]/)?a.replace(/^\[|\]$/g,""):a.replace(/\\/g,"")}function V(a){var b,c,d=a.match(Bd);for(b=0,c=d.length;c>b;b++)Ed[d[b]]?d[b]=Ed[d[b]]:d[b]=U(d[b]);return function(b){var e,f="";for(e=0;c>e;e++)f+=d[e]instanceof Function?d[e].call(b,a):d[e];return f}}
30
+ // format date using native date object
31
+ function W(a,b){return a.isValid()?(b=X(b,a.localeData()),Dd[b]=Dd[b]||V(b),Dd[b](a)):a.localeData().invalidDate()}function X(a,b){function c(a){return b.longDateFormat(a)||a}var d=5;for(Cd.lastIndex=0;d>=0&&Cd.test(a);)a=a.replace(Cd,c),Cd.lastIndex=0,d-=1;return a}function Y(a,b,c){Wd[a]=y(b)?b:function(a,d){return a&&c?c:b}}function Z(a,b){return h(Wd,a)?Wd[a](b._strict,b._locale):new RegExp($(a))}
32
+ // Code from http://stackoverflow.com/questions/3561493/is-there-a-regexp-escape-function-in-javascript
33
+ function $(a){return _(a.replace("\\","").replace(/\\(\[)|\\(\])|\[([^\]\[]*)\]|\\(.)/g,function(a,b,c,d,e){return b||c||d||e}))}function _(a){return a.replace(/[-\/\\^$*+?.()|[\]{}]/g,"\\$&")}function aa(a,b){var c,d=b;for("string"==typeof a&&(a=[a]),"number"==typeof b&&(d=function(a,c){c[b]=t(a)}),c=0;c<a.length;c++)Xd[a[c]]=d}function ba(a,b){aa(a,function(a,c,d,e){d._w=d._w||{},b(a,d._w,d,e)})}function ca(a,b,c){null!=b&&h(Xd,a)&&Xd[a](b,c._a,c,a)}function da(a,b){return new Date(Date.UTC(a,b+1,0)).getUTCDate()}function ea(a,b){return c(this._months)?this._months[a.month()]:this._months[(this._months.isFormat||fe).test(b)?"format":"standalone"][a.month()]}function fa(a,b){return c(this._monthsShort)?this._monthsShort[a.month()]:this._monthsShort[fe.test(b)?"format":"standalone"][a.month()]}function ga(a,b,c){var d,e,f,g=a.toLocaleLowerCase();if(!this._monthsParse)for(
34
+ // this is not used
35
+ this._monthsParse=[],this._longMonthsParse=[],this._shortMonthsParse=[],d=0;12>d;++d)f=j([2e3,d]),this._shortMonthsParse[d]=this.monthsShort(f,"").toLocaleLowerCase(),this._longMonthsParse[d]=this.months(f,"").toLocaleLowerCase();return c?"MMM"===b?(e=sd.call(this._shortMonthsParse,g),-1!==e?e:null):(e=sd.call(this._longMonthsParse,g),-1!==e?e:null):"MMM"===b?(e=sd.call(this._shortMonthsParse,g),-1!==e?e:(e=sd.call(this._longMonthsParse,g),-1!==e?e:null)):(e=sd.call(this._longMonthsParse,g),-1!==e?e:(e=sd.call(this._shortMonthsParse,g),-1!==e?e:null))}function ha(a,b,c){var d,e,f;if(this._monthsParseExact)return ga.call(this,a,b,c);
36
+ // TODO: add sorting
37
+ // Sorting makes sure if one month (or abbr) is a prefix of another
38
+ // see sorting in computeMonthsParse
39
+ for(this._monthsParse||(this._monthsParse=[],this._longMonthsParse=[],this._shortMonthsParse=[]),d=0;12>d;d++){
40
+ // test the regex
41
+ if(e=j([2e3,d]),c&&!this._longMonthsParse[d]&&(this._longMonthsParse[d]=new RegExp("^"+this.months(e,"").replace(".","")+"$","i"),this._shortMonthsParse[d]=new RegExp("^"+this.monthsShort(e,"").replace(".","")+"$","i")),c||this._monthsParse[d]||(f="^"+this.months(e,"")+"|^"+this.monthsShort(e,""),this._monthsParse[d]=new RegExp(f.replace(".",""),"i")),c&&"MMMM"===b&&this._longMonthsParse[d].test(a))return d;if(c&&"MMM"===b&&this._shortMonthsParse[d].test(a))return d;if(!c&&this._monthsParse[d].test(a))return d}}
42
+ // MOMENTS
43
+ function ia(a,b){var c;if(!a.isValid())
44
+ // No op
45
+ return a;if("string"==typeof b)if(/^\d+$/.test(b))b=t(b);else
46
+ // TODO: Another silent failure?
47
+ if(b=a.localeData().monthsParse(b),"number"!=typeof b)return a;return c=Math.min(a.date(),da(a.year(),b)),a._d["set"+(a._isUTC?"UTC":"")+"Month"](b,c),a}function ja(b){return null!=b?(ia(this,b),a.updateOffset(this,!0),this):O(this,"Month")}function ka(){return da(this.year(),this.month())}function la(a){return this._monthsParseExact?(h(this,"_monthsRegex")||na.call(this),a?this._monthsShortStrictRegex:this._monthsShortRegex):(h(this,"_monthsShortRegex")||(this._monthsShortRegex=ie),this._monthsShortStrictRegex&&a?this._monthsShortStrictRegex:this._monthsShortRegex)}function ma(a){return this._monthsParseExact?(h(this,"_monthsRegex")||na.call(this),a?this._monthsStrictRegex:this._monthsRegex):(h(this,"_monthsRegex")||(this._monthsRegex=je),this._monthsStrictRegex&&a?this._monthsStrictRegex:this._monthsRegex)}function na(){function a(a,b){return b.length-a.length}var b,c,d=[],e=[],f=[];for(b=0;12>b;b++)c=j([2e3,b]),d.push(this.monthsShort(c,"")),e.push(this.months(c,"")),f.push(this.months(c,"")),f.push(this.monthsShort(c,""));for(
48
+ // Sorting makes sure if one month (or abbr) is a prefix of another it
49
+ // will match the longer piece.
50
+ d.sort(a),e.sort(a),f.sort(a),b=0;12>b;b++)d[b]=_(d[b]),e[b]=_(e[b]);for(b=0;24>b;b++)f[b]=_(f[b]);this._monthsRegex=new RegExp("^("+f.join("|")+")","i"),this._monthsShortRegex=this._monthsRegex,this._monthsStrictRegex=new RegExp("^("+e.join("|")+")","i"),this._monthsShortStrictRegex=new RegExp("^("+d.join("|")+")","i")}
51
+ // HELPERS
52
+ function oa(a){return pa(a)?366:365}function pa(a){return a%4===0&&a%100!==0||a%400===0}function qa(){return pa(this.year())}function ra(a,b,c,d,e,f,g){
53
+ //can't just apply() to create a date:
54
+ //http://stackoverflow.com/questions/181348/instantiating-a-javascript-object-by-calling-prototype-constructor-apply
55
+ var h=new Date(a,b,c,d,e,f,g);
56
+ //the date constructor remaps years 0-99 to 1900-1999
57
+ return 100>a&&a>=0&&isFinite(h.getFullYear())&&h.setFullYear(a),h}function sa(a){var b=new Date(Date.UTC.apply(null,arguments));
58
+ //the Date.UTC function remaps years 0-99 to 1900-1999
59
+ return 100>a&&a>=0&&isFinite(b.getUTCFullYear())&&b.setUTCFullYear(a),b}
60
+ // start-of-first-week - start-of-year
61
+ function ta(a,b,c){var// first-week day -- which january is always in the first week (4 for iso, 1 for other)
62
+ d=7+b-c,
63
+ // first-week day local weekday -- which local weekday is fwd
64
+ e=(7+sa(a,0,d).getUTCDay()-b)%7;return-e+d-1}
65
+ //http://en.wikipedia.org/wiki/ISO_week_date#Calculating_a_date_given_the_year.2C_week_number_and_weekday
66
+ function ua(a,b,c,d,e){var f,g,h=(7+c-d)%7,i=ta(a,d,e),j=1+7*(b-1)+h+i;return 0>=j?(f=a-1,g=oa(f)+j):j>oa(a)?(f=a+1,g=j-oa(a)):(f=a,g=j),{year:f,dayOfYear:g}}function va(a,b,c){var d,e,f=ta(a.year(),b,c),g=Math.floor((a.dayOfYear()-f-1)/7)+1;return 1>g?(e=a.year()-1,d=g+wa(e,b,c)):g>wa(a.year(),b,c)?(d=g-wa(a.year(),b,c),e=a.year()+1):(e=a.year(),d=g),{week:d,year:e}}function wa(a,b,c){var d=ta(a,b,c),e=ta(a+1,b,c);return(oa(a)-d+e)/7}
67
+ // HELPERS
68
+ // LOCALES
69
+ function xa(a){return va(a,this._week.dow,this._week.doy).week}function ya(){return this._week.dow}function za(){return this._week.doy}
70
+ // MOMENTS
71
+ function Aa(a){var b=this.localeData().week(this);return null==a?b:this.add(7*(a-b),"d")}function Ba(a){var b=va(this,1,4).week;return null==a?b:this.add(7*(a-b),"d")}
72
+ // HELPERS
73
+ function Ca(a,b){return"string"!=typeof a?a:isNaN(a)?(a=b.weekdaysParse(a),"number"==typeof a?a:null):parseInt(a,10)}function Da(a,b){return"string"==typeof a?b.weekdaysParse(a)%7||7:isNaN(a)?null:a}function Ea(a,b){return c(this._weekdays)?this._weekdays[a.day()]:this._weekdays[this._weekdays.isFormat.test(b)?"format":"standalone"][a.day()]}function Fa(a){return this._weekdaysShort[a.day()]}function Ga(a){return this._weekdaysMin[a.day()]}function Ha(a,b,c){var d,e,f,g=a.toLocaleLowerCase();if(!this._weekdaysParse)for(this._weekdaysParse=[],this._shortWeekdaysParse=[],this._minWeekdaysParse=[],d=0;7>d;++d)f=j([2e3,1]).day(d),this._minWeekdaysParse[d]=this.weekdaysMin(f,"").toLocaleLowerCase(),this._shortWeekdaysParse[d]=this.weekdaysShort(f,"").toLocaleLowerCase(),this._weekdaysParse[d]=this.weekdays(f,"").toLocaleLowerCase();return c?"dddd"===b?(e=sd.call(this._weekdaysParse,g),-1!==e?e:null):"ddd"===b?(e=sd.call(this._shortWeekdaysParse,g),-1!==e?e:null):(e=sd.call(this._minWeekdaysParse,g),-1!==e?e:null):"dddd"===b?(e=sd.call(this._weekdaysParse,g),-1!==e?e:(e=sd.call(this._shortWeekdaysParse,g),-1!==e?e:(e=sd.call(this._minWeekdaysParse,g),-1!==e?e:null))):"ddd"===b?(e=sd.call(this._shortWeekdaysParse,g),-1!==e?e:(e=sd.call(this._weekdaysParse,g),-1!==e?e:(e=sd.call(this._minWeekdaysParse,g),-1!==e?e:null))):(e=sd.call(this._minWeekdaysParse,g),-1!==e?e:(e=sd.call(this._weekdaysParse,g),-1!==e?e:(e=sd.call(this._shortWeekdaysParse,g),-1!==e?e:null)))}function Ia(a,b,c){var d,e,f;if(this._weekdaysParseExact)return Ha.call(this,a,b,c);for(this._weekdaysParse||(this._weekdaysParse=[],this._minWeekdaysParse=[],this._shortWeekdaysParse=[],this._fullWeekdaysParse=[]),d=0;7>d;d++){
74
+ // test the regex
75
+ if(e=j([2e3,1]).day(d),c&&!this._fullWeekdaysParse[d]&&(this._fullWeekdaysParse[d]=new RegExp("^"+this.weekdays(e,"").replace(".",".?")+"$","i"),this._shortWeekdaysParse[d]=new RegExp("^"+this.weekdaysShort(e,"").replace(".",".?")+"$","i"),this._minWeekdaysParse[d]=new RegExp("^"+this.weekdaysMin(e,"").replace(".",".?")+"$","i")),this._weekdaysParse[d]||(f="^"+this.weekdays(e,"")+"|^"+this.weekdaysShort(e,"")+"|^"+this.weekdaysMin(e,""),this._weekdaysParse[d]=new RegExp(f.replace(".",""),"i")),c&&"dddd"===b&&this._fullWeekdaysParse[d].test(a))return d;if(c&&"ddd"===b&&this._shortWeekdaysParse[d].test(a))return d;if(c&&"dd"===b&&this._minWeekdaysParse[d].test(a))return d;if(!c&&this._weekdaysParse[d].test(a))return d}}
76
+ // MOMENTS
77
+ function Ja(a){if(!this.isValid())return null!=a?this:NaN;var b=this._isUTC?this._d.getUTCDay():this._d.getDay();return null!=a?(a=Ca(a,this.localeData()),this.add(a-b,"d")):b}function Ka(a){if(!this.isValid())return null!=a?this:NaN;var b=(this.day()+7-this.localeData()._week.dow)%7;return null==a?b:this.add(a-b,"d")}function La(a){if(!this.isValid())return null!=a?this:NaN;
78
+ // behaves the same as moment#day except
79
+ // as a getter, returns 7 instead of 0 (1-7 range instead of 0-6)
80
+ // as a setter, sunday should belong to the previous week.
81
+ if(null!=a){var b=Da(a,this.localeData());return this.day(this.day()%7?b:b-7)}return this.day()||7}function Ma(a){return this._weekdaysParseExact?(h(this,"_weekdaysRegex")||Pa.call(this),a?this._weekdaysStrictRegex:this._weekdaysRegex):(h(this,"_weekdaysRegex")||(this._weekdaysRegex=pe),this._weekdaysStrictRegex&&a?this._weekdaysStrictRegex:this._weekdaysRegex)}function Na(a){return this._weekdaysParseExact?(h(this,"_weekdaysRegex")||Pa.call(this),a?this._weekdaysShortStrictRegex:this._weekdaysShortRegex):(h(this,"_weekdaysShortRegex")||(this._weekdaysShortRegex=qe),this._weekdaysShortStrictRegex&&a?this._weekdaysShortStrictRegex:this._weekdaysShortRegex)}function Oa(a){return this._weekdaysParseExact?(h(this,"_weekdaysRegex")||Pa.call(this),a?this._weekdaysMinStrictRegex:this._weekdaysMinRegex):(h(this,"_weekdaysMinRegex")||(this._weekdaysMinRegex=re),this._weekdaysMinStrictRegex&&a?this._weekdaysMinStrictRegex:this._weekdaysMinRegex)}function Pa(){function a(a,b){return b.length-a.length}var b,c,d,e,f,g=[],h=[],i=[],k=[];for(b=0;7>b;b++)c=j([2e3,1]).day(b),d=this.weekdaysMin(c,""),e=this.weekdaysShort(c,""),f=this.weekdays(c,""),g.push(d),h.push(e),i.push(f),k.push(d),k.push(e),k.push(f);for(
82
+ // Sorting makes sure if one weekday (or abbr) is a prefix of another it
83
+ // will match the longer piece.
84
+ g.sort(a),h.sort(a),i.sort(a),k.sort(a),b=0;7>b;b++)h[b]=_(h[b]),i[b]=_(i[b]),k[b]=_(k[b]);this._weekdaysRegex=new RegExp("^("+k.join("|")+")","i"),this._weekdaysShortRegex=this._weekdaysRegex,this._weekdaysMinRegex=this._weekdaysRegex,this._weekdaysStrictRegex=new RegExp("^("+i.join("|")+")","i"),this._weekdaysShortStrictRegex=new RegExp("^("+h.join("|")+")","i"),this._weekdaysMinStrictRegex=new RegExp("^("+g.join("|")+")","i")}
85
+ // FORMATTING
86
+ function Qa(){return this.hours()%12||12}function Ra(){return this.hours()||24}function Sa(a,b){T(a,0,0,function(){return this.localeData().meridiem(this.hours(),this.minutes(),b)})}
87
+ // PARSING
88
+ function Ta(a,b){return b._meridiemParse}
89
+ // LOCALES
90
+ function Ua(a){
91
+ // IE8 Quirks Mode & IE7 Standards Mode do not allow accessing strings like arrays
92
+ // Using charAt should be more compatible.
93
+ return"p"===(a+"").toLowerCase().charAt(0)}function Va(a,b,c){return a>11?c?"pm":"PM":c?"am":"AM"}function Wa(a){return a?a.toLowerCase().replace("_","-"):a}
94
+ // pick the locale from the array
95
+ // try ['en-au', 'en-gb'] as 'en-au', 'en-gb', 'en', as in move through the list trying each
96
+ // substring from most specific to least, but move to the next array item if it's a more specific variant than the current root
97
+ function Xa(a){for(var b,c,d,e,f=0;f<a.length;){for(e=Wa(a[f]).split("-"),b=e.length,c=Wa(a[f+1]),c=c?c.split("-"):null;b>0;){if(d=Ya(e.slice(0,b).join("-")))return d;if(c&&c.length>=b&&u(e,c,!0)>=b-1)
98
+ //the next array item is better than a shallower substring of this one
99
+ break;b--}f++}return null}function Ya(a){var b=null;
100
+ // TODO: Find a better way to register and load all the locales in Node
101
+ if(!we[a]&&"undefined"!=typeof module&&module&&module.exports)try{b=se._abbr,require("./locale/"+a),
102
+ // because defineLocale currently also sets the global locale, we
103
+ // want to undo that for lazy loaded locales
104
+ Za(b)}catch(c){}return we[a]}
105
+ // This function will load locale and then set the global locale. If
106
+ // no arguments are passed in, it will simply return the current global
107
+ // locale key.
108
+ function Za(a,b){var c;
109
+ // moment.duration._locale = moment._locale = data;
110
+ return a&&(c=o(b)?ab(a):$a(a,b),c&&(se=c)),se._abbr}function $a(a,b){if(null!==b){var c=ve;
111
+ // treat as if there is no base config
112
+ // backwards compat for now: also set the locale
113
+ return b.abbr=a,null!=we[a]?(x("defineLocaleOverride","use moment.updateLocale(localeName, config) to change an existing locale. moment.defineLocale(localeName, config) should only be used for creating a new locale See http://momentjs.com/guides/#/warnings/define-locale/ for more info."),c=we[a]._config):null!=b.parentLocale&&(null!=we[b.parentLocale]?c=we[b.parentLocale]._config:x("parentLocaleUndefined","specified parentLocale is not defined yet. See http://momentjs.com/guides/#/warnings/parent-locale/")),we[a]=new B(A(c,b)),Za(a),we[a]}
114
+ // useful for testing
115
+ return delete we[a],null}function _a(a,b){if(null!=b){var c,d=ve;
116
+ // MERGE
117
+ null!=we[a]&&(d=we[a]._config),b=A(d,b),c=new B(b),c.parentLocale=we[a],we[a]=c,
118
+ // backwards compat for now: also set the locale
119
+ Za(a)}else
120
+ // pass null for config to unupdate, useful for tests
121
+ null!=we[a]&&(null!=we[a].parentLocale?we[a]=we[a].parentLocale:null!=we[a]&&delete we[a]);return we[a]}
122
+ // returns locale data
123
+ function ab(a){var b;if(a&&a._locale&&a._locale._abbr&&(a=a._locale._abbr),!a)return se;if(!c(a)){if(b=Ya(a))return b;a=[a]}return Xa(a)}function bb(){return rd(we)}function cb(a){var b,c=a._a;return c&&-2===l(a).overflow&&(b=c[Zd]<0||c[Zd]>11?Zd:c[$d]<1||c[$d]>da(c[Yd],c[Zd])?$d:c[_d]<0||c[_d]>24||24===c[_d]&&(0!==c[ae]||0!==c[be]||0!==c[ce])?_d:c[ae]<0||c[ae]>59?ae:c[be]<0||c[be]>59?be:c[ce]<0||c[ce]>999?ce:-1,l(a)._overflowDayOfYear&&(Yd>b||b>$d)&&(b=$d),l(a)._overflowWeeks&&-1===b&&(b=de),l(a)._overflowWeekday&&-1===b&&(b=ee),l(a).overflow=b),a}
124
+ // date from iso format
125
+ function db(a){var b,c,d,e,f,g,h=a._i,i=xe.exec(h)||ye.exec(h);if(i){for(l(a).iso=!0,b=0,c=Ae.length;c>b;b++)if(Ae[b][1].exec(i[1])){e=Ae[b][0],d=Ae[b][2]!==!1;break}if(null==e)return void(a._isValid=!1);if(i[3]){for(b=0,c=Be.length;c>b;b++)if(Be[b][1].exec(i[3])){
126
+ // match[2] should be 'T' or space
127
+ f=(i[2]||" ")+Be[b][0];break}if(null==f)return void(a._isValid=!1)}if(!d&&null!=f)return void(a._isValid=!1);if(i[4]){if(!ze.exec(i[4]))return void(a._isValid=!1);g="Z"}a._f=e+(f||"")+(g||""),jb(a)}else a._isValid=!1}
128
+ // date from iso format or fallback
129
+ function eb(b){var c=Ce.exec(b._i);return null!==c?void(b._d=new Date(+c[1])):(db(b),void(b._isValid===!1&&(delete b._isValid,a.createFromInputFallback(b))))}
130
+ // Pick the first defined of two or three arguments.
131
+ function fb(a,b,c){return null!=a?a:null!=b?b:c}function gb(b){
132
+ // hooks is actually the exported moment object
133
+ var c=new Date(a.now());return b._useUTC?[c.getUTCFullYear(),c.getUTCMonth(),c.getUTCDate()]:[c.getFullYear(),c.getMonth(),c.getDate()]}
134
+ // convert an array to a date.
135
+ // the array should mirror the parameters below
136
+ // note: all values past the year are optional and will default to the lowest possible value.
137
+ // [year, month, day , hour, minute, second, millisecond]
138
+ function hb(a){var b,c,d,e,f=[];if(!a._d){
139
+ // Default to current date.
140
+ // * if no year, month, day of month are given, default to today
141
+ // * if day of month is given, default month and year
142
+ // * if month is given, default only year
143
+ // * if year is given, don't default anything
144
+ for(d=gb(a),a._w&&null==a._a[$d]&&null==a._a[Zd]&&ib(a),a._dayOfYear&&(e=fb(a._a[Yd],d[Yd]),a._dayOfYear>oa(e)&&(l(a)._overflowDayOfYear=!0),c=sa(e,0,a._dayOfYear),a._a[Zd]=c.getUTCMonth(),a._a[$d]=c.getUTCDate()),b=0;3>b&&null==a._a[b];++b)a._a[b]=f[b]=d[b];
145
+ // Zero out whatever was not defaulted, including time
146
+ for(;7>b;b++)a._a[b]=f[b]=null==a._a[b]?2===b?1:0:a._a[b];
147
+ // Check for 24:00:00.000
148
+ 24===a._a[_d]&&0===a._a[ae]&&0===a._a[be]&&0===a._a[ce]&&(a._nextDay=!0,a._a[_d]=0),a._d=(a._useUTC?sa:ra).apply(null,f),
149
+ // Apply timezone offset from input. The actual utcOffset can be changed
150
+ // with parseZone.
151
+ null!=a._tzm&&a._d.setUTCMinutes(a._d.getUTCMinutes()-a._tzm),a._nextDay&&(a._a[_d]=24)}}function ib(a){var b,c,d,e,f,g,h,i;b=a._w,null!=b.GG||null!=b.W||null!=b.E?(f=1,g=4,c=fb(b.GG,a._a[Yd],va(rb(),1,4).year),d=fb(b.W,1),e=fb(b.E,1),(1>e||e>7)&&(i=!0)):(f=a._locale._week.dow,g=a._locale._week.doy,c=fb(b.gg,a._a[Yd],va(rb(),f,g).year),d=fb(b.w,1),null!=b.d?(e=b.d,(0>e||e>6)&&(i=!0)):null!=b.e?(e=b.e+f,(b.e<0||b.e>6)&&(i=!0)):e=f),1>d||d>wa(c,f,g)?l(a)._overflowWeeks=!0:null!=i?l(a)._overflowWeekday=!0:(h=ua(c,d,e,f,g),a._a[Yd]=h.year,a._dayOfYear=h.dayOfYear)}
152
+ // date from string and format string
153
+ function jb(b){
154
+ // TODO: Move this to another part of the creation flow to prevent circular deps
155
+ if(b._f===a.ISO_8601)return void db(b);b._a=[],l(b).empty=!0;
156
+ // This array is used to make a Date, either with `new Date` or `Date.UTC`
157
+ var c,d,e,f,g,h=""+b._i,i=h.length,j=0;for(e=X(b._f,b._locale).match(Bd)||[],c=0;c<e.length;c++)f=e[c],d=(h.match(Z(f,b))||[])[0],d&&(g=h.substr(0,h.indexOf(d)),g.length>0&&l(b).unusedInput.push(g),h=h.slice(h.indexOf(d)+d.length),j+=d.length),Ed[f]?(d?l(b).empty=!1:l(b).unusedTokens.push(f),ca(f,d,b)):b._strict&&!d&&l(b).unusedTokens.push(f);
158
+ // add remaining unparsed input length to the string
159
+ l(b).charsLeftOver=i-j,h.length>0&&l(b).unusedInput.push(h),
160
+ // clear _12h flag if hour is <= 12
161
+ b._a[_d]<=12&&l(b).bigHour===!0&&b._a[_d]>0&&(l(b).bigHour=void 0),l(b).parsedDateParts=b._a.slice(0),l(b).meridiem=b._meridiem,
162
+ // handle meridiem
163
+ b._a[_d]=kb(b._locale,b._a[_d],b._meridiem),hb(b),cb(b)}function kb(a,b,c){var d;
164
+ // Fallback
165
+ return null==c?b:null!=a.meridiemHour?a.meridiemHour(b,c):null!=a.isPM?(d=a.isPM(c),d&&12>b&&(b+=12),d||12!==b||(b=0),b):b}
166
+ // date from string and array of format strings
167
+ function lb(a){var b,c,d,e,f;if(0===a._f.length)return l(a).invalidFormat=!0,void(a._d=new Date(NaN));for(e=0;e<a._f.length;e++)f=0,b=p({},a),null!=a._useUTC&&(b._useUTC=a._useUTC),b._f=a._f[e],jb(b),m(b)&&(f+=l(b).charsLeftOver,f+=10*l(b).unusedTokens.length,l(b).score=f,(null==d||d>f)&&(d=f,c=b));i(a,c||b)}function mb(a){if(!a._d){var b=K(a._i);a._a=g([b.year,b.month,b.day||b.date,b.hour,b.minute,b.second,b.millisecond],function(a){return a&&parseInt(a,10)}),hb(a)}}function nb(a){var b=new q(cb(ob(a)));
168
+ // Adding is smart enough around DST
169
+ return b._nextDay&&(b.add(1,"d"),b._nextDay=void 0),b}function ob(a){var b=a._i,d=a._f;return a._locale=a._locale||ab(a._l),null===b||void 0===d&&""===b?n({nullInput:!0}):("string"==typeof b&&(a._i=b=a._locale.preparse(b)),r(b)?new q(cb(b)):(c(d)?lb(a):f(b)?a._d=b:d?jb(a):pb(a),m(a)||(a._d=null),a))}function pb(b){var d=b._i;void 0===d?b._d=new Date(a.now()):f(d)?b._d=new Date(d.valueOf()):"string"==typeof d?eb(b):c(d)?(b._a=g(d.slice(0),function(a){return parseInt(a,10)}),hb(b)):"object"==typeof d?mb(b):"number"==typeof d?
170
+ // from milliseconds
171
+ b._d=new Date(d):a.createFromInputFallback(b)}function qb(a,b,f,g,h){var i={};
172
+ // object construction must be done this way.
173
+ // https://github.com/moment/moment/issues/1423
174
+ return"boolean"==typeof f&&(g=f,f=void 0),(d(a)&&e(a)||c(a)&&0===a.length)&&(a=void 0),i._isAMomentObject=!0,i._useUTC=i._isUTC=h,i._l=f,i._i=a,i._f=b,i._strict=g,nb(i)}function rb(a,b,c,d){return qb(a,b,c,d,!1)}
175
+ // Pick a moment m from moments so that m[fn](other) is true for all
176
+ // other. This relies on the function fn to be transitive.
177
+ //
178
+ // moments should either be an array of moment objects or an array, whose
179
+ // first element is an array of moment objects.
180
+ function sb(a,b){var d,e;if(1===b.length&&c(b[0])&&(b=b[0]),!b.length)return rb();for(d=b[0],e=1;e<b.length;++e)b[e].isValid()&&!b[e][a](d)||(d=b[e]);return d}
181
+ // TODO: Use [].sort instead?
182
+ function tb(){var a=[].slice.call(arguments,0);return sb("isBefore",a)}function ub(){var a=[].slice.call(arguments,0);return sb("isAfter",a)}function vb(a){var b=K(a),c=b.year||0,d=b.quarter||0,e=b.month||0,f=b.week||0,g=b.day||0,h=b.hour||0,i=b.minute||0,j=b.second||0,k=b.millisecond||0;
183
+ // representation for dateAddRemove
184
+ this._milliseconds=+k+1e3*j+// 1000
185
+ 6e4*i+// 1000 * 60
186
+ 1e3*h*60*60,//using 1000 * 60 * 60 instead of 36e5 to avoid floating point rounding errors https://github.com/moment/moment/issues/2978
187
+ // Because of dateAddRemove treats 24 hours as different from a
188
+ // day when working around DST, we need to store them separately
189
+ this._days=+g+7*f,
190
+ // It is impossible translate months into days without knowing
191
+ // which months you are are talking about, so we have to store
192
+ // it separately.
193
+ this._months=+e+3*d+12*c,this._data={},this._locale=ab(),this._bubble()}function wb(a){return a instanceof vb}
194
+ // FORMATTING
195
+ function xb(a,b){T(a,0,0,function(){var a=this.utcOffset(),c="+";return 0>a&&(a=-a,c="-"),c+S(~~(a/60),2)+b+S(~~a%60,2)})}function yb(a,b){var c=(b||"").match(a)||[],d=c[c.length-1]||[],e=(d+"").match(Ge)||["-",0,0],f=+(60*e[1])+t(e[2]);return"+"===e[0]?f:-f}
196
+ // Return a moment from input, that is local/utc/zone equivalent to model.
197
+ function zb(b,c){var d,e;
198
+ // Use low-level api, because this fn is low-level api.
199
+ return c._isUTC?(d=c.clone(),e=(r(b)||f(b)?b.valueOf():rb(b).valueOf())-d.valueOf(),d._d.setTime(d._d.valueOf()+e),a.updateOffset(d,!1),d):rb(b).local()}function Ab(a){
200
+ // On Firefox.24 Date#getTimezoneOffset returns a floating point.
201
+ // https://github.com/moment/moment/pull/1871
202
+ return 15*-Math.round(a._d.getTimezoneOffset()/15)}
203
+ // MOMENTS
204
+ // keepLocalTime = true means only change the timezone, without
205
+ // affecting the local hour. So 5:31:26 +0300 --[utcOffset(2, true)]-->
206
+ // 5:31:26 +0200 It is possible that 5:31:26 doesn't exist with offset
207
+ // +0200, so we adjust the time as needed, to be valid.
208
+ //
209
+ // Keeping the time actually adds/subtracts (one hour)
210
+ // from the actual represented time. That is why we call updateOffset
211
+ // a second time. In case it wants us to change the offset again
212
+ // _changeInProgress == true case, then we have to adjust, because
213
+ // there is no such time in the given timezone.
214
+ function Bb(b,c){var d,e=this._offset||0;return this.isValid()?null!=b?("string"==typeof b?b=yb(Td,b):Math.abs(b)<16&&(b=60*b),!this._isUTC&&c&&(d=Ab(this)),this._offset=b,this._isUTC=!0,null!=d&&this.add(d,"m"),e!==b&&(!c||this._changeInProgress?Sb(this,Mb(b-e,"m"),1,!1):this._changeInProgress||(this._changeInProgress=!0,a.updateOffset(this,!0),this._changeInProgress=null)),this):this._isUTC?e:Ab(this):null!=b?this:NaN}function Cb(a,b){return null!=a?("string"!=typeof a&&(a=-a),this.utcOffset(a,b),this):-this.utcOffset()}function Db(a){return this.utcOffset(0,a)}function Eb(a){return this._isUTC&&(this.utcOffset(0,a),this._isUTC=!1,a&&this.subtract(Ab(this),"m")),this}function Fb(){return this._tzm?this.utcOffset(this._tzm):"string"==typeof this._i&&this.utcOffset(yb(Sd,this._i)),this}function Gb(a){return this.isValid()?(a=a?rb(a).utcOffset():0,(this.utcOffset()-a)%60===0):!1}function Hb(){return this.utcOffset()>this.clone().month(0).utcOffset()||this.utcOffset()>this.clone().month(5).utcOffset()}function Ib(){if(!o(this._isDSTShifted))return this._isDSTShifted;var a={};if(p(a,this),a=ob(a),a._a){var b=a._isUTC?j(a._a):rb(a._a);this._isDSTShifted=this.isValid()&&u(a._a,b.toArray())>0}else this._isDSTShifted=!1;return this._isDSTShifted}function Jb(){return this.isValid()?!this._isUTC:!1}function Kb(){return this.isValid()?this._isUTC:!1}function Lb(){return this.isValid()?this._isUTC&&0===this._offset:!1}function Mb(a,b){var c,d,e,f=a,
215
+ // matching against regexp is expensive, do it on demand
216
+ g=null;// checks for null or undefined
217
+ return wb(a)?f={ms:a._milliseconds,d:a._days,M:a._months}:"number"==typeof a?(f={},b?f[b]=a:f.milliseconds=a):(g=He.exec(a))?(c="-"===g[1]?-1:1,f={y:0,d:t(g[$d])*c,h:t(g[_d])*c,m:t(g[ae])*c,s:t(g[be])*c,ms:t(g[ce])*c}):(g=Ie.exec(a))?(c="-"===g[1]?-1:1,f={y:Nb(g[2],c),M:Nb(g[3],c),w:Nb(g[4],c),d:Nb(g[5],c),h:Nb(g[6],c),m:Nb(g[7],c),s:Nb(g[8],c)}):null==f?f={}:"object"==typeof f&&("from"in f||"to"in f)&&(e=Pb(rb(f.from),rb(f.to)),f={},f.ms=e.milliseconds,f.M=e.months),d=new vb(f),wb(a)&&h(a,"_locale")&&(d._locale=a._locale),d}function Nb(a,b){
218
+ // We'd normally use ~~inp for this, but unfortunately it also
219
+ // converts floats to ints.
220
+ // inp may be undefined, so careful calling replace on it.
221
+ var c=a&&parseFloat(a.replace(",","."));
222
+ // apply sign while we're at it
223
+ return(isNaN(c)?0:c)*b}function Ob(a,b){var c={milliseconds:0,months:0};return c.months=b.month()-a.month()+12*(b.year()-a.year()),a.clone().add(c.months,"M").isAfter(b)&&--c.months,c.milliseconds=+b-+a.clone().add(c.months,"M"),c}function Pb(a,b){var c;return a.isValid()&&b.isValid()?(b=zb(b,a),a.isBefore(b)?c=Ob(a,b):(c=Ob(b,a),c.milliseconds=-c.milliseconds,c.months=-c.months),c):{milliseconds:0,months:0}}function Qb(a){return 0>a?-1*Math.round(-1*a):Math.round(a)}
224
+ // TODO: remove 'name' arg after deprecation is removed
225
+ function Rb(a,b){return function(c,d){var e,f;
226
+ //invert the arguments, but complain about it
227
+ return null===d||isNaN(+d)||(x(b,"moment()."+b+"(period, number) is deprecated. Please use moment()."+b+"(number, period). See http://momentjs.com/guides/#/warnings/add-inverted-param/ for more info."),f=c,c=d,d=f),c="string"==typeof c?+c:c,e=Mb(c,d),Sb(this,e,a),this}}function Sb(b,c,d,e){var f=c._milliseconds,g=Qb(c._days),h=Qb(c._months);b.isValid()&&(e=null==e?!0:e,f&&b._d.setTime(b._d.valueOf()+f*d),g&&P(b,"Date",O(b,"Date")+g*d),h&&ia(b,O(b,"Month")+h*d),e&&a.updateOffset(b,g||h))}function Tb(a,b){var c=a.diff(b,"days",!0);return-6>c?"sameElse":-1>c?"lastWeek":0>c?"lastDay":1>c?"sameDay":2>c?"nextDay":7>c?"nextWeek":"sameElse"}function Ub(b,c){
228
+ // We want to compare the start of today, vs this.
229
+ // Getting start-of-today depends on whether we're local/utc/offset or not.
230
+ var d=b||rb(),e=zb(d,this).startOf("day"),f=a.calendarFormat(this,e)||"sameElse",g=c&&(y(c[f])?c[f].call(this,d):c[f]);return this.format(g||this.localeData().calendar(f,this,rb(d)))}function Vb(){return new q(this)}function Wb(a,b){var c=r(a)?a:rb(a);return this.isValid()&&c.isValid()?(b=J(o(b)?"millisecond":b),"millisecond"===b?this.valueOf()>c.valueOf():c.valueOf()<this.clone().startOf(b).valueOf()):!1}function Xb(a,b){var c=r(a)?a:rb(a);return this.isValid()&&c.isValid()?(b=J(o(b)?"millisecond":b),"millisecond"===b?this.valueOf()<c.valueOf():this.clone().endOf(b).valueOf()<c.valueOf()):!1}function Yb(a,b,c,d){return d=d||"()",("("===d[0]?this.isAfter(a,c):!this.isBefore(a,c))&&(")"===d[1]?this.isBefore(b,c):!this.isAfter(b,c))}function Zb(a,b){var c,d=r(a)?a:rb(a);return this.isValid()&&d.isValid()?(b=J(b||"millisecond"),"millisecond"===b?this.valueOf()===d.valueOf():(c=d.valueOf(),this.clone().startOf(b).valueOf()<=c&&c<=this.clone().endOf(b).valueOf())):!1}function $b(a,b){return this.isSame(a,b)||this.isAfter(a,b)}function _b(a,b){return this.isSame(a,b)||this.isBefore(a,b)}function ac(a,b,c){var d,e,f,g;// 1000
231
+ // 1000 * 60
232
+ // 1000 * 60 * 60
233
+ // 1000 * 60 * 60 * 24, negate dst
234
+ // 1000 * 60 * 60 * 24 * 7, negate dst
235
+ return this.isValid()?(d=zb(a,this),d.isValid()?(e=6e4*(d.utcOffset()-this.utcOffset()),b=J(b),"year"===b||"month"===b||"quarter"===b?(g=bc(this,d),"quarter"===b?g/=3:"year"===b&&(g/=12)):(f=this-d,g="second"===b?f/1e3:"minute"===b?f/6e4:"hour"===b?f/36e5:"day"===b?(f-e)/864e5:"week"===b?(f-e)/6048e5:f),c?g:s(g)):NaN):NaN}function bc(a,b){
236
+ // difference in months
237
+ var c,d,e=12*(b.year()-a.year())+(b.month()-a.month()),
238
+ // b is in (anchor - 1 month, anchor + 1 month)
239
+ f=a.clone().add(e,"months");
240
+ //check for negative zero, return zero if negative zero
241
+ // linear across the month
242
+ // linear across the month
243
+ return 0>b-f?(c=a.clone().add(e-1,"months"),d=(b-f)/(f-c)):(c=a.clone().add(e+1,"months"),d=(b-f)/(c-f)),-(e+d)||0}function cc(){return this.clone().locale("en").format("ddd MMM DD YYYY HH:mm:ss [GMT]ZZ")}function dc(){var a=this.clone().utc();return 0<a.year()&&a.year()<=9999?y(Date.prototype.toISOString)?this.toDate().toISOString():W(a,"YYYY-MM-DD[T]HH:mm:ss.SSS[Z]"):W(a,"YYYYYY-MM-DD[T]HH:mm:ss.SSS[Z]")}function ec(b){b||(b=this.isUtc()?a.defaultFormatUtc:a.defaultFormat);var c=W(this,b);return this.localeData().postformat(c)}function fc(a,b){return this.isValid()&&(r(a)&&a.isValid()||rb(a).isValid())?Mb({to:this,from:a}).locale(this.locale()).humanize(!b):this.localeData().invalidDate()}function gc(a){return this.from(rb(),a)}function hc(a,b){return this.isValid()&&(r(a)&&a.isValid()||rb(a).isValid())?Mb({from:this,to:a}).locale(this.locale()).humanize(!b):this.localeData().invalidDate()}function ic(a){return this.to(rb(),a)}
244
+ // If passed a locale key, it will set the locale for this
245
+ // instance. Otherwise, it will return the locale configuration
246
+ // variables for this instance.
247
+ function jc(a){var b;return void 0===a?this._locale._abbr:(b=ab(a),null!=b&&(this._locale=b),this)}function kc(){return this._locale}function lc(a){
248
+ // the following switch intentionally omits break keywords
249
+ // to utilize falling through the cases.
250
+ switch(a=J(a)){case"year":this.month(0);/* falls through */
251
+ case"quarter":case"month":this.date(1);/* falls through */
252
+ case"week":case"isoWeek":case"day":case"date":this.hours(0);/* falls through */
253
+ case"hour":this.minutes(0);/* falls through */
254
+ case"minute":this.seconds(0);/* falls through */
255
+ case"second":this.milliseconds(0)}
256
+ // weeks are a special case
257
+ // quarters are also special
258
+ return"week"===a&&this.weekday(0),"isoWeek"===a&&this.isoWeekday(1),"quarter"===a&&this.month(3*Math.floor(this.month()/3)),this}function mc(a){
259
+ // 'date' is an alias for 'day', so it should be considered as such.
260
+ return a=J(a),void 0===a||"millisecond"===a?this:("date"===a&&(a="day"),this.startOf(a).add(1,"isoWeek"===a?"week":a).subtract(1,"ms"))}function nc(){return this._d.valueOf()-6e4*(this._offset||0)}function oc(){return Math.floor(this.valueOf()/1e3)}function pc(){return new Date(this.valueOf())}function qc(){var a=this;return[a.year(),a.month(),a.date(),a.hour(),a.minute(),a.second(),a.millisecond()]}function rc(){var a=this;return{years:a.year(),months:a.month(),date:a.date(),hours:a.hours(),minutes:a.minutes(),seconds:a.seconds(),milliseconds:a.milliseconds()}}function sc(){
261
+ // new Date(NaN).toJSON() === null
262
+ return this.isValid()?this.toISOString():null}function tc(){return m(this)}function uc(){return i({},l(this))}function vc(){return l(this).overflow}function wc(){return{input:this._i,format:this._f,locale:this._locale,isUTC:this._isUTC,strict:this._strict}}function xc(a,b){T(0,[a,a.length],0,b)}
263
+ // MOMENTS
264
+ function yc(a){return Cc.call(this,a,this.week(),this.weekday(),this.localeData()._week.dow,this.localeData()._week.doy)}function zc(a){return Cc.call(this,a,this.isoWeek(),this.isoWeekday(),1,4)}function Ac(){return wa(this.year(),1,4)}function Bc(){var a=this.localeData()._week;return wa(this.year(),a.dow,a.doy)}function Cc(a,b,c,d,e){var f;return null==a?va(this,d,e).year:(f=wa(a,d,e),b>f&&(b=f),Dc.call(this,a,b,c,d,e))}function Dc(a,b,c,d,e){var f=ua(a,b,c,d,e),g=sa(f.year,0,f.dayOfYear);return this.year(g.getUTCFullYear()),this.month(g.getUTCMonth()),this.date(g.getUTCDate()),this}
265
+ // MOMENTS
266
+ function Ec(a){return null==a?Math.ceil((this.month()+1)/3):this.month(3*(a-1)+this.month()%3)}
267
+ // HELPERS
268
+ // MOMENTS
269
+ function Fc(a){var b=Math.round((this.clone().startOf("day")-this.clone().startOf("year"))/864e5)+1;return null==a?b:this.add(a-b,"d")}function Gc(a,b){b[ce]=t(1e3*("0."+a))}
270
+ // MOMENTS
271
+ function Hc(){return this._isUTC?"UTC":""}function Ic(){return this._isUTC?"Coordinated Universal Time":""}function Jc(a){return rb(1e3*a)}function Kc(){return rb.apply(null,arguments).parseZone()}function Lc(a){return a}function Mc(a,b,c,d){var e=ab(),f=j().set(d,b);return e[c](f,a)}function Nc(a,b,c){if("number"==typeof a&&(b=a,a=void 0),a=a||"",null!=b)return Mc(a,b,c,"month");var d,e=[];for(d=0;12>d;d++)e[d]=Mc(a,d,c,"month");return e}
272
+ // ()
273
+ // (5)
274
+ // (fmt, 5)
275
+ // (fmt)
276
+ // (true)
277
+ // (true, 5)
278
+ // (true, fmt, 5)
279
+ // (true, fmt)
280
+ function Oc(a,b,c,d){"boolean"==typeof a?("number"==typeof b&&(c=b,b=void 0),b=b||""):(b=a,c=b,a=!1,"number"==typeof b&&(c=b,b=void 0),b=b||"");var e=ab(),f=a?e._week.dow:0;if(null!=c)return Mc(b,(c+f)%7,d,"day");var g,h=[];for(g=0;7>g;g++)h[g]=Mc(b,(g+f)%7,d,"day");return h}function Pc(a,b){return Nc(a,b,"months")}function Qc(a,b){return Nc(a,b,"monthsShort")}function Rc(a,b,c){return Oc(a,b,c,"weekdays")}function Sc(a,b,c){return Oc(a,b,c,"weekdaysShort")}function Tc(a,b,c){return Oc(a,b,c,"weekdaysMin")}function Uc(){var a=this._data;return this._milliseconds=Ue(this._milliseconds),this._days=Ue(this._days),this._months=Ue(this._months),a.milliseconds=Ue(a.milliseconds),a.seconds=Ue(a.seconds),a.minutes=Ue(a.minutes),a.hours=Ue(a.hours),a.months=Ue(a.months),a.years=Ue(a.years),this}function Vc(a,b,c,d){var e=Mb(b,c);return a._milliseconds+=d*e._milliseconds,a._days+=d*e._days,a._months+=d*e._months,a._bubble()}
281
+ // supports only 2.0-style add(1, 's') or add(duration)
282
+ function Wc(a,b){return Vc(this,a,b,1)}
283
+ // supports only 2.0-style subtract(1, 's') or subtract(duration)
284
+ function Xc(a,b){return Vc(this,a,b,-1)}function Yc(a){return 0>a?Math.floor(a):Math.ceil(a)}function Zc(){var a,b,c,d,e,f=this._milliseconds,g=this._days,h=this._months,i=this._data;
285
+ // if we have a mix of positive and negative values, bubble down first
286
+ // check: https://github.com/moment/moment/issues/2166
287
+ // The following code bubbles up values, see the tests for
288
+ // examples of what that means.
289
+ // convert days to months
290
+ // 12 months -> 1 year
291
+ return f>=0&&g>=0&&h>=0||0>=f&&0>=g&&0>=h||(f+=864e5*Yc(_c(h)+g),g=0,h=0),i.milliseconds=f%1e3,a=s(f/1e3),i.seconds=a%60,b=s(a/60),i.minutes=b%60,c=s(b/60),i.hours=c%24,g+=s(c/24),e=s($c(g)),h+=e,g-=Yc(_c(e)),d=s(h/12),h%=12,i.days=g,i.months=h,i.years=d,this}function $c(a){
292
+ // 400 years have 146097 days (taking into account leap year rules)
293
+ // 400 years have 12 months === 4800
294
+ return 4800*a/146097}function _c(a){
295
+ // the reverse of daysToMonths
296
+ return 146097*a/4800}function ad(a){var b,c,d=this._milliseconds;if(a=J(a),"month"===a||"year"===a)return b=this._days+d/864e5,c=this._months+$c(b),"month"===a?c:c/12;switch(b=this._days+Math.round(_c(this._months)),a){case"week":return b/7+d/6048e5;case"day":return b+d/864e5;case"hour":return 24*b+d/36e5;case"minute":return 1440*b+d/6e4;case"second":return 86400*b+d/1e3;
297
+ // Math.floor prevents floating point math errors here
298
+ case"millisecond":return Math.floor(864e5*b)+d;default:throw new Error("Unknown unit "+a)}}
299
+ // TODO: Use this.as('ms')?
300
+ function bd(){return this._milliseconds+864e5*this._days+this._months%12*2592e6+31536e6*t(this._months/12)}function cd(a){return function(){return this.as(a)}}function dd(a){return a=J(a),this[a+"s"]()}function ed(a){return function(){return this._data[a]}}function fd(){return s(this.days()/7)}
301
+ // helper function for moment.fn.from, moment.fn.fromNow, and moment.duration.fn.humanize
302
+ function gd(a,b,c,d,e){return e.relativeTime(b||1,!!c,a,d)}function hd(a,b,c){var d=Mb(a).abs(),e=jf(d.as("s")),f=jf(d.as("m")),g=jf(d.as("h")),h=jf(d.as("d")),i=jf(d.as("M")),j=jf(d.as("y")),k=e<kf.s&&["s",e]||1>=f&&["m"]||f<kf.m&&["mm",f]||1>=g&&["h"]||g<kf.h&&["hh",g]||1>=h&&["d"]||h<kf.d&&["dd",h]||1>=i&&["M"]||i<kf.M&&["MM",i]||1>=j&&["y"]||["yy",j];return k[2]=b,k[3]=+a>0,k[4]=c,gd.apply(null,k)}
303
+ // This function allows you to set the rounding function for relative time strings
304
+ function id(a){return void 0===a?jf:"function"==typeof a?(jf=a,!0):!1}
305
+ // This function allows you to set a threshold for relative time strings
306
+ function jd(a,b){return void 0===kf[a]?!1:void 0===b?kf[a]:(kf[a]=b,!0)}function kd(a){var b=this.localeData(),c=hd(this,!a,b);return a&&(c=b.pastFuture(+this,c)),b.postformat(c)}function ld(){
307
+ // for ISO strings we do not use the normal bubbling rules:
308
+ // * milliseconds bubble up until they become hours
309
+ // * days do not bubble at all
310
+ // * months bubble up until they become years
311
+ // This is because there is no context-free conversion between hours and days
312
+ // (think of clock changes)
313
+ // and also not between days and months (28-31 days per month)
314
+ var a,b,c,d=lf(this._milliseconds)/1e3,e=lf(this._days),f=lf(this._months);a=s(d/60),b=s(a/60),d%=60,a%=60,c=s(f/12),f%=12;
315
+ // inspired by https://github.com/dordille/moment-isoduration/blob/master/moment.isoduration.js
316
+ var g=c,h=f,i=e,j=b,k=a,l=d,m=this.asSeconds();return m?(0>m?"-":"")+"P"+(g?g+"Y":"")+(h?h+"M":"")+(i?i+"D":"")+(j||k||l?"T":"")+(j?j+"H":"")+(k?k+"M":"")+(l?l+"S":""):"P0D"}var md,nd;nd=Array.prototype.some?Array.prototype.some:function(a){for(var b=Object(this),c=b.length>>>0,d=0;c>d;d++)if(d in b&&a.call(this,b[d],d,b))return!0;return!1};
317
+ // Plugins that add properties should also add the key here (null value),
318
+ // so we can properly clone ourselves.
319
+ var od=a.momentProperties=[],pd=!1,qd={};a.suppressDeprecationWarnings=!1,a.deprecationHandler=null;var rd;rd=Object.keys?Object.keys:function(a){var b,c=[];for(b in a)h(a,b)&&c.push(b);return c};var sd,td={sameDay:"[Today at] LT",nextDay:"[Tomorrow at] LT",nextWeek:"dddd [at] LT",lastDay:"[Yesterday at] LT",lastWeek:"[Last] dddd [at] LT",sameElse:"L"},ud={LTS:"h:mm:ss A",LT:"h:mm A",L:"MM/DD/YYYY",LL:"MMMM D, YYYY",LLL:"MMMM D, YYYY h:mm A",LLLL:"dddd, MMMM D, YYYY h:mm A"},vd="Invalid date",wd="%d",xd=/\d{1,2}/,yd={future:"in %s",past:"%s ago",s:"a few seconds",m:"a minute",mm:"%d minutes",h:"an hour",hh:"%d hours",d:"a day",dd:"%d days",M:"a month",MM:"%d months",y:"a year",yy:"%d years"},zd={},Ad={},Bd=/(\[[^\[]*\])|(\\)?([Hh]mm(ss)?|Mo|MM?M?M?|Do|DDDo|DD?D?D?|ddd?d?|do?|w[o|w]?|W[o|W]?|Qo?|YYYYYY|YYYYY|YYYY|YY|gg(ggg?)?|GG(GGG?)?|e|E|a|A|hh?|HH?|kk?|mm?|ss?|S{1,9}|x|X|zz?|ZZ?|.)/g,Cd=/(\[[^\[]*\])|(\\)?(LTS|LT|LL?L?L?|l{1,4})/g,Dd={},Ed={},Fd=/\d/,Gd=/\d\d/,Hd=/\d{3}/,Id=/\d{4}/,Jd=/[+-]?\d{6}/,Kd=/\d\d?/,Ld=/\d\d\d\d?/,Md=/\d\d\d\d\d\d?/,Nd=/\d{1,3}/,Od=/\d{1,4}/,Pd=/[+-]?\d{1,6}/,Qd=/\d+/,Rd=/[+-]?\d+/,Sd=/Z|[+-]\d\d:?\d\d/gi,Td=/Z|[+-]\d\d(?::?\d\d)?/gi,Ud=/[+-]?\d+(\.\d{1,3})?/,Vd=/[0-9]*['a-z\u00A0-\u05FF\u0700-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF]+|[\u0600-\u06FF\/]+(\s*?[\u0600-\u06FF]+){1,2}/i,Wd={},Xd={},Yd=0,Zd=1,$d=2,_d=3,ae=4,be=5,ce=6,de=7,ee=8;sd=Array.prototype.indexOf?Array.prototype.indexOf:function(a){
320
+ // I know
321
+ var b;for(b=0;b<this.length;++b)if(this[b]===a)return b;return-1},T("M",["MM",2],"Mo",function(){return this.month()+1}),T("MMM",0,0,function(a){return this.localeData().monthsShort(this,a)}),T("MMMM",0,0,function(a){return this.localeData().months(this,a)}),I("month","M"),L("month",8),Y("M",Kd),Y("MM",Kd,Gd),Y("MMM",function(a,b){return b.monthsShortRegex(a)}),Y("MMMM",function(a,b){return b.monthsRegex(a)}),aa(["M","MM"],function(a,b){b[Zd]=t(a)-1}),aa(["MMM","MMMM"],function(a,b,c,d){var e=c._locale.monthsParse(a,d,c._strict);null!=e?b[Zd]=e:l(c).invalidMonth=a});
322
+ // LOCALES
323
+ var fe=/D[oD]?(\[[^\[\]]*\]|\s+)+MMMM?/,ge="January_February_March_April_May_June_July_August_September_October_November_December".split("_"),he="Jan_Feb_Mar_Apr_May_Jun_Jul_Aug_Sep_Oct_Nov_Dec".split("_"),ie=Vd,je=Vd;
324
+ // FORMATTING
325
+ T("Y",0,0,function(){var a=this.year();return 9999>=a?""+a:"+"+a}),T(0,["YY",2],0,function(){return this.year()%100}),T(0,["YYYY",4],0,"year"),T(0,["YYYYY",5],0,"year"),T(0,["YYYYYY",6,!0],0,"year"),
326
+ // ALIASES
327
+ I("year","y"),
328
+ // PRIORITIES
329
+ L("year",1),
330
+ // PARSING
331
+ Y("Y",Rd),Y("YY",Kd,Gd),Y("YYYY",Od,Id),Y("YYYYY",Pd,Jd),Y("YYYYYY",Pd,Jd),aa(["YYYYY","YYYYYY"],Yd),aa("YYYY",function(b,c){c[Yd]=2===b.length?a.parseTwoDigitYear(b):t(b)}),aa("YY",function(b,c){c[Yd]=a.parseTwoDigitYear(b)}),aa("Y",function(a,b){b[Yd]=parseInt(a,10)}),
332
+ // HOOKS
333
+ a.parseTwoDigitYear=function(a){return t(a)+(t(a)>68?1900:2e3)};
334
+ // MOMENTS
335
+ var ke=N("FullYear",!0);
336
+ // FORMATTING
337
+ T("w",["ww",2],"wo","week"),T("W",["WW",2],"Wo","isoWeek"),
338
+ // ALIASES
339
+ I("week","w"),I("isoWeek","W"),
340
+ // PRIORITIES
341
+ L("week",5),L("isoWeek",5),
342
+ // PARSING
343
+ Y("w",Kd),Y("ww",Kd,Gd),Y("W",Kd),Y("WW",Kd,Gd),ba(["w","ww","W","WW"],function(a,b,c,d){b[d.substr(0,1)]=t(a)});var le={dow:0,// Sunday is the first day of the week.
344
+ doy:6};
345
+ // FORMATTING
346
+ T("d",0,"do","day"),T("dd",0,0,function(a){return this.localeData().weekdaysMin(this,a)}),T("ddd",0,0,function(a){return this.localeData().weekdaysShort(this,a)}),T("dddd",0,0,function(a){return this.localeData().weekdays(this,a)}),T("e",0,0,"weekday"),T("E",0,0,"isoWeekday"),
347
+ // ALIASES
348
+ I("day","d"),I("weekday","e"),I("isoWeekday","E"),
349
+ // PRIORITY
350
+ L("day",11),L("weekday",11),L("isoWeekday",11),
351
+ // PARSING
352
+ Y("d",Kd),Y("e",Kd),Y("E",Kd),Y("dd",function(a,b){return b.weekdaysMinRegex(a)}),Y("ddd",function(a,b){return b.weekdaysShortRegex(a)}),Y("dddd",function(a,b){return b.weekdaysRegex(a)}),ba(["dd","ddd","dddd"],function(a,b,c,d){var e=c._locale.weekdaysParse(a,d,c._strict);
353
+ // if we didn't get a weekday name, mark the date as invalid
354
+ null!=e?b.d=e:l(c).invalidWeekday=a}),ba(["d","e","E"],function(a,b,c,d){b[d]=t(a)});
355
+ // LOCALES
356
+ var me="Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),ne="Sun_Mon_Tue_Wed_Thu_Fri_Sat".split("_"),oe="Su_Mo_Tu_We_Th_Fr_Sa".split("_"),pe=Vd,qe=Vd,re=Vd;T("H",["HH",2],0,"hour"),T("h",["hh",2],0,Qa),T("k",["kk",2],0,Ra),T("hmm",0,0,function(){return""+Qa.apply(this)+S(this.minutes(),2)}),T("hmmss",0,0,function(){return""+Qa.apply(this)+S(this.minutes(),2)+S(this.seconds(),2)}),T("Hmm",0,0,function(){return""+this.hours()+S(this.minutes(),2)}),T("Hmmss",0,0,function(){return""+this.hours()+S(this.minutes(),2)+S(this.seconds(),2)}),Sa("a",!0),Sa("A",!1),
357
+ // ALIASES
358
+ I("hour","h"),
359
+ // PRIORITY
360
+ L("hour",13),Y("a",Ta),Y("A",Ta),Y("H",Kd),Y("h",Kd),Y("HH",Kd,Gd),Y("hh",Kd,Gd),Y("hmm",Ld),Y("hmmss",Md),Y("Hmm",Ld),Y("Hmmss",Md),aa(["H","HH"],_d),aa(["a","A"],function(a,b,c){c._isPm=c._locale.isPM(a),c._meridiem=a}),aa(["h","hh"],function(a,b,c){b[_d]=t(a),l(c).bigHour=!0}),aa("hmm",function(a,b,c){var d=a.length-2;b[_d]=t(a.substr(0,d)),b[ae]=t(a.substr(d)),l(c).bigHour=!0}),aa("hmmss",function(a,b,c){var d=a.length-4,e=a.length-2;b[_d]=t(a.substr(0,d)),b[ae]=t(a.substr(d,2)),b[be]=t(a.substr(e)),l(c).bigHour=!0}),aa("Hmm",function(a,b,c){var d=a.length-2;b[_d]=t(a.substr(0,d)),b[ae]=t(a.substr(d))}),aa("Hmmss",function(a,b,c){var d=a.length-4,e=a.length-2;b[_d]=t(a.substr(0,d)),b[ae]=t(a.substr(d,2)),b[be]=t(a.substr(e))});var se,te=/[ap]\.?m?\.?/i,ue=N("Hours",!0),ve={calendar:td,longDateFormat:ud,invalidDate:vd,ordinal:wd,ordinalParse:xd,relativeTime:yd,months:ge,monthsShort:he,week:le,weekdays:me,weekdaysMin:oe,weekdaysShort:ne,meridiemParse:te},we={},xe=/^\s*((?:[+-]\d{6}|\d{4})-(?:\d\d-\d\d|W\d\d-\d|W\d\d|\d\d\d|\d\d))(?:(T| )(\d\d(?::\d\d(?::\d\d(?:[.,]\d+)?)?)?)([\+\-]\d\d(?::?\d\d)?|\s*Z)?)?/,ye=/^\s*((?:[+-]\d{6}|\d{4})(?:\d\d\d\d|W\d\d\d|W\d\d|\d\d\d|\d\d))(?:(T| )(\d\d(?:\d\d(?:\d\d(?:[.,]\d+)?)?)?)([\+\-]\d\d(?::?\d\d)?|\s*Z)?)?/,ze=/Z|[+-]\d\d(?::?\d\d)?/,Ae=[["YYYYYY-MM-DD",/[+-]\d{6}-\d\d-\d\d/],["YYYY-MM-DD",/\d{4}-\d\d-\d\d/],["GGGG-[W]WW-E",/\d{4}-W\d\d-\d/],["GGGG-[W]WW",/\d{4}-W\d\d/,!1],["YYYY-DDD",/\d{4}-\d{3}/],["YYYY-MM",/\d{4}-\d\d/,!1],["YYYYYYMMDD",/[+-]\d{10}/],["YYYYMMDD",/\d{8}/],
361
+ // YYYYMM is NOT allowed by the standard
362
+ ["GGGG[W]WWE",/\d{4}W\d{3}/],["GGGG[W]WW",/\d{4}W\d{2}/,!1],["YYYYDDD",/\d{7}/]],Be=[["HH:mm:ss.SSSS",/\d\d:\d\d:\d\d\.\d+/],["HH:mm:ss,SSSS",/\d\d:\d\d:\d\d,\d+/],["HH:mm:ss",/\d\d:\d\d:\d\d/],["HH:mm",/\d\d:\d\d/],["HHmmss.SSSS",/\d\d\d\d\d\d\.\d+/],["HHmmss,SSSS",/\d\d\d\d\d\d,\d+/],["HHmmss",/\d\d\d\d\d\d/],["HHmm",/\d\d\d\d/],["HH",/\d\d/]],Ce=/^\/?Date\((\-?\d+)/i;a.createFromInputFallback=w("moment construction falls back to js Date. This is discouraged and will be removed in upcoming major release. Please refer to http://momentjs.com/guides/#/warnings/js-date/ for more info.",function(a){a._d=new Date(a._i+(a._useUTC?" UTC":""))}),
363
+ // constant that refers to the ISO standard
364
+ a.ISO_8601=function(){};var De=w("moment().min is deprecated, use moment.max instead. http://momentjs.com/guides/#/warnings/min-max/",function(){var a=rb.apply(null,arguments);return this.isValid()&&a.isValid()?this>a?this:a:n()}),Ee=w("moment().max is deprecated, use moment.min instead. http://momentjs.com/guides/#/warnings/min-max/",function(){var a=rb.apply(null,arguments);return this.isValid()&&a.isValid()?a>this?this:a:n()}),Fe=function(){return Date.now?Date.now():+new Date};xb("Z",":"),xb("ZZ",""),
365
+ // PARSING
366
+ Y("Z",Td),Y("ZZ",Td),aa(["Z","ZZ"],function(a,b,c){c._useUTC=!0,c._tzm=yb(Td,a)});
367
+ // HELPERS
368
+ // timezone chunker
369
+ // '+10:00' > ['10', '00']
370
+ // '-1530' > ['-15', '30']
371
+ var Ge=/([\+\-]|\d\d)/gi;
372
+ // HOOKS
373
+ // This function will be called whenever a moment is mutated.
374
+ // It is intended to keep the offset in sync with the timezone.
375
+ a.updateOffset=function(){};
376
+ // ASP.NET json date format regex
377
+ var He=/^(\-)?(?:(\d*)[. ])?(\d+)\:(\d+)(?:\:(\d+)\.?(\d{3})?\d*)?$/,Ie=/^(-)?P(?:(-?[0-9,.]*)Y)?(?:(-?[0-9,.]*)M)?(?:(-?[0-9,.]*)W)?(?:(-?[0-9,.]*)D)?(?:T(?:(-?[0-9,.]*)H)?(?:(-?[0-9,.]*)M)?(?:(-?[0-9,.]*)S)?)?$/;Mb.fn=vb.prototype;var Je=Rb(1,"add"),Ke=Rb(-1,"subtract");a.defaultFormat="YYYY-MM-DDTHH:mm:ssZ",a.defaultFormatUtc="YYYY-MM-DDTHH:mm:ss[Z]";var Le=w("moment().lang() is deprecated. Instead, use moment().localeData() to get the language configuration. Use moment().locale() to change languages.",function(a){return void 0===a?this.localeData():this.locale(a)});
378
+ // FORMATTING
379
+ T(0,["gg",2],0,function(){return this.weekYear()%100}),T(0,["GG",2],0,function(){return this.isoWeekYear()%100}),xc("gggg","weekYear"),xc("ggggg","weekYear"),xc("GGGG","isoWeekYear"),xc("GGGGG","isoWeekYear"),
380
+ // ALIASES
381
+ I("weekYear","gg"),I("isoWeekYear","GG"),
382
+ // PRIORITY
383
+ L("weekYear",1),L("isoWeekYear",1),
384
+ // PARSING
385
+ Y("G",Rd),Y("g",Rd),Y("GG",Kd,Gd),Y("gg",Kd,Gd),Y("GGGG",Od,Id),Y("gggg",Od,Id),Y("GGGGG",Pd,Jd),Y("ggggg",Pd,Jd),ba(["gggg","ggggg","GGGG","GGGGG"],function(a,b,c,d){b[d.substr(0,2)]=t(a)}),ba(["gg","GG"],function(b,c,d,e){c[e]=a.parseTwoDigitYear(b)}),
386
+ // FORMATTING
387
+ T("Q",0,"Qo","quarter"),
388
+ // ALIASES
389
+ I("quarter","Q"),
390
+ // PRIORITY
391
+ L("quarter",7),
392
+ // PARSING
393
+ Y("Q",Fd),aa("Q",function(a,b){b[Zd]=3*(t(a)-1)}),
394
+ // FORMATTING
395
+ T("D",["DD",2],"Do","date"),
396
+ // ALIASES
397
+ I("date","D"),
398
+ // PRIOROITY
399
+ L("date",9),
400
+ // PARSING
401
+ Y("D",Kd),Y("DD",Kd,Gd),Y("Do",function(a,b){return a?b._ordinalParse:b._ordinalParseLenient}),aa(["D","DD"],$d),aa("Do",function(a,b){b[$d]=t(a.match(Kd)[0],10)});
402
+ // MOMENTS
403
+ var Me=N("Date",!0);
404
+ // FORMATTING
405
+ T("DDD",["DDDD",3],"DDDo","dayOfYear"),
406
+ // ALIASES
407
+ I("dayOfYear","DDD"),
408
+ // PRIORITY
409
+ L("dayOfYear",4),
410
+ // PARSING
411
+ Y("DDD",Nd),Y("DDDD",Hd),aa(["DDD","DDDD"],function(a,b,c){c._dayOfYear=t(a)}),
412
+ // FORMATTING
413
+ T("m",["mm",2],0,"minute"),
414
+ // ALIASES
415
+ I("minute","m"),
416
+ // PRIORITY
417
+ L("minute",14),
418
+ // PARSING
419
+ Y("m",Kd),Y("mm",Kd,Gd),aa(["m","mm"],ae);
420
+ // MOMENTS
421
+ var Ne=N("Minutes",!1);
422
+ // FORMATTING
423
+ T("s",["ss",2],0,"second"),
424
+ // ALIASES
425
+ I("second","s"),
426
+ // PRIORITY
427
+ L("second",15),
428
+ // PARSING
429
+ Y("s",Kd),Y("ss",Kd,Gd),aa(["s","ss"],be);
430
+ // MOMENTS
431
+ var Oe=N("Seconds",!1);
432
+ // FORMATTING
433
+ T("S",0,0,function(){return~~(this.millisecond()/100)}),T(0,["SS",2],0,function(){return~~(this.millisecond()/10)}),T(0,["SSS",3],0,"millisecond"),T(0,["SSSS",4],0,function(){return 10*this.millisecond()}),T(0,["SSSSS",5],0,function(){return 100*this.millisecond()}),T(0,["SSSSSS",6],0,function(){return 1e3*this.millisecond()}),T(0,["SSSSSSS",7],0,function(){return 1e4*this.millisecond()}),T(0,["SSSSSSSS",8],0,function(){return 1e5*this.millisecond()}),T(0,["SSSSSSSSS",9],0,function(){return 1e6*this.millisecond()}),
434
+ // ALIASES
435
+ I("millisecond","ms"),
436
+ // PRIORITY
437
+ L("millisecond",16),
438
+ // PARSING
439
+ Y("S",Nd,Fd),Y("SS",Nd,Gd),Y("SSS",Nd,Hd);var Pe;for(Pe="SSSS";Pe.length<=9;Pe+="S")Y(Pe,Qd);for(Pe="S";Pe.length<=9;Pe+="S")aa(Pe,Gc);
440
+ // MOMENTS
441
+ var Qe=N("Milliseconds",!1);
442
+ // FORMATTING
443
+ T("z",0,0,"zoneAbbr"),T("zz",0,0,"zoneName");var Re=q.prototype;Re.add=Je,Re.calendar=Ub,Re.clone=Vb,Re.diff=ac,Re.endOf=mc,Re.format=ec,Re.from=fc,Re.fromNow=gc,Re.to=hc,Re.toNow=ic,Re.get=Q,Re.invalidAt=vc,Re.isAfter=Wb,Re.isBefore=Xb,Re.isBetween=Yb,Re.isSame=Zb,Re.isSameOrAfter=$b,Re.isSameOrBefore=_b,Re.isValid=tc,Re.lang=Le,Re.locale=jc,Re.localeData=kc,Re.max=Ee,Re.min=De,Re.parsingFlags=uc,Re.set=R,Re.startOf=lc,Re.subtract=Ke,Re.toArray=qc,Re.toObject=rc,Re.toDate=pc,Re.toISOString=dc,Re.toJSON=sc,Re.toString=cc,Re.unix=oc,Re.valueOf=nc,Re.creationData=wc,
444
+ // Year
445
+ Re.year=ke,Re.isLeapYear=qa,
446
+ // Week Year
447
+ Re.weekYear=yc,Re.isoWeekYear=zc,
448
+ // Quarter
449
+ Re.quarter=Re.quarters=Ec,
450
+ // Month
451
+ Re.month=ja,Re.daysInMonth=ka,
452
+ // Week
453
+ Re.week=Re.weeks=Aa,Re.isoWeek=Re.isoWeeks=Ba,Re.weeksInYear=Bc,Re.isoWeeksInYear=Ac,
454
+ // Day
455
+ Re.date=Me,Re.day=Re.days=Ja,Re.weekday=Ka,Re.isoWeekday=La,Re.dayOfYear=Fc,
456
+ // Hour
457
+ Re.hour=Re.hours=ue,
458
+ // Minute
459
+ Re.minute=Re.minutes=Ne,
460
+ // Second
461
+ Re.second=Re.seconds=Oe,
462
+ // Millisecond
463
+ Re.millisecond=Re.milliseconds=Qe,
464
+ // Offset
465
+ Re.utcOffset=Bb,Re.utc=Db,Re.local=Eb,Re.parseZone=Fb,Re.hasAlignedHourOffset=Gb,Re.isDST=Hb,Re.isLocal=Jb,Re.isUtcOffset=Kb,Re.isUtc=Lb,Re.isUTC=Lb,
466
+ // Timezone
467
+ Re.zoneAbbr=Hc,Re.zoneName=Ic,
468
+ // Deprecations
469
+ Re.dates=w("dates accessor is deprecated. Use date instead.",Me),Re.months=w("months accessor is deprecated. Use month instead",ja),Re.years=w("years accessor is deprecated. Use year instead",ke),Re.zone=w("moment().zone is deprecated, use moment().utcOffset instead. http://momentjs.com/guides/#/warnings/zone/",Cb),Re.isDSTShifted=w("isDSTShifted is deprecated. See http://momentjs.com/guides/#/warnings/dst-shifted/ for more information",Ib);var Se=Re,Te=B.prototype;Te.calendar=C,Te.longDateFormat=D,Te.invalidDate=E,Te.ordinal=F,Te.preparse=Lc,Te.postformat=Lc,Te.relativeTime=G,Te.pastFuture=H,Te.set=z,
470
+ // Month
471
+ Te.months=ea,Te.monthsShort=fa,Te.monthsParse=ha,Te.monthsRegex=ma,Te.monthsShortRegex=la,
472
+ // Week
473
+ Te.week=xa,Te.firstDayOfYear=za,Te.firstDayOfWeek=ya,
474
+ // Day of Week
475
+ Te.weekdays=Ea,Te.weekdaysMin=Ga,Te.weekdaysShort=Fa,Te.weekdaysParse=Ia,Te.weekdaysRegex=Ma,Te.weekdaysShortRegex=Na,Te.weekdaysMinRegex=Oa,
476
+ // Hours
477
+ Te.isPM=Ua,Te.meridiem=Va,Za("en",{ordinalParse:/\d{1,2}(th|st|nd|rd)/,ordinal:function(a){var b=a%10,c=1===t(a%100/10)?"th":1===b?"st":2===b?"nd":3===b?"rd":"th";return a+c}}),
478
+ // Side effect imports
479
+ a.lang=w("moment.lang is deprecated. Use moment.locale instead.",Za),a.langData=w("moment.langData is deprecated. Use moment.localeData instead.",ab);var Ue=Math.abs,Ve=cd("ms"),We=cd("s"),Xe=cd("m"),Ye=cd("h"),Ze=cd("d"),$e=cd("w"),_e=cd("M"),af=cd("y"),bf=ed("milliseconds"),cf=ed("seconds"),df=ed("minutes"),ef=ed("hours"),ff=ed("days"),gf=ed("months"),hf=ed("years"),jf=Math.round,kf={s:45,// seconds to minute
480
+ m:45,// minutes to hour
481
+ h:22,// hours to day
482
+ d:26,// days to month
483
+ M:11},lf=Math.abs,mf=vb.prototype;mf.abs=Uc,mf.add=Wc,mf.subtract=Xc,mf.as=ad,mf.asMilliseconds=Ve,mf.asSeconds=We,mf.asMinutes=Xe,mf.asHours=Ye,mf.asDays=Ze,mf.asWeeks=$e,mf.asMonths=_e,mf.asYears=af,mf.valueOf=bd,mf._bubble=Zc,mf.get=dd,mf.milliseconds=bf,mf.seconds=cf,mf.minutes=df,mf.hours=ef,mf.days=ff,mf.weeks=fd,mf.months=gf,mf.years=hf,mf.humanize=kd,mf.toISOString=ld,mf.toString=ld,mf.toJSON=ld,mf.locale=jc,mf.localeData=kc,
484
+ // Deprecations
485
+ mf.toIsoString=w("toIsoString() is deprecated. Please use toISOString() instead (notice the capitals)",ld),mf.lang=Le,
486
+ // Side effect imports
487
+ // FORMATTING
488
+ T("X",0,0,"unix"),T("x",0,0,"valueOf"),
489
+ // PARSING
490
+ Y("x",Rd),Y("X",Ud),aa("X",function(a,b,c){c._d=new Date(1e3*parseFloat(a,10))}),aa("x",function(a,b,c){c._d=new Date(t(a))}),
491
+ // Side effect imports
492
+ a.version="2.14.1",b(rb),a.fn=Se,a.min=tb,a.max=ub,a.now=Fe,a.utc=j,a.unix=Jc,a.months=Pc,a.isDate=f,a.locale=Za,a.invalid=n,a.duration=Mb,a.isMoment=r,a.weekdays=Rc,a.parseZone=Kc,a.localeData=ab,a.isDuration=wb,a.monthsShort=Qc,a.weekdaysMin=Tc,a.defineLocale=$a,a.updateLocale=_a,a.locales=bb,a.weekdaysShort=Sc,a.normalizeUnits=J,a.relativeTimeRounding=id,a.relativeTimeThreshold=jd,a.calendarFormat=Tb,a.prototype=Se;var nf=a;return nf});
google-calendar-events.php CHANGED
@@ -5,7 +5,7 @@
5
  * Description: Add Google Calendar events to your WordPress site in minutes. Beautiful calendar displays. Fully responsive.
6
  * Author: Moonstone Media
7
  * Author URI: https://simplecalendar.io
8
- * Version: 3.1.1
9
  * Text Domain: google-calendar-events
10
  * Domain Path: /i18n
11
  *
@@ -21,7 +21,7 @@ if ( ! defined( 'ABSPATH' ) ) {
21
  $this_plugin_path = trailingslashit( dirname( __FILE__ ) );
22
  $this_plugin_dir = plugin_dir_url( __FILE__ );
23
  $this_plugin_constants = array(
24
- 'SIMPLE_CALENDAR_VERSION' => '3.1.1',
25
  'SIMPLE_CALENDAR_MAIN_FILE' => __FILE__,
26
  'SIMPLE_CALENDAR_URL' => $this_plugin_dir,
27
  'SIMPLE_CALENDAR_ASSETS' => $this_plugin_dir . 'assets/',
5
  * Description: Add Google Calendar events to your WordPress site in minutes. Beautiful calendar displays. Fully responsive.
6
  * Author: Moonstone Media
7
  * Author URI: https://simplecalendar.io
8
+ * Version: 3.1.2
9
  * Text Domain: google-calendar-events
10
  * Domain Path: /i18n
11
  *
21
  $this_plugin_path = trailingslashit( dirname( __FILE__ ) );
22
  $this_plugin_dir = plugin_dir_url( __FILE__ );
23
  $this_plugin_constants = array(
24
+ 'SIMPLE_CALENDAR_VERSION' => '3.1.2',
25
  'SIMPLE_CALENDAR_MAIN_FILE' => __FILE__,
26
  'SIMPLE_CALENDAR_URL' => $this_plugin_dir,
27
  'SIMPLE_CALENDAR_ASSETS' => $this_plugin_dir . 'assets/',
includes/admin/metaboxes/settings.php CHANGED
@@ -477,6 +477,7 @@ class Settings implements Meta_Box {
477
  'id' => '_no_events_message',
478
  'tooltip' => __( 'Some calendars may display a message when no events are found. You can change the default message here.', 'google-calendar-events' ),
479
  'value' => get_post_meta( $post->ID, '_no_events_message', true ),
 
480
  ) );
481
 
482
  ?>
477
  'id' => '_no_events_message',
478
  'tooltip' => __( 'Some calendars may display a message when no events are found. You can change the default message here.', 'google-calendar-events' ),
479
  'value' => get_post_meta( $post->ID, '_no_events_message', true ),
480
+ 'placeholder' => __( 'There are no upcoming events.', 'google-calendar-events' ),
481
  ) );
482
 
483
  ?>
includes/admin/pages/system-status.php CHANGED
@@ -335,8 +335,8 @@ class System_Status extends Admin_Page {
335
  * ==================
336
  */
337
 
338
- if ( version_compare( PHP_VERSION, '5.4', '<' ) ) {
339
- $php = '<mark class="error">' . sprintf( __( '%1$s - It is recomendend to upgrade at least to PHP version 5.4 for security reasons. <a href="%2$s" target="_blank">Read more.</a>', 'google-calendar-events' ), PHP_VERSION, 'http://www.wpupdatephp.com/update/' ) . '</mark>';
340
  } else {
341
  $php = '<mark class="ok">' . PHP_VERSION . '</mark>';
342
  }
@@ -412,6 +412,12 @@ class System_Status extends Admin_Page {
412
  $php_max_execution_time = ini_get( 'max_execution_time' );
413
  $php_max_input_vars = ini_get( 'max_input_vars' );
414
 
 
 
 
 
 
 
415
  $sections['server'] = array(
416
  'host' => array(
417
  'label' => __( 'Web Server', 'google-calendar-events' ),
@@ -472,9 +478,9 @@ class System_Status extends Admin_Page {
472
  'result_export' => function_exists( 'fsockopen' ) ? 'Yes' : 'No',
473
  ),
474
  'curl_init' => array(
475
- 'label' => 'cURL',
476
- 'result' => function_exists( 'curl_init' ) ? __( 'Yes', 'google-calendar-events' ) : __( 'No', 'google-calendar-events' ),
477
- 'result_export' => function_exists( 'curl_init' ) ? 'Yes' : 'No',
478
  ),
479
  'soap' => array(
480
  'label' => 'SOAP',
335
  * ==================
336
  */
337
 
338
+ if ( version_compare( PHP_VERSION, '5.5.19', '<' ) ) {
339
+ $php = '<mark class="error">' . sprintf( __( '%1$s - It is recomendend to upgrade at least to PHP version 5.5.19 for security reasons. <a href="%2$s" target="_blank">Read more.</a>', 'google-calendar-events' ), PHP_VERSION, 'http://www.wpupdatephp.com/update/' ) . '</mark>';
340
  } else {
341
  $php = '<mark class="ok">' . PHP_VERSION . '</mark>';
342
  }
412
  $php_max_execution_time = ini_get( 'max_execution_time' );
413
  $php_max_input_vars = ini_get( 'max_input_vars' );
414
 
415
+ $curl_info = '';
416
+
417
+ if ( function_exists( 'curl_version' ) ) {
418
+ $curl_info = curl_version();
419
+ }
420
+
421
  $sections['server'] = array(
422
  'host' => array(
423
  'label' => __( 'Web Server', 'google-calendar-events' ),
478
  'result_export' => function_exists( 'fsockopen' ) ? 'Yes' : 'No',
479
  ),
480
  'curl_init' => array(
481
+ 'label' => 'cURL',
482
+ 'result' => ! empty( $curl_info ) ? $curl_info['version'] . ', ' . $curl_info['ssl_version'] : __( 'No version found.', 'google-calendar-events' ),
483
+ 'result_export' => ! empty( $curl_info ) ? $curl_info['version'] . ', ' . $curl_info['ssl_version'] : 'No version found.',
484
  ),
485
  'soap' => array(
486
  'label' => 'SOAP',
includes/calendars/default-calendar.php CHANGED
@@ -219,13 +219,7 @@ class Default_Calendar extends Calendar {
219
  if ( false !== $event->multiple_days ) {
220
  $days = $event->multiple_days;
221
 
222
- if ( ! empty( $event->whole_day ) ) {
223
- $days--;
224
- }
225
-
226
- if ( $days == 1 ) {
227
- $new_events[ intval( $event->start + ( DAY_IN_SECONDS ) - 1 ) ][] = $event;
228
- } else {
229
 
230
  for ( $d = 1; $d <= $days; $d++ ) {
231
  $new_events[ intval( $event->start + ( $d * DAY_IN_SECONDS ) - 1 ) ][] = $event;
219
  if ( false !== $event->multiple_days ) {
220
  $days = $event->multiple_days;
221
 
222
+ if ( $days > 0 ) {
 
 
 
 
 
 
223
 
224
  for ( $d = 1; $d <= $days; $d++ ) {
225
  $new_events[ intval( $event->start + ( $d * DAY_IN_SECONDS ) - 1 ) ][] = $event;
includes/calendars/views/default-calendar-list.php CHANGED
@@ -188,7 +188,7 @@ class Default_Calendar_List implements Calendar_View {
188
 
189
  if ( $calendar instanceof Default_Calendar ) {
190
 
191
- $disabled = $calendar->static === true ? ' disabled="disabled"' : '';
192
 
193
 
194
  $hide_header = get_post_meta( $this->calendar->id, '_default_calendar_list_header', true ) == 'yes' ? true : false;
@@ -335,12 +335,14 @@ class Default_Calendar_List implements Calendar_View {
335
  }
336
  ksort( $daily_events, SORT_NUMERIC );
337
 
338
- $first_event = array_slice( $paged_events, 0, 1, true );
339
- $first_event = array_pop( $first_event );
340
- $this->first_event = $first_event[0]->start;
 
341
 
342
- $last_event = array_pop( $paged_events );
343
- $this->last_event = $last_event[0]->start;
 
344
 
345
  return $daily_events;
346
  }
@@ -638,7 +640,7 @@ class Default_Calendar_List implements Calendar_View {
638
  $message = get_post_meta( $calendar->id, '_no_events_message', true );
639
 
640
  if ( 'events' == $calendar->group_type ) {
641
- echo ! empty( $message ) ? $message : __( 'Nothing to show.', 'google-calendar-events' );
642
  } else {
643
  if ( ! empty( $message ) ) {
644
  echo $message;
188
 
189
  if ( $calendar instanceof Default_Calendar ) {
190
 
191
+ $disabled = $calendar->static === true || empty( $calendar->events ) ? ' disabled="disabled"' : '';
192
 
193
 
194
  $hide_header = get_post_meta( $this->calendar->id, '_default_calendar_list_header', true ) == 'yes' ? true : false;
335
  }
336
  ksort( $daily_events, SORT_NUMERIC );
337
 
338
+ if ( ! empty( $paged_events ) ) {
339
+ $first_event = array_slice( $paged_events, 0, 1, true );
340
+ $first_event = array_pop( $first_event );
341
+ $this->first_event = $first_event[0]->start;
342
 
343
+ $last_event = array_pop( $paged_events );
344
+ $this->last_event = $last_event[0]->start;
345
+ }
346
 
347
  return $daily_events;
348
  }
640
  $message = get_post_meta( $calendar->id, '_no_events_message', true );
641
 
642
  if ( 'events' == $calendar->group_type ) {
643
+ echo ! empty( $message ) ? $message : __( 'There are no upcoming events.', 'google-calendar-events' );
644
  } else {
645
  if ( ! empty( $message ) ) {
646
  echo $message;
includes/feeds/google.php CHANGED
@@ -280,10 +280,10 @@ class Google extends Feed {
280
  $end_utc = $google_end_utc->getTimestamp();
281
 
282
  // Count multiple days.
283
- $span = $google_start->setTimezone( $calendar['timezone'] )->diffInDays( $google_end->setTimezone( $calendar['timezone'] ) );
284
 
285
  if ( $span == 0 ) {
286
- if ( $google_start->toDateString() !== $google_end->toDateString() ) {
287
  $span = 1;
288
  }
289
  }
280
  $end_utc = $google_end_utc->getTimestamp();
281
 
282
  // Count multiple days.
283
+ $span = $google_start->diffInDays( $google_end );
284
 
285
  if ( $span == 0 ) {
286
+ if ( ( $google_start->toDateString() !== $google_end->toDateString() ) && $google_end->toTimeString() != '00:00:00' ) {
287
  $span = 1;
288
  }
289
  }
readme.txt CHANGED
@@ -1,9 +1,9 @@
1
  === Simple Calendar - Google Calendar Plugin ===
2
  Contributors: moonstonemedia, pderksen, nickyoung87, nekojira, rosshanney
3
  Tags: google calendar, calendar, calendars, google, event calendar, custom calendar, custom calendars, event, events
4
- Requires at least: 4.1
5
- Tested up to: 4.5
6
- Stable tag: 3.1.1
7
  License: GPLv2 or later
8
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
9
 
@@ -23,6 +23,7 @@ Add Google Calendar events to your WordPress site in minutes. Beautiful calendar
23
  * Combine multiple calendars into single displays explicitly or using categories.
24
  * Intuitive, simple display configuration changes for fine tuning.
25
  * Advanced settings to adjust time zones, date/time formats and start of the week.
 
26
  * Additional functionality offered with [add-ons](https://simplecalendar.io/addons/?utm_source=wordpress.org&utm_medium=link&utm_campaign=simple-cal-readme&utm_content=description).
27
  * Translations available with more being added on a regular basis. [Translations welcome!](https://translate.wordpress.org/projects/wp-plugins/google-calendar-events)
28
  * Open source with code hosted on GitHub. [Contributions welcome!](https://github.com/moonstonemedia/Simple-Calendar)
@@ -93,13 +94,20 @@ We'd love your help! Here's a few things you can do:
93
 
94
  == Changelog ==
95
 
 
 
 
 
 
 
 
 
96
  = 3.1.1 - June 16, 2016 =
97
 
98
  * Fix: Correct all-day events displayed in multiple days in some cases.
99
  * Fix: Paging navigation links now hidden when no more events exist past the current page in list view.
100
  * Tweak: "Powered by Simple Calendar" author credit opt in moved to individual per calendar settings.
101
 
102
-
103
  = 3.1.0 - May 25, 2016 =
104
 
105
  * Fix: qTips arrow should line up with events more accurately.
1
  === Simple Calendar - Google Calendar Plugin ===
2
  Contributors: moonstonemedia, pderksen, nickyoung87, nekojira, rosshanney
3
  Tags: google calendar, calendar, calendars, google, event calendar, custom calendar, custom calendars, event, events
4
+ Requires at least: 4.2
5
+ Tested up to: 4.6
6
+ Stable tag: 3.1.2
7
  License: GPLv2 or later
8
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
9
 
23
  * Combine multiple calendars into single displays explicitly or using categories.
24
  * Intuitive, simple display configuration changes for fine tuning.
25
  * Advanced settings to adjust time zones, date/time formats and start of the week.
26
+ * Integration with [Event Calendar Newsletter](https://wordpress.org/plugins/event-calendar-newsletter/) for quickly turning your events into a newsletter-friendly format.
27
  * Additional functionality offered with [add-ons](https://simplecalendar.io/addons/?utm_source=wordpress.org&utm_medium=link&utm_campaign=simple-cal-readme&utm_content=description).
28
  * Translations available with more being added on a regular basis. [Translations welcome!](https://translate.wordpress.org/projects/wp-plugins/google-calendar-events)
29
  * Open source with code hosted on GitHub. [Contributions welcome!](https://github.com/moonstonemedia/Simple-Calendar)
94
 
95
  == Changelog ==
96
 
97
+ = 3.1.2 - July 13, 2016 =
98
+
99
+ * Fix: Multi-day events do not stop short a day.
100
+ * Fix: Events that end at midnight no longer duplicate on the next day.
101
+ * Fix: Header shows correct date in list view when there are no events to show.
102
+ * Tweak: Tightened up security a bit.
103
+ * Dev: Tested up to WordPress 4.6.
104
+
105
  = 3.1.1 - June 16, 2016 =
106
 
107
  * Fix: Correct all-day events displayed in multiple days in some cases.
108
  * Fix: Paging navigation links now hidden when no more events exist past the current page in list view.
109
  * Tweak: "Powered by Simple Calendar" author credit opt in moved to individual per calendar settings.
110
 
 
111
  = 3.1.0 - May 25, 2016 =
112
 
113
  * Fix: qTips arrow should line up with events more accurately.
vendor/composer/installed.json CHANGED
@@ -200,19 +200,64 @@
200
  "shim"
201
  ]
202
  },
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
203
  {
204
  "name": "composer/installers",
205
- "version": "v1.0.25",
206
- "version_normalized": "1.0.25.0",
207
  "source": {
208
  "type": "git",
209
  "url": "https://github.com/composer/installers.git",
210
- "reference": "36e5b5843203d7f1cf6ffb0305a97e014387bd8e"
211
  },
212
  "dist": {
213
  "type": "zip",
214
- "url": "https://api.github.com/repos/composer/installers/zipball/36e5b5843203d7f1cf6ffb0305a97e014387bd8e",
215
- "reference": "36e5b5843203d7f1cf6ffb0305a97e014387bd8e",
216
  "shasum": ""
217
  },
218
  "require": {
@@ -226,7 +271,7 @@
226
  "composer/composer": "1.0.*@dev",
227
  "phpunit/phpunit": "4.1.*"
228
  },
229
- "time": "2016-04-13 19:46:30",
230
  "type": "composer-plugin",
231
  "extra": {
232
  "class": "Composer\\Installers\\Plugin",
@@ -261,6 +306,7 @@
261
  "MODX Evo",
262
  "Mautic",
263
  "OXID",
 
264
  "SMF",
265
  "Thelia",
266
  "WolfCMS",
@@ -276,6 +322,7 @@
276
  "dokuwiki",
277
  "drupal",
278
  "elgg",
 
279
  "fuelphp",
280
  "grav",
281
  "installer",
@@ -302,64 +349,19 @@
302
  "zikula"
303
  ]
304
  },
305
- {
306
- "name": "google/apiclient",
307
- "version": "1.1.7",
308
- "version_normalized": "1.1.7.0",
309
- "source": {
310
- "type": "git",
311
- "url": "https://github.com/google/google-api-php-client.git",
312
- "reference": "400f250a30ae1dd4c4a0a4f750fe973fc70e6311"
313
- },
314
- "dist": {
315
- "type": "zip",
316
- "url": "https://api.github.com/repos/google/google-api-php-client/zipball/400f250a30ae1dd4c4a0a4f750fe973fc70e6311",
317
- "reference": "400f250a30ae1dd4c4a0a4f750fe973fc70e6311",
318
- "shasum": ""
319
- },
320
- "require": {
321
- "php": ">=5.2.1"
322
- },
323
- "require-dev": {
324
- "phpunit/phpunit": "3.7.*",
325
- "squizlabs/php_codesniffer": "~2.3"
326
- },
327
- "time": "2016-02-02 18:50:42",
328
- "type": "library",
329
- "extra": {
330
- "branch-alias": {
331
- "dev-master": "1.1.x-dev"
332
- }
333
- },
334
- "installation-source": "dist",
335
- "autoload": {
336
- "classmap": [
337
- "src/"
338
- ]
339
- },
340
- "notification-url": "https://packagist.org/downloads/",
341
- "license": [
342
- "Apache-2.0"
343
- ],
344
- "description": "Client library for Google APIs",
345
- "homepage": "http://developers.google.com/api-client-library/php",
346
- "keywords": [
347
- "google"
348
- ]
349
- },
350
  {
351
  "name": "symfony/translation",
352
- "version": "v3.1.1",
353
- "version_normalized": "3.1.1.0",
354
  "source": {
355
  "type": "git",
356
  "url": "https://github.com/symfony/translation.git",
357
- "reference": "b36e79d7bbbfa4a7e9708335082b3eba2263d356"
358
  },
359
  "dist": {
360
  "type": "zip",
361
- "url": "https://api.github.com/repos/symfony/translation/zipball/b36e79d7bbbfa4a7e9708335082b3eba2263d356",
362
- "reference": "b36e79d7bbbfa4a7e9708335082b3eba2263d356",
363
  "shasum": ""
364
  },
365
  "require": {
@@ -380,7 +382,7 @@
380
  "symfony/config": "",
381
  "symfony/yaml": ""
382
  },
383
- "time": "2016-06-14 11:18:07",
384
  "type": "library",
385
  "extra": {
386
  "branch-alias": {
200
  "shim"
201
  ]
202
  },
203
+ {
204
+ "name": "google/apiclient",
205
+ "version": "1.1.7",
206
+ "version_normalized": "1.1.7.0",
207
+ "source": {
208
+ "type": "git",
209
+ "url": "https://github.com/google/google-api-php-client.git",
210
+ "reference": "400f250a30ae1dd4c4a0a4f750fe973fc70e6311"
211
+ },
212
+ "dist": {
213
+ "type": "zip",
214
+ "url": "https://api.github.com/repos/google/google-api-php-client/zipball/400f250a30ae1dd4c4a0a4f750fe973fc70e6311",
215
+ "reference": "400f250a30ae1dd4c4a0a4f750fe973fc70e6311",
216
+ "shasum": ""
217
+ },
218
+ "require": {
219
+ "php": ">=5.2.1"
220
+ },
221
+ "require-dev": {
222
+ "phpunit/phpunit": "3.7.*",
223
+ "squizlabs/php_codesniffer": "~2.3"
224
+ },
225
+ "time": "2016-02-02 18:50:42",
226
+ "type": "library",
227
+ "extra": {
228
+ "branch-alias": {
229
+ "dev-master": "1.1.x-dev"
230
+ }
231
+ },
232
+ "installation-source": "dist",
233
+ "autoload": {
234
+ "classmap": [
235
+ "src/"
236
+ ]
237
+ },
238
+ "notification-url": "https://packagist.org/downloads/",
239
+ "license": [
240
+ "Apache-2.0"
241
+ ],
242
+ "description": "Client library for Google APIs",
243
+ "homepage": "http://developers.google.com/api-client-library/php",
244
+ "keywords": [
245
+ "google"
246
+ ]
247
+ },
248
  {
249
  "name": "composer/installers",
250
+ "version": "v1.1.0",
251
+ "version_normalized": "1.1.0.0",
252
  "source": {
253
  "type": "git",
254
  "url": "https://github.com/composer/installers.git",
255
+ "reference": "a3595c5272a6f247228abb20076ed27321e4aae9"
256
  },
257
  "dist": {
258
  "type": "zip",
259
+ "url": "https://api.github.com/repos/composer/installers/zipball/a3595c5272a6f247228abb20076ed27321e4aae9",
260
+ "reference": "a3595c5272a6f247228abb20076ed27321e4aae9",
261
  "shasum": ""
262
  },
263
  "require": {
271
  "composer/composer": "1.0.*@dev",
272
  "phpunit/phpunit": "4.1.*"
273
  },
274
+ "time": "2016-07-05 06:18:20",
275
  "type": "composer-plugin",
276
  "extra": {
277
  "class": "Composer\\Installers\\Plugin",
306
  "MODX Evo",
307
  "Mautic",
308
  "OXID",
309
+ "RadPHP",
310
  "SMF",
311
  "Thelia",
312
  "WolfCMS",
322
  "dokuwiki",
323
  "drupal",
324
  "elgg",
325
+ "expressionengine",
326
  "fuelphp",
327
  "grav",
328
  "installer",
349
  "zikula"
350
  ]
351
  },
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
352
  {
353
  "name": "symfony/translation",
354
+ "version": "v3.1.2",
355
+ "version_normalized": "3.1.2.0",
356
  "source": {
357
  "type": "git",
358
  "url": "https://github.com/symfony/translation.git",
359
+ "reference": "d63a94528530c3ea5ff46924c8001cec4a398609"
360
  },
361
  "dist": {
362
  "type": "zip",
363
+ "url": "https://api.github.com/repos/symfony/translation/zipball/d63a94528530c3ea5ff46924c8001cec4a398609",
364
+ "reference": "d63a94528530c3ea5ff46924c8001cec4a398609",
365
  "shasum": ""
366
  },
367
  "require": {
382
  "symfony/config": "",
383
  "symfony/yaml": ""
384
  },
385
+ "time": "2016-06-29 05:41:56",
386
  "type": "library",
387
  "extra": {
388
  "branch-alias": {
vendor/composer/installers/README.md CHANGED
@@ -38,7 +38,7 @@ is not needed to install packages with these frameworks:
38
  | AGL | `agl-module`
39
  | Bonefish | `bonefish-package`
40
  | AnnotateCms | `annotatecms-module`<br>`annotatecms-component`<br>`annotatecms-service`
41
- | Bitrix | `bitrix-module`<br>`bitrix-component`<br>`bitrix-theme`
42
  | CakePHP 2+ | **`cakephp-plugin`**
43
  | Chef | `chef-cookbook`<br>`chef-role`
44
  | CCFramework | `ccframework-ship`<br>`ccframework-theme`
@@ -46,10 +46,12 @@ is not needed to install packages with these frameworks:
46
  | concrete5 | `concrete5-block`<br>`concrete5-package`<br>`concrete5-theme`<br>`concrete5-update`
47
  | Craft | `craft-plugin`
48
  | Croogo | `croogo-plugin`<br>`croogo-theme`
 
49
  | DokuWiki | `dokuwiki-plugin`<br>`dokuwiki-template`
50
  | Dolibarr | `dolibarr-module`
51
  | Drupal | <b>`drupal-core`<br>`drupal-module`<br>`drupal-theme`</b><br>`drupal-library`<br>`drupal-profile`<br>`drupal-drush`
52
  | Elgg | `elgg-plugin`
 
53
  | FuelPHP v1.x | `fuel-module`<br>`fuel-package`<br/>`fuel-theme`
54
  | FuelPHP v2.x | `fuelphp-component`
55
  | Grav | `grav-plugin`<br>`grav-theme`
@@ -75,6 +77,7 @@ is not needed to install packages with these frameworks:
75
  | Pimcore | `pimcore-plugin`
76
  | PPI | **`ppi-module`**
77
  | Puppet | `puppet-module`
 
78
  | REDAXO | `redaxo-addon`
79
  | Roundcube | `roundcube-plugin`
80
  | shopware | `shopware-backend-plugin`<br/>`shopware-core-plugin`<br/>`shopware-frontend-plugin`<br/>`shopware-theme`
@@ -89,6 +92,7 @@ is not needed to install packages with these frameworks:
89
  | Zend | `zend-library`<br>`zend-extra`<br>`zend-module`
90
  | Zikula | `zikula-module`<br>`zikula-theme`
91
  | Prestashop | `prestashop-module`<br>`prestashop-theme`
 
92
 
93
  ## Example `composer.json` File
94
 
38
  | AGL | `agl-module`
39
  | Bonefish | `bonefish-package`
40
  | AnnotateCms | `annotatecms-module`<br>`annotatecms-component`<br>`annotatecms-service`
41
+ | Bitrix | `bitrix-module` (deprecated) <br>`bitrix-component` (deprecated) <br>`bitrix-theme` (deprecated) <br><br> `bitrix-d7-module` <br> `bitrix-d7-component` <br> `bitrix-d7-template`
42
  | CakePHP 2+ | **`cakephp-plugin`**
43
  | Chef | `chef-cookbook`<br>`chef-role`
44
  | CCFramework | `ccframework-ship`<br>`ccframework-theme`
46
  | concrete5 | `concrete5-block`<br>`concrete5-package`<br>`concrete5-theme`<br>`concrete5-update`
47
  | Craft | `craft-plugin`
48
  | Croogo | `croogo-plugin`<br>`croogo-theme`
49
+ | Decibel | `decibel-app`
50
  | DokuWiki | `dokuwiki-plugin`<br>`dokuwiki-template`
51
  | Dolibarr | `dolibarr-module`
52
  | Drupal | <b>`drupal-core`<br>`drupal-module`<br>`drupal-theme`</b><br>`drupal-library`<br>`drupal-profile`<br>`drupal-drush`
53
  | Elgg | `elgg-plugin`
54
+ | ExpressionEngine 3 | `ee3-addon`<br>`ee3-theme`
55
  | FuelPHP v1.x | `fuel-module`<br>`fuel-package`<br/>`fuel-theme`
56
  | FuelPHP v2.x | `fuelphp-component`
57
  | Grav | `grav-plugin`<br>`grav-theme`
77
  | Pimcore | `pimcore-plugin`
78
  | PPI | **`ppi-module`**
79
  | Puppet | `puppet-module`
80
+ | RadPHP | `radphp-bundle`
81
  | REDAXO | `redaxo-addon`
82
  | Roundcube | `roundcube-plugin`
83
  | shopware | `shopware-backend-plugin`<br/>`shopware-core-plugin`<br/>`shopware-frontend-plugin`<br/>`shopware-theme`
92
  | Zend | `zend-library`<br>`zend-extra`<br>`zend-module`
93
  | Zikula | `zikula-module`<br>`zikula-theme`
94
  | Prestashop | `prestashop-module`<br>`prestashop-theme`
95
+ | Phifty | `phifty-bundle`<br>`phifty-framework`<br>`phifty-library`
96
 
97
  ## Example `composer.json` File
98
 
vendor/composer/installers/composer.json CHANGED
@@ -19,6 +19,7 @@
19
  "Dolibarr",
20
  "Drupal",
21
  "Elgg",
 
22
  "FuelPHP",
23
  "Grav",
24
  "Hurad",
@@ -39,6 +40,7 @@
39
  "phpBB",
40
  "PPI",
41
  "Puppet",
 
42
  "Roundcube",
43
  "shopware",
44
  "SilverStripe",
19
  "Dolibarr",
20
  "Drupal",
21
  "Elgg",
22
+ "ExpressionEngine",
23
  "FuelPHP",
24
  "Grav",
25
  "Hurad",
40
  "phpBB",
41
  "PPI",
42
  "Puppet",
43
+ "RadPHP",
44
  "Roundcube",
45
  "shopware",
46
  "SilverStripe",
vendor/composer/installers/src/Composer/Installers/BitrixInstaller.php CHANGED
@@ -6,9 +6,9 @@ use Composer\Util\Filesystem;
6
 
7
  /**
8
  * Installer for Bitrix Framework. Supported types of extensions:
9
- * - `bitrix-module` — copy the module to directory `bitrix/modules/` directory.
10
- * - `bitrix-component` — copy the component to directory `bitrix/components/`.
11
- * - `bitrix-template` — copy the template to directory `bitrix/templates/`.
12
  *
13
  * You can set custom path to directory with Bitrix kernel in `composer.json`:
14
  *
@@ -26,9 +26,12 @@ use Composer\Util\Filesystem;
26
  class BitrixInstaller extends BaseInstaller
27
  {
28
  protected $locations = array(
29
- 'module' => '{$bitrix_dir}/modules/{$name}/',
30
- 'component' => '{$bitrix_dir}/components/{$name}/',
31
- 'theme' => '{$bitrix_dir}/templates/{$name}/',
 
 
 
32
  );
33
 
34
  /**
6
 
7
  /**
8
  * Installer for Bitrix Framework. Supported types of extensions:
9
+ * - `bitrix-d7-module` — copy the module to directory `bitrix/modules/<vendor>.<name>`.
10
+ * - `bitrix-d7-component` — copy the component to directory `bitrix/components/<vendor>/<name>`.
11
+ * - `bitrix-d7-template` — copy the template to directory `bitrix/templates/<vendor>_<name>`.
12
  *
13
  * You can set custom path to directory with Bitrix kernel in `composer.json`:
14
  *
26
  class BitrixInstaller extends BaseInstaller
27
  {
28
  protected $locations = array(
29
+ 'module' => '{$bitrix_dir}/modules/{$name}/', // deprecated, remove on the major release (Backward compatibility will be broken)
30
+ 'component' => '{$bitrix_dir}/components/{$name}/', // deprecated, remove on the major release (Backward compatibility will be broken)
31
+ 'theme' => '{$bitrix_dir}/templates/{$name}/', // deprecated, remove on the major release (Backward compatibility will be broken)
32
+ 'd7-module' => '{$bitrix_dir}/modules/{$vendor}.{$name}/',
33
+ 'd7-component' => '{$bitrix_dir}/components/{$vendor}/{$name}/',
34
+ 'd7-template' => '{$bitrix_dir}/templates/{$vendor}_{$name}/',
35
  );
36
 
37
  /**
vendor/composer/installers/src/Composer/Installers/DecibelInstaller.php ADDED
@@ -0,0 +1,10 @@
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ namespace Composer\Installers;
3
+
4
+ class DecibelInstaller extends BaseInstaller
5
+ {
6
+ /** @var array */
7
+ protected $locations = array(
8
+ 'app' => 'app/{$name}/',
9
+ );
10
+ }
vendor/composer/installers/src/Composer/Installers/ExpressionEngineInstaller.php ADDED
@@ -0,0 +1,29 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ namespace Composer\Installers;
3
+
4
+ use Composer\Package\PackageInterface;
5
+
6
+ class ExpressionEngineInstaller extends BaseInstaller
7
+ {
8
+
9
+ protected $locations = array();
10
+
11
+ private $ee2Locations = array(
12
+ 'addon' => 'system/expressionengine/third-party/{$name}/',
13
+ 'theme' => 'themes/third-party/{$name}/',
14
+ );
15
+
16
+ private $ee3Locations = array(
17
+ 'addon' => 'system/user/addons/{$name}/',
18
+ 'theme' => 'themes/user/{$name}/',
19
+ );
20
+
21
+ public function getInstallPath(PackageInterface $package, $frameworkType = '')
22
+ {
23
+
24
+ $version = "{$frameworkType}Locations";
25
+ $this->locations = $this->$version;
26
+
27
+ return parent::getInstallPath($package, $frameworkType);
28
+ }
29
+ }
vendor/composer/installers/src/Composer/Installers/Installer.php CHANGED
@@ -29,8 +29,11 @@ class Installer extends LibraryInstaller
29
  'croogo' => 'CroogoInstaller',
30
  'dokuwiki' => 'DokuWikiInstaller',
31
  'dolibarr' => 'DolibarrInstaller',
 
32
  'drupal' => 'DrupalInstaller',
33
  'elgg' => 'ElggInstaller',
 
 
34
  'fuel' => 'FuelInstaller',
35
  'fuelphp' => 'FuelphpInstaller',
36
  'grav' => 'GravInstaller',
@@ -57,6 +60,8 @@ class Installer extends LibraryInstaller
57
  'piwik' => 'PiwikInstaller',
58
  'ppi' => 'PPIInstaller',
59
  'puppet' => 'PuppetInstaller',
 
 
60
  'redaxo' => 'RedaxoInstaller',
61
  'roundcube' => 'RoundcubeInstaller',
62
  'shopware' => 'ShopwareInstaller',
29
  'croogo' => 'CroogoInstaller',
30
  'dokuwiki' => 'DokuWikiInstaller',
31
  'dolibarr' => 'DolibarrInstaller',
32
+ 'decibel' => 'DecibelInstaller',
33
  'drupal' => 'DrupalInstaller',
34
  'elgg' => 'ElggInstaller',
35
+ 'ee3' => 'ExpressionEngineInstaller',
36
+ 'ee2' => 'ExpressionEngineInstaller',
37
  'fuel' => 'FuelInstaller',
38
  'fuelphp' => 'FuelphpInstaller',
39
  'grav' => 'GravInstaller',
60
  'piwik' => 'PiwikInstaller',
61
  'ppi' => 'PPIInstaller',
62
  'puppet' => 'PuppetInstaller',
63
+ 'radphp' => 'RadPHPInstaller',
64
+ 'phifty' => 'PhiftyInstaller',
65
  'redaxo' => 'RedaxoInstaller',
66
  'roundcube' => 'RoundcubeInstaller',
67
  'shopware' => 'ShopwareInstaller',
vendor/composer/installers/src/Composer/Installers/PhiftyInstaller.php ADDED
@@ -0,0 +1,11 @@
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ namespace Composer\Installers;
3
+
4
+ class PhiftyInstaller extends BaseInstaller
5
+ {
6
+ protected $locations = array(
7
+ 'bundle' => 'bundles/{$name}/',
8
+ 'library' => 'libraries/{$name}/',
9
+ 'framework' => 'frameworks/{$name}/',
10
+ );
11
+ }
vendor/composer/installers/src/Composer/Installers/RadPHPInstaller.php ADDED
@@ -0,0 +1,24 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ namespace Composer\Installers;
3
+
4
+ class RadPHPInstaller extends BaseInstaller
5
+ {
6
+ protected $locations = array(
7
+ 'bundle' => 'src/{$name}/'
8
+ );
9
+
10
+ /**
11
+ * Format package name to CamelCase
12
+ */
13
+ public function inflectPackageVars($vars)
14
+ {
15
+ $nameParts = explode('/', $vars['name']);
16
+ foreach ($nameParts as &$value) {
17
+ $value = strtolower(preg_replace('/(?<=\\w)([A-Z])/', '_\\1', $value));
18
+ $value = str_replace(array('-', '_'), ' ', $value);
19
+ $value = str_replace(' ', '', ucwords($value));
20
+ }
21
+ $vars['name'] = implode('/', $nameParts);
22
+ return $vars;
23
+ }
24
+ }
vendor/composer/installers/tests/Composer/Installers/Test/InstallerTest.php CHANGED
@@ -110,10 +110,15 @@ class InstallerTest extends TestCase
110
  array('craft-plugin', true),
111
  array('croogo-plugin', true),
112
  array('croogo-theme', true),
 
113
  array('dokuwiki-plugin', true),
114
  array('dokuwiki-template', true),
115
  array('drupal-module', true),
116
  array('dolibarr-module', true),
 
 
 
 
117
  array('elgg-plugin', true),
118
  array('fuel-module', true),
119
  array('fuel-package', true),
@@ -150,6 +155,7 @@ class InstallerTest extends TestCase
150
  array('prestashop-module', true),
151
  array('prestashop-theme', true),
152
  array('puppet-module', true),
 
153
  array('redaxo-addon', true),
154
  array('redaxo-bestyle-plugin', true),
155
  array('roundcube-plugin', true),
@@ -179,6 +185,9 @@ class InstallerTest extends TestCase
179
  array('zikula-theme', true),
180
  array('kodicms-plugin', true),
181
  array('kodicms-media', true),
 
 
 
182
  );
183
  }
184
 
@@ -211,6 +220,9 @@ class InstallerTest extends TestCase
211
  array('bitrix-module', 'bitrix/modules/my_module/', 'author/my_module'),
212
  array('bitrix-component', 'bitrix/components/my_component/', 'author/my_component'),
213
  array('bitrix-theme', 'bitrix/templates/my_theme/', 'author/my_theme'),
 
 
 
214
  array('bonefish-package', 'Packages/bonefish/package/', 'bonefish/package'),
215
  array('cakephp-plugin', 'Plugin/Ftp/', 'shama/ftp'),
216
  array('chef-cookbook', 'Chef/mre/my_cookbook/', 'mre/my_cookbook'),
@@ -224,6 +236,7 @@ class InstallerTest extends TestCase
224
  array('craft-plugin', 'craft/plugins/my_plugin/', 'mdcpepper/my_plugin'),
225
  array('croogo-plugin', 'Plugin/Sitemaps/', 'fahad19/sitemaps'),
226
  array('croogo-theme', 'View/Themed/Readable/', 'rchavik/readable'),
 
227
  array('dokuwiki-plugin', 'lib/plugins/someplugin/', 'author/someplugin'),
228
  array('dokuwiki-template', 'lib/tpl/sometemplate/', 'author/sometemplate'),
229
  array('dolibarr-module', 'htdocs/custom/my_module/', 'shama/my_module'),
@@ -232,6 +245,10 @@ class InstallerTest extends TestCase
232
  array('drupal-profile', 'profiles/my_module/', 'shama/my_module'),
233
  array('drupal-drush', 'drush/my_module/', 'shama/my_module'),
234
  array('elgg-plugin', 'mod/sample_plugin/', 'test/sample_plugin'),
 
 
 
 
235
  array('fuel-module', 'fuel/app/modules/module/', 'fuel/module'),
236
  array('fuel-package', 'fuel/packages/orm/', 'fuel/orm'),
237
  array('fuel-theme', 'fuel/app/themes/theme/', 'fuel/theme'),
@@ -274,6 +291,7 @@ class InstallerTest extends TestCase
274
  array('pimcore-plugin', 'plugins/MyPlugin/', 'ubikz/my_plugin'),
275
  array('ppi-module', 'modules/foo/', 'test/foo'),
276
  array('puppet-module', 'modules/puppet-name/', 'puppet/puppet-name'),
 
277
  array('redaxo-addon', 'redaxo/include/addons/my_plugin/', 'shama/my_plugin'),
278
  array('redaxo-bestyle-plugin', 'redaxo/include/addons/be_style/plugins/my_plugin/', 'shama/my_plugin'),
279
  array('roundcube-plugin', 'plugins/base/', 'test/base'),
@@ -309,6 +327,9 @@ class InstallerTest extends TestCase
309
  array('zikula-theme', 'themes/my-test_theme/', 'my/test_theme'),
310
  array('kodicms-media', 'cms/media/vendor/my_media/', 'shama/my_media'),
311
  array('kodicms-plugin', 'cms/plugins/my_plugin/', 'shama/my_plugin'),
 
 
 
312
  );
313
  }
314
 
110
  array('craft-plugin', true),
111
  array('croogo-plugin', true),
112
  array('croogo-theme', true),
113
+ array('decibel-app', true),
114
  array('dokuwiki-plugin', true),
115
  array('dokuwiki-template', true),
116
  array('drupal-module', true),
117
  array('dolibarr-module', true),
118
+ array('ee3-theme', true),
119
+ array('ee3-addon', true),
120
+ array('ee2-theme', true),
121
+ array('ee2-addon', true),
122
  array('elgg-plugin', true),
123
  array('fuel-module', true),
124
  array('fuel-package', true),
155
  array('prestashop-module', true),
156
  array('prestashop-theme', true),
157
  array('puppet-module', true),
158
+ array('radphp-bundle', true),
159
  array('redaxo-addon', true),
160
  array('redaxo-bestyle-plugin', true),
161
  array('roundcube-plugin', true),
185
  array('zikula-theme', true),
186
  array('kodicms-plugin', true),
187
  array('kodicms-media', true),
188
+ array('phifty-bundle', true),
189
+ array('phifty-library', true),
190
+ array('phifty-framework', true),
191
  );
192
  }
193
 
220
  array('bitrix-module', 'bitrix/modules/my_module/', 'author/my_module'),
221
  array('bitrix-component', 'bitrix/components/my_component/', 'author/my_component'),
222
  array('bitrix-theme', 'bitrix/templates/my_theme/', 'author/my_theme'),
223
+ array('bitrix-d7-module', 'bitrix/modules/author.my_module/', 'author/my_module'),
224
+ array('bitrix-d7-component', 'bitrix/components/author/my_component/', 'author/my_component'),
225
+ array('bitrix-d7-template', 'bitrix/templates/author_my_template/', 'author/my_template'),
226
  array('bonefish-package', 'Packages/bonefish/package/', 'bonefish/package'),
227
  array('cakephp-plugin', 'Plugin/Ftp/', 'shama/ftp'),
228
  array('chef-cookbook', 'Chef/mre/my_cookbook/', 'mre/my_cookbook'),
236
  array('craft-plugin', 'craft/plugins/my_plugin/', 'mdcpepper/my_plugin'),
237
  array('croogo-plugin', 'Plugin/Sitemaps/', 'fahad19/sitemaps'),
238
  array('croogo-theme', 'View/Themed/Readable/', 'rchavik/readable'),
239
+ array('decibel-app', 'app/someapp/', 'author/someapp'),
240
  array('dokuwiki-plugin', 'lib/plugins/someplugin/', 'author/someplugin'),
241
  array('dokuwiki-template', 'lib/tpl/sometemplate/', 'author/sometemplate'),
242
  array('dolibarr-module', 'htdocs/custom/my_module/', 'shama/my_module'),
245
  array('drupal-profile', 'profiles/my_module/', 'shama/my_module'),
246
  array('drupal-drush', 'drush/my_module/', 'shama/my_module'),
247
  array('elgg-plugin', 'mod/sample_plugin/', 'test/sample_plugin'),
248
+ array('ee3-addon', 'system/user/addons/ee_theme/', 'author/ee_theme'),
249
+ array('ee3-theme', 'themes/user/ee_package/', 'author/ee_package'),
250
+ array('ee2-addon', 'system/expressionengine/third-party/ee_theme/', 'author/ee_theme'),
251
+ array('ee2-theme', 'themes/third-party/ee_package/', 'author/ee_package'),
252
  array('fuel-module', 'fuel/app/modules/module/', 'fuel/module'),
253
  array('fuel-package', 'fuel/packages/orm/', 'fuel/orm'),
254
  array('fuel-theme', 'fuel/app/themes/theme/', 'fuel/theme'),
291
  array('pimcore-plugin', 'plugins/MyPlugin/', 'ubikz/my_plugin'),
292
  array('ppi-module', 'modules/foo/', 'test/foo'),
293
  array('puppet-module', 'modules/puppet-name/', 'puppet/puppet-name'),
294
+ array('radphp-bundle', 'src/Migration/', 'atkrad/migration'),
295
  array('redaxo-addon', 'redaxo/include/addons/my_plugin/', 'shama/my_plugin'),
296
  array('redaxo-bestyle-plugin', 'redaxo/include/addons/be_style/plugins/my_plugin/', 'shama/my_plugin'),
297
  array('roundcube-plugin', 'plugins/base/', 'test/base'),
327
  array('zikula-theme', 'themes/my-test_theme/', 'my/test_theme'),
328
  array('kodicms-media', 'cms/media/vendor/my_media/', 'shama/my_media'),
329
  array('kodicms-plugin', 'cms/plugins/my_plugin/', 'shama/my_plugin'),
330
+ array('phifty-bundle', 'bundles/core/', 'shama/core'),
331
+ array('phifty-library', 'libraries/my-lib/', 'shama/my-lib'),
332
+ array('phifty-framework', 'frameworks/my-framework/', 'shama/my-framework'),
333
  );
334
  }
335
 
vendor/symfony/translation/Loader/MoFileLoader.php CHANGED
@@ -37,7 +37,7 @@ class MoFileLoader extends FileLoader
37
  /**
38
  * The size of the header of a MO file in bytes.
39
  *
40
- * @var int Number of bytes.
41
  */
42
  const MO_HEADER_SIZE = 28;
43
 
37
  /**
38
  * The size of the header of a MO file in bytes.
39
  *
40
+ * @var int Number of bytes
41
  */
42
  const MO_HEADER_SIZE = 28;
43
 
vendor/symfony/translation/Tests/PluralizationRulesTest.php CHANGED
@@ -93,7 +93,7 @@ class PluralizationRulesTest extends \PHPUnit_Framework_TestCase
93
  * We validate only on the plural coverage. Thus the real rules is not tested.
94
  *
95
  * @param string $nplural plural expected
96
- * @param array $matrix containing langcodes and their plural index values.
97
  * @param bool $expectSuccess
98
  */
99
  protected function validateMatrix($nplural, $matrix, $expectSuccess = true)
93
  * We validate only on the plural coverage. Thus the real rules is not tested.
94
  *
95
  * @param string $nplural plural expected
96
+ * @param array $matrix containing langcodes and their plural index values
97
  * @param bool $expectSuccess
98
  */
99
  protected function validateMatrix($nplural, $matrix, $expectSuccess = true)
vendor/symfony/translation/Tests/TranslatorTest.php CHANGED
@@ -285,12 +285,12 @@ class TranslatorTest extends \PHPUnit_Framework_TestCase
285
 
286
  $resources = $translator->getCatalogue('en')->getResources();
287
  $this->assertCount(1, $resources);
288
- $this->assertContains( __DIR__.DIRECTORY_SEPARATOR.'fixtures'.DIRECTORY_SEPARATOR.'resources.yml', $resources);
289
 
290
  $resources = $translator->getCatalogue('en_GB')->getResources();
291
  $this->assertCount(2, $resources);
292
- $this->assertContains( __DIR__.DIRECTORY_SEPARATOR.'fixtures'.DIRECTORY_SEPARATOR.'empty.yml', $resources);
293
- $this->assertContains( __DIR__.DIRECTORY_SEPARATOR.'fixtures'.DIRECTORY_SEPARATOR.'resources.yml', $resources);
294
  }
295
 
296
  /**
285
 
286
  $resources = $translator->getCatalogue('en')->getResources();
287
  $this->assertCount(1, $resources);
288
+ $this->assertContains(__DIR__.DIRECTORY_SEPARATOR.'fixtures'.DIRECTORY_SEPARATOR.'resources.yml', $resources);
289
 
290
  $resources = $translator->getCatalogue('en_GB')->getResources();
291
  $this->assertCount(2, $resources);
292
+ $this->assertContains(__DIR__.DIRECTORY_SEPARATOR.'fixtures'.DIRECTORY_SEPARATOR.'empty.yml', $resources);
293
+ $this->assertContains(__DIR__.DIRECTORY_SEPARATOR.'fixtures'.DIRECTORY_SEPARATOR.'resources.yml', $resources);
294
  }
295
 
296
  /**