CMP – Coming Soon & Maintenance Plugin by NiteoThemes - Version 1.6.0

Version Description

Download this release

Release Info

Developer niteo
Plugin Icon 128x128 CMP – Coming Soon & Maintenance Plugin by NiteoThemes
Version 1.6.0
Comparing to
See all releases

Code changes from version 1.5.1 to 1.6.0

cmp-options.php CHANGED
@@ -171,7 +171,7 @@ $niteoCS_analytics = stripslashes(get_option('niteoCS_analytics', ''));
171
  $niteoCS_custom_css = stripslashes(get_option('niteoCS_custom_css', ''));
172
  $niteoCS_unsplash_id = get_option('niteoCS_unsplash_id', '');
173
  $logo_id = get_option('niteoCS_logo_id');
174
- $niteoCS_banner = get_option('niteoCS_banner', '0');
175
  $banner_id = get_option('niteoCS_banner_id');
176
  $unsplash_feed = get_option('niteoCS_unsplash_feed', '3');
177
  $niteoCS_unsplash_0 = get_option('niteoCS_unsplash_0');
@@ -183,9 +183,9 @@ $niteoCS_banner_pattern = get_option('niteoCS_banner_pattern', 'sakura');
183
  $niteoCS_banner_pattern_custom = get_option('niteoCS_banner_pattern_custom');
184
  $niteoCS_cat_keyword = get_option('niteoCS_cat_keyword');
185
  $niteoCS_soc_title = get_option('niteoCS_soc_title', 'GET SOCIAL WITH US');
186
- $niteoCS_subscribe_type = get_option('niteoCS_subscribe_type', '0');
187
  $niteoCS_subscribe_code = get_option('niteoCS_subscribe_code');
188
- $niteoCS_subscribe_label = get_option('niteoCS_subscribe_label');
189
  $subscriber_list = get_option('niteoCS_subscribers_list');
190
  $niteoCS_csv_export_time = get_option('niteoCS_csv_export_time');
191
  $niteoCS_font_content = get_option('niteoCS_font_content', 'Average Sans');
@@ -231,7 +231,7 @@ if ( $subscriber_list ) {
231
  }
232
 
233
  // define patterns array
234
- $patterns = array('sakura', 'playstation');
235
 
236
  // define fonts array
237
  $fonts = array('Fjalla One', 'Average Sans', 'Playfair Display', 'Work Sans', 'Rubik', 'Libre Franklin', 'Space Mono', 'Fira Sans', 'Eczar', 'Alegreya Sans', 'Chivo', 'Lora', 'Source Sans Pro', 'Source Serif Pro', 'Roboto Slab', 'Raleway');
@@ -421,6 +421,28 @@ add_thickbox();
421
  </table>
422
  </div>
423
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
424
  <div class="table-wrapper content">
425
  <h3><?php _e('Theme Background', 'cmp');?></h3>
426
  <table class="content">
@@ -485,6 +507,7 @@ add_thickbox();
485
  </fieldset>
486
 
487
  <fieldset id="unsplash_banner">
 
488
  <label for="unsplash_feed"><?php _e('Choose Unsplash Feed', 'cmp');?></label></br>
489
  <select name="unsplash_feed">
490
  <option value="0" <?php if ( $unsplash_feed == '0' ) { echo ' selected="selected"'; } ?>><?php _e('Specific Photo', 'cmp');?></option>
@@ -573,6 +596,11 @@ add_thickbox();
573
  if (file_exists($this->cmp_themePath().$this->cmp_selectedTheme().'/'.$this->cmp_selectedTheme().'-slider_settings.php')) {
574
  include ( $this->cmp_themePath().$this->cmp_selectedTheme().'/'.$this->cmp_selectedTheme().'-slider_settings.php' );
575
  }
 
 
 
 
 
576
  ?>
577
 
578
  <div class="table-wrapper content">
@@ -634,34 +662,6 @@ add_thickbox();
634
  </table>
635
  </div>
636
 
637
- <div class="table-wrapper content">
638
- <h3><?php _e('Content', 'cmp');?></h3>
639
- <table class="content">
640
- <tr class="body-title">
641
- <th><h4><?php _e('Body Title', 'cmp');?></h4></th>
642
- <td>
643
- <fieldset>
644
- <input type="text" name="niteoCS_body_title" id="niteoCS_body_title" value="<?php echo stripslashes(esc_attr( $niteoCS_body_title)); ?>" class="regular-text code">
645
- </fieldset>
646
- </td>
647
- </tr>
648
-
649
- <tr>
650
- <th><h4><?php _e('Body Message', 'cmp');?></h4></th>
651
- <td>
652
- <?php wp_editor( stripslashes( $this->niteo_sanitize_html( $body ) ), 'niteoCS_body', $settings = array('textarea_name'=>'niteoCS_body', 'editor_height'=>'300') ); ?>
653
- </td>
654
- </tr>
655
-
656
- </table>
657
- </div>
658
-
659
- <?php
660
- // include theme related settings
661
- if (file_exists($this->cmp_themePath().$this->cmp_selectedTheme().'/'.$this->cmp_selectedTheme().'-settings.php')) {
662
- require ( $this->cmp_themePath().$this->cmp_selectedTheme().'/'.$this->cmp_selectedTheme().'-settings.php' );
663
- }
664
- ?>
665
 
666
  <div class="table-wrapper content" id="subscribe-section">
667
  <h3><?php _e('Subscribe Form', 'cmp');?></h3>
@@ -704,7 +704,7 @@ add_thickbox();
704
  <input type="text" name="niteoCS_subscribe_code" id="niteoCS_subscribe_code" value="<?php echo stripslashes( esc_attr($niteoCS_subscribe_code ));?>" class="regular-text code">
705
  </label>
706
 
707
- <p><?php _e('You can find Shortode in your Contact Form Plugin settings. Should be something similar to code below: ', 'cmp');?><br><code>[contact-form-7 id="8" title='Contact form 1']</code></p>
708
 
709
  <p><?php _e('Your Subscribe Form should have only one input (type=email) and submit (input=submit). If you have more than one input field, our design will not work and you need to use custom CSS to style your Subscribe form.', 'cmp');?></p>
710
  <p><?php _e('Example of Subscribe Form code for ', 'cmp');?><a href="https://wordpress.org/plugins/mailchimp-for-wp/">MailChimp</a> plugin:</p>
@@ -753,6 +753,7 @@ add_thickbox();
753
  <tr>
754
  <th><h4><?php _e('Social Media Icons', 'cmp');?></h4></th>
755
  <td>
 
756
  <ul class="social-media">
757
  <?php
758
  $socialmedia = json_decode($niteoCS_socialmedia, true);
@@ -784,6 +785,8 @@ add_thickbox();
784
  <?php
785
  } ?>
786
  </ul>
 
 
787
 
788
  <ul class="social-inputs">
789
  <span class="label"><?php _e('Position', 'cmp');?></span><span class="label"><?php _e('Active', 'cmp');?></span><span class="label"><?php _e('Website URL', 'cmp');?></span>
@@ -842,7 +845,7 @@ add_thickbox();
842
  <h3><?php _e('SEO Settings', 'cmp');?></h3>
843
  <table class="seo">
844
 
845
- <tr class="body-title">
846
  <th><h4><?php _e('Header Title', 'cmp');?></h4></th>
847
  <td>
848
  <fieldset>
171
  $niteoCS_custom_css = stripslashes(get_option('niteoCS_custom_css', ''));
172
  $niteoCS_unsplash_id = get_option('niteoCS_unsplash_id', '');
173
  $logo_id = get_option('niteoCS_logo_id');
174
+ $niteoCS_banner = get_option('niteoCS_banner', '2');
175
  $banner_id = get_option('niteoCS_banner_id');
176
  $unsplash_feed = get_option('niteoCS_unsplash_feed', '3');
177
  $niteoCS_unsplash_0 = get_option('niteoCS_unsplash_0');
183
  $niteoCS_banner_pattern_custom = get_option('niteoCS_banner_pattern_custom');
184
  $niteoCS_cat_keyword = get_option('niteoCS_cat_keyword');
185
  $niteoCS_soc_title = get_option('niteoCS_soc_title', 'GET SOCIAL WITH US');
186
+ $niteoCS_subscribe_type = get_option('niteoCS_subscribe_type', '2');
187
  $niteoCS_subscribe_code = get_option('niteoCS_subscribe_code');
188
+ $niteoCS_subscribe_label = get_option('niteoCS_subscribe_label', 'Type your email and get notified');
189
  $subscriber_list = get_option('niteoCS_subscribers_list');
190
  $niteoCS_csv_export_time = get_option('niteoCS_csv_export_time');
191
  $niteoCS_font_content = get_option('niteoCS_font_content', 'Average Sans');
231
  }
232
 
233
  // define patterns array
234
+ $patterns = array('fabric', 'gray_sand', 'green_dust_scratch', 'mirrored_squares', 'noisy', 'photography', 'playstation', 'sakura', 'white_sand', 'white_texture');
235
 
236
  // define fonts array
237
  $fonts = array('Fjalla One', 'Average Sans', 'Playfair Display', 'Work Sans', 'Rubik', 'Libre Franklin', 'Space Mono', 'Fira Sans', 'Eczar', 'Alegreya Sans', 'Chivo', 'Lora', 'Source Sans Pro', 'Source Serif Pro', 'Roboto Slab', 'Raleway');
421
  </table>
422
  </div>
423
 
424
+ <div class="table-wrapper content">
425
+ <h3><?php _e('Content', 'cmp');?></h3>
426
+ <table class="content">
427
+ <tr class="body-title">
428
+ <th><h4><?php _e('Body Title', 'cmp');?></h4></th>
429
+ <td>
430
+ <fieldset>
431
+ <input type="text" name="niteoCS_body_title" id="niteoCS_body_title" value="<?php echo stripslashes(esc_attr( $niteoCS_body_title)); ?>" class="regular-text code">
432
+ </fieldset>
433
+ </td>
434
+ </tr>
435
+
436
+ <tr>
437
+ <th><h4><?php _e('Body Message', 'cmp');?></h4></th>
438
+ <td>
439
+ <?php wp_editor( stripslashes( $this->niteo_sanitize_html( $body ) ), 'niteoCS_body', $settings = array('textarea_name'=>'niteoCS_body', 'editor_height'=>'300') ); ?>
440
+ </td>
441
+ </tr>
442
+
443
+ </table>
444
+ </div>
445
+
446
  <div class="table-wrapper content">
447
  <h3><?php _e('Theme Background', 'cmp');?></h3>
448
  <table class="content">
507
  </fieldset>
508
 
509
  <fieldset id="unsplash_banner">
510
+ <p class="unplash-description"><a href="http://unsplash.com" target="_blank">Unsplash</a> <?php _e('is a world leading source for free to use high quality stock images. All of the images that are submitted and published on Unsplash fall under under the Creative Commons Zero (CC0) license, which means you can use the image for any personal or commercial use.', 'cmp');?></p>
511
  <label for="unsplash_feed"><?php _e('Choose Unsplash Feed', 'cmp');?></label></br>
512
  <select name="unsplash_feed">
513
  <option value="0" <?php if ( $unsplash_feed == '0' ) { echo ' selected="selected"'; } ?>><?php _e('Specific Photo', 'cmp');?></option>
596
  if (file_exists($this->cmp_themePath().$this->cmp_selectedTheme().'/'.$this->cmp_selectedTheme().'-slider_settings.php')) {
597
  include ( $this->cmp_themePath().$this->cmp_selectedTheme().'/'.$this->cmp_selectedTheme().'-slider_settings.php' );
598
  }
599
+
600
+ // include theme related settings
601
+ if (file_exists($this->cmp_themePath().$this->cmp_selectedTheme().'/'.$this->cmp_selectedTheme().'-settings.php')) {
602
+ require ( $this->cmp_themePath().$this->cmp_selectedTheme().'/'.$this->cmp_selectedTheme().'-settings.php' );
603
+ }
604
  ?>
605
 
606
  <div class="table-wrapper content">
662
  </table>
663
  </div>
664
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
665
 
666
  <div class="table-wrapper content" id="subscribe-section">
667
  <h3><?php _e('Subscribe Form', 'cmp');?></h3>
704
  <input type="text" name="niteoCS_subscribe_code" id="niteoCS_subscribe_code" value="<?php echo stripslashes( esc_attr($niteoCS_subscribe_code ));?>" class="regular-text code">
705
  </label>
706
 
707
+ <p><?php _e('You can find Shortode in your Contact Form Plugin settings. Should be something similar to code below: ', 'cmp');?><br><code>[contact-form-7 id="8" title='Contact form 1']</code> or <code>[mc4wp_form id='7']</code></p>
708
 
709
  <p><?php _e('Your Subscribe Form should have only one input (type=email) and submit (input=submit). If you have more than one input field, our design will not work and you need to use custom CSS to style your Subscribe form.', 'cmp');?></p>
710
  <p><?php _e('Example of Subscribe Form code for ', 'cmp');?><a href="https://wordpress.org/plugins/mailchimp-for-wp/">MailChimp</a> plugin:</p>
753
  <tr>
754
  <th><h4><?php _e('Social Media Icons', 'cmp');?></h4></th>
755
  <td>
756
+ <p class="social-description"><?php _e('Click on Social Icons below to enable Social Media settings.', 'cmp');?></p>
757
  <ul class="social-media">
758
  <?php
759
  $socialmedia = json_decode($niteoCS_socialmedia, true);
785
  <?php
786
  } ?>
787
  </ul>
788
+
789
+
790
 
791
  <ul class="social-inputs">
792
  <span class="label"><?php _e('Position', 'cmp');?></span><span class="label"><?php _e('Active', 'cmp');?></span><span class="label"><?php _e('Website URL', 'cmp');?></span>
845
  <h3><?php _e('SEO Settings', 'cmp');?></h3>
846
  <table class="seo">
847
 
848
+ <tr class="seo-title">
849
  <th><h4><?php _e('Header Title', 'cmp');?></h4></th>
850
  <td>
851
  <fieldset>
cs_style.css CHANGED
@@ -58,7 +58,11 @@ input[type="text"], textarea{width:100%;}
58
  font-weight: 600;
59
  position: absolute;
60
  top: -20px;
61
- left: -15px;
 
 
 
 
62
  }
63
 
64
  .social-inputs .label:nth-of-type(2) {
@@ -68,8 +72,8 @@ input[type="text"], textarea{width:100%;}
68
  left: 148px;
69
  }
70
 
