PluginProbe ʕ •ᴥ•ʔ
My Sticky Bar – Floating Notification Bar & Sticky Header (formerly myStickymenu) / 2.2.8
My Sticky Bar – Floating Notification Bar & Sticky Header (formerly myStickymenu) v2.2.8
2.9.1 2.9.0 2.8.9 2.8.8 trunk 1.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.8.1 1.8.2 1.8.3 1.8.4 1.8.5 1.8.6 1.8.7 1.8.8 1.8.9 1.9 1.9.1 2.0 2.0.1 2.0.3 2.0.4 2.0.5 2.0.6 2.1 2.1.1 2.1.2 2.1.3 2.1.4 2.1.5 2.1.6 2.1.7 2.1.8 2.2 2.2.1 2.2.2 2.2.3 2.2.4 2.2.5 2.2.6 2.2.7 2.2.8 2.2.9 2.3 2.3.1 2.3.2 2.3.3 2.3.4 2.3.5 2.3.6 2.3.7 2.3.8 2.3.9 2.4 2.4.1 2.4.2 2.4.3 2.4.4 2.4.5 2.4.6 2.4.7 2.4.8 2.4.9 2.5 2.5.1 2.5.2 2.5.3 2.5.4 2.5.5 2.5.6 2.5.7 2.5.8 2.5.9 2.6 2.6.1 2.6.2 2.6.3 2.6.4 2.6.5 2.6.6 2.6.7 2.6.8 2.6.9 2.7 2.7.1 2.7.2 2.7.3 2.7.4 2.7.5 2.7.6 2.7.7 2.7.8 2.7.9 2.8.0 2.8.1 2.8.2 2.8.3 2.8.4 2.8.5 2.8.6 2.8.7
mystickymenu / welcome-bar.php
mystickymenu Last commit date
css 6 years ago fonts 7 years ago images 6 years ago js 6 years ago languages 7 years ago class-review-box.php 6 years ago index.php 8 years ago mystickymenu-affiliate.php 6 years ago mystickymenu-fonts.php 6 years ago mystickymenu.php 6 years ago readme.txt 6 years ago uninstall.php 7 years ago welcome-bar.php 6 years ago
welcome-bar.php
1647 lines
1 <?php
2
3 function mysticky_welcome_bar_backend() {
4 $upgarde_url = admin_url("admin.php?page=my-stickymenu-upgrade");
5 $nonce = wp_create_nonce('mysticky_option_welcomebar_update');
6 $nonce_reset = wp_create_nonce('mysticky_option_welcomebar_reset');
7
8 $welcomebar = get_option( 'mysticky_option_welcomebar' );
9 if ( $welcomebar == '' || empty($welcomebar)) {
10 $welcomebar = mysticky_welcomebar_pro_widget_default_fields();
11 }
12
13 $mysticky_welcomebar_showx_desktop = $mysticky_welcomebar_showx_mobile = '';
14 $mysticky_welcomebar_btn_desktop = $mysticky_welcomebar_btn_mobile = '';
15 $mysticky_welcomebar_display_desktop = $mysticky_welcomebar_display_mobile = '';
16 if( isset($welcomebar['mysticky_welcomebar_x_desktop']) ) {
17 $mysticky_welcomebar_showx_desktop = ' mysticky-welcomebar-showx-desktop';
18 }
19 if( isset($welcomebar['mysticky_welcomebar_x_mobile']) ) {
20 $mysticky_welcomebar_showx_mobile = ' mysticky-welcomebar-showx-mobile';
21 }
22 if( isset($welcomebar['mysticky_welcomebar_btn_desktop']) ) {
23 $mysticky_welcomebar_btn_desktop = ' mysticky-welcomebar-btn-desktop';
24 }
25 if( isset($welcomebar['mysticky_welcomebar_btn_mobile']) ) {
26 $mysticky_welcomebar_btn_mobile = ' mysticky-welcomebar-btn-mobile';
27 }
28 $display = ' mysticky-welcomebar-attention-'.$welcomebar['mysticky_welcomebar_attentionselect'];
29 $display_main_class = "mysticky-welcomebar-position-" . $welcomebar['mysticky_welcomebar_position'] . $mysticky_welcomebar_showx_desktop . $mysticky_welcomebar_showx_mobile . $mysticky_welcomebar_btn_desktop . $mysticky_welcomebar_btn_mobile . $display;
30 ?>
31 <form class="mysticky-welcomebar-form" id="mysticky_welcomebar_form" method="post" action="#">
32 <div class="mysticky-welcomebar-header-title">
33 <h3><?php _e('myStickymenu', 'myStickymenu'); ?></h3>
34 <label for="mysticky-welcomebar-contact-form-enabled" class="mysticky-welcomebar-switch">
35 <input type="checkbox" id="mysticky-welcomebar-contact-form-enabled" name="mysticky_option_welcomebar[mysticky_welcomebar_enable]" value="1" <?php checked( @$welcomebar['mysticky_welcomebar_enable'], '1' );?> />
36 <span class="slider"></span>
37 </label>
38 </div>
39 <div class="mysticky-welcomebar-setting-wrap">
40 <div class="mysticky-welcomebar-setting-left">
41 <div class="mysticky-welcomebar-setting-block">
42 <div class="mysticky-welcomebar-subheader-title">
43 <h4><?php _e('Design', 'myStickymenu'); ?></h4>
44 </div>
45 <div class="mysticky-welcomebar-setting-content mysticky-welcomebar-setting-position">
46 <label><?php _e('Position', 'myStickymenu'); ?></label>
47 <div class="mysticky-welcomebar-setting-content-right">
48 <label>
49 <input name="mysticky_option_welcomebar[mysticky_welcomebar_position]" value= "top" type="radio" <?php checked( @$welcomebar['mysticky_welcomebar_position'], 'top' );?> />
50 <?php _e("Top", 'mystickymenu'); ?>
51 </label>
52 <label>
53 <input name="mysticky_option_welcomebar[mysticky_welcomebar_position]" value="bottom" type="radio" disabled />
54 <?php _e("Bottom", 'mystickymenu'); ?>
55 </label>
56 <span class="myStickymenu-upgrade"><a class="sticky-header-upgrade-now" href="<?php echo esc_url($upgarde_url); ?>" target="_blank"><?php _e( 'Upgrade Now', 'mystickymenu' );?></a></span>
57 </div>
58 </div>
59 <div class="mysticky-welcomebar-setting-content">
60 <label><?php _e('Height', 'myStickymenu'); ?></label>
61 <div class="mysticky-welcomebar-setting-content-right">
62 <div class="px-wrap">
63 <input type="number" class="" min="0" step="1" id="mysticky_welcomebar_height" name="mysticky_option_welcomebar[mysticky_welcomebar_height]" value="60" disabled />
64 <span class="input-px">PX</span>
65 </div>
66 <span class="myStickymenu-upgrade"><a class="sticky-header-upgrade-now" href="<?php echo esc_url($upgarde_url); ?>" target="_blank"><?php _e( 'Upgrade Now', 'mystickymenu' );?></a></span>
67 </div>
68 </div>
69 <div class="mysticky-welcomebar-setting-content">
70 <label><?php _e('Background Color', 'myStickymenu'); ?></label>
71 <div class="mysticky-welcomebar-setting-content-right mysticky-welcomebar-colorpicker">
72 <input type="text" id="mysticky_welcomebar_bgcolor" name="mysticky_option_welcomebar[mysticky_welcomebar_bgcolor]" class="my-color-field" value="<?php echo $welcomebar['mysticky_welcomebar_bgcolor'];?>" />
73 </div>
74 </div>
75 <div class="mysticky-welcomebar-setting-content">
76 <label><?php _e('Background Text Color', 'myStickymenu'); ?></label>
77 <div class="mysticky-welcomebar-setting-content-right mysticky-welcomebar-colorpicker">
78 <input type="text" id="mysticky_welcomebar_bgtxtcolor" name="mysticky_option_welcomebar[mysticky_welcomebar_bgtxtcolor]" class="my-color-field" value="<?php echo $welcomebar['mysticky_welcomebar_bgtxtcolor'];?>" />
79 </div>
80 </div>
81 <div class="mysticky-welcomebar-setting-content">
82 <label><?php _e('Font', 'myStickymenu'); ?></label>
83 <div class="mysticky-welcomebar-setting-content-right">
84 <select name="mysticky_option_welcomebar[mysticky_welcomebar_font]" class="form-fonts">
85 <option value=""><?php _e( 'Select font family', 'myStickymenu' );?></option>
86 <?php $group= ''; foreach( myStickymenu_fonts() as $key=>$value):
87 if ($value != $group){
88 echo '<optgroup label="' . $value . '">';
89 $group = $value;
90 }
91 ?>
92 <option value="<?php echo esc_attr($key);?>" <?php selected( @$welcomebar['mysticky_welcomebar_font'], $key ); ?>><?php echo esc_html($key);?></option>
93 <?php endforeach;?>
94 </select>
95 </div>
96 </div>
97 <div class="mysticky-welcomebar-setting-content">
98 <label><?php _e('Font Size', 'myStickymenu'); ?></label>
99 <div class="mysticky-welcomebar-setting-content-right">
100 <div class="px-wrap">
101 <input type="number" class="" min="0" step="1" id="mysticky_welcomebar_fontsize" name="mysticky_option_welcomebar[mysticky_welcomebar_fontsize]" value="<?php echo @$welcomebar['mysticky_welcomebar_fontsize'];?>" />
102 <span class="input-px">PX</span>
103 </div>
104 </div>
105 </div>
106 <div class="mysticky-welcomebar-setting-content">
107 <label><?php _e('Bar Text', 'myStickymenu'); ?></label>
108 <div class="mysticky-welcomebar-setting-content-right">
109 <input type="text" id="mysticky_bar_text" class="mystickyinput" name="mysticky_option_welcomebar[mysticky_welcomebar_bar_text]" value="<?php echo esc_attr( stripslashes($welcomebar['mysticky_welcomebar_bar_text']));?>" />
110 </div>
111 </div>
112 <div class="mysticky-welcomebar-setting-content">
113 <label><?php _e('Show X', 'myStickymenu'); ?></label>
114 <div class="mysticky-welcomebar-setting-content-right">
115 <label>
116 <input name="mysticky_option_welcomebar[mysticky_welcomebar_x_desktop]" value= "desktop" type="checkbox" <?php checked( @$welcomebar['mysticky_welcomebar_x_desktop'], 'desktop' );?> />
117 <?php _e( 'Desktop', 'mystickymenu' );?>
118 </label>
119 <label>
120 <input name="mysticky_option_welcomebar[mysticky_welcomebar_x_mobile]" value= "mobile" type="checkbox" <?php checked( @$welcomebar['mysticky_welcomebar_x_mobile'], 'mobile' );?> />
121 <?php _e( 'Mobile', 'mystickymenu' );?>
122 </label>
123 </div>
124 </div>
125 </div>
126 <div class="mysticky-welcomebar-setting-block">
127 <div class="mysticky-welcomebar-subheader-title">
128 <h4><?php _e('Button', 'myStickymenu'); ?></h4>
129 </div>
130 <div class="mysticky-welcomebar-setting-content">
131 <label><?php _e('Button', 'myStickymenu'); ?></label>
132 <div class="mysticky-welcomebar-setting-content-right">
133 <label>
134 <input name="mysticky_option_welcomebar[mysticky_welcomebar_btn_desktop]" value= "desktop" type="checkbox" <?php checked( @$welcomebar['mysticky_welcomebar_btn_desktop'], 'desktop' );?> />
135 <?php _e( 'Desktop', 'mystickymenu' );?>
136 </label>
137 <label>
138 <input name="mysticky_option_welcomebar[mysticky_welcomebar_btn_mobile]" value= "mobile" type="checkbox"<?php checked( @$welcomebar['mysticky_welcomebar_btn_mobile'], 'mobile' );?> />
139 <?php _e( 'Mobile', 'mystickymenu' );?>
140 </label>
141 </div>
142 </div>
143 <div class="mysticky-welcomebar-setting-content">
144 <label><?php _e('Button Color', 'myStickymenu'); ?></label>
145 <div class="mysticky-welcomebar-setting-content-right mysticky-welcomebar-colorpicker">
146 <input type="text" id="mysticky_welcomebar_btncolor" name="mysticky_option_welcomebar[mysticky_welcomebar_btncolor]" class="my-color-field" value="<?php echo esc_attr($welcomebar['mysticky_welcomebar_btncolor']);?>" />
147 </div>
148 </div>
149 <div class="mysticky-welcomebar-setting-content">
150 <label><?php _e('Button Text Color', 'myStickymenu'); ?></label>
151 <div class="mysticky-welcomebar-setting-content-right mysticky-welcomebar-colorpicker">
152 <input type="text" id="mysticky_welcomebar_btntxtcolor" name="mysticky_option_welcomebar[mysticky_welcomebar_btntxtcolor]" class="my-color-field" value="<?php echo $welcomebar['mysticky_welcomebar_btntxtcolor'];?>" />
153 </div>
154 </div>
155 <div class="mysticky-welcomebar-setting-content">
156 <label><?php _e('Button Text', 'myStickymenu'); ?></label>
157 <div class="mysticky-welcomebar-setting-content-right">
158 <input type="text" id="mysticky_welcomebar_btn_text" class="mystickyinput" name="mysticky_option_welcomebar[mysticky_welcomebar_btn_text]" value="<?php echo $welcomebar['mysticky_welcomebar_btn_text'];?>" />
159 </div>
160 </div>
161 <div class="mysticky-welcomebar-setting-content">
162 <label><?php _e('Action', 'myStickymenu'); ?></label>
163 <div class="mysticky-welcomebar-setting-content-right mysticky-welcomebar-setting-redirect-wrap">
164 <div class="mysticky-welcomebar-setting-action">
165 <select name="mysticky_option_welcomebar[mysticky_welcomebar_actionselect]" class="mysticky-welcomebar-action">
166 <option value="redirect_to_url" <?php selected( @$welcomebar['mysticky_welcomebar_actionselect'], 'redirect_to_url' ); ?>><?php _e( 'Redirect to URL', 'myStickymenu' );?></option>
167 <option value="close_bar" <?php selected( @$welcomebar['mysticky_welcomebar_actionselect'], 'close_bar' ); ?>><?php _e( 'Close bar', 'myStickymenu' );?></option>
168 </select>
169 </div>
170 <div class="mysticky-welcomebar-setting-action mysticky-welcomebar-redirect" <?php if ( $welcomebar['mysticky_welcomebar_actionselect'] == 'close_bar' ) : ?> style="display:none;" <?php endif;?> >
171 <input type="text" id="mysticky_welcomebar_redirect" class="mystickyinput" name="mysticky_option_welcomebar[mysticky_welcomebar_redirect]" value="<?php echo esc_url($welcomebar['mysticky_welcomebar_redirect']);?>" placeholder="<?php echo esc_url("https://www.yourdomain.com"); ?>" />
172 </div>
173 <div class="mysticky-welcomebar-setting-newtab mysticky-welcomebar-redirect" <?php if ( $welcomebar['mysticky_welcomebar_actionselect'] == 'close_bar' ) : ?> style="display:none;" <?php endif;?> >
174 <label>
175 <input name="mysticky_option_welcomebar[mysticky_welcomebar_redirect_newtab]" value= "1" type="checkbox" disabled />
176 <?php _e( 'Open in a new tab', 'mystickymenu' );?>
177 </label>
178 <span class="myStickymenu-upgrade"><a class="sticky-header-upgrade-now" href="<?php echo esc_url($upgarde_url); ?>" target="_blank"><?php _e( 'Upgrade Now', 'mystickymenu' );?></a></span>
179 </div>
180 </div>
181 </div>
182 <!-- -->
183 <div class="mysticky-welcomebar-setting-content">
184 <label><?php _e('Attention Effect', 'myStickymenu'); ?></label>
185 <div class="mysticky-welcomebar-setting-content-right">
186 <div class="mysticky-welcomebar-setting-attention">
187 <select name="mysticky_option_welcomebar[mysticky_welcomebar_attentionselect]" class="mysticky-welcomebar-attention">
188 <option value="default" <?php selected( @$welcomebar['mysticky_welcomebar_attentionselect'], ' ' ); ?>><?php _e( 'None', 'myStickymenu' );?></option>
189 <option value="flash" <?php selected( @$welcomebar['mysticky_welcomebar_attentionselect'], 'flash' ); ?>><?php _e( 'Flash', 'myStickymenu' );?></option>
190 <option value="shake" <?php selected( @$welcomebar['mysticky_welcomebar_attentionselect'], 'shake' ); ?>><?php _e( 'Shake', 'myStickymenu' );?></option>
191 <option value="swing" <?php selected( @$welcomebar['mysticky_welcomebar_attentionselect'], 'swing' ); ?>><?php _e( 'Swing', 'myStickymenu' );?></option>
192 <option value="tada" <?php selected( @$welcomebar['mysticky_welcomebar_attentionselect'], 'tada' ); ?>><?php _e( 'Tada', 'myStickymenu' );?></option>
193 <option value="heartbeat" <?php selected( @$welcomebar['mysticky_welcomebar_attentionselect'], 'heartbeat' ); ?>><?php _e( 'Heartbeat', 'myStickymenu' );?></option>
194 <option value="wobble" <?php selected( @$welcomebar['mysticky_welcomebar_attentionselect'], 'wobble' ); ?>><?php _e( 'Wobble', 'myStickymenu' );?></option>
195 </select>
196 </div>
197 </div>
198 </div>
199 <!-- -->
200 <div class="mysticky-welcomebar-setting-content mysticky-welcomebar-setting-remove-getbar">
201 <label><?php _e('Remove myStickymenu', 'myStickymenu'); ?></label>
202 <div class="mysticky-welcomebar-setting-content-right">
203 <div class="mysticky-welcomebar-switch">
204 <input type="checkbox" id="mysticky-welcomebar-remove-getbar" name="mysticky_option_welcomebar[mysticky_welcomebar_remove_getbar]" value="1" disabled />
205 <span class="slider"></span>
206 </div>
207 <span class="myStickymenu-upgrade"><a class="sticky-header-upgrade-now" href="<?php echo esc_url($upgarde_url); ?>" target="_blank"><?php _e( 'Upgrade Now', 'mystickymenu' );?></a></span>
208 </div>
209 </div>
210 </div>
211 <div class="mysticky-welcomebar-setting-block">
212 <div class="mysticky-welcomebar-subheader-title">
213 <h4><?php _e('Display Rules', 'myStickymenu'); ?></h4>
214 </div>
215 <div class="mysticky-welcomebar-upgrade-main mysticky_device_upgrade">
216 <span class="myStickymenu-upgrade">
217 <a class="sticky-header-upgrade-now" href="<?php echo esc_url($upgarde_url); ?>" target="_blank"><?php _e( ' Upgrade Now', 'mystickymenu' );?></a>
218 </span>
219 <div class="mysticky-welcomebar-setting-content">
220 <label><?php _e('Devices', 'myStickymenu'); ?></label>
221 <div class="mysticky-welcomebar-setting-content-right">
222 <label>
223 <input name="mysticky_option_welcomebar[mysticky_welcomebar_device_desktop]" value= "desktop" type="checkbox" checked disabled />
224 <?php _e( 'Desktop', 'mystickymenu' );?>
225 </label>
226 <label>
227 <input name="mysticky_option_welcomebar[mysticky_welcomebar_device_mobile]" value= "mobile" type="checkbox" checked disabled />
228 <?php _e( 'Mobile', 'mystickymenu' );?>
229 </label>
230 </div>
231 </div>
232 <div class="mysticky-welcomebar-setting-content">
233 <label><?php _e('Trigger', 'myStickymenu'); ?></label>
234 <div class="mysticky-welcomebar-setting-content-right">
235 <div class="mysticky-welcomebar-setting-action mysticky-welcomebar-trigger-wrap">
236 <label>
237 <input type="radio" name="mysticky_option_welcomebar[mysticky_welcomebar_trigger]" value="after_a_few_seconds" checked disabled />&nbsp;<?php _e( 'After a few seconds', 'myStickymenu' );?>
238 </label>
239 <label>
240 <input type="radio" name="mysticky_option_welcomebar[mysticky_welcomebar_trigger]" value="after_scroll" disabled />&nbsp;<?php _e( 'After Scroll', 'myStickymenu' );?>
241 </label>
242 </div>
243 <div class="mysticky-welcomebar-setting-action mysticky-welcomebar-triggersec">
244 <div class="px-wrap">
245 <input type="number" class="" min="0" step="1" id="mysticky_welcomebar_triggersec" name="mysticky_option_welcomebar[mysticky_welcomebar_triggersec]" value="0" disabled />
246 <span class="input-px"><?php echo ( isset($welcomebar['mysticky_welcomebar_trigger']) && $welcomebar['mysticky_welcomebar_trigger'] == 'after_scroll' ) ? '%' : 'Sec'; ?></span>
247 </div>
248 </div>
249 </div>
250 </div>
251 <div class="mysticky-welcomebar-setting-content">
252 <label><?php _e('Expiry date', 'myStickymenu'); ?></label>
253 <div class="mysticky-welcomebar-setting-content-right">
254 <div class="mysticky-welcomebar-expirydate">
255 <input type="text" id="mysticky_welcomebar_expirydate" name="mysticky_option_welcomebar[mysticky_welcomebar_expirydate]" placeholder="<?php _e('No expiry date', 'myStickymenu'); ?>" value="" disabled />
256 <span class="dashicons dashicons-calendar-alt"></span>
257 </div>
258 </div>
259 </div>
260 <div class="mysticky-welcomebar-setting-content show-on-apper">
261 <label><?php _e('Page targeting', 'myStickymenu'); ?></label>
262 <div class="mysticky-welcomebar-setting-content-right">
263 <a href="javascript:void(0);" class="create-rule" id="create-rule"><?php esc_html_e( "Add Rule", "mystickyelements" );?></a>
264 </div>
265 <div class="mysticky-welcomebar-page-options-html" style="display: none">
266 <div class="mysticky-welcomebar-page-option">
267 <div class="url-content">
268 <div class="mysticky-welcomebar-url-select">
269 <select name="mysticky_option_welcomebar[page_settings][__count__][shown_on]" id="url_shown_on___count___option" disabled>
270 <option value="show_on"><?php esc_html_e("Show on", "mysticky" );?></option>
271 <option value="not_show_on"><?php esc_html_e("Don't show on", "mysticky" );?></option>
272 </select>
273 </div>
274 <div class="mysticky-welcomebar-url-option">
275 <select class="mysticky-welcomebar-url-options" name="mysticky_option_welcomebar[page_settings][__count__][option]" id="url_rules___count___option" disabled>
276 <option selected="selected" disabled value=""><?php esc_html_e("Select Rule", "mysticky" );?></option>
277 </select>
278 </div>
279 <div class="mysticky-welcomebar-url-box">
280 <span class='mysticky-welcomebar-url'><?php echo site_url("/"); ?></span>
281 </div>
282 <div class="mysticky-welcomebar-url-values">
283 <input type="text" value="" name="mysticky_option_welcomebar[page_settings][__count__][value]" id="url_rules___count___value" disabled />
284 </div>
285 <div class="clear"></div>
286 </div>
287 </div>
288 </div>
289 <div class="mysticky-welcomebar-page-options mysticky-welcomebar-setting-content-right" id="mysticky-welcomebar-page-options" style="display:none"></div>
290 </div>
291 </div>
292 </div>
293 </div>
294 <div class="mysticky-welcomebar-setting-right">
295 <div class="mysticky-welcomebar-header-title">
296 <h3><?php _e('Preview', 'mystickyelements'); ?></h3>
297 </div>
298 <div class="mysticky-welcomebar-preview-screen">
299 <link href="https://fonts.googleapis.com/css?family=<?php echo $welcomebar['mysticky_welcomebar_font'] ?>:400,600,700|Lato:400,500,600,700" rel="stylesheet" type="text/css" class="sfba-google-font">
300 <div class="mysticky-welcomebar-fixed mysticky-welcomebar-display-desktop <?php echo $display_main_class; ?>" >
301 <div class="mysticky-welcomebar-content">
302 <p><?php echo isset($welcomebar['mysticky_welcomebar_bar_text'])? stripslashes($welcomebar['mysticky_welcomebar_bar_text']) :"Get 30% off your first purchase";?></p>
303 </div>
304 <div class="mysticky-welcomebar-btn">
305 <a href="#" ><?php echo isset($welcomebar['mysticky_welcomebar_btn_text']) ? $welcomebar['mysticky_welcomebar_btn_text'] : "Got it!";?></a>
306 </div>
307 <a href="javascript:void(0)" class="mysticky-welcomebar-close">X</a>
308 <a href="#" class="mysticky-welcomebar-getbar"><?php _e( 'myStickymenu', 'mystickymenu' );?></a>
309 </div>
310 </div>
311 </div>
312 </div>
313 <div class="mysticky-welcomebar-submit">
314 <input type="submit" name="submit" id="submit" class="button button-primary" value="<?php _e('Save', 'mystickymenu');?>">
315 </div>
316 <input type="hidden" name="nonce" value="<?php echo $nonce; ?>">
317 <input type="hidden" name="active_tab_element" value="1">
318 <input type="hidden" id="save_welcome_bar" name="save_welcome_bar" value="">
319
320 </form>
321 <form class="mysticky-welcomebar-form-reset" method="post" action="#">
322 <div class="mysticky-welcomebar-submit">
323 <input type="submit" name="mysticky_welcomebar_reset" id="reset" class="button button-secondary" value="<?php _e('Reset', 'mystickymenu');?>">
324 </div>
325 <input type="hidden" name="nonce_reset" value="<?php echo $nonce_reset; ?>">
326 <input type="hidden" name="active_tab_element" value="1">
327 </form>
328 <div id="mysticky-welcomebar-save-confirm" style="display:none;" title="<?php esc_attr_e( 'myStickymenu is currently off', 'mystickymenu' ); ?>">
329 <p>
330 <?php _e('Your Welcome Bar is currently turned off, would you like to save and show it on your site?', 'mystickymenu' ); ?>
331 </p>
332 </div>
333 <script>
334 jQuery(".mysticky-welcomebar-fixed").on(
335 "animationend MSAnimationEnd webkitAnimationEnd oAnimationEnd",
336 function() {
337 jQuery(this).removeClass("animation-start");
338 }
339 );
340 jQuery(document).ready(function() {
341 var container = jQuery(".mysticky-welcomebar-fixed");
342 var refreshId = setInterval(function() {
343 container.addClass("animation-start");
344 }, 3500);
345 });
346 </script>
347 <style>
348 .mysticky-welcomebar-fixed {
349 height: 80px;
350 background-color: <?php echo $welcomebar['mysticky_welcomebar_bgcolor'] ?>;
351 font-family: <?php echo $welcomebar['mysticky_welcomebar_font'] ?>;
352 position: absolute;
353 left: 0;
354 right: 0;
355 display: none;
356 align-items: center;
357 justify-content: center;
358 padding: 20px 30px 20px 10px;
359 z-index: 9999999;
360 }
361 .mysticky-welcomebar-preview-mobile-screen .mysticky-welcomebar-fixed{
362 padding: 0 25px;
363 }
364 .mysticky-welcomebar-display-desktop.mysticky-welcomebar-fixed {
365 display: flex;
366 }
367 .mysticky-welcomebar-position-top {
368 top:0;
369 }
370 .mysticky-welcomebar-position-bottom {
371 bottom:0;
372 }
373 .mysticky-welcomebar-fixed .mysticky-welcomebar-content p {
374 color: <?php echo $welcomebar['mysticky_welcomebar_bgtxtcolor'] ?>;
375 font-size: <?php echo $welcomebar['mysticky_welcomebar_fontsize'] ?>px;
376 font-family: inherit;
377 margin: 0;
378 padding: 0;
379 line-height: 1.2;
380 font-weight: 400;
381 }
382 .mysticky-welcomebar-fixed .mysticky-welcomebar-btn {
383 padding-left: 30px;
384 display: none;
385 }
386 .mysticky-welcomebar-fixed.mysticky-welcomebar-btn-desktop .mysticky-welcomebar-btn {
387 display: block;
388 }
389 .mysticky-welcomebar-fixed .mysticky-welcomebar-btn a {
390 background-color: <?php echo $welcomebar['mysticky_welcomebar_btncolor'] ?>;
391 font-family: inherit;
392 color: <?php echo $welcomebar['mysticky_welcomebar_btntxtcolor'] ?>;
393 border-radius: 4px;
394 text-decoration: none;
395 display: inline-block;
396 vertical-align: top;
397 line-height: 1.2;
398 font-size: <?php echo $welcomebar['mysticky_welcomebar_fontsize'] ?>px;
399 font-weight: 400;
400 padding: 5px 20px;
401 white-space: nowrap;
402 }
403 .mysticky-welcomebar-fixed .mysticky-welcomebar-btn a:hover {
404 /*opacity: 0.7;*/
405 -moz-box-shadow: 1px 2px 4px rgba(0, 0, 0,0.5);
406 -webkit-box-shadow: 1px 2px 4px rgba(0, 0, 0, 0.5);
407 box-shadow: 1px 2px 4px rgba(0, 0, 0, 0.5);
408 }
409 .mysticky-welcomebar-fixed .mysticky-welcomebar-close {
410 display: none;
411 vertical-align: top;
412 width: 20px;
413 height: 20px;
414 text-align: center;
415 text-decoration: none;
416 line-height: 20px;
417 border-radius: 5px;
418 color: #000;
419 position: absolute;
420 font-family: Lato;
421 top: 5px;
422 right: 5px;
423 -webkit-transition: all 0.5s ease 0s;
424 -moz-transition: all 0.5s ease 0s;
425 transition: all 0.5s ease 0s;
426 -webkit-transform-origin: 50% 50%;
427 -moz-transform-origin: 50% 50%;
428 transform-origin: 50% 50%;
429 }
430 .mysticky-welcomebar-fixed .mysticky-welcomebar-close:hover {
431 opacity: 0.5;
432 -webkit-transform: rotate(180deg);
433 -moz-transform: rotate(180deg);
434 transform: rotate(180deg);
435 }
436 .mysticky-welcomebar-fixed.mysticky-welcomebar-showx-desktop .mysticky-welcomebar-close {
437 display: inline-block;
438 }
439 .mysticky-welcomebar-getbar:focus,
440 .mysticky-welcomebar-getbar:active,
441 .mysticky-welcomebar-getbar {
442 background-color: rgba(140,140,140,0.5) !important;
443 border-radius: 8px !important;
444 color: #FFFFFF !important;
445 position: absolute !important;
446 padding: 3px !important;
447 bottom: 3px !important;
448 left: 3px !important;
449 font-size: 10px !important;
450 line-height: 1.4 !important;
451 margin: 0 !important;
452 display: inline-block !important;
453 vertical-align: top !important;
454 font-family: Poppins !important;
455 text-decoration: none !important;
456 visibility: visible !important;
457 }
458 .mysticky-welcomebar-getbar:hover {
459 color: #000000 !important;
460 opacity: 0.5 !important;
461 }
462
463 @media only screen and (max-width: 1024px) {
464 .mysticky-welcomebar-fixed {
465 padding: 0 20px 0 10px;
466 }
467 .mysticky-welcomebar-fixed .mysticky-welcomebar-close {
468 width: 20px;
469 height: 20px;
470 line-height: 20px;
471 right: 0px;
472 }
473 }
474
475 /* Animated Buttons */
476 .mysticky-welcomebar-btn a {
477 -webkit-animation: 1s;
478 animation-duration: 1s;
479 }
480 @-webkit-keyframes flash {
481 from,
482 50%,
483 to {
484 opacity: 1;
485 }
486
487 25%,
488 75% {
489 opacity: 0;
490 }
491 }
492 @keyframes flash {
493 from,
494 50%,
495 to {
496 opacity: 1;
497 }
498
499 25%,
500 75% {
501 opacity: 0;
502 }
503 }
504 .mysticky-welcomebar-attention-flash.animation-start .mysticky-welcomebar-btn a {
505 -webkit-animation-name: flash;
506 animation-name: flash;
507 }
508
509 @keyframes shake {
510 from,
511 to {
512 -webkit-transform: translate3d(0, 0, 0);
513 transform: translate3d(0, 0, 0);
514 }
515
516 10%,
517 30%,
518 50%,
519 70%,
520 90% {
521 -webkit-transform: translate3d(-10px, 0, 0);
522 transform: translate3d(-10px, 0, 0);
523 }
524
525 20%,
526 40%,
527 60%,
528 80% {
529 -webkit-transform: translate3d(10px, 0, 0);
530 transform: translate3d(10px, 0, 0);
531 }
532 }
533
534 .mysticky-welcomebar-attention-shake.animation-start .mysticky-welcomebar-btn a {
535 -webkit-animation-name: shake;
536 animation-name: shake;
537 }
538
539 @-webkit-keyframes swing {
540 20% {
541 -webkit-transform: rotate3d(0, 0, 1, 15deg);
542 transform: rotate3d(0, 0, 1, 15deg);
543 }
544
545 40% {
546 -webkit-transform: rotate3d(0, 0, 1, -10deg);
547 transform: rotate3d(0, 0, 1, -10deg);
548 }
549
550 60% {
551 -webkit-transform: rotate3d(0, 0, 1, 5deg);
552 transform: rotate3d(0, 0, 1, 5deg);
553 }
554
555 80% {
556 -webkit-transform: rotate3d(0, 0, 1, -5deg);
557 transform: rotate3d(0, 0, 1, -5deg);
558 }
559
560 to {
561 -webkit-transform: rotate3d(0, 0, 1, 0deg);
562 transform: rotate3d(0, 0, 1, 0deg);
563 }
564 }
565
566 @keyframes swing {
567 20% {
568 -webkit-transform: rotate3d(0, 0, 1, 15deg);
569 transform: rotate3d(0, 0, 1, 15deg);
570 }
571
572 40% {
573 -webkit-transform: rotate3d(0, 0, 1, -10deg);
574 transform: rotate3d(0, 0, 1, -10deg);
575 }
576
577 60% {
578 -webkit-transform: rotate3d(0, 0, 1, 5deg);
579 transform: rotate3d(0, 0, 1, 5deg);
580 }
581
582 80% {
583 -webkit-transform: rotate3d(0, 0, 1, -5deg);
584 transform: rotate3d(0, 0, 1, -5deg);
585 }
586
587 to {
588 -webkit-transform: rotate3d(0, 0, 1, 0deg);
589 transform: rotate3d(0, 0, 1, 0deg);
590 }
591 }
592
593 .mysticky-welcomebar-attention-swing.animation-start .mysticky-welcomebar-btn a {
594 -webkit-transform-origin: top center;
595 transform-origin: top center;
596 -webkit-animation-name: swing;
597 animation-name: swing;
598 }
599
600 @-webkit-keyframes tada {
601 from {
602 -webkit-transform: scale3d(1, 1, 1);
603 transform: scale3d(1, 1, 1);
604 }
605
606 10%,
607 20% {
608 -webkit-transform: scale3d(0.9, 0.9, 0.9) rotate3d(0, 0, 1, -3deg);
609 transform: scale3d(0.9, 0.9, 0.9) rotate3d(0, 0, 1, -3deg);
610 }
611
612 30%,
613 50%,
614 70%,
615 90% {
616 -webkit-transform: scale3d(1.1, 1.1, 1.1) rotate3d(0, 0, 1, 3deg);
617 transform: scale3d(1.1, 1.1, 1.1) rotate3d(0, 0, 1, 3deg);
618 }
619
620 40%,
621 60%,
622 80% {
623 -webkit-transform: scale3d(1.1, 1.1, 1.1) rotate3d(0, 0, 1, -3deg);
624 transform: scale3d(1.1, 1.1, 1.1) rotate3d(0, 0, 1, -3deg);
625 }
626
627 to {
628 -webkit-transform: scale3d(1, 1, 1);
629 transform: scale3d(1, 1, 1);
630 }
631 }
632
633 @keyframes tada {
634 from {
635 -webkit-transform: scale3d(1, 1, 1);
636 transform: scale3d(1, 1, 1);
637 }
638
639 10%,
640 20% {
641 -webkit-transform: scale3d(0.9, 0.9, 0.9) rotate3d(0, 0, 1, -3deg);
642 transform: scale3d(0.9, 0.9, 0.9) rotate3d(0, 0, 1, -3deg);
643 }
644
645 30%,
646 50%,
647 70%,
648 90% {
649 -webkit-transform: scale3d(1.1, 1.1, 1.1) rotate3d(0, 0, 1, 3deg);
650 transform: scale3d(1.1, 1.1, 1.1) rotate3d(0, 0, 1, 3deg);
651 }
652
653 40%,
654 60%,
655 80% {
656 -webkit-transform: scale3d(1.1, 1.1, 1.1) rotate3d(0, 0, 1, -3deg);
657 transform: scale3d(1.1, 1.1, 1.1) rotate3d(0, 0, 1, -3deg);
658 }
659
660 to {
661 -webkit-transform: scale3d(1, 1, 1);
662 transform: scale3d(1, 1, 1);
663 }
664 }
665
666 .mysticky-welcomebar-attention-tada.animation-start .mysticky-welcomebar-btn a {
667 -webkit-animation-name: tada;
668 animation-name: tada;
669 }
670
671 @-webkit-keyframes heartBeat {
672 0% {
673 -webkit-transform: scale(1);
674 transform: scale(1);
675 }
676
677 14% {
678 -webkit-transform: scale(1.3);
679 transform: scale(1.3);
680 }
681
682 28% {
683 -webkit-transform: scale(1);
684 transform: scale(1);
685 }
686
687 42% {
688 -webkit-transform: scale(1.3);
689 transform: scale(1.3);
690 }
691
692 70% {
693 -webkit-transform: scale(1);
694 transform: scale(1);
695 }
696 }
697
698 @keyframes heartBeat {
699 0% {
700 -webkit-transform: scale(1);
701 transform: scale(1);
702 }
703
704 14% {
705 -webkit-transform: scale(1.3);
706 transform: scale(1.3);
707 }
708
709 28% {
710 -webkit-transform: scale(1);
711 transform: scale(1);
712 }
713
714 42% {
715 -webkit-transform: scale(1.3);
716 transform: scale(1.3);
717 }
718
719 70% {
720 -webkit-transform: scale(1);
721 transform: scale(1);
722 }
723 }
724
725 .mysticky-welcomebar-attention-heartbeat.animation-start .mysticky-welcomebar-btn a {
726 -webkit-animation-name: heartBeat;
727 animation-name: heartBeat;
728 -webkit-animation-duration: 1.3s;
729 animation-duration: 1.3s;
730 -webkit-animation-timing-function: ease-in-out;
731 animation-timing-function: ease-in-out;
732 }
733
734 @-webkit-keyframes wobble {
735 from {
736 -webkit-transform: translate3d(0, 0, 0);
737 transform: translate3d(0, 0, 0);
738 }
739
740 15% {
741 -webkit-transform: translate3d(-25%, 0, 0) rotate3d(0, 0, 1, -5deg);
742 transform: translate3d(-25%, 0, 0) rotate3d(0, 0, 1, -5deg);
743 }
744
745 30% {
746 -webkit-transform: translate3d(20%, 0, 0) rotate3d(0, 0, 1, 3deg);
747 transform: translate3d(20%, 0, 0) rotate3d(0, 0, 1, 3deg);
748 }
749
750 45% {
751 -webkit-transform: translate3d(-15%, 0, 0) rotate3d(0, 0, 1, -3deg);
752 transform: translate3d(-15%, 0, 0) rotate3d(0, 0, 1, -3deg);
753 }
754
755 60% {
756 -webkit-transform: translate3d(10%, 0, 0) rotate3d(0, 0, 1, 2deg);
757 transform: translate3d(10%, 0, 0) rotate3d(0, 0, 1, 2deg);
758 }
759
760 75% {
761 -webkit-transform: translate3d(-5%, 0, 0) rotate3d(0, 0, 1, -1deg);
762 transform: translate3d(-5%, 0, 0) rotate3d(0, 0, 1, -1deg);
763 }
764
765 to {
766 -webkit-transform: translate3d(0, 0, 0);
767 transform: translate3d(0, 0, 0);
768 }
769 }
770
771 @keyframes wobble {
772 from {
773 -webkit-transform: translate3d(0, 0, 0);
774 transform: translate3d(0, 0, 0);
775 }
776
777 15% {
778 -webkit-transform: translate3d(-25%, 0, 0) rotate3d(0, 0, 1, -5deg);
779 transform: translate3d(-25%, 0, 0) rotate3d(0, 0, 1, -5deg);
780 }
781
782 30% {
783 -webkit-transform: translate3d(20%, 0, 0) rotate3d(0, 0, 1, 3deg);
784 transform: translate3d(20%, 0, 0) rotate3d(0, 0, 1, 3deg);
785 }
786
787 45% {
788 -webkit-transform: translate3d(-15%, 0, 0) rotate3d(0, 0, 1, -3deg);
789 transform: translate3d(-15%, 0, 0) rotate3d(0, 0, 1, -3deg);
790 }
791
792 60% {
793 -webkit-transform: translate3d(10%, 0, 0) rotate3d(0, 0, 1, 2deg);
794 transform: translate3d(10%, 0, 0) rotate3d(0, 0, 1, 2deg);
795 }
796
797 75% {
798 -webkit-transform: translate3d(-5%, 0, 0) rotate3d(0, 0, 1, -1deg);
799 transform: translate3d(-5%, 0, 0) rotate3d(0, 0, 1, -1deg);
800 }
801
802 to {
803 -webkit-transform: translate3d(0, 0, 0);
804 transform: translate3d(0, 0, 0);
805 }
806 }
807
808 .mysticky-welcomebar-attention-wobble.animation-start .mysticky-welcomebar-btn a {
809 -webkit-animation-name: wobble;
810 animation-name: wobble;
811 }
812 </style>
813
814 <?php
815 }
816
817 function mysticky_welcomebar_pro_widget_default_fields() {
818 return array(
819 'mysticky_welcomebar_position' => 'top',
820 'mysticky_welcomebar_height' => '60',
821 'mysticky_welcomebar_bgcolor' => '#03ed96',
822 'mysticky_welcomebar_bgtxtcolor' => '#000000',
823 'mysticky_welcomebar_font' => 'Poppins',
824 'mysticky_welcomebar_fontsize' => '16',
825 'mysticky_welcomebar_bar_text' => 'Get 30% off your first purchase',
826 'mysticky_welcomebar_x_desktop' => 'desktop',
827 'mysticky_welcomebar_x_mobile' => 'mobile',
828 'mysticky_welcomebar_btn_desktop' => 'desktop',
829 'mysticky_welcomebar_btn_mobile' => 'mobile',
830 'mysticky_welcomebar_btncolor' => '#000000',
831 'mysticky_welcomebar_btntxtcolor' => '#ffffff',
832 'mysticky_welcomebar_btn_text' => 'Got it!',
833 'mysticky_welcomebar_actionselect' => 'close_bar',
834 'mysticky_welcomebar_redirect' => 'https://www.yourdomain.com',
835 'mysticky_welcomebar_redirect_newtab' => '',
836 'mysticky_welcomebar_device_desktop' => 'desktop',
837 'mysticky_welcomebar_device_mobile' => 'mobile',
838 'mysticky_welcomebar_trigger' => 'after_a_few_seconds',
839 'mysticky_welcomebar_triggersec' => '0',
840 'mysticky_welcomebar_expirydate' => '',
841 'mysticky_welcomebar_page_settings' => '',
842 );
843 }
844
845 function mysticky_welcome_bar_frontend(){
846 $welcomebar = get_option( 'mysticky_option_welcomebar' );
847
848 if ( ( isset($welcomebar['mysticky_welcomebar_expirydate']) && $welcomebar['mysticky_welcomebar_expirydate'] !='' && strtotime( date('m/d/Y')) > strtotime($welcomebar['mysticky_welcomebar_expirydate']) ) || !isset($welcomebar['mysticky_welcomebar_enable'] ) ) {
849 return;
850 }
851 $mysticky_welcomebar_showx_desktop = $mysticky_welcomebar_showx_mobile = '';
852 $mysticky_welcomebar_btn_desktop = $mysticky_welcomebar_btn_mobile = '';
853 $mysticky_welcomebar_display_desktop = $mysticky_welcomebar_display_mobile = '';
854 if( isset($welcomebar['mysticky_welcomebar_x_desktop']) ) {
855 $mysticky_welcomebar_showx_desktop = ' mysticky-welcomebar-showx-desktop';
856 }
857 if( isset($welcomebar['mysticky_welcomebar_x_mobile']) ) {
858 $mysticky_welcomebar_showx_mobile = ' mysticky-welcomebar-showx-mobile';
859 }
860 if( isset($welcomebar['mysticky_welcomebar_btn_desktop']) ) {
861 $mysticky_welcomebar_btn_desktop = ' mysticky-welcomebar-btn-desktop';
862 }
863 if( isset($welcomebar['mysticky_welcomebar_btn_mobile']) ) {
864 $mysticky_welcomebar_btn_mobile = ' mysticky-welcomebar-btn-mobile';
865 }
866 $display = ' mysticky-welcomebar-attention-'.$welcomebar['mysticky_welcomebar_attentionselect'];
867 $mysticky_welcomebar_display_desktop = ' mysticky-welcomebar-display-desktop';
868 $mysticky_welcomebar_display_mobile = ' mysticky-welcomebar-display-mobile';
869
870 $display_main_class = "mysticky-welcomebar-position-" . $welcomebar['mysticky_welcomebar_position'] . $mysticky_welcomebar_showx_desktop . $mysticky_welcomebar_showx_mobile . $mysticky_welcomebar_btn_desktop . $mysticky_welcomebar_btn_mobile . $mysticky_welcomebar_display_desktop . $mysticky_welcomebar_display_mobile .$display;
871
872 if( isset($welcomebar['mysticky_welcomebar_actionselect']) ) {
873 if( $welcomebar['mysticky_welcomebar_actionselect'] == 'redirect_to_url' ) {
874 $mysticky_welcomebar_actionselect_url = esc_url( $welcomebar['mysticky_welcomebar_redirect'] );
875 } else {
876 $mysticky_welcomebar_actionselect_url = 'javascript:void(0)';
877 }
878 }
879 if( !isset($welcomebar['mysticky_welcomebar_enable']) ) {
880 if ( $welcomebar['mysticky_welcomebar_position'] == 'top' ) {
881 $welcomebar_enable_block = "top: -60px";
882 } else {
883 $welcomebar_enable_block = "bottom: -60px";
884 }
885 }
886
887 ?>
888 <div class="mysticky-welcomebar-fixed <?php echo $display_main_class; ?>" style="<?php echo $welcomebar_enable_block; ?>" data-after-triger="after_a_few_seconds" data-triger-sec="0" data-position="<?php echo esc_attr($welcomebar['mysticky_welcomebar_position']);?>" data-height="<?php echo esc_attr($welcomebar['mysticky_welcomebar_height']);?>" data-rediect="<?php echo esc_attr($welcomebar['mysticky_welcomebar_actionselect']);?>">
889 <div class="mysticky-welcomebar-content">
890 <p><?php echo isset($welcomebar['mysticky_welcomebar_bar_text'])? stripslashes($welcomebar['mysticky_welcomebar_bar_text']) :"Get 30% off your first purchase";?></p>
891 </div>
892 <div class="mysticky-welcomebar-btn">
893 <a href="<?php echo $mysticky_welcomebar_actionselect_url; ?>" <?php if( isset($welcomebar['mysticky_welcomebar_redirect_newtab']) && $welcomebar['mysticky_welcomebar_actionselect'] == 'redirect_to_url' && $welcomebar['mysticky_welcomebar_redirect_newtab']== 1):?> target="_blank" <?php endif;?>><?php echo isset($welcomebar['mysticky_welcomebar_btn_text'])?$welcomebar['mysticky_welcomebar_btn_text']:"Got it!";?></a>
894 </div>
895 <a href="javascript:void(0)" class="mysticky-welcomebar-close">X</a>
896 <a href="https://premio.io/downloads/mystickymenu/?utm_source=credit&domain=<?php echo $_SERVER['HTTP_HOST']; ?>" class="mysticky-welcomebar-getbar" target="_blank" rel="noopener"><?php _e( 'myStickymenu', 'mystickymenu' );?></a>
897 </div>
898 <script>
899
900 jQuery(document).ready(function($){
901 var mysticky_welcomebar_height = jQuery( '.mysticky-welcomebar-fixed' ).innerHeight();
902 if( jQuery( '.mysticky-welcomebar-fixed' ).data('position') == 'top' ) {
903 jQuery( '.mysticky-welcomebar-fixed' ).css( 'top', '-' + mysticky_welcomebar_height + 'px' );
904 } else {
905 jQuery( '.mysticky-welcomebar-fixed' ).css( 'bottom', '-' + mysticky_welcomebar_height + 'px' );
906 }
907 if ( sessionStorage.getItem("welcomebar_close") === null ){
908
909 var after_trigger = jQuery( '.mysticky-welcomebar-fixed' ).data('after-triger');
910
911 if ( after_trigger == 'after_a_few_seconds' ) {
912 if ( $( '.mysticky-welcomebar-fixed' ).hasClass( 'mysticky-welcomebar-display-desktop' ) ) {
913 if ( $( window ).width() > 767 ) {
914 var trigger_sec = jQuery( '.mysticky-welcomebar-fixed' ).data('triger-sec') * 1000;
915 var welcombar_position = $( '.mysticky-welcomebar-fixed' ).data('position');
916 var welcombar_height = $( '.mysticky-welcomebar-fixed' ).data('height');
917 setTimeout(function(){
918 jQuery( '.mysticky-welcomebar-fixed' ).addClass( 'mysticky-welcomebar-animation' );
919 if ( welcombar_position == 'top' ) {
920 jQuery( '.mysticky-welcomebar-fixed' ).addClass( 'mysticky-welcomebar-animation' );
921 jQuery( '.mysticky-welcomebar-fixed' ).css( 'top', '0' );
922 jQuery( '.mysticky-welcomebar-fixed' ).css( 'opacity', '1' );
923 $( 'html' ).css( 'margin-bottom', '' );
924 $( 'html' ).attr( 'style', 'margin-top: ' + mysticky_welcomebar_height + 'px !important' );
925 $( '#mysticky-nav' ).css( 'top', mysticky_welcomebar_height + 'px' );
926 } else {
927 jQuery( '.mysticky-welcomebar-fixed' ).css( 'bottom', '0' );
928 jQuery( '.mysticky-welcomebar-fixed' ).css( 'opacity', '1' );
929 $( 'html' ).css( 'margin-top', '' );
930 $( 'html' ).attr( 'style', 'margin-bottom: ' + mysticky_welcomebar_height + 'px !important' );
931 }
932 }, trigger_sec );
933 }
934 }
935 }
936 if ( $( window ).width() < 767 ) {
937 if ( after_trigger == 'after_a_few_seconds' ) {
938 if ( $( '.mysticky-welcomebar-fixed' ).hasClass( 'mysticky-welcomebar-display-mobile' ) ) {
939 var trigger_sec = jQuery( '.mysticky-welcomebar-fixed' ).data('triger-sec') * 1000;
940 var welcombar_position = $( '.mysticky-welcomebar-fixed' ).data('position');
941 var welcombar_height = $( '.mysticky-welcomebar-fixed' ).data('height');
942 setTimeout(function(){
943 jQuery( '.mysticky-welcomebar-fixed' ).addClass( 'mysticky-welcomebar-animation' );
944 if ( welcombar_position == 'top' ) {
945 jQuery( '.mysticky-welcomebar-fixed' ).css( 'top', '0' );
946 jQuery( '.mysticky-welcomebar-fixed' ).css( 'opacity', '1' );
947 $( 'html' ).css( 'margin-bottom', '' );
948 $( 'html' ).attr( 'style', 'margin-top: ' + mysticky_welcomebar_height + 'px !important' );
949 $( '#mysticky-nav' ).css( 'top', mysticky_welcomebar_height + 'px' );
950 } else {
951 jQuery( '.mysticky-welcomebar-fixed' ).css( 'bottom', '0' );
952 jQuery( '.mysticky-welcomebar-fixed' ).css( 'opacity', '1' );
953 $( 'html' ).css( 'margin-top', '' );
954 $( 'html' ).attr( 'style', 'margin-bottom: ' + mysticky_welcomebar_height + 'px !important' );
955 }
956 }, trigger_sec );
957 }
958 }
959 }
960 mystickyelements_present();
961 }
962 $( window ).resize( function(){
963 if ( sessionStorage.getItem("welcomebar_close") === null ){
964 var after_trigger = jQuery( '.mysticky-welcomebar-fixed' ).data('after-triger');
965 if ( after_trigger == 'after_a_few_seconds' ) {
966 var trigger_sec = jQuery( '.mysticky-welcomebar-fixed' ).data('triger-sec') * 1000;
967 var welcombar_position = $( '.mysticky-welcomebar-fixed' ).data('position');
968 var welcombar_height = $( '.mysticky-welcomebar-fixed' ).data('height');
969 if ( $( window ).width() < 767 ) {
970 if ( $( '.mysticky-welcomebar-fixed' ).hasClass( 'mysticky-welcomebar-display-mobile' ) ) {
971 setTimeout(function(){
972 jQuery( '.mysticky-welcomebar-fixed' ).addClass( 'mysticky-welcomebar-animation' );
973 if ( welcombar_position == 'top' ) {
974 jQuery( '.mysticky-welcomebar-fixed' ).css( 'top', '0' );
975 jQuery( '.mysticky-welcomebar-fixed' ).css( 'opacity', '1' );
976 $( 'html' ).css( 'margin-bottom', '' );
977 $( 'html' ).attr( 'style', 'margin-top: ' + mysticky_welcomebar_height + 'px !important' );
978 $( '#mysticky-nav' ).css( 'top', mysticky_welcomebar_height + 'px' );
979 } else {
980 jQuery( '.mysticky-welcomebar-fixed' ).css( 'bottom', '0' );
981 jQuery( '.mysticky-welcomebar-fixed' ).css( 'opacity', '1' );
982 $( 'html' ).css( 'margin-top', '' );
983 $( 'html' ).attr( 'style', 'margin-bottom: ' + mysticky_welcomebar_height + 'px !important' );
984 }
985 }, trigger_sec );
986 }
987 } else {
988 if ( $( '.mysticky-welcomebar-fixed' ).hasClass( 'mysticky-welcomebar-display-desktop' ) ) {
989 setTimeout(function(){
990 jQuery( '.mysticky-welcomebar-fixed' ).addClass( 'mysticky-welcomebar-animation' );
991 if ( welcombar_position == 'top' ) {
992 jQuery( '.mysticky-welcomebar-fixed' ).css( 'top', '0' );
993 jQuery( '.mysticky-welcomebar-fixed' ).css( 'opacity', '1' );
994 $( 'html' ).css( 'margin-bottom', '' );
995 $( 'html' ).attr( 'style', 'margin-top: ' + mysticky_welcomebar_height + 'px !important' );
996 $( '#mysticky-nav' ).css( 'top', mysticky_welcomebar_height + 'px' );
997 } else {
998 jQuery( '.mysticky-welcomebar-fixed' ).css( 'bottom', '0' );
999 jQuery( '.mysticky-welcomebar-fixed' ).css( 'opacity', '1' );
1000 $( 'html' ).css( 'margin-top', '' );
1001 $( 'html' ).attr( 'style', 'margin-bottom: ' + mysticky_welcomebar_height + 'px !important' );
1002 }
1003 }, trigger_sec );
1004 }
1005 }
1006 }
1007 mystickyelements_present();
1008 }
1009 } );
1010
1011 jQuery(window).scroll(function(){
1012 if ( sessionStorage.getItem("welcomebar_close") === null ){
1013 var welcombar_height = $( '.mysticky-welcomebar-fixed' ).data('height');
1014 var welcombar_position = $( '.mysticky-welcomebar-fixed' ).data('position');
1015 if ( welcombar_position == 'top' ) {
1016 $( '#mysticky-nav' ).css( 'top', mysticky_welcomebar_height + 'px' );
1017 }
1018 if ( after_trigger === 'after_scroll' ) {
1019 var scroll = 100 * $(window).scrollTop() / ($(document).height() - $(window).height());
1020 var after_scroll_val = jQuery( '.mysticky-welcomebar-fixed' ).data('triger-sec');
1021 var welcombar_position = $( '.mysticky-welcomebar-fixed' ).data('position');
1022 var welcombar_height = $( '.mysticky-welcomebar-fixed' ).data('height');
1023 if( scroll > after_scroll_val ) {
1024 if ( $( '.mysticky-welcomebar-fixed' ).hasClass( 'mysticky-welcomebar-display-desktop' ) ) {
1025 if ( $( window ).width() > 767 ) {
1026 jQuery( '.mysticky-welcomebar-fixed' ).addClass( 'mysticky-welcomebar-animation' );
1027 if ( welcombar_position == 'top' ) {
1028 jQuery( '.mysticky-welcomebar-fixed' ).css( 'top', '0' );
1029 jQuery( '.mysticky-welcomebar-fixed' ).css( 'opacity', '1' );
1030 $( 'html' ).css( 'margin-bottom', '' );
1031 $( 'html' ).attr( 'style', 'margin-top: ' + mysticky_welcomebar_height + 'px !important' );
1032 $( '#mysticky-nav' ).css( 'top', mysticky_welcomebar_height + 'px' );
1033 } else {
1034 jQuery( '.mysticky-welcomebar-fixed' ).css( 'bottom', '0' );
1035 jQuery( '.mysticky-welcomebar-fixed' ).css( 'opacity', '1' );
1036 $( 'html' ).css( 'margin-top', '' );
1037 $( 'html' ).attr( 'style', 'margin-bottom: ' + mysticky_welcomebar_height + 'px !important' );
1038 }
1039 }
1040 }
1041 if ( $( '.mysticky-welcomebar-fixed' ).hasClass( 'mysticky-welcomebar-display-mobile' ) ) {
1042 if ( $( window ).width() < 767 ) {
1043 jQuery( '.mysticky-welcomebar-fixed' ).addClass( 'mysticky-welcomebar-animation' );
1044 if ( welcombar_position == 'top' ) {
1045 jQuery( '.mysticky-welcomebar-fixed' ).css( 'top', '0' );
1046 jQuery( '.mysticky-welcomebar-fixed' ).css( 'opacity', '1' );
1047 $( 'html' ).css( 'margin-bottom', '' );
1048 $( 'html' ).attr( 'style', 'margin-top: ' + mysticky_welcomebar_height + 'px !important' );
1049 $( '#mysticky-nav' ).css( 'top', mysticky_welcomebar_height + 'px' );
1050 } else {
1051 jQuery( '.mysticky-welcomebar-fixed' ).css( 'bottom', '0' );
1052 jQuery( '.mysticky-welcomebar-fixed' ).css( 'opacity', '1' );
1053 $( 'html' ).css( 'margin-top', '' );
1054 $( 'html' ).attr( 'style', 'margin-bottom: ' + mysticky_welcomebar_height + 'px !important' );
1055 }
1056 }
1057 }
1058 }
1059 }
1060 mystickyelements_present();
1061 }
1062
1063 });
1064 jQuery( '.mysticky-welcomebar-close, .mysticky-welcomebar-btn a' ).on( 'click', function(){
1065 console.log("mysticky_welcomebar_height = " + mysticky_welcomebar_height);
1066 sessionStorage.setItem('welcomebar_close', 'close');
1067 var welcombar_position = $( '.mysticky-welcomebar-fixed' ).data('position');
1068 var welcombar_height = $( '.mysticky-welcomebar-fixed' ).data('height');
1069 jQuery( '.mysticky-welcomebar-fixed' ).slideUp( 'slow' );
1070 if ( welcombar_position == 'top' ) {
1071 jQuery( '.mysticky-welcomebar-fixed' ).css( 'top', '-' + mysticky_welcomebar_height + 'px' );
1072 } else {
1073 jQuery( '.mysticky-welcomebar-fixed' ).css( 'bottom', '-' + mysticky_welcomebar_height + 'px' );
1074 }
1075 jQuery( 'html' ).css( 'margin-top', '' );
1076 jQuery( 'html' ).css( 'margin-bottom', '' );
1077 $( '#mysticky-nav' ).css( 'top', '0px' );
1078 /*if mystickyelements show*/
1079 var mystickyelements_show = $( '.mystickyelements-fixed' ).length;
1080 if( mystickyelements_show && $( window ).width() <= 1024 && $( '.mystickyelements-fixed' ).hasClass( 'mystickyelements-position-mobile-top' ) && welcombar_position == 'top' ) {
1081 var mystickyelements_height = $( '.mystickyelements-fixed' ).height();
1082 $( '.mystickyelements-fixed' ).css( 'top', '' );
1083 $( 'html' ).attr( 'style', 'margin-top: ' + mystickyelements_height + 'px !important' );
1084 }
1085 } );
1086 });
1087 function mystickyelements_present() {
1088 var after_trigger = jQuery( '.mysticky-welcomebar-fixed' ).data('after-triger');
1089 var mystickyelements_show = jQuery( '.mystickyelements-fixed' ).length;
1090 if( mystickyelements_show ) {
1091 var welcombar_position = jQuery( '.mysticky-welcomebar-fixed' ).data('position');
1092 var welcombar_height = jQuery( '.mysticky-welcomebar-fixed' ).innerHeight();
1093 var mystickyelements_height = jQuery( '.mystickyelements-fixed' ).height();
1094 var mystickyelements_total_height = welcombar_height + mystickyelements_height;
1095 if ( jQuery( window ).width() <= 1024 && jQuery( '.mystickyelements-fixed' ).hasClass( 'mystickyelements-position-mobile-top' ) ) {
1096 if ( after_trigger == 'after_a_few_seconds' ) {
1097 if ( jQuery( '.mysticky-welcomebar-fixed' ).hasClass( 'mysticky-welcomebar-display-mobile' ) ) {
1098 var trigger_sec = jQuery( '.mysticky-welcomebar-fixed' ).data('triger-sec') * 1000;
1099 setTimeout(function(){
1100 if ( welcombar_position == 'top' ) {
1101 jQuery( '.mystickyelements-fixed' ).css( 'top', welcombar_height );
1102 jQuery( 'html' ).attr( 'style', 'margin-top: ' + mystickyelements_total_height + 'px !important' );
1103 } else {
1104 jQuery( '.mystickyelements-fixed' ).css( 'top', '' );
1105 jQuery( 'html' ).attr( 'style', 'margin-bottom: ' + welcombar_height + 'px !important' );
1106 }
1107 }, trigger_sec );
1108 }
1109 } else if ( after_trigger === 'after_scroll' ) {
1110 var scroll = 100 * $(window).scrollTop() / ($(document).height() - $(window).height());
1111 var after_scroll_val = $( '.mysticky-welcomebar-fixed' ).data('triger-sec');
1112 if( scroll > after_scroll_val ) {
1113 if ( jQuery( '.mysticky-welcomebar-fixed' ).hasClass( 'mysticky-welcomebar-display-mobile' ) ) {
1114 if ( welcombar_position == 'top' ) {
1115 jQuery( '.mystickyelements-fixed' ).css( 'top', welcombar_height );
1116 jQuery( 'html' ).attr( 'style', 'margin-top: ' + mystickyelements_total_height + 'px !important' );
1117 } else {
1118 jQuery( '.mystickyelements-fixed' ).css( 'top', '' );
1119 jQuery( 'html' ).attr( 'style', 'margin-bottom: ' + welcombar_height + 'px !important' );
1120 }
1121 }
1122 }
1123 }
1124 }
1125 }
1126 }
1127 jQuery(".mysticky-welcomebar-fixed").on(
1128 "animationend MSAnimationEnd webkitAnimationEnd oAnimationEnd",
1129 function() {
1130 jQuery(this).removeClass("animation-start");
1131 }
1132 );
1133 jQuery(document).ready(function() {
1134 var container = jQuery(".mysticky-welcomebar-fixed");
1135 var refreshId = setInterval(function() {
1136 container.addClass("animation-start");
1137 }, 3500);
1138 });
1139
1140 </script>
1141 <style>
1142 .mysticky-welcomebar-fixed {
1143 height: 60px;
1144 background-color: <?php echo $welcomebar['mysticky_welcomebar_bgcolor'] ?>;
1145 font-family: <?php echo $welcomebar['mysticky_welcomebar_font'] ?>;
1146 position: fixed;
1147 left: 0;
1148 right: 0;
1149 display: flex;
1150 align-items: center;
1151 justify-content: center;
1152 padding: 20px 50px;
1153 z-index: 9999999;
1154 opacity: 0;
1155 }
1156 .mysticky-welcomebar-animation {
1157 -webkit-transition: all 0.5s ease 0s;
1158 -moz-transition: all 0.5s ease 0s;
1159 transition: all 0.5s ease 0s;
1160 }
1161 .mysticky-welcomebar-position-top {
1162 top: -60px;
1163 }
1164 .mysticky-welcomebar-position-bottom {
1165 bottom: -60px;
1166 }
1167 .mysticky-welcomebar-display-desktop.mysticky-welcomebar-position-top.mysticky-welcomebar-fixed {
1168 top: 0;
1169 }
1170 .mysticky-welcomebar-display-desktop.mysticky-welcomebar-position-bottom.mysticky-welcomebar-fixed {
1171 bottom: 0;
1172 }
1173 .mysticky-welcomebar-fixed .mysticky-welcomebar-content p {
1174 color: <?php echo $welcomebar['mysticky_welcomebar_bgtxtcolor'] ?>;
1175 font-size: <?php echo $welcomebar['mysticky_welcomebar_fontsize'] ?>px;
1176 margin: 0;
1177 padding: 0;
1178 line-height: 1.2;
1179 font-family: inherit;
1180 font-weight: 400;
1181 }
1182 .mysticky-welcomebar-fixed .mysticky-welcomebar-btn {
1183 padding-left: 30px;
1184 display: none;
1185 line-height: 1;
1186 }
1187 .mysticky-welcomebar-fixed.mysticky-welcomebar-btn-desktop .mysticky-welcomebar-btn {
1188 display: block;
1189 }
1190 .mysticky-welcomebar-fixed .mysticky-welcomebar-btn a {
1191 background-color: <?php echo $welcomebar['mysticky_welcomebar_btncolor'] ?>;
1192 font-family: inherit;
1193 color: <?php echo $welcomebar['mysticky_welcomebar_btntxtcolor'] ?>;
1194 border-radius: 4px;
1195 text-decoration: none;
1196 display: inline-block;
1197 vertical-align: top;
1198 line-height: 1.2;
1199 font-size: <?php echo $welcomebar['mysticky_welcomebar_fontsize'] ?>px;
1200 font-weight: 400;
1201 padding: 5px 20px;
1202 white-space: nowrap;
1203 }
1204 .mysticky-welcomebar-fixed .mysticky-welcomebar-btn a:hover {
1205 /*opacity: 0.7;*/
1206 -moz-box-shadow: 1px 2px 4px rgba(0, 0, 0,0.5);
1207 -webkit-box-shadow: 1px 2px 4px rgba(0, 0, 0, 0.5);
1208 box-shadow: 1px 2px 4px rgba(0, 0, 0, 0.5);
1209 }
1210 .mysticky-welcomebar-fixed .mysticky-welcomebar-close {
1211 display: none;
1212 vertical-align: top;
1213 width: 30px;
1214 height: 30px;
1215 text-align: center;
1216 line-height: 30px;
1217 border-radius: 5px;
1218 color: #000;
1219 position: absolute;
1220 top: 5px;
1221 right: 10px;
1222 outline: none;
1223 font-family: Lato;
1224 text-decoration: none;
1225 -webkit-transition: all 0.5s ease 0s;
1226 -moz-transition: all 0.5s ease 0s;
1227 transition: all 0.5s ease 0s;
1228 -webkit-transform-origin: 50% 50%;
1229 -moz-transform-origin: 50% 50%;
1230 transform-origin: 50% 50%;
1231 }
1232 .mysticky-welcomebar-fixed .mysticky-welcomebar-close:hover {
1233 opacity: 0.5;
1234 -webkit-transform: rotate(180deg);
1235 -moz-transform: rotate(180deg);
1236 transform: rotate(180deg);
1237 }
1238 .mysticky-welcomebar-fixed .mysticky-welcomebar-close span.dashicons {
1239 font-size: 27px;
1240 }
1241 .mysticky-welcomebar-fixed.mysticky-welcomebar-showx-desktop .mysticky-welcomebar-close {
1242 display: inline-block;
1243 }
1244 .mysticky-welcomebar-getbar:focus,
1245 .mysticky-welcomebar-getbar:active,
1246 .mysticky-welcomebar-getbar {
1247 background-color: rgba(140,140,140,0.5) !important;
1248 border-radius: 8px !important;
1249 color: #FFFFFF !important;
1250 position: absolute !important;
1251 padding: 3px !important;
1252 bottom: 5px !important;
1253 left: 10px !important;
1254 font-size: 12px !important;
1255 line-height: 1.4 !important;
1256 margin: 0 !important;
1257 display: inline-block !important;
1258 vertical-align: top !important;
1259 font-family: Poppins !important;
1260 text-decoration: none !important;
1261 visibility: visible !important;
1262 outline: 0 !important;
1263 }
1264 .mysticky-welcomebar-getbar:hover {
1265 color: #000000 !important;
1266 opacity: 0.5 !important;
1267 }
1268 /* Animated Buttons */
1269 .mysticky-welcomebar-btn a {
1270 animation-duration: 1s;
1271 -webkit-animation-duration: 1s;
1272 }
1273 @-webkit-keyframes flash {
1274 from,
1275 50%,
1276 to {
1277 opacity: 1;
1278 }
1279
1280 25%,
1281 75% {
1282 opacity: 0;
1283 }
1284 }
1285 @keyframes flash {
1286 from,
1287 50%,
1288 to {
1289 opacity: 1;
1290 }
1291
1292 25%,
1293 75% {
1294 opacity: 0;
1295 }
1296 }
1297 .mysticky-welcomebar-attention-flash.animation-start .mysticky-welcomebar-btn a {
1298 -webkit-animation-name: flash;
1299 animation-name: flash;
1300 }
1301
1302 @keyframes shake {
1303 from,
1304 to {
1305 -webkit-transform: translate3d(0, 0, 0);
1306 transform: translate3d(0, 0, 0);
1307 }
1308
1309 10%,
1310 30%,
1311 50%,
1312 70%,
1313 90% {
1314 -webkit-transform: translate3d(-10px, 0, 0);
1315 transform: translate3d(-10px, 0, 0);
1316 }
1317
1318 20%,
1319 40%,
1320 60%,
1321 80% {
1322 -webkit-transform: translate3d(10px, 0, 0);
1323 transform: translate3d(10px, 0, 0);
1324 }
1325 }
1326
1327 .mysticky-welcomebar-attention-shake.animation-start .mysticky-welcomebar-btn a {
1328 -webkit-animation-name: shake;
1329 animation-name: shake;
1330 }
1331
1332 @-webkit-keyframes swing {
1333 20% {
1334 -webkit-transform: rotate3d(0, 0, 1, 15deg);
1335 transform: rotate3d(0, 0, 1, 15deg);
1336 }
1337
1338 40% {
1339 -webkit-transform: rotate3d(0, 0, 1, -10deg);
1340 transform: rotate3d(0, 0, 1, -10deg);
1341 }
1342
1343 60% {
1344 -webkit-transform: rotate3d(0, 0, 1, 5deg);
1345 transform: rotate3d(0, 0, 1, 5deg);
1346 }
1347
1348 80% {
1349 -webkit-transform: rotate3d(0, 0, 1, -5deg);
1350 transform: rotate3d(0, 0, 1, -5deg);
1351 }
1352
1353 to {
1354 -webkit-transform: rotate3d(0, 0, 1, 0deg);
1355 transform: rotate3d(0, 0, 1, 0deg);
1356 }
1357 }
1358
1359 @keyframes swing {
1360 20% {
1361 -webkit-transform: rotate3d(0, 0, 1, 15deg);
1362 transform: rotate3d(0, 0, 1, 15deg);
1363 }
1364
1365 40% {
1366 -webkit-transform: rotate3d(0, 0, 1, -10deg);
1367 transform: rotate3d(0, 0, 1, -10deg);
1368 }
1369
1370 60% {
1371 -webkit-transform: rotate3d(0, 0, 1, 5deg);
1372 transform: rotate3d(0, 0, 1, 5deg);
1373 }
1374
1375 80% {
1376 -webkit-transform: rotate3d(0, 0, 1, -5deg);
1377 transform: rotate3d(0, 0, 1, -5deg);
1378 }
1379
1380 to {
1381 -webkit-transform: rotate3d(0, 0, 1, 0deg);
1382 transform: rotate3d(0, 0, 1, 0deg);
1383 }
1384 }
1385
1386 .mysticky-welcomebar-attention-swing.animation-start .mysticky-welcomebar-btn a {
1387 -webkit-transform-origin: top center;
1388 transform-origin: top center;
1389 -webkit-animation-name: swing;
1390 animation-name: swing;
1391 }
1392
1393 @-webkit-keyframes tada {
1394 from {
1395 -webkit-transform: scale3d(1, 1, 1);
1396 transform: scale3d(1, 1, 1);
1397 }
1398
1399 10%,
1400 20% {
1401 -webkit-transform: scale3d(0.9, 0.9, 0.9) rotate3d(0, 0, 1, -3deg);
1402 transform: scale3d(0.9, 0.9, 0.9) rotate3d(0, 0, 1, -3deg);
1403 }
1404
1405 30%,
1406 50%,
1407 70%,
1408 90% {
1409 -webkit-transform: scale3d(1.1, 1.1, 1.1) rotate3d(0, 0, 1, 3deg);
1410 transform: scale3d(1.1, 1.1, 1.1) rotate3d(0, 0, 1, 3deg);
1411 }
1412
1413 40%,
1414 60%,
1415 80% {
1416 -webkit-transform: scale3d(1.1, 1.1, 1.1) rotate3d(0, 0, 1, -3deg);
1417 transform: scale3d(1.1, 1.1, 1.1) rotate3d(0, 0, 1, -3deg);
1418 }
1419
1420 to {
1421 -webkit-transform: scale3d(1, 1, 1);
1422 transform: scale3d(1, 1, 1);
1423 }
1424 }
1425
1426 @keyframes tada {
1427 from {
1428 -webkit-transform: scale3d(1, 1, 1);
1429 transform: scale3d(1, 1, 1);
1430 }
1431
1432 10%,
1433 20% {
1434 -webkit-transform: scale3d(0.9, 0.9, 0.9) rotate3d(0, 0, 1, -3deg);
1435 transform: scale3d(0.9, 0.9, 0.9) rotate3d(0, 0, 1, -3deg);
1436 }
1437
1438 30%,
1439 50%,
1440 70%,
1441 90% {
1442 -webkit-transform: scale3d(1.1, 1.1, 1.1) rotate3d(0, 0, 1, 3deg);
1443 transform: scale3d(1.1, 1.1, 1.1) rotate3d(0, 0, 1, 3deg);
1444 }
1445
1446 40%,
1447 60%,
1448 80% {
1449 -webkit-transform: scale3d(1.1, 1.1, 1.1) rotate3d(0, 0, 1, -3deg);
1450 transform: scale3d(1.1, 1.1, 1.1) rotate3d(0, 0, 1, -3deg);
1451 }
1452
1453 to {
1454 -webkit-transform: scale3d(1, 1, 1);
1455 transform: scale3d(1, 1, 1);
1456 }
1457 }
1458
1459 .mysticky-welcomebar-attention-tada.animation-start .mysticky-welcomebar-btn a {
1460 -webkit-animation-name: tada;
1461 animation-name: tada;
1462 }
1463
1464 @-webkit-keyframes heartBeat {
1465 0% {
1466 -webkit-transform: scale(1);
1467 transform: scale(1);
1468 }
1469
1470 14% {
1471 -webkit-transform: scale(1.3);
1472 transform: scale(1.3);
1473 }
1474
1475 28% {
1476 -webkit-transform: scale(1);
1477 transform: scale(1);
1478 }
1479
1480 42% {
1481 -webkit-transform: scale(1.3);
1482 transform: scale(1.3);
1483 }
1484
1485 70% {
1486 -webkit-transform: scale(1);
1487 transform: scale(1);
1488 }
1489 }
1490
1491 @keyframes heartBeat {
1492 0% {
1493 -webkit-transform: scale(1);
1494 transform: scale(1);
1495 }
1496
1497 14% {
1498 -webkit-transform: scale(1.3);
1499 transform: scale(1.3);
1500 }
1501
1502 28% {
1503 -webkit-transform: scale(1);
1504 transform: scale(1);
1505 }
1506
1507 42% {
1508 -webkit-transform: scale(1.3);
1509 transform: scale(1.3);
1510 }
1511
1512 70% {
1513 -webkit-transform: scale(1);
1514 transform: scale(1);
1515 }
1516 }
1517
1518 .mysticky-welcomebar-attention-heartbeat.animation-start .mysticky-welcomebar-btn a {
1519 -webkit-animation-name: heartBeat;
1520 animation-name: heartBeat;
1521 -webkit-animation-duration: 1.3s;
1522 animation-duration: 1.3s;
1523 -webkit-animation-timing-function: ease-in-out;
1524 animation-timing-function: ease-in-out;
1525 }
1526
1527 @-webkit-keyframes wobble {
1528 from {
1529 -webkit-transform: translate3d(0, 0, 0);
1530 transform: translate3d(0, 0, 0);
1531 }
1532
1533 15% {
1534 -webkit-transform: translate3d(-25%, 0, 0) rotate3d(0, 0, 1, -5deg);
1535 transform: translate3d(-25%, 0, 0) rotate3d(0, 0, 1, -5deg);
1536 }
1537
1538 30% {
1539 -webkit-transform: translate3d(20%, 0, 0) rotate3d(0, 0, 1, 3deg);
1540 transform: translate3d(20%, 0, 0) rotate3d(0, 0, 1, 3deg);
1541 }
1542
1543 45% {
1544 -webkit-transform: translate3d(-15%, 0, 0) rotate3d(0, 0, 1, -3deg);
1545 transform: translate3d(-15%, 0, 0) rotate3d(0, 0, 1, -3deg);
1546 }
1547
1548 60% {
1549 -webkit-transform: translate3d(10%, 0, 0) rotate3d(0, 0, 1, 2deg);
1550 transform: translate3d(10%, 0, 0) rotate3d(0, 0, 1, 2deg);
1551 }
1552
1553 75% {
1554 -webkit-transform: translate3d(-5%, 0, 0) rotate3d(0, 0, 1, -1deg);
1555 transform: translate3d(-5%, 0, 0) rotate3d(0, 0, 1, -1deg);
1556 }
1557
1558 to {
1559 -webkit-transform: translate3d(0, 0, 0);
1560 transform: translate3d(0, 0, 0);
1561 }
1562 }
1563
1564 @keyframes wobble {
1565 from {
1566 -webkit-transform: translate3d(0, 0, 0);
1567 transform: translate3d(0, 0, 0);
1568 }
1569
1570 15% {
1571 -webkit-transform: translate3d(-25%, 0, 0) rotate3d(0, 0, 1, -5deg);
1572 transform: translate3d(-25%, 0, 0) rotate3d(0, 0, 1, -5deg);
1573 }
1574
1575 30% {
1576 -webkit-transform: translate3d(20%, 0, 0) rotate3d(0, 0, 1, 3deg);
1577 transform: translate3d(20%, 0, 0) rotate3d(0, 0, 1, 3deg);
1578 }
1579
1580 45% {
1581 -webkit-transform: translate3d(-15%, 0, 0) rotate3d(0, 0, 1, -3deg);
1582 transform: translate3d(-15%, 0, 0) rotate3d(0, 0, 1, -3deg);
1583 }
1584
1585 60% {
1586 -webkit-transform: translate3d(10%, 0, 0) rotate3d(0, 0, 1, 2deg);
1587 transform: translate3d(10%, 0, 0) rotate3d(0, 0, 1, 2deg);
1588 }
1589
1590 75% {
1591 -webkit-transform: translate3d(-5%, 0, 0) rotate3d(0, 0, 1, -1deg);
1592 transform: translate3d(-5%, 0, 0) rotate3d(0, 0, 1, -1deg);
1593 }
1594
1595 to {
1596 -webkit-transform: translate3d(0, 0, 0);
1597 transform: translate3d(0, 0, 0);
1598 }
1599 }
1600
1601 .mysticky-welcomebar-attention-wobble.animation-start .mysticky-welcomebar-btn a {
1602 -webkit-animation-name: wobble;
1603 animation-name: wobble;
1604 }
1605 @media only screen and (max-width: 767px) {
1606 .mysticky-welcomebar-display-desktop.mysticky-welcomebar-position-top.mysticky-welcomebar-fixed {
1607 top: -60px;
1608 }
1609 .mysticky-welcomebar-display-desktop.mysticky-welcomebar-position-bottom.mysticky-welcomebar-fixed {
1610 bottom: -60px;
1611 }
1612 .mysticky-welcomebar-display-mobile.mysticky-welcomebar-position-top.mysticky-welcomebar-fixed {
1613 top: 0;
1614 }
1615 .mysticky-welcomebar-display-mobile.mysticky-welcomebar-position-bottom.mysticky-welcomebar-fixed {
1616 bottom: 0;
1617 }
1618 .mysticky-welcomebar-fixed.mysticky-welcomebar-showx-desktop .mysticky-welcomebar-close {
1619 display: none;
1620 }
1621 .mysticky-welcomebar-fixed.mysticky-welcomebar-showx-mobile .mysticky-welcomebar-close {
1622 display: inline-block;
1623 }
1624 .mysticky-welcomebar-fixed.mysticky-welcomebar-btn-desktop .mysticky-welcomebar-btn {
1625 display: none;
1626 }
1627 .mysticky-welcomebar-fixed.mysticky-welcomebar-btn-mobile .mysticky-welcomebar-btn {
1628 display: block;
1629 }
1630 }
1631 @media only screen and (max-width: 480px) {
1632 .mysticky-welcomebar-fixed {
1633 height: auto;
1634 min-height: 60px;
1635 padding: 15px 36px 35px 10px;
1636 }
1637 .mysticky-welcomebar-fixed .mysticky-welcomebar-btn {
1638 padding-left: 10px;
1639 }
1640 .mysticky-welcomebar-fixed .mysticky-welcomebar-close {
1641 right: 7px;
1642 }
1643 }
1644 </style>
1645 <?php
1646 }
1647 add_action( 'wp_footer', 'mysticky_welcome_bar_frontend' );