71
- .social-media li {display: inline-block;}
72
- .social-media i {font-size:1.5em;padding:7px;cursor:pointer;}
73
  .social-media i.active {color:#d54e21;}
74
 
75
  .social-inputs li {display: none;width:100%;}
@@ -106,6 +110,7 @@ th label {font-weight: 600;}
106
  .logo-wrapper, .banner-wrapper {margin: 1em 0;}
107
  .logo-wrapper img {background-color: #efefef;padding:1em;}
108
  .logo-wrapper img, .banner-wrapper img,.thumbnail-holder img {max-width: 100%;}
 
109
  .thumbnail-holder {display: inline-block;max-width: 250px;padding:1em;margin:1em;text-align: center;border: 1px solid #efefef;}
110
  #font-example-wrapper {padding:1em;border:1px solid #dedede;}
111
  #heading-example {padding-left: 0;border-bottom:none;}
58
  font-weight: 600;
59
  position: absolute;
60
  top: -20px;
61
+ left: -8px;
62
+ }
63
+
64
+ .social-description {
65
+ margin-top: 0;
66
  }
67
 
68
  .social-inputs .label:nth-of-type(2) {
72
  left: 148px;
73
  }
74
 
75
+ .social-media li {display: inline-block;padding-right:1em;padding-bottom: 1em;}
76
+ .social-media i {font-size:1.65em;cursor:pointer;}
77
  .social-media i.active {color:#d54e21;}
78
 
79
  .social-inputs li {display: none;width:100%;}
110
  .logo-wrapper, .banner-wrapper {margin: 1em 0;}
111
  .logo-wrapper img {background-color: #efefef;padding:1em;}
112
  .logo-wrapper img, .banner-wrapper img,.thumbnail-holder img {max-width: 100%;}
113
+ .logo-wrapper img {max-height: 150px;}
114
  .thumbnail-holder {display: inline-block;max-width: 250px;padding:1em;margin:1em;text-align: center;border: 1px solid #efefef;}
115
  #font-example-wrapper {padding:1em;border:1px solid #dedede;}
116
  #heading-example {padding-left: 0;border-bottom:none;}
img/patterns/fabric.png ADDED
Binary file
img/patterns/gray_sand.png ADDED
Binary file
img/patterns/green_dust_scratch.png ADDED
Binary file
img/patterns/mirrored_squares.png ADDED
Binary file
img/patterns/noisy.png ADDED
Binary file
img/patterns/photography.png ADDED
Binary file
img/patterns/white_sand.png ADDED
Binary file
img/patterns/white_texture.png ADDED
Binary file
niteo-cmp.php CHANGED
@@ -3,7 +3,7 @@
3
  Plugin Name: CMP - Coming Soon & Maintenance Plugin
4
  Plugin URI: https://wordpress.org/plugins/cmp-coming-soon-maintenance/
5
  Description: Display customizable landing page for Coming Soon, Maintenance & Under Construction page.
6
- Version: 1.5.1
7
  Author: NiteoThemes
8
  Author URI: http://www.niteo.cz
9
  Text Domain: cmp
@@ -16,13 +16,14 @@
16
  class niteo_cmp {
17
  var $installedFolder = '';
18
  var $version = '';
 
19
  var $remoteServer = '';
20
  var $theme_array = array();
21
  var $premium_installed = array();
22
 
23
  function __construct() {
24
- $this->version = '1.5.1';
25
-
26
  $this->installedFolder = basename(dirname(__FILE__));
27
 
28
  // get all installed themes [folder names under /themes] and put them to array
@@ -34,7 +35,15 @@ class niteo_cmp {
34
  } else {
35
  $this->theme_array = $this->themes_standard;
36
  }
37
- $this->remoteServer = 'http://niteo.cz/niteo-updates/';
 
 
 
 
 
 
 
 
38
  }
39
 
40
  function cmp() {
@@ -219,11 +228,7 @@ class niteo_cmp {
219
 
220
  // check selected theme
221
  function cmp_selectedTheme() {
222
- if ( !get_option('niteoCS_theme') ) { //if it's not set yet
223
- update_option('niteoCS_theme', 'construct'); //set it
224
- }
225
-
226
- return get_option('niteoCS_theme');
227
  }
228
 
229
  // return installed theme path
@@ -381,10 +386,14 @@ class niteo_cmp {
381
  }
382
 
383
  } else {
 
 
384
  echo '<div class="notice notice-error is-dismissible"><p>'.__('There has been error from remote server: ','cmp').wp_remote_retrieve_response_code($request).' '.__('while checking for','cmp').' '.esc_attr(ucwords(str_replace('_', ' ', $theme_slug))).' '.__('Theme update. Please try again later or contact us at info@niteo.cz if this error message keeps appearing.','cmp').'</p></div>';
385
  }
386
 
387
  } else {
 
 
388
  echo '<div class="notice notice-error is-dismissible"><p>'.__('There has been error: Internal server error:','cmp').' '.$request->get_error_message().' '.__('while checking for Theme update. Please try again later or contact us at info@niteo.cz if this error message keeps appearing.','cmp').'</p></div>';
389
 
390
  }
@@ -415,7 +424,6 @@ class niteo_cmp {
415
  $filetype = wp_check_filetype( $filename );
416
 
417
  if ( $filetype['ext'] == 'zip' ) {
418
-
419
  // Upload file
420
  $movefile = wp_handle_upload( $uploadedfile, array('test_form' => FALSE) );
421
 
@@ -613,11 +621,12 @@ class niteo_cmp {
613
  case '0':
614
  // check if $query contains unsplash.com url
615
  if ( strpos( $url, 'unsplash.com' ) !== false ) {
616
- $parts = parse_url( $url, PHP_URL_PATH );
617
 
618
  // check for photo parameter in URL
619
  parse_str($parts['query'], $query);
620
  $id = $query['photo'];
 
621
  // if no ID found, get last part of URL containing ID
622
  if ( is_null( $id ) ) {
623
 
@@ -772,54 +781,72 @@ class niteo_cmp {
772
  // convert hex to hsl css
773
  function hex2hsl( $hex, $opacity ) {
774
 
775
- if ( $hex[0] != '#' ) {
776
- $rgba = explode( ',', $hex);
777
- $rgba[3] = str_replace(')', '', $rgba[3]);
778
- $rgba[3] = $rgba[3] - ( $opacity / 100 );
779
- $rgba = $rgba[0] . ',' . $rgba[1] . ',' . $rgba[2] . ',' . $rgba[3] . ')';
780
- return $rgba;
781
- }
782
-
783
- list( $red, $green, $blue ) = sscanf( $hex, '#%02x%02x%02x' );
784
-
785
- $r = $red / 255.0;
786
- $g = $green / 255.0;
787
- $b = $blue / 255.0;
788
- $H = 0;
789
- $S = 0;
790
- $V = 0;
791
-
792
- $min = min( $r, $g, $b );
793
- $max = max( $r, $g, $b );
794
- $delta = ( $max - $min );
795
-
796
- $L = ( $max + $min ) / 2.0;
797
-
798
- if( $delta == 0 ) {
799
- $H = 0;
800
- $S = 0;
801
- } else {
802
- $S = $L > 0.5 ? $delta / ( 2 - $max - $min ) : $delta / ( $max + $min );
803
-
804
- $dR = ( ( ( $max - $r ) / 6) + ( $delta / 2 ) ) / $delta;
805
- $dG = ( ( ( $max - $g ) / 6) + ( $delta / 2 ) ) / $delta;
806
- $dB = ( ( ( $max - $b ) / 6) + ( $delta / 2 ) ) / $delta;
807
-
808
- if ( $r == $max )
809
- $H = $dB - $dG;
810
- else if( $g == $max )
811
- $H = ( 1/3 ) + $dR - $dB;
812
- else
813
- $H = ( 2/3 ) + $dG - $dR;
814
-
815
- if ( $H < 0 )
816
- $H += 1;
817
- if ( $H > 1 )
818
- $H -= 1;
819
- }
820
- $HSL = array( 'hue' => round( ($H*360), 0 ), 'saturation'=> round( ($S*100), 0 ), 'luminosity' => round( ( $L*100 ), 0) );
821
- $HSL = 'hsl( '. $HSL['hue'] .', '.( $HSL['saturation']) .'%, '. ( $HSL['luminosity'] - $opacity ) . '%)';
822
- return $HSL;
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
823
 
824
  }
825
 
3
  Plugin Name: CMP - Coming Soon & Maintenance Plugin
4
  Plugin URI: https://wordpress.org/plugins/cmp-coming-soon-maintenance/
5
  Description: Display customizable landing page for Coming Soon, Maintenance & Under Construction page.
6
+ Version: 1.6.0
7
  Author: NiteoThemes
8
  Author URI: http://www.niteo.cz
9
  Text Domain: cmp
16
  class niteo_cmp {
17
  var $installedFolder = '';
18
  var $version = '';
19
+ var $dev;
20
  var $remoteServer = '';
21
  var $theme_array = array();
22
  var $premium_installed = array();
23
 
24
  function __construct() {
25
+ $this->version = '1.6.0';
26
+ $this->dev = false;
27
  $this->installedFolder = basename(dirname(__FILE__));
28
 
29
  // get all installed themes [folder names under /themes] and put them to array
35
  } else {
36
  $this->theme_array = $this->themes_standard;
37
  }
38
+ $this->remoteServer = $this->dev ? 'http://niteo.cz/updates-test/' : 'http://niteo.cz/niteo-updates/';
39
+ // set default settings, if theme is not yet set
40
+ if ( !get_option('niteoCS_theme') ) {
41
+ // set defaults
42
+ update_option('niteoCS_banner', '4');
43
+ update_option('niteoCS_banner_color', '#ffffff');
44
+ update_option('niteoCS_overlay_checkbox[hardwork]', 'false');
45
+ update_option('niteoCS_font_color[hardwork]', '#696969');
46
+ }
47
  }
48
 
49
  function cmp() {
228
 
229
  // check selected theme
230
  function cmp_selectedTheme() {
231
+ return get_option('niteoCS_theme', 'hardwork');
 
 
 
 
232
  }
233
 
234
  // return installed theme path
386
  }
387
 
388
  } else {
389
+ // set transient no update available with 12 hours expire
390
+ set_transient( $theme_slug.'_updatecheck', '', 60*60*12 );
391
  echo '<div class="notice notice-error is-dismissible"><p>'.__('There has been error from remote server: ','cmp').wp_remote_retrieve_response_code($request).' '.__('while checking for','cmp').' '.esc_attr(ucwords(str_replace('_', ' ', $theme_slug))).' '.__('Theme update. Please try again later or contact us at info@niteo.cz if this error message keeps appearing.','cmp').'</p></div>';
392
  }
393
 
394
  } else {
395
+ // set transient no update available with 12 hours expire
396
+ set_transient( $theme_slug.'_updatecheck', '', 60*60*12 );
397
  echo '<div class="notice notice-error is-dismissible"><p>'.__('There has been error: Internal server error:','cmp').' '.$request->get_error_message().' '.__('while checking for Theme update. Please try again later or contact us at info@niteo.cz if this error message keeps appearing.','cmp').'</p></div>';
398
 
399
  }
424
  $filetype = wp_check_filetype( $filename );
425
 
426
  if ( $filetype['ext'] == 'zip' ) {
 
427
  // Upload file
428
  $movefile = wp_handle_upload( $uploadedfile, array('test_form' => FALSE) );
429
 
621
  case '0':
622
  // check if $query contains unsplash.com url
623
  if ( strpos( $url, 'unsplash.com' ) !== false ) {
624
+ $parts = parse_url( $url );
625
 
626
  // check for photo parameter in URL
627
  parse_str($parts['query'], $query);
628
  $id = $query['photo'];
629
+
630
  // if no ID found, get last part of URL containing ID
631
  if ( is_null( $id ) ) {
632
 
781
  // convert hex to hsl css
782
  function hex2hsl( $hex, $opacity ) {
783
 
784
+ if ( $hex[0] != '#' ) {
785
+ $rgba = explode( ',', $hex);
786
+ $rgba[3] = str_replace(')', '', $rgba[3]);
787
+ $rgba[3] = $rgba[3] - ( $opacity / 100 );
788
+ $rgba = $rgba[0] . ',' . $rgba[1] . ',' . $rgba[2] . ',' . $rgba[3] . ')';
789
+ return $rgba;
790
+ }
791
+
792
+ list( $red, $green, $blue ) = sscanf( $hex, '#%02x%02x%02x' );
793
+
794
+ $r = $red / 255.0;
795
+ $g = $green / 255.0;
796
+ $b = $blue / 255.0;
797
+ $H = 0;
798
+ $S = 0;
799
+ $V = 0;
800
+
801
+ $min = min( $r, $g, $b );
802
+ $max = max( $r, $g, $b );
803
+ $delta = ( $max - $min );
804
+
805
+ $L = ( $max + $min ) / 2.0;
806
+
807
+ if( $delta == 0 ) {
808
+ $H = 0;
809
+ $S = 0;
810
+ } else {
811
+ $S = $L > 0.5 ? $delta / ( 2 - $max - $min ) : $delta / ( $max + $min );
812
+
813
+ $dR = ( ( ( $max - $r ) / 6) + ( $delta / 2 ) ) / $delta;
814
+ $dG = ( ( ( $max - $g ) / 6) + ( $delta / 2 ) ) / $delta;
815
+ $dB = ( ( ( $max - $b ) / 6) + ( $delta / 2 ) ) / $delta;
816
+
817
+ if ( $r == $max )
818
+ $H = $dB - $dG;
819
+ else if( $g == $max )
820
+ $H = ( 1/3 ) + $dR - $dB;
821
+ else
822
+ $H = ( 2/3 ) + $dG - $dR;
823
+
824
+ if ( $H < 0 )
825
+ $H += 1;
826
+ if ( $H > 1 )
827
+ $H -= 1;
828
+ }
829
+
830
+
831
+
832
+ $HSL = array( 'hue' => round( ($H*360), 0 ), 'saturation'=> round( ($S*100), 0 ), 'luminosity' => round( ( $L*100 ), 0) );
833
+
834
+ // if color is white {
835
+ if ( $HSL['hue'] == 0 && $HSL['saturation'] == 0) {
836
+ $requested_lumi = $HSL['luminosity'] + $opacity;
837
+ } else {
838
+ $requested_lumi = $HSL['luminosity'] - $opacity;
839
+ }
840
+
841
+ $requested_lumi = (int)round($requested_lumi);
842
+
843
+ if ( $requested_lumi > 90 ) {
844
+
845
+ $requested_lumi = 90;
846
+ }
847
+
848
+ $HSL = 'hsl( '. $HSL['hue'] .', '.( $HSL['saturation']) .'%, '. $requested_lumi . '%)';
849
+ return $HSL;
850
 
851
  }
852
 
readme.txt CHANGED
@@ -4,7 +4,7 @@ Donate link: https://www.paypal.com/cgi-bin/webscr?cmd=_donations&business=KV2JF
4
  Tags: under construction, construction page, maintenance mode, landing page, launch page, launching, security, coming soon, customizable, offline, offline page, unavailable, free, unsplash, subscribe form
5
  Requires at least: 3.0
6
  Tested up to: 4.7.4
7
- Stable tag: 1.5.1
8
  License: GPLv2 or later
9
  License URI: https://www.gnu.org/licenses/gpl-2.0.html
10
 
@@ -16,26 +16,30 @@ Free plugin to create and customize your own Coming Soon or Maintenance landing
16
 
17
  <h3>Preview</h3>
18
  <a href="http://cmp.niteo.cz/?cmp_preview=true&theme=construct" target="_blank">Click for preview of Construct Theme >></a><br>
19
- <a href="http://cmp.niteo.cz/?cmp_preview=true&theme=hardwork" target="_blank">Click for preview of Hardwork Theme >></a>
20
- <a href="http://cmp.niteo.cz/?cmp_preview=true&theme=hardwork_premium" target="_blank">Click for preview of Hardwork Premium Theme >></a>
21
- <a href="http://cmp.niteo.cz/?cmp_preview=true&theme=frame" target="_blank">Click for preview of Frame Theme >></a>
22
- <a href="http://cmp.niteo.cz/?cmp_preview=true&theme=fifty" target="_blank">Click for preview of Fifty Theme >></a>
 
 
 
 
 
 
23
 
24
  <h3>Features</h3>
25
  <ul>
26
- <li>Works with any WordPress Theme</li>
27
- <li>Responsive and Retina ready</li>
28
- <li>Works on all devices</li>
29
- <li>Setup custom Social Icons</li>
30
- <li>Customize Logo, Fonts and Colors</li>
31
- <li>Subscribe form works with any 3rd party plugin(Mailchimp, etc)</li>
32
- <li>Custom Subscribe form to store emails in custom database with export to csv</li>
33
- <li>Select and Display random beautiful images from <a href="http://unsplash.com" target="_blank">Unsplash source</a> with built-in search API or use custom photos</li>
34
- <li>Customize SEO meta tags to search engines</li>
35
- <li>Set response code to search engines</li>
36
  <li>Insert Google Analytics Code</li>
37
  <li>Insert Custom CSS</li>
38
- <li>Uses HTML5 & CSS3</li>
39
  <li>Extandable by downloadable Themes.</li>
40
  <li>Translation Ready</li>
41
  </ul>
@@ -61,16 +65,6 @@ Free plugin to create and customize your own Coming Soon or Maintenance landing
61
  <li>To Setup click Settings->CMP Settings and change the settings there</li>
62
  </ul>
63
 
64
- <h3>FTP Upload</h3>
65
- <ul>
66
- <li>Navigate to the 'Add New' in the plugins dashboard</li>
67
- <li>Navigate to the 'Upload' area</li>
68
- <li>Download <code>comingsoon.zip</code> and extract the <code>comingsoon.zip</code> zip file to your computer</li>
69
- <li>Upload the extracted <code>comingsoon</code> directory to the <code>/wp-content/plugins/</code> directory</li>
70
- <li>Activate the plugin in the Plugin dashboard</li>
71
- <li>To Setup click Settings->CMP Settings and change the settings there</li>
72
- </ul>
73
-
74
 
75
  == Screenshots ==
76
  1. CMP - Coming Soon Construct Theme
@@ -100,15 +94,19 @@ Free plugin to create and customize your own Coming Soon or Maintenance landing
100
 
101
 
102
  == Changelog ==
 
103
  <ul>
104
- <li>Updated CMP Settings change when Social Inputs Labels where out of its correct positions.</li>
105
- <li>Updated logic of CMP Theme Update Checker - set to check every 24 hours instead of every time when CMP Settings page was accessed.</li>
 
106
  </ul>
 
107
  <h4>1.5.1</h4>
108
  <ul>
109
  <li>Updated CMP Settings change when Social Inputs Labels where out of its correct positions.</li>
110
  <li>Updated logic of CMP Theme Update Checker - set to check every 24 hours instead of every time when CMP Settings page was accessed.</li>
111
  </ul>
 
112
  <h4>1.5.0</h4>
113
  <ul>
114
  <li>New auto update feature for all Themes.</li>
@@ -118,41 +116,49 @@ Free plugin to create and customize your own Coming Soon or Maintenance landing
118
  <li>Many small enhancements in UI settings.</li>
119
  <li>Resolved bug: Default Theme Graphic Banner no longer dissappears when Custom Media were uploaded and deleted in CMP Options.</li>
120
  </ul>
 
121
  <h4>1.4.1</h4>
122
  <ul>
123
  <li>Resolved bug: Not possible to save Social profiles URLs after release of update 1.4.0.</li>
124
  </ul>
 
125
  <h4>1.4.0</h4>
126
  <ul>
127
  <li>New Feature: It is now possible to drag&drop the social menu icons position and enable/disable them.</li>
128
  <li>New Feature: Fifty theme can have two position of social icons: Footer and Body content.</li>
129
  <li>Resolved bug : Specific Theme options are now always correctly displayed right after Theme selection change.</li>
130
  </ul>
 
131
  <h4>1.3.0</h4>
132
  <ul>
133
  <li>New premium theme: Fifty.</li>
134
  <li>Updated CSS styles for all free and premium Themes.</li>
135
  <li>Migrated Thumbnails from comingsoon to cmp domain.</li>
136
  </ul>
 
137
  <h4>1.2.1</h4>
138
  <ul>
139
  <li>Resolved issue when plugin update caused deletion of installed Premium themes.</li>
140
  </ul>
 
141
  <h4>1.2.0</h4>
142
  <ul>
143
  <li>New premium theme: Hardwork Premium</li>
144
  <li>Small changes in CMP-Settings page.</li>
145
  </ul>
 
146
  <h4>1.1.0</h4>
147
  <ul>
148
  <li>New premium theme: CMP Frame</li>
149
  <li>Added option to display Label for default CMP Subscribe form.</li>
150
  <li>Small changes in CMP-Settings page.</li>
151
  </ul>
 
152
  <h4>1.0.1</h4>
153
  <ul>
154
  <li>Resolved bug with save settings on old PHP version.</li>
155
  </ul>
 
156
  <h4>1.0.0</h4>
157
  <ul>
158
  <li>Initial release</li>
4
  Tags: under construction, construction page, maintenance mode, landing page, launch page, launching, security, coming soon, customizable, offline, offline page, unavailable, free, unsplash, subscribe form
5
  Requires at least: 3.0
6
  Tested up to: 4.7.4
7
+ Stable tag: 1.6.0
8
  License: GPLv2 or later
9
  License URI: https://www.gnu.org/licenses/gpl-2.0.html
10
 
16
 
17
  <h3>Preview</h3>
18
  <a href="http://cmp.niteo.cz/?cmp_preview=true&theme=construct" target="_blank">Click for preview of Construct Theme >></a><br>
19
+
20
+ <a href="http://cmp.niteo.cz/?cmp_preview=true&theme=hardwork" target="_blank">Click for preview of Hardwork Theme >></a><br>
21
+
22
+ <a href="http://cmp.niteo.cz/?cmp_preview=true&theme=countdown" target="_blank">Click for preview of Countdown Theme >></a><br>
23
+
24
+ <a href="http://cmp.niteo.cz/?cmp_preview=true&theme=hardwork_premium" target="_blank">Click for preview of Hardwork Premium Theme >></a><br>
25
+
26
+ <a href="http://cmp.niteo.cz/?cmp_preview=true&theme=frame" target="_blank">Click for preview of Frame Theme >></a><br>
27
+
28
+ <a href="http://cmp.niteo.cz/?cmp_preview=true&theme=fifty" target="_blank">Click for preview of Fifty Theme >></a><br>
29
 
30
  <h3>Features</h3>
31
  <ul>
32
+ <li>Works with any WordPress Theme as Landing page to not logged-in visitors of your page</li>
33
+ <li>Works on all devices, 100% responsive and Retina ready</li>
34
+ <li>Insert Custom Logo and content vith Wordpress Rich Editor</li>
35
+ <li>Customize colors and choose from hundreds of Google Fonts</li>
36
+ <li>Setup custom Social Icons from all social networks</li>
37
+ <li>Display our custom Subscribe form with .csv export or you can insert any 3rd party plugin(Mailchimp, etc) Subscribe form.</li>
38
+ <li>Browse and Display random hi-res images from <a href="http://unsplash.com" target="_blank">Unsplash source</a> with built-in search API or you can use custom photos for backgrounds.</li>
39
+ <li>Customize SEO meta tags for search engines</li>
40
+ <li>Set response code (200, 503) for search engines</li>
 
41
  <li>Insert Google Analytics Code</li>
42
  <li>Insert Custom CSS</li>
 
43
  <li>Extandable by downloadable Themes.</li>
44
  <li>Translation Ready</li>
45
  </ul>
65
  <li>To Setup click Settings->CMP Settings and change the settings there</li>
66
  </ul>
67
 
 
 
 
 
 
 
 
 
 
 
68
 
69
  == Screenshots ==
70
  1. CMP - Coming Soon Construct Theme
94
 
95
 
96
  == Changelog ==
97
+ <h4>1.6.0</h4>
98
  <ul>
99
+ <li>New free theme: Countdown</li>
100
+ <li>Added 8 more free background patterns.</li>
101
+ <li>Many small CMP Settings page UI changes.</li>
102
  </ul>
103
+
104
  <h4>1.5.1</h4>
105
  <ul>
106
  <li>Updated CMP Settings change when Social Inputs Labels where out of its correct positions.</li>
107
  <li>Updated logic of CMP Theme Update Checker - set to check every 24 hours instead of every time when CMP Settings page was accessed.</li>
108
  </ul>
109
+
110
  <h4>1.5.0</h4>
111
  <ul>
112
  <li>New auto update feature for all Themes.</li>
116
  <li>Many small enhancements in UI settings.</li>
117
  <li>Resolved bug: Default Theme Graphic Banner no longer dissappears when Custom Media were uploaded and deleted in CMP Options.</li>
118
  </ul>
119
+
120
  <h4>1.4.1</h4>
121
  <ul>
122
  <li>Resolved bug: Not possible to save Social profiles URLs after release of update 1.4.0.</li>
123
  </ul>
124
+
125
  <h4>1.4.0</h4>
126
  <ul>
127
  <li>New Feature: It is now possible to drag&drop the social menu icons position and enable/disable them.</li>
128
  <li>New Feature: Fifty theme can have two position of social icons: Footer and Body content.</li>
129
  <li>Resolved bug : Specific Theme options are now always correctly displayed right after Theme selection change.</li>
130
  </ul>
131
+
132
  <h4>1.3.0</h4>
133
  <ul>
134
  <li>New premium theme: Fifty.</li>
135
  <li>Updated CSS styles for all free and premium Themes.</li>
136
  <li>Migrated Thumbnails from comingsoon to cmp domain.</li>
137
  </ul>
138
+
139
  <h4>1.2.1</h4>
140
  <ul>
141
  <li>Resolved issue when plugin update caused deletion of installed Premium themes.</li>
142
  </ul>
143
+
144
  <h4>1.2.0</h4>
145
  <ul>
146
  <li>New premium theme: Hardwork Premium</li>
147
  <li>Small changes in CMP-Settings page.</li>
148
  </ul>
149
+
150
  <h4>1.1.0</h4>
151
  <ul>
152
  <li>New premium theme: CMP Frame</li>
153
  <li>Added option to display Label for default CMP Subscribe form.</li>
154
  <li>Small changes in CMP-Settings page.</li>
155
  </ul>
156
+
157
  <h4>1.0.1</h4>
158
  <ul>
159
  <li>Resolved bug with save settings on old PHP version.</li>
160
  </ul>
161
+
162
  <h4>1.0.0</h4>
163
  <ul>
164
  <li>Initial release</li>
themes/construct/construct-theme.php CHANGED
@@ -17,7 +17,7 @@
17
 
18
  <?php
19
  // get saved style options
20
- $ver = '1.5';
21
  $active_color = get_option('niteoCS_active_color[construct]', '#f37004');
22
  $font_color = get_option('niteoCS_font_color[construct]', '#686868');
23
  $background_color = get_option('niteoCS_background_color[construct]', '#ffffff');
@@ -28,8 +28,8 @@
28
  $niteoCS_banner = get_option('niteoCS_banner', '2');
29
  $unplash_feed = get_option('niteoCS_unsplash_feed', '0');
30
  $body_title = get_option('niteoCS_body_title', 'SOMETHING IS HAPPENING!');
31
- $subscribe = get_option('niteoCS_subscribe_type', '0');
32
- $niteoCS_subscribe_label= get_option('niteoCS_subscribe_label');
33
  $copyright = get_option('niteoCS_copyright', 'Copyright 2017 NiteoThemes. All rights reserved.');
34
  $social_title = get_option('niteoCS_soc_title', 'GET SOCIAL WITH US');
35
 
@@ -208,12 +208,16 @@
208
  break;
209
 
210
  case '3':
 
211
  // Pattern
212
  $background_class = 'pattern';
213
  $niteoCS_banner_pattern = get_option('niteoCS_banner_pattern', 'sakura');
214
 
215
  if ($niteoCS_banner_pattern != 'custom') {
216
- $banner_url = str_replace('themes', '', plugin_dir_url( dirname( __FILE__ ) )) . 'img/patterns/'.esc_attr($niteoCS_banner_pattern).'.png';
 
 
 
217
  } else {
218
  $banner_url = get_option('niteoCS_banner_pattern_custom');
219
  }
17
 
18
  <?php
19
  // get saved style options
20
+ $ver = '1.6';
21
  $active_color = get_option('niteoCS_active_color[construct]', '#f37004');
22
  $font_color = get_option('niteoCS_font_color[construct]', '#686868');
23
  $background_color = get_option('niteoCS_background_color[construct]', '#ffffff');
28
  $niteoCS_banner = get_option('niteoCS_banner', '2');
29
  $unplash_feed = get_option('niteoCS_unsplash_feed', '0');
30
  $body_title = get_option('niteoCS_body_title', 'SOMETHING IS HAPPENING!');
31
+ $subscribe = get_option('niteoCS_subscribe_type', '2');
32
+ $niteoCS_subscribe_label = get_option('niteoCS_subscribe_label', 'Type your email and get notified');
33
  $copyright = get_option('niteoCS_copyright', 'Copyright 2017 NiteoThemes. All rights reserved.');
34
  $social_title = get_option('niteoCS_soc_title', 'GET SOCIAL WITH US');
35
 
208
  break;
209
 
210
  case '3':
211
+ // Pattern
212
  // Pattern
213
  $background_class = 'pattern';
214
  $niteoCS_banner_pattern = get_option('niteoCS_banner_pattern', 'sakura');
215
 
216
  if ($niteoCS_banner_pattern != 'custom') {
217
+ $banner_url = plugins_url('cmp-coming-soon-maintenance/img/patterns/'.esc_attr($niteoCS_banner_pattern).'.png');
218
+ // echo copyright pattern
219
+ echo '<!-- Background pattern from Subtle Patterns --!>';
220
+
221
  } else {
222
  $banner_url = get_option('niteoCS_banner_pattern_custom');
223
  }
themes/construct/img/construct_banner_full.jpg CHANGED
Binary file
themes/construct/style.css CHANGED
@@ -3,7 +3,7 @@ Theme Name: Construct
3
  Theme URI: http://cmp.niteo.cz/?cmp_preview=true&theme=construct
4
  Author: Niteo
5
  Author URI: http://niteo.cz/
6
- Version: 1.5
7
  Description: Premium Theme for CMP Coming Soon & Maintenance plugin
8
  Text Domain: niteo
9
 
@@ -11,12 +11,33 @@ Normalizing styles have been helped along thanks to the fine work of
11
  Nicolas Gallagher and Jonathan Neal http://necolas.github.com/normaalize.css/
12
  */
13
 
14
- body{margin:0;}
 
 
 
 
 
 
15
  :focus {outline:none;}
16
  h1,h2,h3,h4,h5,h6{font-weight: 400;font-size:2em;}
17
- .section {padding: 50px 2em;text-align: center;position: relative;}
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
18
  .section-logo {max-width: 500px; margin: 0 auto;}
19
- .section-logo img {max-width: 100%;}
20
  .section-banner{height: 300px;}
21
  .section-body p{width:70%;max-width: 900px;margin:1em auto;}
22
  .section-social{background-color: #f8f8f8;}
3
  Theme URI: http://cmp.niteo.cz/?cmp_preview=true&theme=construct
4
  Author: Niteo
5
  Author URI: http://niteo.cz/
6
+ Version: 1.6
7
  Description: Premium Theme for CMP Coming Soon & Maintenance plugin
8
  Text Domain: niteo
9
 
11
  Nicolas Gallagher and Jonathan Neal http://necolas.github.com/normaalize.css/
12
  */
13
 
14
+ body {
15
+ display: flex;
16
+ flex-direction: column;
17
+ margin: 0;
18
+ min-height: 100vh;
19
+ }
20
+
21
  :focus {outline:none;}
22
  h1,h2,h3,h4,h5,h6{font-weight: 400;font-size:2em;}
23
+ .section {padding: 50px 2em;text-align: center;
24
+ position: relative;
25
+ display: -webkit-flex;
26
+ display: -moz-flex;
27
+ display: -ms-flex;
28
+ display: -o-flex;
29
+ display: flex;
30
+ justify-content: center;
31
+ -moz-justify-content: center;
32
+ -webkit-justify-content: center;
33
+ -webkit-flex-direction: column;
34
+ -moz-flex-direction: column;
35
+ flex-direction: column;
36
+ flex-grow: 1;
37
+ -webkit-flex-grow: 1;
38
+ -moz-flex-grow: 1;}
39
  .section-logo {max-width: 500px; margin: 0 auto;}
40
+ .section-logo img {max-width: 100%;max-height: 300px;}
41
  .section-banner{height: 300px;}
42
  .section-body p{width:70%;max-width: 900px;margin:1em auto;}
43
  .section-social{background-color: #f8f8f8;}
themes/countdown/countdown-settings.php ADDED
@@ -0,0 +1,234 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ defined( 'ABSPATH' ) or die( 'No script kiddies please!' );
3
+
4
+ // check onces and wordpress rights, else DIE
5
+ if ( $_SERVER['REQUEST_METHOD'] == 'POST' ) {
6
+ if( !wp_verify_nonce($_POST['save_options_field'], 'save_options') || !current_user_can('publish_pages') ) {
7
+ die('Sorry, but this request is invalid');
8
+ }
9
+ }
10
+ // register and enqueue admin needed scripts
11
+ wp_register_script('countdown_flatpicker_js', $this->cmp_themeDirPath().'/countdown/js/flatpickr.min.js');
12
+ wp_register_style( 'countdown_flatpicker_css', $this->cmp_themeDirPath().'/countdown/css/flatpickr.min.css');
13
+ wp_enqueue_script('countdown_flatpicker_js');
14
+ wp_enqueue_style( 'countdown_flatpicker_css');
15
+
16
+
17
+ if (isset($_POST['niteoCS_active_color_countdown'])) {
18
+ update_option('niteoCS_active_color[countdown]', sanitize_hex_color($_POST['niteoCS_active_color_countdown']));
19
+ }
20
+
21
+ if (isset($_POST['niteoCS_font_color_countdown'])) {
22
+ update_option('niteoCS_font_color[countdown]', sanitize_hex_color($_POST['niteoCS_font_color_countdown']));
23
+ }
24
+
25
+ if (isset($_POST['niteoCS_overlay_color_countdown'])) {
26
+ update_option('niteoCS_overlay_color[countdown]', sanitize_hex_color($_POST['niteoCS_overlay_color_countdown']));
27
+ }
28
+
29
+ if (isset($_POST['niteoCS_overlay_opacity_countdown'])) {
30
+ update_option('niteoCS_overlay_opacity[countdown]', sanitize_text_field($_POST['niteoCS_overlay_opacity_countdown']));
31
+ }
32
+
33
+ if (isset($_POST['niteoCS_counter']) && is_numeric($_POST['niteoCS_counter'])) {
34
+ update_option('niteoCS_counter', sanitize_text_field($_POST['niteoCS_counter']));
35
+ }
36
+
37
+ if (isset($_POST['niteoCS_counter_date'])) {
38
+ update_option('niteoCS_counter_date', sanitize_text_field($_POST['niteoCS_counter_date']));
39
+ }
40
+
41
+ if (isset($_POST['niteoCS_countdown_action'])) {
42
+ update_option('niteoCS_countdown_action', sanitize_text_field($_POST['niteoCS_countdown_action']));
43
+ }
44
+
45
+ if (isset($_POST['niteoCS_countdown_text'])) {
46
+ update_option('niteoCS_countdown_text', sanitize_text_field($_POST['niteoCS_countdown_text']));
47
+ }
48
+
49
+ if (isset($_POST['niteoCS_countdown_redirect'])) {
50
+ update_option('niteoCS_countdown_redirect', esc_url_raw($_POST['niteoCS_countdown_redirect']));
51
+ }
52
+
53
+ // get options
54
+ $niteoCS_active_color = get_option('niteoCS_active_color[countdown]', '#E85C4F');
55
+ $niteoCS_font_color = get_option('niteoCS_font_color[countdown]', '#ffffff');
56
+ $niteoCS_overlay_color = get_option('niteoCS_overlay_color[countdown]', '#0a0a0a');
57
+ $niteoCS_overlay_opacity = get_option('niteoCS_overlay_opacity[countdown]', '0.0');
58
+ $niteoCS_counter = get_option('niteoCS_counter', '0');
59
+ $niteoCS_counter_date = get_option('niteoCS_counter_date');
60
+ $niteoCS_countdown_action = get_option('niteoCS_countdown_action', 'no-action');
61
+ $niteoCS_countdown_text = get_option('niteoCS_countdown_text');
62
+ $niteoCS_countdown_redirect = get_option('niteoCS_countdown_redirect');
63
+
64
+ ?>
65
+
66
+ <style>
67
+ #social-section tr:first-of-type {display: none!important;}
68
+ .flatpickr-input {width: 50%;margin-bottom: 1em;}
69
+ #niteoCS_countdown_text,
70
+ #niteoCS_countdown_redirect {display: none;}
71
+ </style>
72
+
73
+ <div class="table-wrapper content">
74
+ <h3><?php _e('Countdown Timer Setup', 'cmp');?></h3>
75
+ <table class="content">
76
+ <tr>
77
+ <th>
78
+ <fieldset>
79
+ <legend class="screen-reader-text">
80
+ <span><?php _e('Counter setup', 'cmp');?></span>
81
+ </legend>
82
+
83
+ <p>
84
+ <label title="Enabled">
85
+ <input type="radio" name="niteoCS_counter" value="1"<?php if ( $niteoCS_counter == 1) { echo ' checked="checked"'; } ?>>&nbsp;<?php _e('Enabled', 'cmp');?>
86
+ </label>
87
+ </p>
88
+
89
+ <p>
90
+ <label title="Disabled">
91
+ <input type="radio" name="niteoCS_counter" value="0"<?php if ( $niteoCS_counter == 0) { echo ' checked="checked"'; } ?>>&nbsp;<?php _e('Disabled', 'cmp');?>
92
+ </label>
93
+ </p>
94
+
95
+ </fieldset>
96
+ </th>
97
+
98
+ <td id="counter-disabled">
99
+ <p><?php _e('Countdown Timer is disabled.', 'cmp');?></p>
100
+ </td>
101
+
102
+ <td id="counter-enabled">
103
+ <p><?php _e('Click on date input and set a date & time for a Countdown timer.', 'cmp');?></p>
104
+ <fieldset>
105
+ <legend class="screen-reader-text">
106
+ <span><?php _e('Counter setup', 'cmp');?></span>
107
+ </legend>
108
+
109
+ <input type="text" name="niteoCS_counter_date" id="niteoCS_counter_date" placeholder="<?php _e('Select Date..','cmp');?>" value="<?php echo esc_attr( $niteoCS_counter_date); ?>" class="regular-text code"><br>
110
+
111
+ <label for="niteoCS_countdown_action"><?php _e('Countdown action:', 'cmp');?></label>
112
+ <select name="niteoCS_countdown_action">
113
+ <option value="no-action" <?php if ( $niteoCS_countdown_action == 'no-action' ) { echo ' selected="selected"'; } ?>><?php _e('No action', 'cmp');?></option>
114
+ <!-- <option value="display-text" <?php if ( $niteoCS_countdown_action == 'display-text' ) { echo ' selected="selected"'; } ?>><?php _e('Display custom text', 'cmp');?></option> -->
115
+ <option value="disable-cmp" <?php if ( $niteoCS_countdown_action == 'disable-cmp' ) { echo ' selected="selected"'; } ?>><?php _e('Disable CMP Plugin Page', 'cmp');?></option>
116
+ <option value="redirect" <?php if ( $niteoCS_countdown_action == 'redirect' ) { echo ' selected="selected"'; } ?>><?php _e('URL redirect', 'cmp');?></option>
117
+ </select>
118
+
119
+ <label for="niteoCS_countdown_text" id="niteoCS_countdown_text"><?php _e('Enter custom text', 'cmp');?>
120
+ <input type="text" name="niteoCS_countdown_text" value="<?php echo esc_attr( $niteoCS_countdown_text); ?>" class="regular-text code"><br>
121
+ </label>
122
+
123
+ <label for="niteoCS_countdown_redirect" id="niteoCS_countdown_redirect"><?php _e('Enter redirect URL', 'cmp');?>
124
+ <input type="text" name="niteoCS_countdown_redirect" value="<?php echo esc_url( $niteoCS_countdown_redirect); ?>" class="regular-text code"><br>
125
+ </label>
126
+ </fieldset>
127
+ </td>
128
+ </tr>
129
+ </table>
130
+ </div>
131
+
132
+ <div class="table-wrapper content">
133
+ <h3><?php _e('Customize Colors', 'cmp');?></h3>
134
+ <table class="customization">
135
+ <tr>
136
+ <th><h4><?php _e('Active Color', 'cmp');?></h4></th>
137
+ <td>
138
+
139
+ <fieldset>
140
+ <input type="text" name="niteoCS_active_color_countdown" id="niteoCS_active_color" value="<?php echo esc_attr( $niteoCS_active_color); ?>" data-default-color="#e82e1e" class="regular-text code"><br>
141
+ </fieldset>
142
+
143
+ </td>
144
+ </tr>
145
+ <tr>
146
+ <th><h4><?php _e('Font Color', 'cmp');?></h4></th>
147
+ <td>
148
+
149
+ <fieldset>
150
+ <input type="text" name="niteoCS_font_color_countdown" id="niteoCS_font_color" value="<?php echo esc_attr( $niteoCS_font_color); ?>" data-default-color="#ffffff" class="regular-text code"><br>
151
+ </fieldset>
152
+ </td>
153
+ </tr>
154
+ <tr>
155
+ <th><h4><?php _e('Overlay Color', 'cmp');?></h4></th>
156
+ <td>
157
+
158
+ <fieldset id="overlay-color">
159
+ <input type="text" name="niteoCS_overlay_color_countdown" id="niteoCS_overlay_color" value="<?php echo esc_attr( $niteoCS_overlay_color); ?>" data-default-color="#0a0a0a" class="regular-text code"><br>
160
+
161
+ <label for="niteoCS_overlay_opacity"><?php _e('Overlay Opacity', 'cmp');?> <span id="current-opacity">: <?php echo esc_attr( $niteoCS_overlay_opacity); ?></span></label><br>
162
+ <input type="range" id="niteoCS_overlay_opacity" name="niteoCS_overlay_opacity_countdown" min="0" max="1" step="0.1"value="<?php echo esc_attr( $niteoCS_overlay_opacity); ?>" />
163
+
164
+ </fieldset>
165
+ </td>
166
+ </tr>
167
+ </table>
168
+ </div>
169
+
170
+
171
+ <script>
172
+ jQuery(document).ready(function($){
173
+
174
+ // enable-disable counter
175
+ $('#csoptions input[name="niteoCS_counter"]').bind('change', function(){
176
+ if ( jQuery('#csoptions input[name="niteoCS_counter"]:checked' ).val() == 0 ) {
177
+ jQuery('#counter-disabled').css('display','block');
178
+ jQuery('#counter-enabled').css('display','none');
179
+
180
+ } else if ( jQuery('#csoptions input[name="niteoCS_counter"]:checked' ).val() == 1 ) {
181
+ jQuery('#counter-disabled').css('display','none');
182
+ jQuery('#counter-enabled').css('display','block');
183
+ }
184
+ });
185
+ jQuery('#csoptions input[name="niteoCS_counter"]').trigger('change');
186
+
187
+
188
+ // set countdown action
189
+ $('#csoptions select[name="niteoCS_countdown_action"]').bind('change', function(){
190
+ if ( jQuery('#csoptions select[name="niteoCS_countdown_action"]' ).val() == 'display-text' ) {
191
+ jQuery('#niteoCS_countdown_text').css('display','block');
192
+ jQuery('#niteoCS_countdown_redirect').css('display','none');
193
+
194
+ } else if ( jQuery('#csoptions select[name="niteoCS_countdown_action"]' ).val() == 'redirect' ) {
195
+ jQuery('#niteoCS_countdown_text').css('display','none');
196
+ jQuery('#niteoCS_countdown_redirect').css('display','block');
197
+ } else {
198
+ jQuery('#niteoCS_countdown_text').css('display','none');
199
+ jQuery('#niteoCS_countdown_redirect').css('display','none')
200
+ }
201
+ });
202
+ jQuery('#csoptions select[name="niteoCS_countdown_action"]').trigger('change');
203
+
204
+ // ini color picker
205
+ jQuery('#niteoCS_font_color').wpColorPicker();
206
+ jQuery('#niteoCS_background_color').wpColorPicker();
207
+ jQuery('#niteoCS_active_color').wpColorPicker();
208
+ jQuery('#niteoCS_overlay_color').wpColorPicker();
209
+
210
+ var currentValue = jQuery('#current-opacity');
211
+
212
+ jQuery('#niteoCS_overlay_opacity').change(function(){
213
+ currentValue.html(this.value);
214
+ });
215
+ <?php
216
+ if ( $niteoCS_counter_date != '') { ?>
217
+ var date = new Date(<?php echo esc_attr($niteoCS_counter_date);?>*1000);
218
+ <?php
219
+ } else { ?>
220
+ var date = false;
221
+ <?php
222
+ } ?>
223
+ // flatpicker
224
+ $('#niteoCS_counter_date').flatpickr({
225
+ minDate: 'today',
226
+ defaultDate: date,
227
+ enableTime: true,
228
+ altInput: true,
229
+ dateFormat: 'U'
230
+ });
231
+
232
+
233
+ });
234
+ </script>
themes/countdown/countdown-social_settings.php ADDED
@@ -0,0 +1,29 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ defined( 'ABSPATH' ) or die( 'No script kiddies please!' );
3
+
4
+ // check onces and wordpress rights, else DIE
5
+ if ( $_SERVER['REQUEST_METHOD'] == 'POST' ) {
6
+ if( !wp_verify_nonce($_POST['save_options_field'], 'save_options') || !current_user_can('publish_pages') ) {
7
+ die('Sorry, but this request is invalid');
8
+ }
9
+ }
10
+
11
+
12
+ if (isset($_POST['social_location']) && $_POST['social_location']) {
13
+ update_option('social_location', sanitize_text_field($_POST['social_location']));
14
+ }
15
+
16
+ $social_location = get_option('social_location', 'footer');
17
+
18
+ ?>
19
+ <tr>
20
+ <th><h4><?php _e('Social Icons Location', 'cmp');?></h4></th>
21
+ <td>
22
+ <fieldset>
23
+ <select name="social_location">
24
+ <option value="body" <?php if ( $social_location == 'body' ) { echo ' selected="selected"'; } ?>><?php _e('Below Content (big icons)', 'cmp');?></option>
25
+ <option value="footer" <?php if ( $social_location == 'footer' ) { echo ' selected="selected"'; } ?>><?php _e('Footer (small icons)', 'cmp');?></option>
26
+ </select>
27
+ </fieldset>
28
+ </td>
29
+ </tr>
themes/countdown/countdown-theme.php ADDED
@@ -0,0 +1,492 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ if ( $_SERVER['REQUEST_METHOD'] == 'POST' && $_POST['form_honeypot'] === '' && isset( $_POST['EMAIL'] ) && is_email( $_POST['EMAIL'] ) ) {
3
+ $subscribe_response = $this->niteo_subscribe( $_POST['EMAIL'] );
4
+ }
5
+ ?>
6
+ <!DOCTYPE html>
7
+
8
+ <html <?php language_attributes(); ?>>
9
+ <head>
10
+ <meta charset="<?php bloginfo( 'charset' ); ?>">
11
+ <meta name="viewport" content="width=device-width, initial-scale=1">
12
+
13
+ <!-- SEO -->
14
+ <meta name="description" content="<?php echo esc_attr( stripslashes(get_option('niteoCS_descr', 'Just another Coming Soon Page')) ); ?>">
15
+ <title><?php echo esc_html( stripslashes(get_option('niteoCS_title', get_bloginfo('name').' is coming soon!')) ); ?></title>
16
+
17
+ <?php
18
+ // get saved style options
19
+ $ver = '1.1';
20
+ $niteoCS_active_color = get_option('niteoCS_active_color[countdown]', '#e82e1e');
21
+ $niteoCS_font_color = get_option('niteoCS_font_color[countdown]', '#3a3a3a');
22
+ $niteoCS_font_color_light = $this->hex2hsl($niteoCS_font_color, '-30');
23
+ $niteoCS_overlay_color = get_option('niteoCS_overlay_color[countdown]', '#0a0a0a');
24
+ $niteoCS_overlay_opacity = get_option('niteoCS_overlay_opacity[countdown]', '0.0');
25
+ $background_overlay = $this->hex2rgba($niteoCS_overlay_color, $niteoCS_overlay_opacity);
26
+ $content_font = get_option('niteoCS_font_content', 'Raleway');
27
+ // get saved content options
28
+ $logo_id = get_option('niteoCS_logo_id');
29
+ $niteoCS_banner = get_option('niteoCS_banner', '3');
30
+ $unplash_feed = get_option('niteoCS_unsplash_feed', '0');
31
+ $subscribe = get_option('niteoCS_subscribe_type', '2');
32
+ $niteoCS_subscribe_label = get_option('niteoCS_subscribe_label', 'Type your email and get notified');
33
+ $niteoCS_counter = get_option('niteoCS_counter');
34
+ $niteoCS_counter_date = get_option('niteoCS_counter_date', date("Y-m-d"));
35
+ $countdown_action = get_option('niteoCS_countdown_action', 'no-action');
36
+ $body_title = get_option('niteoCS_body_title', 'SOMETHING IS HAPPENING!');
37
+ $body = get_option('niteoCS_body');
38
+ $copyright = get_option('niteoCS_copyright', 'Copyright 2017 NiteoThemes. All rights reserved.');
39
+
40
+ if ( $content_font == 'custom' ) {
41
+ $content_font = get_option('niteoCS_font_content_custom');
42
+ }
43
+
44
+ $socialmedia = stripslashes(get_option('niteoCS_socialmedia'));
45
+ $socialmedia = json_decode($socialmedia, true);
46
+ $social_location = get_option('social_location', 'footer');
47
+ $enable_social = false;
48
+
49
+ foreach ($socialmedia as $social) {
50
+
51
+ if ( $social['hidden'] == '0' && $social['active'] == '1') {
52
+ $enable_social = true;
53
+ //sort array by hidden, then order key
54
+ function sort_social($a, $b){
55
+ if ( $a['hidden'] == $b['hidden'] ) {
56
+ if( $a['order'] == $b['order'] ) {
57
+ return 0;
58
+ }
59
+ return $a['order'] < $b['order'] ? -1 : 1;
60
+ } else {
61
+ return $a['hidden'] > $b['hidden'] ? 1 : -1;
62
+ }
63
+ }
64
+ uasort($socialmedia , 'sort_social');
65
+ break;
66
+ }
67
+ }
68
+
69
+ // override options if theme preview isset
70
+ if ( isset( $theme_preview ) && $theme_preview == 'countdown' ) {
71
+ $content_font ='Lato';
72
+ $logo_id = '8';
73
+ // $niteoCS_banner = '2';
74
+ $niteoCS_subscribe_label = 'Type your email and get notified.';
75
+ $body = '<h2>We are currently improving our site</h2>';
76
+ }
77
+
78
+
79
+ if ( get_option( 'blog_public' ) == 0 ) {
80
+ echo "<meta name='robots' content='noindex,nofollow' />";
81
+ } ?>
82
+
83
+ <?php
84
+ if ( $enable_social === true || $subscribe == '2') { ?>
85
+ <link rel="stylesheet" href="//maxcdn.bootstrapcdn.com/font-awesome/4.7.0/css/font-awesome.min.css">
86
+ <?php
87
+ } ?>
88
+ <link rel="stylesheet" href="<?php echo plugin_dir_url( dirname( __FILE__ ) ) . 'countdown/style.css?v='.$ver;?>" type="text/css" media="all"></link>
89
+
90
+ <link href="https://fonts.googleapis.com/css?family=<?php echo esc_attr(str_replace(' ', '+', $content_font));?>:400,400i,700" rel="stylesheet">
91
+
92
+ <?php wp_site_icon();?>
93
+
94
+ <style>
95
+ body,input {font-family:'<?php echo esc_attr($content_font);?>', 'sans-serif';color:<?php echo esc_attr( $niteoCS_font_color ); ?>;}
96
+ a {color:<?php echo esc_attr( $niteoCS_font_color ); ?>;}
97
+ input[type="submit"] {background-color: <?php echo esc_attr($niteoCS_active_color);?>;}
98
+ ::-webkit-input-placeholder {color: <?php echo esc_attr($niteoCS_font_color_light);?>;}
99
+ ::-moz-placeholder {color: <?php echo esc_attr($niteoCS_font_color_light);?>;}
100
+ :-ms-input-placeholder {color: <?php echo esc_attr($niteoCS_font_color_light);?>;}
101
+ ::-moz-placeholder {color: <?php echo esc_attr($niteoCS_font_color_light);?>;}
102
+ .input-icon:before,input[type="email"]{color: <?php echo esc_attr($niteoCS_font_color_light);?>;}
103
+ input[type="email"] {border:1px solid <?php echo esc_attr($niteoCS_font_color_light);?>;}
104
+ .background-overlay{background-color:<?php echo esc_attr($background_overlay);?>;}
105
+ .counter-wrap {border: 1px solid <?php echo esc_attr($niteoCS_font_color_light);?>;}
106
+ .counter-wrap span {color: <?php echo esc_attr($niteoCS_active_color);?>;}
107
+ footer, footer a {color: <?php echo esc_attr($niteoCS_font_color_light);?>;}
108
+ .social-list.body a {background-color: <?php echo esc_attr( $niteoCS_font_color ); ?>;}
109
+ .social-list.body a:hover {background-color: <?php echo esc_attr( $niteoCS_active_color ); ?>;}
110
+ .social-list.footer a:hover {color: <?php echo esc_attr( $niteoCS_active_color ); ?>;}
111
+ .social-list.footer li:not(:last-of-type)::after {background-color: <?php echo esc_attr( $niteoCS_font_color_light ); ?>;}
112
+ <?php
113
+ // if graphic banner, display transparent counter and input
114
+ $types = array('0', '1', '2');
115
+ if ( in_array($niteoCS_banner, $types) ) { ?>
116
+ .counter-wrap,
117
+ input[type="email"],
118
+ .social-list.body a {background:rgba(255, 255, 255, 0.10);}
119
+ input[type="submit"] {border:1px solid <?php echo esc_attr($niteoCS_font_color_light);?>;}
120
+ <?php
121
+ } ?>
122
+ </style>
123
+
124
+ <?php
125
+ // custom CSS
126
+ if ( get_option('niteoCS_custom_css', '') !== '' ) { ?>
127
+ <!-- custom CSS -->
128
+ <style>
129
+ <?php
130
+
131
+ echo stripslashes(wp_filter_nohtml_kses(get_option('niteoCS_custom_css'))); ?>
132
+ </style>
133
+ <?php
134
+ }
135
+
136
+ // GOOGLE ANALYTICS
137
+ if ( get_option('niteoCS_analytics', '') !== '' ) { ?>
138
+ <!-- Google analytics code -->
139
+ <script>
140
+ (function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
141
+ (i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
142
+ m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
143
+ })(window,document,'script','https://www.google-analytics.com/analytics.js','ga');
144
+
145
+ ga('create', '<?php echo esc_attr(get_option('niteoCS_analytics'));?>', 'auto');
146
+ ga('send', 'pageview');
147
+
148
+ </script>
149
+ <?php
150
+ } ?>
151
+
152
+ </head>
153
+
154
+ <?php
155
+ // check for mobile/desktop and determine image size
156
+ if (preg_match("/(android|avantgo|blackberry|bolt|boost|cricket|docomo|fone|hiptop|mini|mobi|palm|phone|pie|tablet|up\.browser|up\.link|webos|wos)/i", $_SERVER["HTTP_USER_AGENT"])) {
157
+ $size = 'large';
158
+ } else {
159
+ $size = 'full';
160
+ }
161
+ // get logo
162
+ if ( $logo_id != '' ) {
163
+ $logo_url = wp_get_attachment_image_src( $logo_id, $size);
164
+ }
165
+
166
+ switch ($niteoCS_banner) {
167
+ // custom media
168
+ case '0':
169
+ $banner_id = get_option('niteoCS_banner_id');
170
+ $background_class = 'image';
171
+ if ( $banner_id != '' ) {
172
+ $banner_ids = explode(',', $banner_id);
173
+ $banner_url = wp_get_attachment_image_src( $banner_ids[mt_rand(0, count( $banner_ids ) - 1)], $size);
174
+ if ( isset($banner_url[0]) ) {
175
+ $banner_url = $banner_url[0];
176
+ }
177
+
178
+ } else {
179
+ // set construct img
180
+ $banner_url = plugin_dir_url( dirname( __FILE__ ) ) . 'countdown/img/countdown_banner_'.$size.'.jpg';
181
+ }
182
+ break;
183
+
184
+ case '1':
185
+ // unsplash
186
+ $background_class = 'image';
187
+ switch ( $unplash_feed ) {
188
+ // SINGLE IMAGE
189
+ case '0':
190
+ $params = array('feed' => '0', 'url' => get_option('niteoCS_unsplash_0', '') );
191
+ $banner_url = $this->niteo_unsplash( $params );
192
+ break;
193
+ // category random
194
+ case '1':
195
+ $params = array('feed' => '1', 'cat' => get_option('niteoCS_unsplash_category'), 'custom_str' => get_option('niteoCS_cat_keyword', '') );
196
+ $banner_url = $this->niteo_unsplash( $params );
197
+ break;
198
+ // collection
199
+ case '2':
200
+ $params = array('feed' => '2', 'url' => get_option('niteoCS_unsplash_2', '') );
201
+ $banner_url = $this->niteo_unsplash( $params );
202
+ break;
203
+ // random photo
204
+ case '3':
205
+ $params = array('feed' => '3', 'url' => get_option('niteoCS_unsplash_3', ''), 'cat' => get_option('niteoCS_unsplash_feat', '0') );
206
+ $banner_url = $this->niteo_unsplash( $params );
207
+ break;
208
+
209
+ default:
210
+ break;
211
+ }
212
+
213
+ break;
214
+
215
+ case '2':
216
+ // default image
217
+ $background_class = 'image';
218
+ $banner_url = plugin_dir_url( dirname( __FILE__ ) ) . 'countdown/img/countdown_banner_'.$size.'.jpg';
219
+ break;
220
+
221
+ case '3':
222
+ // Pattern
223
+ $background_class = 'pattern';
224
+ $niteoCS_banner_pattern = get_option('niteoCS_banner_pattern', 'sakura');
225
+
226
+ if ($niteoCS_banner_pattern != 'custom') {
227
+ $banner_url = plugins_url('cmp-coming-soon-maintenance/img/patterns/'.esc_attr($niteoCS_banner_pattern).'.png');
228
+ // echo copyright pattern
229
+ echo '<!-- Background pattern from Subtle Patterns --!>';
230
+
231
+ } else {
232
+ $banner_url = get_option('niteoCS_banner_pattern_custom');
233
+ }
234
+
235
+ break;
236
+ case '4':
237
+ // Pattern
238
+ $background_class = 'color';
239
+ $banner_url = '';
240
+ $niteoCS_banner_color = get_option('niteoCS_banner_color', '#bdc3c7');
241
+ echo '<style>#background-image.color{background-color:'.esc_attr($niteoCS_banner_color).';}</style>';
242
+ break;
243
+
244
+ default:
245
+ break;
246
+ }
247
+
248
+ ?>
249
+
250
+ <body id="body">
251
+
252
+ <div id="background-wrapper">
253
+ <?php
254
+ // if banner is unsplash
255
+ if ( $niteoCS_banner == 1 ) { ?>
256
+ <script>
257
+ var screenWidth = Math.round(screen.width*window.devicePixelRatio);
258
+ var screenHeight = screenWidth / 1.77777;
259
+ screenHeight = screenHeight.toFixed(0);
260
+
261
+ var banner = '<div id="background-image" style="background-image:url(\'<?php echo esc_url( $banner_url ); ?>\')"></div>';
262
+ banner = banner.replace('WIDTHxHEIGHT', screenWidth + 'x' + screenHeight);
263
+ document.getElementById('background-wrapper').innerHTML = banner;
264
+ </script>
265
+ <?php
266
+
267
+ } else { ?>
268
+ <div id="background-image" class="<?php echo esc_attr($background_class);?>" style="background-image:url('<?php echo esc_url( $banner_url ); ?>')"></div>
269
+ <?php
270
+ } ?>
271
+
272
+ <div class="background-overlay"></div>
273
+
274
+ <div class="inner-content">
275
+
276
+ <?php
277
+ // display logo
278
+ if ( isset($logo_url[0]) ) { ?>
279
+ <div class="logo">
280
+ <img src="<?php echo esc_url( $logo_url[0] ); ?>" alt="logo">
281
+ </div>
282
+ <?php
283
+ }
284
+
285
+ // display body content
286
+ if ($body_title != '') { ?>
287
+ <h2 class="title">
288
+ <?php echo esc_html($body_title);?>
289
+ </h2>
290
+ <?php
291
+ }
292
+
293
+ // display counter
294
+ if ( $niteoCS_counter == '1') { ?>
295
+ <div id="counter" data-date="<?php echo esc_attr($niteoCS_counter_date);?>">
296
+ <div class="counter-wrap">
297
+ <div class="inner-counter">
298
+ <span id="counter-day">00</span>
299
+ <p><?php _e('DAYS', 'cmp');?></p>
300
+ </div>
301
+ </div>
302
+
303
+ <div class="counter-wrap">
304
+ <div class="inner-counter">
305
+ <span id="counter-hour">00</span>
306
+ <p><?php _e('HOURS', 'cmp');?></p>
307
+ </div>
308
+ </div>
309
+
310
+ <div class="counter-wrap">
311
+ <div class="inner-counter">
312
+ <span id="counter-minute">00</span>
313
+ <p><?php _e('MINUTES', 'cmp');?></p>
314
+ </div>
315
+ </div>
316
+
317
+ <div class="counter-wrap">
318
+ <div class="inner-counter">
319
+ <span id="counter-second">00</span>
320
+ <p><?php _e('SECONDS', 'cmp');?></p>
321
+ </div>
322
+ </div>
323
+ </div>
324
+ <?php
325
+ }
326
+
327
+ // display body content
328
+ if ($body != '') { ?>
329
+ <div class="body">
330
+ <?php echo apply_filters('the_content', stripslashes($body));?>
331
+ </div>
332
+ <?php
333
+ }
334
+
335
+ // display social if in body
336
+ if ( $enable_social === true && $social_location == 'body') { ?>
337
+
338
+ <div class="social-wrapper">
339
+
340
+ <ul class="social-list <?php echo esc_attr($social_location );?>">
341
+ <?php
342
+ foreach ( $socialmedia as $social ) {
343
+ if ($social['active'] == '1' && $social['hidden'] == '0') {
344
+ if ( $social['name'] == 'envelope-o' ) {
345
+ echo '<li><a href="mailto:'.antispambot(esc_html($social['url'])).'" target="_blank"><i class="fa fa-'.$social['name'].'" aria-hidden="true"></i></a></li>';
346
+
347
+ } else {
348
+ echo '<li><a href="'.esc_url($social['url']).'" target="top"><i class="fa fa-'.$social['name'].'" aria-hidden="true"></i></a></li>';
349
+ }
350
+ }
351
+
352
+ } //end foreach socialmedia
353
+ ?>
354
+ </ul>
355
+ </div>
356
+ <?php
357
+ }
358
+
359
+ // if subscribers is 3rd party plugin, render form by shortcode
360
+ if ( $subscribe != '0' ) {
361
+ echo '<div class="subscribe">';
362
+ }
363
+
364
+ if ( $subscribe == '1' ) {
365
+ $replace = array('<p>', '</p>' );
366
+ echo str_replace($replace, '', do_shortcode( stripslashes( get_option('niteoCS_subscribe_code') ))) ;
367
+
368
+ // if subsctbiers is niteo, render our html form
369
+ } else if ( $subscribe == '2' ) { ?>
370
+ <form id="subscribe-form" method="post">
371
+
372
+ <?php wp_nonce_field('save_options','save_options_field'); ?>
373
+ <?php
374
+ if ( $niteoCS_subscribe_label != '' ) { ?>
375
+ <label for="EMAIL"><?php echo esc_html($niteoCS_subscribe_label);?></label>
376
+ <?php
377
+ } ?>
378
+ <div class="input-icon"></div>
379
+ <input type="email" name="EMAIL" class="subscribe-input" placeholder="<?php _e('Insert your email address', 'cmp');?>" required>
380
+
381
+ <input type="submit" value="SUBMIT">
382
+
383
+ <div style="display: none;">
384
+ <input type="text" name="form_honeypot" value="" tabindex="-1" autocomplete="off">
385
+ </div>
386
+
387
+ <div class="subsribe-response"><?php echo isset( $subscribe_response ) ? $subscribe_response : '';?></div>
388
+ </form>
389
+ <?php
390
+ }
391
+
392
+ if ( $subscribe != '0' ) {
393
+ echo '</div>';
394
+ } ?>
395
+
396
+ </div>
397
+
398
+ <?php
399
+ if ( ($enable_social === true && $social_location == 'footer') || $copyright != '') {
400
+
401
+ echo '<footer>';
402
+
403
+ if ( $enable_social === true && $social_location == 'footer') { ?>
404
+
405
+ <div class="social-wrapper">
406
+
407
+ <ul class="social-list <?php echo esc_attr($social_location );?>">
408
+ <?php
409
+ foreach ( $socialmedia as $social ) {
410
+ if ($social['active'] == '1' && $social['hidden'] == '0') {
411
+ if ( $social['name'] == 'envelope-o' ) {
412
+ echo '<li><a href="mailto:'.antispambot(esc_html($social['url'])).'" target="_blank"><i class="fa fa-'.$social['name'].'" aria-hidden="true"></i></a></li>';
413
+
414
+ } else {
415
+ echo '<li><a href="'.esc_url($social['url']).'" target="top"><i class="fa fa-'.$social['name'].'" aria-hidden="true"></i></a></li>';
416
+ }
417
+ }
418
+
419
+ } //end foreach ?>
420
+ </ul>
421
+ </div>
422
+ <?php
423
+ }
424
+ if ($copyright != '') { ?>
425
+ <p class="copyright"><?php echo esc_html( $copyright );?></p>
426
+ <?php
427
+
428
+ }
429
+ echo '</footer>';
430
+ } ?>
431
+ </div>
432
+ </body>
433
+
434
+ <?php
435
+ if ( $niteoCS_counter == '1') { ?>
436
+ <script>
437
+ // Set the date we're counting down to
438
+ var counter = document.getElementById('counter');
439
+ var unixtime = counter.getAttribute('data-date');
440
+ var date = new Date(unixtime*1000);
441
+ var countDownDate = new Date(date).getTime();
442
+
443
+ // Update the count down every 1 second
444
+ var x = setInterval(function() {
445
+
446
+ // Get todays date and time
447
+ var now = new Date().getTime();
448
+
449
+ // Find the distance between now an the count down date
450
+ var distance = countDownDate - now;
451
+
452
+ // Time calculations for days, hours, minutes and seconds
453
+ var days = Math.floor(distance / (1000 * 60 * 60 * 24));
454
+ var hours = Math.floor((distance % (1000 * 60 * 60 * 24)) / (1000 * 60 * 60));
455
+ var minutes = Math.floor((distance % (1000 * 60 * 60)) / (1000 * 60));
456
+ var seconds = Math.floor((distance % (1000 * 60)) / 1000);
457
+
458
+ if (days < 10) {
459
+ days = '0' + days;
460
+ }
461
+ if (hours < 10) {
462
+ hours = '0' + hours;
463
+ }
464
+ if (minutes < 10) {
465
+ minutes = '0' + minutes;
466
+ }
467
+ if (seconds < 10) {
468
+ seconds = '0' + seconds;
469
+ }
470
+ if (distance >= 0) {
471
+ document.getElementById('counter-day').innerHTML = days;
472
+ document.getElementById('counter-hour').innerHTML = hours;
473
+ document.getElementById('counter-minute').innerHTML = minutes;
474
+ document.getElementById('counter-second').innerHTML = seconds;
475
+ }
476
+
477
+ <?php
478
+ if ( $countdown_action != 'no-action' && $countdown_action != 'display-text') { ?>
479
+
480
+ // If the count down is over, write some text
481
+ if (distance < 0) {
482
+ clearInterval(x);
483
+ window.location.reload();
484
+ }
485
+ <?php
486
+ } ?>
487
+
488
+ }, 1000);
489
+ </script>
490
+ <?php
491
+ } ?>
492
+ </html>
themes/countdown/css/flatpickr.min.css ADDED
@@ -0,0 +1,13 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ .flatpickr-calendar{background:transparent;overflow:hidden;max-height:0;opacity:0;visibility:hidden;text-align:center;padding:0;animation:none;direction:ltr;border:0;font-size:14px;line-height:24px;border-radius:5px;position:absolute;width:315px;box-sizing:border-box;background:#fff;box-shadow:1px 0 0 #e6e6e6,-1px 0 0 #e6e6e6,0 1px 0 #e6e6e6,0 -1px 0 #e6e6e6,0 3px 13px rgba(0,0,0,0.08);}.flatpickr-calendar.open,.flatpickr-calendar.inline{opacity:1;visibility:visible;overflow:visible;max-height:640px}.flatpickr-calendar.open{display:inline-block;animation:flatpickrFadeInDown 300ms cubic-bezier(0,1,.5,1);z-index:99999}.flatpickr-calendar.inline{display:block;position:relative;top:2px}.flatpickr-calendar.static{position:absolute;top:calc(100% + 2px);}.flatpickr-calendar.static.open{z-index:999;display:block}.flatpickr-calendar.hasWeeks{width:auto}.flatpickr-calendar.showTimeInput.hasTime .flatpickr-time{height:40px;border-top:1px solid #e6e6e6}.flatpickr-calendar.noCalendar.hasTime .flatpickr-time{height:auto}.flatpickr-calendar:before,.flatpickr-calendar:after{position:absolute;display:block;pointer-events:none;border:solid transparent;content:'';height:0;width:0;left:22px}.flatpickr-calendar.rightMost:before,.flatpickr-calendar.rightMost:after{left:auto;right:22px}.flatpickr-calendar:before{border-width:5px;margin:0 -5px}.flatpickr-calendar:after{border-width:4px;margin:0 -4px}.flatpickr-calendar.arrowTop:before,.flatpickr-calendar.arrowTop:after{bottom:100%}.flatpickr-calendar.arrowTop:before{border-bottom-color:#e6e6e6}.flatpickr-calendar.arrowTop:after{border-bottom-color:#fff}.flatpickr-calendar.arrowBottom:before,.flatpickr-calendar.arrowBottom:after{top:100%}.flatpickr-calendar.arrowBottom:before{border-top-color:#e6e6e6}.flatpickr-calendar.arrowBottom:after{border-top-color:#fff}.flatpickr-wrapper{position:relative;display:inline-block}.flatpickr-month{background:transparent;color:rgba(0,0,0,0.9);fill:rgba(0,0,0,0.9);height:28px;line-height:24px;text-align:center;position:relative;user-select:none}.flatpickr-prev-month,.flatpickr-next-month{text-decoration:none;cursor:pointer;position:absolute;top:10px;height:16px;line-height:16px;}.flatpickr-prev-month i,.flatpickr-next-month i{position:relative}.flatpickr-prev-month.flatpickr-prev-month,.flatpickr-next-month.flatpickr-prev-month{/*
2
+ /*rtl:begin:ignore*/left:calc(3.57% - 1.5px);/*
3
+ /*rtl:end:ignore*/}/*
4
+ /*rtl:begin:ignore*/
5
+ /*
6
+ /*rtl:end:ignore*/
7
+ .flatpickr-prev-month.flatpickr-next-month,.flatpickr-next-month.flatpickr-next-month{/*
8
+ /*rtl:begin:ignore*/right:calc(3.57% - 1.5px);/*
9
+ /*rtl:end:ignore*/}/*
10
+ /*rtl:begin:ignore*/
11
+ /*
12
+ /*rtl:end:ignore*/
13
+ .flatpickr-prev-month:hover,.flatpickr-next-month:hover{color:#959ea9;}.flatpickr-prev-month:hover svg,.flatpickr-next-month:hover svg{fill:#f64747}.flatpickr-prev-month svg,.flatpickr-next-month svg{width:14px;}.flatpickr-prev-month svg path,.flatpickr-next-month svg path{transition:fill .1s;fill:inherit}.numInputWrapper{position:relative;height:auto;}.numInputWrapper input,.numInputWrapper span{display:inline-block}.numInputWrapper input{width:100%}.numInputWrapper span{position:absolute;right:0;width:14px;padding:0 4px 0 2px;height:50%;line-height:50%;opacity:0;cursor:pointer;border:1px solid rgba(57,57,57,0.05);box-sizing:border-box;}.numInputWrapper span:hover{background:rgba(0,0,0,0.1)}.numInputWrapper span:active{background:rgba(0,0,0,0.2)}.numInputWrapper span:after{display:block;content:"";position:absolute;top:33%}.numInputWrapper span.arrowUp{top:0;border-bottom:0;}.numInputWrapper span.arrowUp:after{border-left:4px solid transparent;border-right:4px solid transparent;border-bottom:4px solid rgba(57,57,57,0.6)}.numInputWrapper span.arrowDown{top:50%;}.numInputWrapper span.arrowDown:after{border-left:4px solid transparent;border-right:4px solid transparent;border-top:4px solid rgba(57,57,57,0.6)}.numInputWrapper span svg{width:inherit;height:auto;}.numInputWrapper span svg path{fill:rgba(0,0,0,0.5)}.numInputWrapper:hover{background:rgba(0,0,0,0.05);}.numInputWrapper:hover span{opacity:1}.flatpickr-current-month{font-size:135%;line-height:inherit;font-weight:300;color:inherit;position:absolute;width:75%;left:12.5%;top:5px;display:inline-block;text-align:center;}.flatpickr-current-month span.cur-month{font-family:inherit;font-weight:700;color:inherit;display:inline-block;margin-left:7px;padding:0;}.flatpickr-current-month span.cur-month:hover{background:rgba(0,0,0,0.05)}.flatpickr-current-month .numInputWrapper{width:6ch;width:7ch\0;display:inline-block;}.flatpickr-current-month .numInputWrapper span.arrowUp:after{border-bottom-color:rgba(0,0,0,0.9)}.flatpickr-current-month .numInputWrapper span.arrowDown:after{border-top-color:rgba(0,0,0,0.9)}.flatpickr-current-month input.cur-year{background:transparent;box-sizing:border-box;color:inherit;cursor:default;padding:0 0 0 .5ch;margin:0;display:inline;font-size:inherit;font-family:inherit;font-weight:300;line-height:inherit;height:initial;border:0;border-radius:0;vertical-align:initial;}.flatpickr-current-month input.cur-year:focus{outline:0}.flatpickr-current-month input.cur-year[disabled],.flatpickr-current-month input.cur-year[disabled]:hover{font-size:100%;color:rgba(0,0,0,0.5);background:transparent;pointer-events:none}.flatpickr-weekdays{background:transparent;text-align:center;overflow:hidden}.flatpickr-days,.flatpickr-weeks{padding:1px 0 0 0}.flatpickr-days{padding:0;outline:0;text-align:left;width:315px;box-sizing:border-box;display:inline-block;display:-ms-flexbox;display:flex;flex-wrap:wrap;-ms-flex-wrap:wrap;-ms-flex-pack:justify;justify-content:space-around;}.flatpickr-day{background:none;border:1px solid transparent;border-radius:150px;box-sizing:border-box;color:#393939;cursor:pointer;font-weight:400;width:14.2857143%;flex-basis:14.2857143%;max-width:40px;height:40px;line-height:40px;margin:0;display:inline-block;position:relative;justify-content:center;text-align:center;}.flatpickr-day.inRange,.flatpickr-day.prevMonthDay.inRange,.flatpickr-day.nextMonthDay.inRange,.flatpickr-day.today.inRange,.flatpickr-day.prevMonthDay.today.inRange,.flatpickr-day.nextMonthDay.today.inRange,.flatpickr-day:hover,.flatpickr-day.prevMonthDay:hover,.flatpickr-day.nextMonthDay:hover,.flatpickr-day:focus,.flatpickr-day.prevMonthDay:focus,.flatpickr-day.nextMonthDay:focus{cursor:pointer;outline:0;background:#e6e6e6;border-color:#e6e6e6}.flatpickr-day.today{border-color:#959ea9;}.flatpickr-day.today:hover,.flatpickr-day.today:focus{border-color:#959ea9;background:#959ea9;color:#fff}.flatpickr-day.selected,.flatpickr-day.startRange,.flatpickr-day.endRange,.flatpickr-day.selected:focus,.flatpickr-day.startRange:focus,.flatpickr-day.endRange:focus,.flatpickr-day.selected:hover,.flatpickr-day.startRange:hover,.flatpickr-day.endRange:hover,.flatpickr-day.selected.prevMonthDay,.flatpickr-day.startRange.prevMonthDay,.flatpickr-day.endRange.prevMonthDay,.flatpickr-day.selected.nextMonthDay,.flatpickr-day.startRange.nextMonthDay,.flatpickr-day.endRange.nextMonthDay{background:#569ff7;color:#fff;border-color:#569ff7}.flatpickr-day.selected.startRange,.flatpickr-day.startRange.startRange,.flatpickr-day.endRange.startRange{border-radius:50px 0 0 50px}.flatpickr-day.selected.endRange,.flatpickr-day.startRange.endRange,.flatpickr-day.endRange.endRange{border-radius:0 50px 50px 0}.flatpickr-day.selected.startRange.endRange,.flatpickr-day.startRange.startRange.endRange,.flatpickr-day.endRange.startRange.endRange{border-radius:50px}.flatpickr-day.inRange{border-radius:0;box-shadow:-5px 0 0 #e6e6e6,5px 0 0 #e6e6e6}.flatpickr-day.disabled,.flatpickr-day.disabled:hover{pointer-events:none}.flatpickr-day.disabled,.flatpickr-day.disabled:hover,.flatpickr-day.prevMonthDay,.flatpickr-day.nextMonthDay,.flatpickr-day.notAllowed,.flatpickr-day.notAllowed.prevMonthDay,.flatpickr-day.notAllowed.nextMonthDay{color:rgba(57,57,57,0.3);background:transparent;border-color:transparent;cursor:default}span.flatpickr-weekday{cursor:default;font-size:90%;color:rgba(0,0,0,0.54);height:27.333333333333332px;line-height:24px;margin:0;background:transparent;text-align:center;display:block;float:left;width:14.28%;font-weight:bold;margin:0;padding-top:3.333333333333333px}.rangeMode .flatpickr-day{margin-top:1px}.flatpickr-weekwrapper{display:inline-block;float:left;}.flatpickr-weekwrapper .flatpickr-weeks{padding:1px 12px 0 12px;box-shadow:1px 0 0 #e6e6e6}.flatpickr-weekwrapper .flatpickr-weekday{float:none;width:100%}.flatpickr-weekwrapper span.flatpickr-day{display:block;width:100%;max-width:none}.flatpickr-innerContainer{display:block;display:flex;box-sizing:border-box;overflow:hidden;}.flatpickr-rContainer{display:inline-block;padding:0;box-sizing:border-box}.flatpickr-time{text-align:center;outline:0;display:block;height:0;line-height:40px;max-height:40px;box-sizing:border-box;overflow:hidden;transition:height .33s cubic-bezier(0,1,.5,1);display:flex;}.flatpickr-time:after{content:"";display:table;clear:both}.flatpickr-time .numInputWrapper{flex:1;width:40%;height:40px;float:left;}.flatpickr-time .numInputWrapper span.arrowUp:after{border-bottom-color:#393939}.flatpickr-time .numInputWrapper span.arrowDown:after{border-top-color:#393939}.flatpickr-time.hasSeconds .numInputWrapper{width:26%}.flatpickr-time.time24hr .numInputWrapper{width:49%}.flatpickr-time input{background:transparent;box-shadow:none;border:0;border-radius:0;text-align:center;margin:0;padding:0;height:inherit;line-height:inherit;cursor:pointer;color:#393939;font-size:14px;position:relative;box-sizing:border-box;}.flatpickr-time input.flatpickr-hour{font-weight:bold}.flatpickr-time input.flatpickr-minute,.flatpickr-time input.flatpickr-second{font-weight:400}.flatpickr-time input:focus{outline:0;border:0}.flatpickr-time .flatpickr-time-separator,.flatpickr-time .flatpickr-am-pm{height:inherit;display:inline-block;float:left;line-height:inherit;color:#393939;font-weight:bold;width:2%;user-select:none}.flatpickr-time .flatpickr-am-pm{outline:0;width:18%;cursor:pointer;text-align:center;font-weight:400;}.flatpickr-time .flatpickr-am-pm:hover,.flatpickr-time .flatpickr-am-pm:focus{background:#f0f0f0}.hasWeeks .flatpickr-days,.hasTime .flatpickr-days{border-bottom:0;border-bottom-right-radius:0;border-bottom-left-radius:0}.hasWeeks .flatpickr-days{border-left:0}@media all and (-ms-high-contrast:none){.flatpickr-month{padding:0;}.flatpickr-month svg{top:0 !important}}.flatpickr-input[readonly]{cursor:pointer}@-moz-keyframes flatpickrFadeInDown{from{opacity:0;transform:translate3d(0,-20px,0)}to{opacity:1;transform:none}}@-webkit-keyframes flatpickrFadeInDown{from{opacity:0;transform:translate3d(0,-20px,0)}to{opacity:1;transform:none}}@-o-keyframes flatpickrFadeInDown{from{opacity:0;transform:translate3d(0,-20px,0)}to{opacity:1;transform:none}}@keyframes flatpickrFadeInDown{from{opacity:0;transform:translate3d(0,-20px,0)}to{opacity:1;transform:none}}
themes/countdown/img/countdown_banner_full.jpg ADDED
Binary file
themes/countdown/img/countdown_banner_large.jpg ADDED
Binary file
themes/countdown/img/countdown_thumbnail.jpg ADDED
Binary file
themes/countdown/img/fifty_thumbnail.jpg ADDED
Binary file
themes/countdown/js/flatpickr.min.js ADDED
@@ -0,0 +1,3 @@
 
 
 
1
+ /*! flatpickr v2.4.7, @license MIT */
2
+ function Flatpickr(e,t){function n(e){return e&&e.bind?e.bind(oe):e}function a(e){oe.config.noCalendar&&!oe.selectedDates.length&&(oe.selectedDates=[oe.now]),re(e),oe.selectedDates.length&&(!oe.minDateHasTime||"input"!==e.type||e.target.value.length>=2?(i(),G()):setTimeout(function(){i(),G()},1e3))}function i(){if(oe.config.enableTime){var e=parseInt(oe.hourElement.value,10)||0,t=parseInt(oe.minuteElement.value,10)||0,n=oe.config.enableSeconds?parseInt(oe.secondElement.value,10)||0:0;oe.amPM&&(e=e%12+12*("PM"===oe.amPM.textContent)),oe.minDateHasTime&&0===ie(oe.latestSelectedDateObj,oe.config.minDate)&&(e=Math.max(e,oe.config.minDate.getHours()))===oe.config.minDate.getHours()&&(t=Math.max(t,oe.config.minDate.getMinutes())),oe.maxDateHasTime&&0===ie(oe.latestSelectedDateObj,oe.config.maxDate)&&(e=Math.min(e,oe.config.maxDate.getHours()))===oe.config.maxDate.getHours()&&(t=Math.min(t,oe.config.maxDate.getMinutes())),o(e,t,n)}}function r(e){var t=e||oe.latestSelectedDateObj;t&&o(t.getHours(),t.getMinutes(),t.getSeconds())}function o(e,t,n){oe.selectedDates.length&&oe.latestSelectedDateObj.setHours(e%24,t,n||0,0),oe.config.enableTime&&!oe.isMobile&&(oe.hourElement.value=oe.pad(oe.config.time_24hr?e:(12+e)%12+12*(e%12==0)),oe.minuteElement.value=oe.pad(t),oe.config.time_24hr||(oe.amPM.textContent=e>=12?"PM":"AM"),oe.config.enableSeconds&&(oe.secondElement.value=oe.pad(n)))}function l(e){var t=e.target.value;e.delta&&(t=(parseInt(t)+e.delta).toString()),4===t.length&&(oe.currentYearElement.blur(),/[^\d]/.test(t)||T(t))}function c(e){e.preventDefault(),oe.changeMonth(Math.max(-1,Math.min(1,e.wheelDelta||-e.deltaY)))}function s(){if(oe.config.wrap&&["open","close","toggle","clear"].forEach(function(e){for(var t=oe.element.querySelectorAll("[data-"+e+"]"),n=0;n<t.length;n++)t[n].addEventListener("click",oe[e])}),void 0!==window.document.createEvent&&(oe.changeEvent=window.document.createEvent("HTMLEvents"),oe.changeEvent.initEvent("change",!1,!0)),oe.isMobile)return z();oe.debouncedResize=ae(N,50),oe.triggerChange=function(){V("Change")},oe.debouncedChange=ae(oe.triggerChange,300),"range"===oe.config.mode&&oe.days&&oe.days.addEventListener("mouseover",Y),oe.calendarContainer.addEventListener("keydown",I),oe.config.static||(oe.altInput||oe.input).addEventListener("keydown",I),oe.config.inline||oe.config.static||window.addEventListener("resize",oe.debouncedResize),window.ontouchstart&&window.document.addEventListener("touchstart",x),window.document.addEventListener("click",x),(oe.altInput||oe.input).addEventListener("blur",x),oe.config.clickOpens&&(oe.altInput||oe.input).addEventListener("focus",S),oe.config.noCalendar||(oe.prevMonthNav.addEventListener("click",function(){return y(-1)}),oe.nextMonthNav.addEventListener("click",function(){return y(1)}),oe.currentMonthElement.addEventListener("wheel",function(e){return ae(c(e),50)}),oe.currentYearElement.addEventListener("wheel",function(e){return ae(X(e),50)}),oe.currentYearElement.addEventListener("focus",function(){oe.currentYearElement.select()}),oe.currentYearElement.addEventListener("input",l),oe.currentYearElement.addEventListener("increment",l),oe.days.addEventListener("click",H)),oe.config.enableTime&&(oe.timeContainer.addEventListener("transitionend",A),oe.timeContainer.addEventListener("wheel",function(e){return ae(a(e),5)}),oe.timeContainer.addEventListener("input",a),oe.timeContainer.addEventListener("increment",a),oe.timeContainer.addEventListener("increment",oe.debouncedChange),oe.timeContainer.addEventListener("wheel",oe.debouncedChange),oe.timeContainer.addEventListener("input",oe.triggerChange),oe.hourElement.addEventListener("focus",function(){oe.hourElement.select()}),oe.minuteElement.addEventListener("focus",function(){oe.minuteElement.select()}),oe.secondElement&&oe.secondElement.addEventListener("focus",function(){oe.secondElement.select()}),oe.amPM&&oe.amPM.addEventListener("click",function(e){a(e),oe.triggerChange(e)}))}function u(e){e=e?oe.parseDate(e):oe.latestSelectedDateObj||(oe.config.minDate>oe.now?oe.config.minDate:oe.config.maxDate&&oe.config.maxDate<oe.now?oe.config.maxDate:oe.now);try{oe.currentYear=e.getFullYear(),oe.currentMonth=e.getMonth()}catch(t){console.error(t.stack),console.warn("Invalid date supplied: "+e)}oe.redraw()}function d(e,t,n){var a=n||e.target.parentNode.childNodes[0],i=void 0;try{i=new Event("increment",{bubbles:!0})}catch(e){i=window.document.createEvent("CustomEvent"),i.initCustomEvent("increment",!0,!0,{})}i.delta=t,a.dispatchEvent(i)}function f(e){var t=ee("div","numInputWrapper"),n=ee("input","numInput "+e),a=ee("span","arrowUp"),i=ee("span","arrowDown");return n.type="text",n.pattern="\\d*",t.appendChild(n),t.appendChild(a),t.appendChild(i),a.addEventListener("click",function(e){return d(e,1)}),i.addEventListener("click",function(e){return d(e,-1)}),t}function p(){var e=window.document.createDocumentFragment();oe.calendarContainer=ee("div","flatpickr-calendar"),oe.numInputType=navigator.userAgent.indexOf("MSIE 9.0")>0?"text":"number",oe.config.noCalendar||(e.appendChild(D()),oe.innerContainer=ee("div","flatpickr-innerContainer"),oe.config.weekNumbers&&oe.innerContainer.appendChild(b()),oe.rContainer=ee("div","flatpickr-rContainer"),oe.rContainer.appendChild(w()),oe.days||(oe.days=ee("div","flatpickr-days"),oe.days.tabIndex=-1),h(),oe.rContainer.appendChild(oe.days),oe.innerContainer.appendChild(oe.rContainer),e.appendChild(oe.innerContainer)),oe.config.enableTime&&e.appendChild(v()),"range"===oe.config.mode&&oe.calendarContainer.classList.add("rangeMode"),oe.calendarContainer.appendChild(e);var t=oe.config.appendTo&&oe.config.appendTo.nodeType;if(oe.config.inline||oe.config.static){if(oe.calendarContainer.classList.add(oe.config.inline?"inline":"static"),oe.config.inline&&!t)return oe.element.parentNode.insertBefore(oe.calendarContainer,(oe.altInput||oe.input).nextSibling);if(oe.config.static){var n=ee("div","flatpickr-wrapper");return oe.element.parentNode.insertBefore(n,oe.element),n.appendChild(oe.element),oe.altInput&&n.appendChild(oe.altInput),void n.appendChild(oe.calendarContainer)}}(t?oe.config.appendTo:window.document.body).appendChild(oe.calendarContainer)}function g(e,t,n,a){var i=F(t,!0),r=ee("span","flatpickr-day "+e,t.getDate());return r.dateObj=t,r.$i=a,r.setAttribute("aria-label",oe.formatDate(t,"F j, Y")),0===ie(t,oe.now)&&(oe.todayDateElem=r,r.classList.add("today")),i?(r.tabIndex=-1,Z(t)&&(r.classList.add("selected"),oe.selectedDateElem=r,"range"===oe.config.mode&&(ne(r,"startRange",0===ie(t,oe.selectedDates[0])),ne(r,"endRange",0===ie(t,oe.selectedDates[1]))))):(r.classList.add("disabled"),oe.selectedDates[0]&&t>oe.minRangeDate&&t<oe.selectedDates[0]?oe.minRangeDate=t:oe.selectedDates[0]&&t<oe.maxRangeDate&&t>oe.selectedDates[0]&&(oe.maxRangeDate=t)),"range"===oe.config.mode&&(q(t)&&!Z(t)&&r.classList.add("inRange"),1===oe.selectedDates.length&&(t<oe.minRangeDate||t>oe.maxRangeDate)&&r.classList.add("notAllowed")),oe.config.weekNumbers&&"prevMonthDay"!==e&&n%7==1&&oe.weekNumbers.insertAdjacentHTML("beforeend","<span class='disabled flatpickr-day'>"+oe.config.getWeek(t)+"</span>"),V("DayCreate",r),r}function m(e,t){if(void 0===e)return(oe.todayDateElem||oe.days.childNodes[0]).focus();var n=e+t||0,a=oe.days.childNodes[n];a?a.focus():t>0?(oe.changeMonth(1),oe.days.childNodes[n%42].focus()):(oe.changeMonth(-1),oe.days.childNodes[42+n].focus())}function h(e,t){var n=(new Date(oe.currentYear,oe.currentMonth,1).getDay()-oe.l10n.firstDayOfWeek+7)%7,a="range"===oe.config.mode;oe.prevMonthDays=oe.utils.getDaysinMonth((oe.currentMonth-1+12)%12),oe.todayDateElem=null;var i=oe.utils.getDaysinMonth(),r=window.document.createDocumentFragment(),o=oe.prevMonthDays+1-n,l=0;for(oe.config.weekNumbers&&oe.weekNumbers.firstChild&&(oe.weekNumbers.textContent=""),a&&(oe.minRangeDate=new Date(oe.currentYear,oe.currentMonth-1,o),oe.maxRangeDate=new Date(oe.currentYear,oe.currentMonth+1,(42-n)%i)),oe.days.firstChild&&(oe.days.textContent="");o<=oe.prevMonthDays;o++,l++)r.appendChild(g("prevMonthDay",new Date(oe.currentYear,oe.currentMonth-1,o),o,l));for(o=1;o<=i;o++,l++)r.appendChild(g("",new Date(oe.currentYear,oe.currentMonth,o),o,l));for(var c=i+1;c<=42-n;c++,l++)r.appendChild(g("nextMonthDay",new Date(oe.currentYear,oe.currentMonth+1,c%i),c,l));return a&&1===oe.selectedDates.length&&r.childNodes[0]?(oe._hidePrevMonthArrow=oe._hidePrevMonthArrow||oe.minRangeDate>r.childNodes[0].dateObj,oe._hideNextMonthArrow=oe._hideNextMonthArrow||oe.maxRangeDate<new Date(oe.currentYear,oe.currentMonth+1,1)):Q(),oe.days.appendChild(r),oe.days}function D(){var e=window.document.createDocumentFragment();oe.monthNav=ee("div","flatpickr-month"),oe.prevMonthNav=ee("span","flatpickr-prev-month"),oe.prevMonthNav.innerHTML=oe.config.prevArrow,oe.currentMonthElement=ee("span","cur-month"),oe.currentMonthElement.title=oe.l10n.scrollTitle;var t=f("cur-year");return oe.currentYearElement=t.childNodes[0],oe.currentYearElement.title=oe.l10n.scrollTitle,oe.config.minDate&&(oe.currentYearElement.min=oe.config.minDate.getFullYear()),oe.config.maxDate&&(oe.currentYearElement.max=oe.config.maxDate.getFullYear(),oe.currentYearElement.disabled=oe.config.minDate&&oe.config.minDate.getFullYear()===oe.config.maxDate.getFullYear()),oe.nextMonthNav=ee("span","flatpickr-next-month"),oe.nextMonthNav.innerHTML=oe.config.nextArrow,oe.navigationCurrentMonth=ee("span","flatpickr-current-month"),oe.navigationCurrentMonth.appendChild(oe.currentMonthElement),oe.navigationCurrentMonth.appendChild(t),e.appendChild(oe.prevMonthNav),e.appendChild(oe.navigationCurrentMonth),e.appendChild(oe.nextMonthNav),oe.monthNav.appendChild(e),Object.defineProperty(oe,"_hidePrevMonthArrow",{get:function(){return this.__hidePrevMonthArrow},set:function(e){this.__hidePrevMonthArrow!==e&&(oe.prevMonthNav.style.display=e?"none":"block"),this.__hidePrevMonthArrow=e}}),Object.defineProperty(oe,"_hideNextMonthArrow",{get:function(){return this.__hideNextMonthArrow},set:function(e){this.__hideNextMonthArrow!==e&&(oe.nextMonthNav.style.display=e?"none":"block"),this.__hideNextMonthArrow=e}}),Q(),oe.monthNav}function v(){oe.calendarContainer.classList.add("hasTime"),oe.config.noCalendar&&oe.calendarContainer.classList.add("noCalendar"),oe.timeContainer=ee("div","flatpickr-time"),oe.timeContainer.tabIndex=-1;var e=ee("span","flatpickr-time-separator",":"),t=f("flatpickr-hour");oe.hourElement=t.childNodes[0];var n=f("flatpickr-minute");if(oe.minuteElement=n.childNodes[0],oe.hourElement.tabIndex=oe.minuteElement.tabIndex=-1,oe.hourElement.value=oe.pad(oe.latestSelectedDateObj?oe.latestSelectedDateObj.getHours():oe.config.defaultHour),oe.minuteElement.value=oe.pad(oe.latestSelectedDateObj?oe.latestSelectedDateObj.getMinutes():oe.config.defaultMinute),oe.hourElement.step=oe.config.hourIncrement,oe.minuteElement.step=oe.config.minuteIncrement,oe.hourElement.min=oe.config.time_24hr?0:1,oe.hourElement.max=oe.config.time_24hr?23:12,oe.minuteElement.min=0,oe.minuteElement.max=59,oe.hourElement.title=oe.minuteElement.title=oe.l10n.scrollTitle,oe.timeContainer.appendChild(t),oe.timeContainer.appendChild(e),oe.timeContainer.appendChild(n),oe.config.time_24hr&&oe.timeContainer.classList.add("time24hr"),oe.config.enableSeconds){oe.timeContainer.classList.add("hasSeconds");var a=f("flatpickr-second");oe.secondElement=a.childNodes[0],oe.secondElement.value=oe.latestSelectedDateObj?oe.pad(oe.latestSelectedDateObj.getSeconds()):"00",oe.secondElement.step=oe.minuteElement.step,oe.secondElement.min=oe.minuteElement.min,oe.secondElement.max=oe.minuteElement.max,oe.timeContainer.appendChild(ee("span","flatpickr-time-separator",":")),oe.timeContainer.appendChild(a)}return oe.config.time_24hr||(oe.amPM=ee("span","flatpickr-am-pm",["AM","PM"][oe.hourElement.value>11|0]),oe.amPM.title=oe.l10n.toggleTitle,oe.amPM.tabIndex=-1,oe.timeContainer.appendChild(oe.amPM)),oe.timeContainer}function w(){oe.weekdayContainer||(oe.weekdayContainer=ee("div","flatpickr-weekdays"));var e=oe.l10n.firstDayOfWeek,t=oe.l10n.weekdays.shorthand.slice();return e>0&&e<t.length&&(t=[].concat(t.splice(e,t.length),t.splice(0,e))),oe.weekdayContainer.innerHTML="\n\t\t<span class=flatpickr-weekday>\n\t\t\t"+t.join("</span><span class=flatpickr-weekday>")+"\n\t\t</span>\n\t\t",oe.weekdayContainer}function b(){return oe.calendarContainer.classList.add("hasWeeks"),oe.weekWrapper=ee("div","flatpickr-weekwrapper"),oe.weekWrapper.appendChild(ee("span","flatpickr-weekday",oe.l10n.weekAbbreviation)),oe.weekNumbers=ee("div","flatpickr-weeks"),oe.weekWrapper.appendChild(oe.weekNumbers),oe.weekWrapper}function y(e,t){t=void 0===t||t;var n=t?e:e-oe.currentMonth;n<0&&oe._hidePrevMonthArrow||n>0&&oe._hideNextMonthArrow||(oe.currentMonth+=n,(oe.currentMonth<0||oe.currentMonth>11)&&(oe.currentYear+=oe.currentMonth>11?1:-1,oe.currentMonth=(oe.currentMonth+12)%12,V("YearChange")),Q(),h(),oe.config.noCalendar||oe.days.focus(),V("MonthChange"))}function M(e){oe.input.value="",oe.altInput&&(oe.altInput.value=""),oe.mobileInput&&(oe.mobileInput.value=""),oe.selectedDates=[],oe.latestSelectedDateObj=null,oe.showTimeInput=!1,oe.redraw(),e!==!1&&V("Change")}function C(){oe.isOpen=!1,oe.isMobile||(oe.calendarContainer.classList.remove("open"),(oe.altInput||oe.input).classList.remove("active")),V("Close")}function k(e){e=e||oe,e.clear(!1),window.removeEventListener("resize",e.debouncedResize),window.document.removeEventListener("click",x),window.document.removeEventListener("touchstart",x),window.document.removeEventListener("blur",x),e.timeContainer&&e.timeContainer.removeEventListener("transitionend",A),e.mobileInput?(e.mobileInput.parentNode&&e.mobileInput.parentNode.removeChild(e.mobileInput),delete e.mobileInput):e.calendarContainer&&e.calendarContainer.parentNode&&e.calendarContainer.parentNode.removeChild(e.calendarContainer),e.altInput&&(e.input.type="text",e.altInput.parentNode&&e.altInput.parentNode.removeChild(e.altInput),delete e.altInput),e.input.type=e.input._type,e.input.classList.remove("flatpickr-input"),e.input.removeEventListener("focus",S),e.input.removeAttribute("readonly"),delete e.input._flatpickr}function E(e){return!(!oe.config.appendTo||!oe.config.appendTo.contains(e))||oe.calendarContainer.contains(e)}function x(e){if(oe.isOpen&&!oe.config.inline){var t=E(e.target),n=e.target===oe.input||e.target===oe.altInput||oe.element.contains(e.target)||e.path&&e.path.indexOf&&(~e.path.indexOf(oe.input)||~e.path.indexOf(oe.altInput));("blur"===e.type?n&&e.relatedTarget&&!E(e.relatedTarget):!n&&!t)&&(e.preventDefault(),oe.close(),"range"===oe.config.mode&&1===oe.selectedDates.length&&(oe.clear(),oe.redraw()))}}function T(e){if(!(!e||oe.currentYearElement.min&&e<oe.currentYearElement.min||oe.currentYearElement.max&&e>oe.currentYearElement.max)){var t=parseInt(e,10),n=oe.currentYear!==t;oe.currentYear=t||oe.currentYear,oe.config.maxDate&&oe.currentYear===oe.config.maxDate.getFullYear()?oe.currentMonth=Math.min(oe.config.maxDate.getMonth(),oe.currentMonth):oe.config.minDate&&oe.currentYear===oe.config.minDate.getFullYear()&&(oe.currentMonth=Math.max(oe.config.minDate.getMonth(),oe.currentMonth)),n&&(oe.redraw(),V("YearChange"))}}function F(e,t){var n=ie(e,oe.config.minDate,void 0!==t?t:!oe.minDateHasTime)<0,a=ie(e,oe.config.maxDate,void 0!==t?t:!oe.maxDateHasTime)>0;if(n||a)return!1;if(!oe.config.enable.length&&!oe.config.disable.length)return!0;for(var i,r=oe.parseDate(e,!0),o=oe.config.enable.length>0,l=o?oe.config.enable:oe.config.disable,c=0;c<l.length;c++){if((i=l[c])instanceof Function&&i(r))return o;if(i instanceof Date&&i.getTime()===r.getTime())return o;if("string"==typeof i&&oe.parseDate(i,!0).getTime()===r.getTime())return o;if("object"===(void 0===i?"undefined":_typeof(i))&&i.from&&i.to&&r>=i.from&&r<=i.to)return o}return!o}function I(e){if(e.target===(oe.altInput||oe.input)&&"Enter"===e.key)H(e);else if(oe.isOpen||oe.config.inline){switch(e.key){case"Enter":oe.timeContainer&&oe.timeContainer.contains(e.target)?G():H(e);break;case"Escape":e.preventDefault(),oe.close();break;case"ArrowLeft":e.preventDefault(),m(e.target.$i,-1);break;case"ArrowUp":oe.timeContainer&&oe.timeContainer.contains(e.target)?a(e):(e.preventDefault(),m(e.target.$i,-7));break;case"ArrowRight":e.preventDefault(),m(e.target.$i,1);break;case"ArrowDown":oe.timeContainer&&oe.timeContainer.contains(e.target)?a(e):(e.preventDefault(),m(e.target.$i,7));break;case"Tab":e.target===oe.hourElement?(e.preventDefault(),oe.minuteElement.select()):e.target===oe.minuteElement&&oe.amPM&&(e.preventDefault(),oe.amPM.focus())}V("KeyDown",e)}}function Y(e){if(1===oe.selectedDates.length&&e.target.classList.contains("flatpickr-day")){for(var t=e.target.dateObj,n=oe.parseDate(oe.selectedDates[0],!0),a=Math.min(t.getTime(),oe.selectedDates[0].getTime()),i=Math.max(t.getTime(),oe.selectedDates[0].getTime()),r=!1,o=a;o<i;o+=oe.utils.duration.DAY)if(!F(new Date(o))){r=!0;break}for(var l=oe.days.childNodes[0].dateObj.getTime(),c=0;c<42;c++,l+=oe.utils.duration.DAY){(function(o,l){var c=o<oe.minRangeDate.getTime()||o>oe.maxRangeDate.getTime();if(c)return oe.days.childNodes[l].classList.add("notAllowed"),["inRange","startRange","endRange"].forEach(function(e){oe.days.childNodes[l].classList.remove(e)}),"continue";if(r&&!c)return"continue";["startRange","inRange","endRange","notAllowed"].forEach(function(e){oe.days.childNodes[l].classList.remove(e)});var s=Math.max(oe.minRangeDate.getTime(),a),u=Math.min(oe.maxRangeDate.getTime(),i);e.target.classList.add(t<oe.selectedDates[0]?"startRange":"endRange"),n>t&&o===n.getTime()?oe.days.childNodes[l].classList.add("endRange"):n<t&&o===n.getTime()?oe.days.childNodes[l].classList.add("startRange"):o>=s&&o<=u&&oe.days.childNodes[l].classList.add("inRange")})(l,c)}}}function N(){!oe.isOpen||oe.config.static||oe.config.inline||A()}function S(e){if(oe.isMobile)return e&&(e.preventDefault(),e.target.blur()),setTimeout(function(){oe.mobileInput.click()},0),void V("Open");oe.isOpen||(oe.altInput||oe.input).disabled||oe.config.inline||(oe.isOpen=!0,oe.calendarContainer.classList.add("open"),A(),(oe.altInput||oe.input).classList.add("active"),V("Open"))}function L(e){return function(t){var n=oe.config["_"+e+"Date"]=oe.parseDate(t),a=oe.config["_"+("min"===e?"max":"min")+"Date"],i=t&&n instanceof Date;i&&(oe[e+"DateHasTime"]=n.getHours()||n.getMinutes()||n.getSeconds()),oe.selectedDates&&(oe.selectedDates=oe.selectedDates.filter(function(e){return F(e)}),oe.selectedDates.length||"min"!==e||r(n),G()),oe.days&&(j(),i?oe.currentYearElement[e]=n.getFullYear():oe.currentYearElement.removeAttribute(e),oe.currentYearElement.disabled=a&&n&&a.getFullYear()===n.getFullYear())}}function O(){var e=["utc","wrap","weekNumbers","allowInput","clickOpens","time_24hr","enableTime","noCalendar","altInput","shorthandCurrentMonth","inline","static","enableSeconds","disableMobile"],t=["onChange","onClose","onDayCreate","onKeyDown","onMonthChange","onOpen","onParseConfig","onReady","onValueUpdate","onYearChange"];oe.config=Object.create(Flatpickr.defaultConfig);var a=_extends({},oe.instanceConfig,JSON.parse(JSON.stringify(oe.element.dataset||{})));oe.config.parseDate=a.parseDate,oe.config.formatDate=a.formatDate,_extends(oe.config,a),!a.dateFormat&&a.enableTime&&(oe.config.dateFormat=oe.config.noCalendar?"H:i"+(oe.config.enableSeconds?":S":""):Flatpickr.defaultConfig.dateFormat+" H:i"+(oe.config.enableSeconds?":S":"")),a.altInput&&a.enableTime&&!a.altFormat&&(oe.config.altFormat=oe.config.noCalendar?"h:i"+(oe.config.enableSeconds?":S K":" K"):Flatpickr.defaultConfig.altFormat+" h:i"+(oe.config.enableSeconds?":S":"")+" K"),Object.defineProperty(oe.config,"minDate",{get:function(){return this._minDate},set:L("min")}),Object.defineProperty(oe.config,"maxDate",{get:function(){return this._maxDate},set:L("max")}),oe.config.minDate=a.minDate,oe.config.maxDate=a.maxDate;for(var i=0;i<e.length;i++)oe.config[e[i]]=oe.config[e[i]]===!0||"true"===oe.config[e[i]];for(var r=0;r<t.length;r++)oe.config[t[r]]=te(oe.config[t[r]]||[]).map(n);for(var o=0;o<oe.config.plugins.length;o++){var l=oe.config.plugins[o](oe)||{};for(var c in l)Array.isArray(oe.config[c])||~t.indexOf(c)?oe.config[c]=te(l[c]).map(n).concat(oe.config[c]):void 0===a[c]&&(oe.config[c]=l[c])}V("ParseConfig")}function _(){"object"!==_typeof(oe.config.locale)&&void 0===Flatpickr.l10ns[oe.config.locale]&&console.warn("flatpickr: invalid locale "+oe.config.locale),oe.l10n=_extends(Object.create(Flatpickr.l10ns.default),"object"===_typeof(oe.config.locale)?oe.config.locale:"default"!==oe.config.locale?Flatpickr.l10ns[oe.config.locale]||{}:{})}function A(e){if(!e||e.target===oe.timeContainer){var t=oe.calendarContainer.offsetHeight,n=oe.calendarContainer.offsetWidth,a=oe.config.position,i=oe.altInput||oe.input,r=i.getBoundingClientRect(),o=window.innerHeight-r.bottom+i.offsetHeight,l="above"===a||"below"!==a&&o<t&&r.top>t,c=window.pageYOffset+r.top+(l?-t-2:i.offsetHeight+2);if(ne(oe.calendarContainer,"arrowTop",!l),ne(oe.calendarContainer,"arrowBottom",l),!oe.config.inline){var s=window.pageXOffset+r.left,u=window.document.body.offsetWidth-r.right,d=s+n>window.document.body.offsetWidth;ne(oe.calendarContainer,"rightMost",d),oe.config.static||(oe.calendarContainer.style.top=c+"px",d?(oe.calendarContainer.style.left="auto",oe.calendarContainer.style.right=u+"px"):(oe.calendarContainer.style.left=s+"px",oe.calendarContainer.style.right="auto"))}}}function j(){oe.config.noCalendar||oe.isMobile||(w(),Q(),h())}function H(e){if(e.preventDefault(),e.stopPropagation(),oe.config.allowInput&&"Enter"===e.key&&e.target===(oe.altInput||oe.input))return oe.setDate((oe.altInput||oe.input).value,!0,e.target===oe.altInput?oe.config.altFormat:oe.config.dateFormat),e.target.blur();if(e.target.classList.contains("flatpickr-day")&&!e.target.classList.contains("disabled")&&!e.target.classList.contains("notAllowed")){var t=oe.latestSelectedDateObj=new Date(e.target.dateObj.getTime());if(oe.selectedDateElem=e.target,"single"===oe.config.mode)oe.selectedDates=[t];else if("multiple"===oe.config.mode){var n=Z(t);n?oe.selectedDates.splice(n,1):oe.selectedDates.push(t)}else"range"===oe.config.mode&&(2===oe.selectedDates.length&&oe.clear(),oe.selectedDates.push(t),0!==ie(t,oe.selectedDates[0],!0)&&oe.selectedDates.sort(function(e,t){return e.getTime()-t.getTime()}));if(i(),t.getMonth()!==oe.currentMonth&&"range"!==oe.config.mode){var a=oe.currentYear!==t.getFullYear();oe.currentYear=t.getFullYear(),oe.currentMonth=t.getMonth(),a&&V("YearChange"),V("MonthChange")}h(),oe.minDateHasTime&&oe.config.enableTime&&0===ie(t,oe.config.minDate)&&r(oe.config.minDate),G(),setTimeout(function(){return oe.showTimeInput=!0},50),"range"===oe.config.mode&&(1===oe.selectedDates.length?(Y(e),oe._hidePrevMonthArrow=oe._hidePrevMonthArrow||oe.minRangeDate>oe.days.childNodes[0].dateObj,oe._hideNextMonthArrow=oe._hideNextMonthArrow||oe.maxRangeDate<new Date(oe.currentYear,oe.currentMonth+1,1)):(Q(),oe.close())),oe.config.enableTime&&setTimeout(function(){return oe.hourElement.select()},451),"single"!==oe.config.mode||oe.config.enableTime||oe.close(),V("Change")}}function P(e,t){oe.config[e]=t,oe.redraw(),u()}function R(e,t){if(Array.isArray(e))oe.selectedDates=e.map(function(e){return oe.parseDate(e,!1,t)});else if(e instanceof Date||!isNaN(e))oe.selectedDates=[oe.parseDate(e)];else if(e&&e.substring)switch(oe.config.mode){case"single":oe.selectedDates=[oe.parseDate(e,!1,t)];break;case"multiple":oe.selectedDates=e.split("; ").map(function(e){return oe.parseDate(e,!1,t)});break;case"range":oe.selectedDates=e.split(oe.l10n.rangeSeparator).map(function(e){return oe.parseDate(e,!1,t)})}oe.selectedDates=oe.selectedDates.filter(function(e){return e instanceof Date&&F(e,!1)}),oe.selectedDates.sort(function(e,t){return e.getTime()-t.getTime()})}function W(e,t,n){if(!e)return oe.clear();R(e,n),oe.showTimeInput=oe.selectedDates.length>0,oe.latestSelectedDateObj=oe.selectedDates[0],oe.redraw(),u(),r(),G(),t&&V("Change")}function U(){function e(e){for(var t=e.length;t--;)"string"==typeof e[t]||+e[t]?e[t]=oe.parseDate(e[t],!0):e[t]&&e[t].from&&e[t].to&&(e[t].from=oe.parseDate(e[t].from),e[t].to=oe.parseDate(e[t].to));return e.filter(function(e){return e})}oe.selectedDates=[],oe.now=new Date,oe.config.disable.length&&(oe.config.disable=e(oe.config.disable)),oe.config.enable.length&&(oe.config.enable=e(oe.config.enable)),R(oe.config.defaultDate||oe.input.value);var t=oe.selectedDates.length?oe.selectedDates[0]:oe.config.minDate&&oe.config.minDate.getTime()>oe.now?oe.config.minDate:oe.config.maxDate&&oe.config.maxDate.getTime()<oe.now?oe.config.maxDate:oe.now;oe.currentYear=t.getFullYear(),oe.currentMonth=t.getMonth(),oe.selectedDates.length&&(oe.latestSelectedDateObj=oe.selectedDates[0]),oe.minDateHasTime=oe.config.minDate&&(oe.config.minDate.getHours()||oe.config.minDate.getMinutes()||oe.config.minDate.getSeconds()),oe.maxDateHasTime=oe.config.maxDate&&(oe.config.maxDate.getHours()||oe.config.maxDate.getMinutes()||oe.config.maxDate.getSeconds()),Object.defineProperty(oe,"latestSelectedDateObj",{get:function(){return oe._selectedDateObj||oe.selectedDates[oe.selectedDates.length-1]||null},set:function(e){oe._selectedDateObj=e}}),oe.isMobile||Object.defineProperty(oe,"showTimeInput",{get:function(){return oe._showTimeInput},set:function(e){oe._showTimeInput=e,oe.calendarContainer&&ne(oe.calendarContainer,"showTimeInput",e)}})}function J(){oe.utils={duration:{DAY:864e5},getDaysinMonth:function(e,t){return e=void 0===e?oe.currentMonth:e,t=void 0===t?oe.currentYear:t,1===e&&(t%4==0&&t%100!=0||t%400==0)?29:oe.l10n.daysInMonth[e]},monthToStr:function(e,t){return t=void 0===t?oe.config.shorthandCurrentMonth:t,oe.l10n.months[(t?"short":"long")+"hand"][e]}}}function B(){["D","F","J","M","W","l"].forEach(function(e){oe.formats[e]=Flatpickr.prototype.formats[e].bind(oe)}),oe.revFormat.F=Flatpickr.prototype.revFormat.F.bind(oe),oe.revFormat.M=Flatpickr.prototype.revFormat.M.bind(oe)}function K(){if(oe.input=oe.config.wrap?oe.element.querySelector("[data-input]"):oe.element,!oe.input)return console.warn("Error: invalid input element specified",oe.input);oe.input._type=oe.input.type,oe.input.type="text",oe.input.classList.add("flatpickr-input"),oe.config.altInput&&(oe.altInput=ee(oe.input.nodeName,oe.input.className+" "+oe.config.altInputClass),oe.altInput.placeholder=oe.input.placeholder,oe.altInput.type="text",oe.input.type="hidden",!oe.config.static&&oe.input.parentNode&&oe.input.parentNode.insertBefore(oe.altInput,oe.input.nextSibling)),oe.config.allowInput||(oe.altInput||oe.input).setAttribute("readonly","readonly")}function z(){var e=oe.config.enableTime?oe.config.noCalendar?"time":"datetime-local":"date";oe.mobileInput=ee("input",oe.input.className+" flatpickr-mobile"),oe.mobileInput.step="any",oe.mobileInput.tabIndex=1,oe.mobileInput.type=e,oe.mobileInput.disabled=oe.input.disabled,oe.mobileInput.placeholder=oe.input.placeholder,oe.mobileFormatStr="datetime-local"===e?"Y-m-d\\TH:i:S":"date"===e?"Y-m-d":"H:i:S",oe.selectedDates.length&&(oe.mobileInput.defaultValue=oe.mobileInput.value=oe.formatDate(oe.selectedDates[0],oe.mobileFormatStr)),oe.config.minDate&&(oe.mobileInput.min=oe.formatDate(oe.config.minDate,"Y-m-d")),oe.config.maxDate&&(oe.mobileInput.max=oe.formatDate(oe.config.maxDate,"Y-m-d")),oe.input.type="hidden",oe.config.altInput&&(oe.altInput.type="hidden");try{oe.input.parentNode.insertBefore(oe.mobileInput,oe.input.nextSibling)}catch(e){}oe.mobileInput.addEventListener("change",function(e){oe.latestSelectedDateObj=oe.parseDate(e.target.value),oe.setDate(oe.latestSelectedDateObj),V("Change"),V("Close")})}function $(){oe.isOpen?oe.close():oe.open()}function V(e,t){var n=oe.config["on"+e];if(n)for(var a=0;n[a]&&a<n.length;a++)n[a](oe.selectedDates,oe.input&&oe.input.value,oe,t);if("Change"===e)if("function"==typeof Event&&Event.constructor)oe.input.dispatchEvent(new Event("change",{bubbles:!0})),oe.input.dispatchEvent(new Event("input",{bubbles:!0}));else{if(void 0!==window.document.createEvent)return oe.input.dispatchEvent(oe.changeEvent);oe.input.fireEvent("onchange")}}function Z(e){for(var t=0;t<oe.selectedDates.length;t++)if(0===ie(oe.selectedDates[t],e))return""+t;return!1}function q(e){return!("range"!==oe.config.mode||oe.selectedDates.length<2)&&(ie(e,oe.selectedDates[0])>=0&&ie(e,oe.selectedDates[1])<=0)}function Q(){oe.config.noCalendar||oe.isMobile||!oe.monthNav||(oe.currentMonthElement.textContent=oe.utils.monthToStr(oe.currentMonth)+" ",oe.currentYearElement.value=oe.currentYear,oe._hidePrevMonthArrow=oe.config.minDate&&(oe.currentYear===oe.config.minDate.getFullYear()?oe.currentMonth<=oe.config.minDate.getMonth():oe.currentYear<oe.config.minDate.getFullYear()),oe._hideNextMonthArrow=oe.config.maxDate&&(oe.currentYear===oe.config.maxDate.getFullYear()?oe.currentMonth+1>oe.config.maxDate.getMonth():oe.currentYear>oe.config.maxDate.getFullYear()))}function G(){if(!oe.selectedDates.length)return oe.clear();oe.isMobile&&(oe.mobileInput.value=oe.selectedDates.length?oe.formatDate(oe.latestSelectedDateObj,oe.mobileFormatStr):"");var e="range"!==oe.config.mode?"; ":oe.l10n.rangeSeparator;oe.input.value=oe.selectedDates.map(function(e){return oe.formatDate(e,oe.config.dateFormat)}).join(e),oe.config.altInput&&(oe.altInput.value=oe.selectedDates.map(function(e){return oe.formatDate(e,oe.config.altFormat)}).join(e)),V("ValueUpdate")}function X(e){e.preventDefault();var t=Math.max(-1,Math.min(1,e.wheelDelta||-e.deltaY));T(parseInt(e.target.value,10)+t),e.target.value=oe.currentYear}function ee(e,t,n){var a=window.document.createElement(e);return t=t||"",n=n||"",a.className=t,n&&(a.textContent=n),a}function te(e){return Array.isArray(e)?e:[e]}function ne(e,t,n){if(n)return e.classList.add(t);e.classList.remove(t)}function ae(e,t,n){var a=void 0;return function(){var i=this,r=arguments;clearTimeout(a),a=setTimeout(function(){a=null,n||e.apply(i,r)},t),n&&!a&&e.apply(i,r)}}function ie(e,t,n){return e instanceof Date&&t instanceof Date&&(n!==!1?new Date(e.getTime()).setHours(0,0,0,0)-new Date(t.getTime()).setHours(0,0,0,0):e.getTime()-t.getTime())}function re(e){e.preventDefault();var t="keydown"===e.type,n=(e.type,e.type,e.target);if("input"!==e.type&&!t&&(e.target.value||e.target.textContent).length>=2&&(e.target.focus(),e.target.blur()),oe.amPM&&e.target===oe.amPM)return e.target.textContent=["AM","PM"]["AM"===e.target.textContent|0];var a=Number(n.min),i=Number(n.max),r=Number(n.step),o=parseInt(n.value,10),l=e.delta||(t?38===e.which?1:-1:Math.max(-1,Math.min(1,e.wheelDelta||-e.deltaY))||0),c=o+r*l;if(void 0!==n.value&&2===n.value.length){var s=n===oe.hourElement,u=n===oe.minuteElement;c<a?(c=i+c+!s+(s&&!oe.amPM),u&&d(null,-1,oe.hourElement)):c>i&&(c=n===oe.hourElement?c-i-!oe.amPM:a,u&&d(null,1,oe.hourElement)),oe.amPM&&s&&(1===r?c+o===23:Math.abs(c-o)>r)&&(oe.amPM.textContent="PM"===oe.amPM.textContent?"AM":"PM"),n.value=oe.pad(c)}}var oe=this;return oe.changeMonth=y,oe.changeYear=T,oe.clear=M,oe.close=C,oe._createElement=ee,oe.destroy=k,oe.isEnabled=F,oe.jumpToDate=u,oe.open=S,oe.redraw=j,oe.set=P,oe.setDate=W,oe.toggle=$,function(){e._flatpickr&&k(e._flatpickr),e._flatpickr=oe,oe.element=e,oe.instanceConfig=t||{},oe.parseDate=Flatpickr.prototype.parseDate.bind(oe),oe.formatDate=Flatpickr.prototype.formatDate.bind(oe),B(),O(),_(),K(),U(),J(),oe.isOpen=oe.config.inline,oe.isMobile=!oe.config.disableMobile&&!oe.config.inline&&"single"===oe.config.mode&&!oe.config.disable.length&&!oe.config.enable.length&&!oe.config.weekNumbers&&/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent),oe.isMobile||p(),s(),(oe.selectedDates.length||oe.config.noCalendar)&&(oe.config.enableTime&&r(oe.config.noCalendar?oe.latestSelectedDateObj||oe.config.minDate:null),G()),oe.config.weekNumbers&&(oe.calendarContainer.style.width=oe.days.clientWidth+oe.weekWrapper.clientWidth+"px"),oe.showTimeInput=oe.selectedDates.length>0||oe.config.noCalendar,oe.isMobile||A(),V("Ready")}(),oe}
3
+ function _flatpickr(e,t){for(var n=Array.prototype.slice.call(e),a=[],i=0;i<n.length;i++)try{n[i]._flatpickr=new Flatpickr(n[i],t||{}),a.push(n[i]._flatpickr)}catch(e){console.warn(e,e.stack)}return 1===a.length?a[0]:a}function flatpickr(e,t){return _flatpickr(window.document.querySelectorAll(e),t)}var _extends=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var a in n)Object.prototype.hasOwnProperty.call(n,a)&&(e[a]=n[a])}return e},_typeof="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e};Flatpickr.defaultConfig={mode:"single",position:"top",utc:!1,wrap:!1,weekNumbers:!1,allowInput:!1,clickOpens:!0,time_24hr:!1,enableTime:!1,noCalendar:!1,dateFormat:"Y-m-d",altInput:!1,altInputClass:"flatpickr-input form-control input",altFormat:"F j, Y",defaultDate:null,minDate:null,maxDate:null,parseDate:null,formatDate:null,getWeek:function(e){var t=new Date(e.getTime());t.setHours(0,0,0,0),t.setDate(t.getDate()+3-(t.getDay()+6)%7);var n=new Date(t.getFullYear(),0,4);return 1+Math.round(((t.getTime()-n.getTime())/864e5-3+(n.getDay()+6)%7)/7)},enable:[],disable:[],shorthandCurrentMonth:!1,inline:!1,static:!1,appendTo:null,prevArrow:"<svg version='1.1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' viewBox='0 0 17 17'><g></g><path d='M5.207 8.471l7.146 7.147-0.707 0.707-7.853-7.854 7.854-7.853 0.707 0.707-7.147 7.146z' /></svg>",nextArrow:"<svg version='1.1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' viewBox='0 0 17 17'><g></g><path d='M13.207 8.472l-7.854 7.854-0.707-0.707 7.146-7.146-7.146-7.148 0.707-0.707 7.854 7.854z' /></svg>",enableSeconds:!1,hourIncrement:1,minuteIncrement:5,defaultHour:12,defaultMinute:0,disableMobile:!1,locale:"default",plugins:[],onClose:[],onChange:[],onDayCreate:[],onMonthChange:[],onOpen:[],onParseConfig:[],onReady:[],onValueUpdate:[],onYearChange:[],onKeyDown:[]},Flatpickr.l10ns={en:{weekdays:{shorthand:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],longhand:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"]},months:{shorthand:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],longhand:["January","February","March","April","May","June","July","August","September","October","November","December"]},daysInMonth:[31,28,31,30,31,30,31,31,30,31,30,31],firstDayOfWeek:0,ordinal:function(e){var t=e%100;if(t>3&&t<21)return"th";switch(t%10){case 1:return"st";case 2:return"nd";case 3:return"rd";default:return"th"}},rangeSeparator:" to ",weekAbbreviation:"Wk",scrollTitle:"Scroll to increment",toggleTitle:"Click to toggle"}},Flatpickr.l10ns.default=Object.create(Flatpickr.l10ns.en),Flatpickr.localize=function(e){return _extends(Flatpickr.l10ns.default,e||{})},Flatpickr.setDefaults=function(e){return _extends(Flatpickr.defaultConfig,e||{})},Flatpickr.prototype={formats:{Z:function(e){return e.toISOString()},D:function(e){return this.l10n.weekdays.shorthand[this.formats.w(e)]},F:function(e){return this.utils.monthToStr(this.formats.n(e)-1,!1)},H:function(e){return Flatpickr.prototype.pad(e.getHours())},J:function(e){return e.getDate()+this.l10n.ordinal(e.getDate())},K:function(e){return e.getHours()>11?"PM":"AM"},M:function(e){return this.utils.monthToStr(e.getMonth(),!0)},S:function(e){return Flatpickr.prototype.pad(e.getSeconds())},U:function(e){return e.getTime()/1e3},W:function(e){return this.config.getWeek(e)},Y:function(e){return e.getFullYear()},d:function(e){return Flatpickr.prototype.pad(e.getDate())},h:function(e){return e.getHours()%12?e.getHours()%12:12},i:function(e){return Flatpickr.prototype.pad(e.getMinutes())},j:function(e){return e.getDate()},l:function(e){return this.l10n.weekdays.longhand[e.getDay()]},m:function(e){return Flatpickr.prototype.pad(e.getMonth()+1)},n:function(e){return e.getMonth()+1},s:function(e){return e.getSeconds()},w:function(e){return e.getDay()},y:function(e){return String(e.getFullYear()).substring(2)}},formatDate:function(e,t){var n=this;if(this.config.formatDate)try{return this.config.formatDate(e,t)}catch(n){return console.warn("Please swap the format string and the date object parameters in your formatDate option","\nThe old signature will be deprecated by v2.5"),this.config.formatDate(t,e)}return t.split("").map(function(t,a,i){return n.formats[t]&&"\\"!==i[a-1]?n.formats[t](e):"\\"!==t?t:""}).join("")},revFormat:{D:function(){},F:function(e,t){e.setMonth(this.l10n.months.longhand.indexOf(t))},H:function(e,t){return e.setHours(parseFloat(t))},J:function(e,t){return e.setDate(parseFloat(t))},K:function(e,t){var n=e.getHours();12!==n&&e.setHours(n%12+12*/pm/i.test(t))},M:function(e,t){e.setMonth(this.l10n.months.shorthand.indexOf(t))},S:function(e,t){return e.setSeconds(t)},W:function(){},Y:function(e,t){return e.setFullYear(t)},Z:function(e,t){return new Date(t)},d:function(e,t){return e.setDate(parseFloat(t))},h:function(e,t){return e.setHours(parseFloat(t))},i:function(e,t){return e.setMinutes(parseFloat(t))},j:function(e,t){return e.setDate(parseFloat(t))},l:function(){},m:function(e,t){return e.setMonth(parseFloat(t)-1)},n:function(e,t){return e.setMonth(parseFloat(t)-1)},s:function(e,t){return e.setSeconds(parseFloat(t))},w:function(){},y:function(e,t){return e.setFullYear(2e3+parseFloat(t))}},tokenRegex:{D:"(\\w+)",F:"(\\w+)",H:"(\\d\\d|\\d)",J:"(\\d\\d|\\d)\\w+",K:"(\\w+)",M:"(\\w+)",S:"(\\d\\d|\\d)",Y:"(\\d{4})",Z:"(.+)",d:"(\\d\\d|\\d)",h:"(\\d\\d|\\d)",i:"(\\d\\d|\\d)",j:"(\\d\\d|\\d)",l:"(\\w+)",m:"(\\d\\d|\\d)",n:"(\\d\\d|\\d)",s:"(\\d\\d|\\d)",w:"(\\d\\d|\\d)",y:"(\\d{2})"},pad:function(e){return("0"+e).slice(-2)},parseDate:function(e,t,n){if(!e)return null;var a=e;if(e.toFixed)e=new Date(e);else if("string"==typeof e){var i="string"==typeof n?n:this.config.dateFormat;if("today"===(e=e.trim()))e=new Date,t=!0;else if(this.config&&this.config.parseDate)e=this.config.parseDate(e);else if(/Z$/.test(e)||/GMT$/.test(e))e=new Date(e);else{for(var r=this.config.noCalendar?new Date((new Date).setHours(0,0,0,0)):new Date((new Date).getFullYear(),0,1,0,0,0,0),o=!1,l=0,c=0,s="";l<i.length;l++){var u=i[l],d="\\"===u,f="\\"===i[l-1]||d;if(this.tokenRegex[u]&&!f){s+=this.tokenRegex[u];var p=new RegExp(s).exec(e);p&&(o=!0)&&this.revFormat[u](r,p[++c])}else d||(s+=".")}e=o?r:null}}else e instanceof Date&&(e=new Date(e.getTime()));return e instanceof Date?(this.config&&this.config.utc&&!e.fp_isUTC&&(e=e.fp_toUTC()),t===!0&&e.setHours(0,0,0,0),e):(console.warn("flatpickr: invalid date "+a),console.info(this.element),null)}},"undefined"!=typeof HTMLElement&&(HTMLCollection.prototype.flatpickr=NodeList.prototype.flatpickr=function(e){return _flatpickr(this,e)},HTMLElement.prototype.flatpickr=function(e){return _flatpickr([this],e)}),"undefined"!=typeof jQuery&&(jQuery.fn.flatpickr=function(e){return _flatpickr(this,e)}),Date.prototype.fp_incr=function(e){return new Date(this.getFullYear(),this.getMonth(),this.getDate()+parseInt(e,10))},Date.prototype.fp_isUTC=!1,Date.prototype.fp_toUTC=function(){var e=new Date(this.getUTCFullYear(),this.getUTCMonth(),this.getUTCDate(),this.getUTCHours(),this.getUTCMinutes(),this.getUTCSeconds());return e.fp_isUTC=!0,e},!window.document.documentElement.classList&&Object.defineProperty&&"undefined"!=typeof HTMLElement&&Object.defineProperty(HTMLElement.prototype,"classList",{get:function(){function e(e){return function(n){var a=t.className.split(/\s+/),i=a.indexOf(n);e(a,i,n),t.className=a.join(" ")}}var t=this,n={add:e(function(e,t,n){~t||e.push(n)}),remove:e(function(e,t){~t&&e.splice(t,1)}),toggle:e(function(e,t,n){~t?e.splice(t,1):e.push(n)}),contains:function(e){return!!~t.className.split(/\s+/).indexOf(e)},item:function(e){return t.className.split(/\s+/)[e]||null}};return Object.defineProperty(n,"length",{get:function(){return t.className.split(/\s+/).length}}),n}}),"undefined"!=typeof module&&(module.exports=Flatpickr);
themes/countdown/style.css ADDED
@@ -0,0 +1,583 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ /*
2
+ Theme Name: Countdown
3
+ Theme URI: http://cmp.niteo.cz/?cmp_preview=true&theme=countdown
4
+ Author: Niteo
5
+ Author URI: http://niteo.cz/
6
+ Version: 1.2
7
+ Description: Premium Theme for CMP Coming Soon & Maintenance plugin
8
+ Text Domain: niteo
9
+
10
+ Normalizing styles have been helped along thanks to the fine work of
11
+ Nicolas Gallagher and Jonathan Neal http://necolas.github.com/normaalize.css/
12
+ */
13
+ /*--------------------------------------------------------------
14
+ # Normalize
15
+ --------------------------------------------------------------*/
16
+
17
+ html {
18
+ -webkit-text-size-adjust: 100%;
19
+ -ms-text-size-adjust: 100%;
20
+ }
21
+
22
+
23
+ article,
24
+ aside,
25
+ details,
26
+ figcaption,
27
+ figure,
28
+ footer,
29
+ header,
30
+ main,
31
+ menu,
32
+ nav,
33
+ section,
34
+ summary {
35
+ display: block;
36
+ }
37
+
38
+ article {
39
+ margin: 0;
40
+ }
41
+
42
+
43
+ article:last-of-type {
44
+ margin-bottom: 0;
45
+ }
46
+
47
+
48
+ audio,
49
+ canvas,
50
+ progress,
51
+ video {
52
+ display: inline-block;
53
+ vertical-align: baseline;
54
+ }
55
+
56
+ audio:not([controls]) {
57
+ display: none;
58
+ height: 0;
59
+ }
60
+
61
+ [hidden],
62
+ template {
63
+ display: none;
64
+ }
65
+
66
+ a {
67
+ background-color: transparent;
68
+ text-decoration: none;
69
+ -webkit-transition: color .3s ease-in-out;
70
+ -o-transition: color .3s ease-in-out;
71
+ transition: color .3s ease-in-out;
72
+
73
+ }
74
+
75
+ a:active,
76
+ a:hover {
77
+ outline: 0;
78
+ }
79
+
80
+ abbr[title] {
81
+ border-bottom: 1px dotted;
82
+ }
83
+
84
+ b,
85
+ strong {
86
+ font-weight: bold;
87
+ }
88
+
89
+ dfn {
90
+ font-style: italic;
91
+ }
92
+
93
+
94
+ small {
95
+ font-size: 80%;
96
+ }
97
+
98
+ sub,
99
+ sup {
100
+ font-size: 75%;
101
+ line-height: 0;
102
+ position: relative;
103
+ vertical-align: baseline;
104
+ }
105
+
106
+ sup {
107
+ top: -0.5em;
108
+ }
109
+
110
+ sub {
111
+ bottom: -0.25em;
112
+ }
113
+
114
+ img {
115
+ border: 0;
116
+ }
117
+
118
+ svg:not(:root) {
119
+ overflow: hidden;
120
+ }
121
+
122
+ figure {
123
+ margin: 0;
124
+ width: auto!important;
125
+ }
126
+
127
+ hr {
128
+ box-sizing: content-box;
129
+ height: 0;
130
+ }
131
+
132
+ pre {
133
+ overflow: auto;
134
+ }
135
+
136
+ code,
137
+ kbd,
138
+ pre,
139
+ samp {
140
+ font-family: monospace, monospace;
141
+ font-size: 1em;
142
+ }
143
+
144
+ code {
145
+ background-color: #BEFFE9;
146
+ }
147
+
148
+ button,
149
+ input,
150
+ optgroup,
151
+ select,
152
+ textarea {
153
+ color: inherit;
154
+ font: inherit;
155
+ margin: 0;
156
+ box-shadow: inset 0 0 0 0 !important;
157
+ -webkit-box-shadow: inset 0 0 0 0 !important;
158
+ border-radius: 0 !important;
159
+ -webkit-appearance: none;
160
+ outline: none;
161
+ }
162
+
163
+ textarea {
164
+ text-indent: 5px;
165
+ }
166
+
167
+ button {
168
+ overflow: visible;
169
+ }
170
+
171
+ button,
172
+ select {
173
+ text-transform: none;
174
+ }
175
+
176
+ button,
177
+ html input[type="button"],
178
+ input[type="reset"],
179
+ input[type="submit"] {
180
+ -webkit-appearance: button;
181
+ cursor: pointer;
182
+ text-indent: 0;
183
+ }
184
+
185
+ button[disabled],
186
+ html input[disabled] {
187
+ cursor: default;
188
+ }
189
+
190
+ button::-moz-focus-inner,
191
+ input::-moz-focus-inner {
192
+ border: 0;
193
+ padding: 0;
194
+ }
195
+
196
+ input {
197
+ line-height: normal;
198
+ text-indent: 5px;
199
+ }
200
+
201
+ input[type="checkbox"],
202
+ input[type="radio"] {
203
+ box-sizing: border-box;
204
+ padding: 0;
205
+ }
206
+
207
+ input[type="number"]::-webkit-inner-spin-button,
208
+ input[type="number"]::-webkit-outer-spin-button {
209
+ height: auto;
210
+ }
211
+
212
+ input[type="search"] {
213
+ -webkit-appearance: textfield;
214
+ box-sizing: content-box;
215
+ }
216
+
217
+ input[type="search"]::-webkit-search-cancel-button,
218
+ input[type="search"]::-webkit-search-decoration {
219
+ -webkit-appearance: none;
220
+ }
221
+
222
+ fieldset {
223
+ border: 1px solid #c0c0c0;
224
+ margin: 0 2px;
225
+ padding: 0.35em 0.625em 0.75em;
226
+ }
227
+
228
+ legend {
229
+ border: 0;
230
+ padding: 0;
231
+ }
232
+
233
+ textarea {
234
+ overflow: auto;
235
+ padding: 5px;
236
+ }
237
+
238
+ optgroup {
239
+ font-weight: bold;
240
+ }
241
+
242
+ table {
243
+ border-collapse: collapse;
244
+ border-spacing: 0;
245
+ }
246
+
247
+ td,
248
+ th {
249
+ padding: 0;
250
+ }
251
+
252
+ body{
253
+ margin:0;
254
+ position: relative;
255
+ }
256
+
257
+ h1 {
258
+ font-size: 2em;
259
+ }
260
+
261
+
262
+
263
+ h1,h2,h3,h4,h5,h6 {
264
+ font-weight: 700;
265
+ font-size: 2em;
266
+ margin-bottom: .3em;
267
+ }
268
+
269
+ h3,h4,h5,h6 {
270
+ font-size: 1.3em;
271
+ }
272
+
273
+ #background-wrapper {
274
+ position: relative;
275
+ display: -webkit-flex;
276
+ display: -moz-flex;
277
+ display: -ms-flexbox;
278
+ display: -o-flex;
279
+ display: flex;
280
+ min-height: 100vh;
281
+ padding: 0 1em;
282
+ -webkit-flex-direction: column;
283
+ -moz-flex-direction: column;
284
+ flex-direction: column;
285
+ text-align: center;
286
+ }
287
+
288
+
289
+ #background-image {
290
+ position: absolute;
291
+ top: 0;
292
+ right: 0;
293
+ bottom: 0;
294
+ left: 0;
295
+ background-position: center center;
296
+ background-repeat: no-repeat;
297
+ background-size: cover;
298
+ z-index: -1;
299
+ }
300
+
301
+ .background-overlay {
302
+ position: absolute;
303
+ top: 0;
304
+ right: 0;
305
+ bottom: 0;
306
+ left: 0;
307
+ z-index: -1;
308
+ }
309
+
310
+ #background-image.pattern {
311
+ background-repeat: repeat;
312
+ background-size: initial;
313
+ }
314
+
315
+
316
+
317
+ .inner-content,
318
+ footer {
319
+ display: -webkit-flex;
320
+ display: -moz-flex;
321
+ display: -ms-flexbox;
322
+ display: -o-flex;
323
+ display: flex;
324
+ max-width: 768px;
325
+ width: 768px;
326
+ margin: 0 auto;
327
+ padding: 0;
328
+ -webkit-flex-direction: column;
329
+ -moz-flex-direction: column;
330
+ flex-direction: column;
331
+ flex-grow: 1;
332
+ flex-shrink: 0;
333
+ -webkit-flex-grow: 1;
334
+ -webkit-flex-shrink: 0;
335
+ -moz-flex-grow: 1;
336
+ -moz-flex-shrink: 0;
337
+ justify-content: center;
338
+ -moz-justify-content: center;
339
+ -webkit-justify-content: center;
340
+ text-align: center;
341
+ overflow: hidden;
342
+ opacity: .9;
343
+ }
344
+
345
+
346
+ footer {
347
+ justify-content: flex-end;
348
+ display: flex;
349
+ flex-direction: column;
350
+ flex-grow: 0;
351
+ -webkit-flex-grow: 0;
352
+ }
353
+
354
+ .logo {
355
+ padding: 30px 0;
356
+ }
357
+
358
+ .logo img {
359
+ max-width: 350px;
360
+ max-height: 250px;
361
+ }
362
+
363
+ .body p {
364
+ font-size: 1.1em;
365
+ }
366
+
367
+ .social-list {
368
+ display: inline-block;
369
+ padding:0;
370
+ margin-bottom: 0;
371
+ padding-bottom: 10px;
372
+ }
373
+
374
+ .social-list li{
375
+ position: relative;
376
+ list-style: none;
377
+ display: inline-block;
378
+ padding: 0 2px;
379
+ }
380
+
381
+ .social-list a{
382
+ display: block;
383
+ height: 2em;
384
+ width: 2em;
385
+ line-height: 2em;
386
+ background: transparent;
387
+ -webkit-transition: background 300ms linear;
388
+ -o-transition: background 300ms linear;
389
+ transition: background 300ms linear;
390
+ }
391
+ .social-list i{
392
+ font-size: 1em;
393
+ -webkit-transition: all 300ms linear;
394
+ -o-transition: all 300ms linear;
395
+ transition: all 300ms linear;
396
+ }
397
+
398
+ .social-list.body li {
399
+ padding: 5px 10px;
400
+ }
401
+
402
+ .social-list.body i {
403
+ color: #ffffff;
404
+ }
405
+ /* .social-list a:hover i {
406
+ -webkit-animation: spin 300ms linear;
407
+ -moz-animation: spin 300ms linear;
408
+ animation: spin 300ms linear;
409
+ } */
410
+
411
+ .social-list.footer {
412
+ padding-bottom: 5px;
413
+ }
414
+
415
+ .social-list.footer li:not(:last-of-type)::after {
416
+ content: '';
417
+ position: absolute;
418
+ top: 5px;
419
+ bottom: 5px;
420
+ right: 0;
421
+ width: 1px;
422
+ opacity: .5;
423
+ }
424
+
425
+ .subscribe {
426
+ padding: 1em 0;
427
+ padding-bottom: 2em;
428
+ }
429
+
430
+ .copyright {
431
+ margin-top: 0;
432
+ }
433
+
434
+ .inner-content form {
435
+ text-align: left;
436
+ }
437
+
438
+ .inner-content form br {
439
+ display: none;
440
+ }
441
+
442
+ label {
443
+ display: block;
444
+ text-align: left;
445
+ padding-bottom: 10px;
446
+ }
447
+
448
+ .input-icon {
449
+ position: relative;
450
+ }
451
+
452
+ .input-icon:before {
453
+ font-family: 'fontAwesome';
454
+ content: '\f003';
455
+ position: absolute;
456
+ line-height: 3em;
457
+ padding-left: 10px;
458
+ }
459
+
460
+ input[type="email"].subscribe-input {
461
+ text-indent: 35px;
462
+ }
463
+
464
+ input:focus {
465
+ border: 1px solid #ffffff;
466
+ }
467
+ input[type="email"] {
468
+ width: 75%;
469
+ background-color: #ffffff;
470
+ text-indent: 15px;
471
+ font-style: italic;
472
+ border: 1px solid #dcdcdc;
473
+
474
+ }
475
+ input[type="submit"] {
476
+ width: 25%;
477
+ padding: 0;
478
+ margin-left:-6px;
479
+ color: white;
480
+ font-weight:700;
481
+ border: none;
482
+ letter-spacing: 1px;
483
+ cursor:pointer;
484
+ text-transform: uppercase;
485
+ }
486
+ input[type="email"],
487
+ input[type="submit"] {
488
+ display: inline-block;
489
+ line-height: 3em;
490
+ height: 3em;
491
+ box-sizing: border-box;
492
+ vertical-align: middle;
493
+ }
494
+
495
+ #counter {
496
+ padding: 1.5em 0 3em 0;
497
+ }
498
+
499
+ .counter-wrap {
500
+ position: relative;
501
+ display: inline-block;
502
+ width: calc(25% - 21px);
503
+ background-color: #ffffff;
504
+ }
505
+
506
+ .counter-wrap::before {
507
+ content: "";
508
+ display: block;
509
+ padding-top: 100%;
510
+ }
511
+
512
+ .counter-wrap:not(:last-of-type) {
513
+ margin-right: 20px;
514
+ }
515
+
516
+ .inner-counter {
517
+ position: absolute;
518
+ top: 50%;
519
+ right: 0;
520
+ left: 0;
521
+ -webkit-transform: translateY(-50%);
522
+ -ms-transform: translateY(-50%);
523
+ -o-transform: translateY(-50%);
524
+ transform: translateY(-50%);
525
+ }
526
+
527
+ .counter-wrap p {
528
+ margin: 0;
529
+ font-weight: 700;
530
+ }
531
+
532
+ .counter-wrap span {
533
+ display: inline-block;
534
+ font-weight: 700;
535
+ font-size: 3em;
536
+ }
537
+
538
+ /* contact form 7 */
539
+ .wpcf7 .screen-reader-response, .wpcf7 .wpcf7-validation-errors {display: none;}
540
+ .wpcf7 .wpcf7-form-control-wrap {position: relative;}
541
+ .wpcf7-form .wpcf7-not-valid-tip {position: absolute;bottom: -3em;left: 15px;right: -100px;text-align: left;}
542
+
543
+
544
+
545
+ @-webkit-keyframes spin {
546
+ from { -webkit-transform: rotate(0deg); }
547
+ to { -webkit-transform: rotate(360deg); }
548
+ }
549
+ @keyframes spin {
550
+ from {transform:rotate(0deg);}
551
+ to {transform:rotate(360deg);}
552
+ }
553
+
554
+ @media only screen and (max-width : 1024px) {
555
+
556
+
557
+ }
558
+
559
+ @media only screen and (max-width : 820px) {
560
+ .counter-wrap:not(:last-of-type) {margin-right: 30px;}
561
+ .counter-wrap{width: calc(25% - 28px);}
562
+ #counter {padding-bottom: 0;}
563
+ }
564
+
565
+ @media only screen and (max-width : 768px) {
566
+ .inner-content, footer {width:auto;}
567
+ }
568
+
569
+ @media only screen and (max-width : 620px) {
570
+ .counter-wrap span {font-size: 2em;}
571
+ .counter-wrap {width: calc(25% - 17px);}
572
+ .counter-wrap:not(:last-of-type) {margin-right: 15px;}
573
+ }
574
+
575
+ @media only screen and (max-width : 520px) {
576
+ .counter-wrap p {font-size: .7em;}
577
+ .counter-wrap {width: calc(25% - 6px);}
578
+ .counter-wrap:not(:last-of-type) {margin-right: 0;}
579
+ input[type="email"], input[type="submit"] {display:block;width:100%;}
580
+ input[type="submit"] {margin:0;}
581
+ input[type="email"]{margin-bottom: 5px;}
582
+ .logo img {max-width: 250px;}
583
+ }
themes/hardwork/hardwork-settings.php CHANGED
@@ -70,9 +70,8 @@ if ( $_SERVER['REQUEST_METHOD'] == 'POST' ) {
70
  <fieldset id="overlay-color">
71
  <input type="text" name="niteoCS_overlay_color_hardwork" id="niteoCS_overlay_color" value="<?php echo esc_attr( $niteoCS_overlay_color); ?>" data-default-color="#0a0a0a" class="regular-text code"><br>
72
 
73
- <label for="niteoCS_overlay_opacity"><?php _e('Overlay Opacity', 'cmp');?></label><br>
74
- <input type="range" id="niteoCS_overlay_opacity" name="niteoCS_overlay_opacity_hardwork" min="0" max="1" step="0.1"value="<?php echo esc_attr( $niteoCS_overlay_opacity); ?>" />
75
- <p class="opacity-value">Current value: <span id="current-opacity"><?php echo esc_attr( $niteoCS_overlay_opacity); ?></span></p>
76
  </fieldset>
77
  </td>
78
  </tr>
70
  <fieldset id="overlay-color">
71
  <input type="text" name="niteoCS_overlay_color_hardwork" id="niteoCS_overlay_color" value="<?php echo esc_attr( $niteoCS_overlay_color); ?>" data-default-color="#0a0a0a" class="regular-text code"><br>
72
 
73
+ <label for="niteoCS_overlay_opacity"><?php _e('Overlay Opacity', 'cmp');?> <span id="current-opacity">: <?php echo esc_attr( $niteoCS_overlay_opacity); ?></span></label><br>
74
+ <input type="range" id="niteoCS_overlay_opacity" name="niteoCS_overlay_opacity_countdown" min="0" max="1" step="0.1"value="<?php echo esc_attr( $niteoCS_overlay_opacity); ?>" />
 
75
  </fieldset>
76
  </td>
77
  </tr>
themes/hardwork/hardwork-theme.php CHANGED
@@ -11,7 +11,7 @@
11
 
12
  <?php
13
  // get saved style options
14
- $ver = '1.5';
15
  $font_color = get_option('niteoCS_font_color[hardwork]', '#ffffff');
16
  $background_color = get_option('niteoCS_overlay_color[hardwork]', '#000000');
17
  $background_opa = get_option('niteoCS_overlay_opacity[hardwork]', '0.5');
@@ -216,7 +216,10 @@
216
  $niteoCS_banner_pattern = get_option('niteoCS_banner_pattern', 'sakura');
217
 
218
  if ($niteoCS_banner_pattern != 'custom') {
219
- $banner_url = str_replace('themes', '', plugin_dir_url( dirname( __FILE__ ) )) . 'img/patterns/'.esc_attr($niteoCS_banner_pattern).'.png';
 
 
 
220
  } else {
221
  $banner_url = get_option('niteoCS_banner_pattern_custom');
222
  }
11
 
12
  <?php
13
  // get saved style options
14
+ $ver = '1.7';
15
  $font_color = get_option('niteoCS_font_color[hardwork]', '#ffffff');
16
  $background_color = get_option('niteoCS_overlay_color[hardwork]', '#000000');
17
  $background_opa = get_option('niteoCS_overlay_opacity[hardwork]', '0.5');
216
  $niteoCS_banner_pattern = get_option('niteoCS_banner_pattern', 'sakura');
217
 
218
  if ($niteoCS_banner_pattern != 'custom') {
219
+ $banner_url = plugins_url('cmp-coming-soon-maintenance/img/patterns/'.esc_attr($niteoCS_banner_pattern).'.png');
220
+ // echo copyright pattern
221
+ echo '<!-- Background pattern from Subtle Patterns --!>';
222
+
223
  } else {
224
  $banner_url = get_option('niteoCS_banner_pattern_custom');
225
  }
themes/hardwork/img/hardwork_banner_full.jpg CHANGED
Binary file
themes/hardwork/img/hardwork_banner_large.jpg CHANGED
Binary file
themes/hardwork/style.css CHANGED
@@ -3,7 +3,7 @@ Theme Name: Hardwork
3
  Theme URI: http://cmp.niteo.cz/?cmp_preview=true&theme=hardwork
4
  Author: Niteo
5
  Author URI: http://niteo.cz/
6
- Version: 1.5
7
  Description: Premium Theme for CMP Coming Soon & Maintenance plugin
8
  Text Domain: niteo
9
 
@@ -21,7 +21,7 @@ body{
21
 
22
  h1,h2,h3,h4,h5,h6{
23
  font-weight: 400;
24
- font-size: 3.5em;
25
  margin-bottom: .3em;
26
  }
27
  .section {
@@ -48,22 +48,26 @@ h1,h2,h3,h4,h5,h6{
48
  -moz-flex-grow: 10;
49
  }
50
 
 
 
 
 
51
 
52
  .logo-wrapper {
53
- padding: 50px 0;
54
  max-width: 500px;
55
  margin: 0 auto;
56
  }
57
 
58
  .logo-wrapper img {
59
  max-width: 100%;
 
60
  }
61
 
62
 
63
  .section-body p {
64
  max-width: 70%;
65
  margin:1em auto;
66
- font-size: 1.2em;
67
  }
68
 
69
  #background-wrapper,
3
  Theme URI: http://cmp.niteo.cz/?cmp_preview=true&theme=hardwork
4
  Author: Niteo
5
  Author URI: http://niteo.cz/
6
+ Version: 1.7
7
  Description: Premium Theme for CMP Coming Soon & Maintenance plugin
8
  Text Domain: niteo
9
 
21
 
22
  h1,h2,h3,h4,h5,h6{
23
  font-weight: 400;
24
+ font-size: 2.5em;
25
  margin-bottom: .3em;
26
  }
27
  .section {
48
  -moz-flex-grow: 10;
49
  }
50
 
51
+ .section-social {
52
+ flex-grow: 0;
53
+ }
54
+
55
 
56
  .logo-wrapper {
 
57
  max-width: 500px;
58
  margin: 0 auto;
59
  }
60
 
61
  .logo-wrapper img {
62
  max-width: 100%;
63
+ max-height: 300px;
64
  }
65
 
66
 
67
  .section-body p {
68
  max-width: 70%;
69
  margin:1em auto;
70
+ font-size: 1.1em;
71
  }
72
 
73
  #background-wrapper,