Version Description
- Added: An option to remove plugin admin notices.
- Added: Professional stats panel with date range + status selector options. [PRO]
- Added: A new template called "Feedback". [PRO]
- Fixed: A important issue with only logged in option.
- Fixed: Schema attributes escape issue.
- Fixed: Some small issues.
Download this release
Release Info
Developer | alimir |
Plugin | WP ULike |
Version | 4.0.2 |
Comparing to | |
See all releases |
Code changes from version 4.0.1 to 4.0.2
- admin/admin-hooks.php +13 -6
- admin/assets/css/plugins.css +256 -962
- admin/assets/js/scripts.js +0 -197
- admin/assets/js/solo/statistics.js +195 -0
- admin/classes/class-wp-ulike-admin-assets.php +9 -0
- admin/classes/class-wp-ulike-admin-pages.php +7 -7
- admin/classes/class-wp-ulike-widget.php +24 -1
- assets/js/wp-ulike.js +9 -6
- assets/js/wp-ulike.min.js +1 -1
- inc/classes/class-wp-ulike-mycred.php +2 -2
- inc/classes/class-wp-ulike.php +1 -1
- inc/frontend-ajax.php +2 -3
- inc/general-functions.php +54 -36
- readme.txt +10 -2
- wp-ulike.php +3 -3
admin/admin-hooks.php
CHANGED
@@ -139,10 +139,10 @@ function wp_ulike_notice_manager(){
|
|
139 |
'label' => __('Not Now', WP_ULIKE_SLUG),
|
140 |
'type' => 'skip',
|
141 |
'color_name' => 'info',
|
142 |
-
'expiration' =>
|
143 |
),
|
144 |
array(
|
145 |
-
'label' => __('
|
146 |
'type' => 'skip',
|
147 |
'color_name' => 'error',
|
148 |
'expiration' => YEAR_IN_SECONDS * 10
|
@@ -180,10 +180,10 @@ function wp_ulike_notice_manager(){
|
|
180 |
'expiration' => WEEK_IN_SECONDS * 2
|
181 |
),
|
182 |
array(
|
183 |
-
'label' => __('
|
184 |
'type' => 'skip',
|
185 |
'color_name' => 'error',
|
186 |
-
'expiration' => YEAR_IN_SECONDS *
|
187 |
)
|
188 |
)
|
189 |
]);
|
@@ -212,7 +212,7 @@ function wp_ulike_go_pro_admin_menu( $submenus ){
|
|
212 |
'title' => sprintf( '<span class="wp-ulike-gopro-menu-link"><strong>%s</strong></span>', __( 'Go Pro', WP_ULIKE_SLUG )),
|
213 |
'parent_slug' => 'wp-ulike-settings',
|
214 |
'capability' => 'manage_options',
|
215 |
-
'path' => '/includes/templates/go-pro.php',
|
216 |
'menu_slug' => 'wp-ulike-go-pro',
|
217 |
'load_screen' => false
|
218 |
);
|
@@ -220,4 +220,11 @@ function wp_ulike_go_pro_admin_menu( $submenus ){
|
|
220 |
|
221 |
return $submenus;
|
222 |
}
|
223 |
-
add_filter( 'wp_ulike_admin_pages', 'wp_ulike_go_pro_admin_menu', 1, 10 );
|
|
|
|
|
|
|
|
|
|
|
|
|
|
139 |
'label' => __('Not Now', WP_ULIKE_SLUG),
|
140 |
'type' => 'skip',
|
141 |
'color_name' => 'info',
|
142 |
+
'expiration' => WEEK_IN_SECONDS * 2
|
143 |
),
|
144 |
array(
|
145 |
+
'label' => __('No thanks and never ask me again', WP_ULIKE_SLUG),
|
146 |
'type' => 'skip',
|
147 |
'color_name' => 'error',
|
148 |
'expiration' => YEAR_IN_SECONDS * 10
|
180 |
'expiration' => WEEK_IN_SECONDS * 2
|
181 |
),
|
182 |
array(
|
183 |
+
'label' => __('No thanks and never ask me again', WP_ULIKE_SLUG),
|
184 |
'type' => 'skip',
|
185 |
'color_name' => 'error',
|
186 |
+
'expiration' => YEAR_IN_SECONDS * 10
|
187 |
)
|
188 |
)
|
189 |
]);
|
212 |
'title' => sprintf( '<span class="wp-ulike-gopro-menu-link"><strong>%s</strong></span>', __( 'Go Pro', WP_ULIKE_SLUG )),
|
213 |
'parent_slug' => 'wp-ulike-settings',
|
214 |
'capability' => 'manage_options',
|
215 |
+
'path' => WP_ULIKE_ADMIN_DIR . '/includes/templates/go-pro.php',
|
216 |
'menu_slug' => 'wp-ulike-go-pro',
|
217 |
'load_screen' => false
|
218 |
);
|
220 |
|
221 |
return $submenus;
|
222 |
}
|
223 |
+
add_filter( 'wp_ulike_admin_pages', 'wp_ulike_go_pro_admin_menu', 1, 10 );
|
224 |
+
|
225 |
+
function wp_ulike_hide_admin_notifications( $notice_list ){
|
226 |
+
$screen = get_current_screen();
|
227 |
+
$hide_admin_notice = wp_ulike_get_setting( 'wp_ulike_general', 'hide_admin_notice', false );
|
228 |
+
return wp_ulike_is_true( $hide_admin_notice ) && strpos( $screen->base, WP_ULIKE_SLUG ) === false ? array() : $notice_list;
|
229 |
+
}
|
230 |
+
add_filter( 'wp_ulike_admin_notices_instances', 'wp_ulike_hide_admin_notifications', 1, 20 );
|
admin/assets/css/plugins.css
CHANGED
@@ -1,6 +1,5 @@
|
|
1 |
/*
|
2 |
-
/------------------------------------------\
|
3 |
-
_ __ _ _____ _ _ _ _
|
4 |
| | / \ | | ___ \ | |(_)| | / /
|
5 |
| | / /\ \ | | |_/ / _| || || |/ / ___
|
6 |
| | / / \ \ | | __/ | | | || || | / _ \
|
@@ -20,1001 +19,296 @@ https://github.com/bgrins/spectrum
|
|
20 |
Author: Brian Grinstead
|
21 |
License: MIT
|
22 |
***/
|
23 |
-
.sp-container {
|
24 |
-
|
25 |
-
|
26 |
-
left: 0;
|
27 |
-
display: inline-block;
|
28 |
-
*display: inline;
|
29 |
-
*zoom: 1;
|
30 |
-
/* https://github.com/bgrins/spectrum/issues/40 */
|
31 |
-
z-index: 9999994;
|
32 |
-
overflow: hidden;
|
33 |
-
}
|
34 |
-
|
35 |
-
.sp-container.sp-flat {
|
36 |
-
position: relative;
|
37 |
-
}
|
38 |
|
39 |
/* Fix for * { box-sizing: border-box; } */
|
40 |
-
.sp-container,
|
41 |
-
.sp-container * {
|
42 |
-
-webkit-box-sizing: content-box;
|
43 |
-
-moz-box-sizing: content-box;
|
44 |
-
box-sizing: content-box;
|
45 |
-
}
|
46 |
|
47 |
/* http://ansciath.tumblr.com/post/7347495869/css-aspect-ratio */
|
48 |
-
.sp-top {
|
49 |
-
|
50 |
-
|
51 |
-
|
52 |
-
}
|
53 |
-
|
54 |
-
.sp-top
|
55 |
-
|
56 |
-
|
57 |
-
|
58 |
-
|
59 |
-
|
60 |
-
}
|
61 |
-
|
62 |
-
.sp-
|
63 |
-
|
64 |
-
|
65 |
-
|
66 |
-
|
67 |
-
|
68 |
-
}
|
69 |
-
|
70 |
-
.sp-
|
71 |
-
|
72 |
-
|
73 |
-
|
74 |
-
|
75 |
-
|
76 |
-
|
77 |
-
}
|
78 |
-
|
79 |
-
.sp-clear-enabled .sp-hue {
|
80 |
-
top: 33px;
|
81 |
-
height: 77.5%;
|
82 |
-
}
|
83 |
-
|
84 |
-
.sp-fill {
|
85 |
-
padding-top: 80%;
|
86 |
-
}
|
87 |
-
|
88 |
-
.sp-sat, .sp-val {
|
89 |
-
position: absolute;
|
90 |
-
top: 0;
|
91 |
-
left: 0;
|
92 |
-
right: 0;
|
93 |
-
bottom: 0;
|
94 |
-
}
|
95 |
-
|
96 |
-
.sp-alpha-enabled .sp-top {
|
97 |
-
margin-bottom: 18px;
|
98 |
-
}
|
99 |
-
|
100 |
-
.sp-alpha-enabled .sp-alpha {
|
101 |
-
display: block;
|
102 |
-
}
|
103 |
-
|
104 |
-
.sp-alpha-handle {
|
105 |
-
position: absolute;
|
106 |
-
top: -4px;
|
107 |
-
bottom: -4px;
|
108 |
-
width: 6px;
|
109 |
-
left: 50%;
|
110 |
-
cursor: pointer;
|
111 |
-
border: 1px solid black;
|
112 |
-
background: white;
|
113 |
-
opacity: .8;
|
114 |
-
}
|
115 |
-
|
116 |
-
.sp-alpha {
|
117 |
-
display: none;
|
118 |
-
position: absolute;
|
119 |
-
bottom: -14px;
|
120 |
-
right: 0;
|
121 |
-
left: 0;
|
122 |
-
height: 8px;
|
123 |
-
}
|
124 |
-
|
125 |
-
.sp-alpha-inner {
|
126 |
-
border: solid 1px #333;
|
127 |
-
}
|
128 |
-
|
129 |
-
.sp-clear {
|
130 |
-
display: none;
|
131 |
-
}
|
132 |
-
|
133 |
-
.sp-clear.sp-clear-display {
|
134 |
-
background-position: center;
|
135 |
-
}
|
136 |
-
|
137 |
-
.sp-clear-enabled .sp-clear {
|
138 |
-
display: block;
|
139 |
-
position: absolute;
|
140 |
-
top: 0px;
|
141 |
-
right: 0;
|
142 |
-
bottom: 0;
|
143 |
-
left: 84%;
|
144 |
-
height: 28px;
|
145 |
-
}
|
146 |
|
147 |
/* Don't allow text selection */
|
148 |
-
.sp-container, .sp-replacer, .sp-preview, .sp-dragger, .sp-slider, .sp-alpha, .sp-clear, .sp-alpha-handle, .sp-container.sp-dragging .sp-input, .sp-container button {
|
149 |
-
-webkit-user-select: none;
|
150 |
-
-moz-user-select: -moz-none;
|
151 |
-
-o-user-select: none;
|
152 |
-
user-select: none;
|
153 |
-
}
|
154 |
|
155 |
-
.sp-container.sp-input-disabled .sp-input-container {
|
156 |
-
display: none;
|
157 |
-
}
|
158 |
|
159 |
-
.sp-container.sp-buttons-disabled .sp-button-container {
|
160 |
-
display: none;
|
161 |
-
}
|
162 |
|
163 |
-
.sp-container.sp-palette-buttons-disabled .sp-palette-button-container {
|
164 |
-
display: none;
|
165 |
-
}
|
166 |
|
167 |
-
.sp-palette-only .sp-picker-container {
|
168 |
-
display: none;
|
169 |
-
}
|
170 |
|
171 |
-
.sp-palette-disabled .sp-palette-container {
|
172 |
-
display: none;
|
173 |
-
}
|
174 |
|
175 |
-
.sp-initial-disabled .sp-initial {
|
176 |
-
display: none;
|
177 |
-
}
|
178 |
|
179 |
/* Gradients for hue, saturation and value instead of images. Not pretty... but it works */
|
180 |
-
.sp-sat {
|
181 |
-
|
182 |
-
|
183 |
-
|
184 |
-
|
185 |
-
|
186 |
-
|
187 |
-
|
188 |
-
|
189 |
-
}
|
190 |
-
|
191 |
-
.sp-
|
192 |
-
|
193 |
-
|
194 |
-
|
195 |
-
|
196 |
-
|
197 |
-
|
198 |
-
|
199 |
-
|
200 |
-
}
|
201 |
-
|
202 |
-
.sp-hue {
|
203 |
-
background: -moz-linear-gradient(top, #ff0000 0%, #ffff00 17%, #00ff00 33%, #00ffff 50%, #0000ff 67%, #ff00ff 83%, #ff0000 100%);
|
204 |
-
background: -ms-linear-gradient(top, #ff0000 0%, #ffff00 17%, #00ff00 33%, #00ffff 50%, #0000ff 67%, #ff00ff 83%, #ff0000 100%);
|
205 |
-
background: -o-linear-gradient(top, #ff0000 0%, #ffff00 17%, #00ff00 33%, #00ffff 50%, #0000ff 67%, #ff00ff 83%, #ff0000 100%);
|
206 |
-
background: -webkit-gradient(linear, left top, left bottom, from(#ff0000), color-stop(0.17, #ffff00), color-stop(0.33, #00ff00), color-stop(0.5, #00ffff), color-stop(0.67, #0000ff), color-stop(0.83, #ff00ff), to(#ff0000));
|
207 |
-
background: -webkit-linear-gradient(top, #ff0000 0%, #ffff00 17%, #00ff00 33%, #00ffff 50%, #0000ff 67%, #ff00ff 83%, #ff0000 100%);
|
208 |
-
background: linear-gradient(to bottom, #ff0000 0%, #ffff00 17%, #00ff00 33%, #00ffff 50%, #0000ff 67%, #ff00ff 83%, #ff0000 100%);
|
209 |
-
}
|
210 |
-
|
211 |
-
/* IE filters do not support multiple color stops.
|
212 |
-
Generate 6 divs, line them up, and do two color gradients for each.
|
213 |
-
Yes, really.
|
214 |
-
*/
|
215 |
-
.sp-1 {
|
216 |
-
height: 17%;
|
217 |
-
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff0000', endColorstr='#ffff00');
|
218 |
-
}
|
219 |
-
|
220 |
-
.sp-2 {
|
221 |
-
height: 16%;
|
222 |
-
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffff00', endColorstr='#00ff00');
|
223 |
-
}
|
224 |
-
|
225 |
-
.sp-3 {
|
226 |
-
height: 17%;
|
227 |
-
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#00ff00', endColorstr='#00ffff');
|
228 |
-
}
|
229 |
-
|
230 |
-
.sp-4 {
|
231 |
-
height: 17%;
|
232 |
-
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#00ffff', endColorstr='#0000ff');
|
233 |
-
}
|
234 |
-
|
235 |
-
.sp-5 {
|
236 |
-
height: 16%;
|
237 |
-
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#0000ff', endColorstr='#ff00ff');
|
238 |
-
}
|
239 |
-
|
240 |
-
.sp-6 {
|
241 |
-
height: 17%;
|
242 |
-
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff00ff', endColorstr='#ff0000');
|
243 |
-
}
|
244 |
-
|
245 |
-
.sp-hidden {
|
246 |
-
display: none !important;
|
247 |
-
}
|
248 |
|
249 |
/* Clearfix hack */
|
250 |
-
.sp-cf:before, .sp-cf:after {
|
251 |
-
content: "";
|
252 |
-
display: table;
|
253 |
-
}
|
254 |
|
255 |
-
.sp-cf:after {
|
256 |
-
clear: both;
|
257 |
-
}
|
258 |
|
259 |
-
.sp-cf {
|
260 |
-
*zoom: 1;
|
261 |
-
}
|
262 |
|
263 |
/* Mobile devices, make hue slider bigger so it is easier to slide */
|
264 |
-
@media (max-device-width: 480px) {
|
265 |
-
.sp-
|
266 |
-
|
267 |
-
|
268 |
-
|
269 |
-
|
270 |
-
left: 63%;
|
271 |
-
}
|
272 |
-
|
273 |
-
.sp-fill {
|
274 |
-
padding-top: 60%;
|
275 |
-
}
|
276 |
-
}
|
277 |
-
.sp-dragger {
|
278 |
-
border-radius: 5px;
|
279 |
-
height: 5px;
|
280 |
-
width: 5px;
|
281 |
-
border: 1px solid #fff;
|
282 |
-
background: #000;
|
283 |
-
cursor: pointer;
|
284 |
-
position: absolute;
|
285 |
-
top: 0;
|
286 |
-
left: 0;
|
287 |
-
}
|
288 |
-
|
289 |
-
.sp-slider {
|
290 |
-
position: absolute;
|
291 |
-
top: 0;
|
292 |
-
cursor: pointer;
|
293 |
-
height: 3px;
|
294 |
-
left: -1px;
|
295 |
-
right: -1px;
|
296 |
-
border: 1px solid #000;
|
297 |
-
background: white;
|
298 |
-
opacity: .8;
|
299 |
-
}
|
300 |
|
301 |
/*
|
302 |
Theme authors:
|
303 |
Here are the basic themeable display options (colors, fonts, global widths).
|
304 |
See http://bgrins.github.io/spectrum/themes/ for instructions.
|
305 |
*/
|
306 |
-
.sp-container {
|
307 |
-
|
308 |
-
|
309 |
-
|
310 |
-
|
311 |
-
|
312 |
-
|
313 |
-
.sp-container, .sp-container button, .sp-container input, .sp-color, .sp-hue, .sp-clear {
|
314 |
-
font: normal 12px "Lucida Grande", "Lucida Sans Unicode", "Lucida Sans", Geneva, Verdana, sans-serif;
|
315 |
-
-webkit-box-sizing: border-box;
|
316 |
-
-moz-box-sizing: border-box;
|
317 |
-
-ms-box-sizing: border-box;
|
318 |
-
box-sizing: border-box;
|
319 |
-
}
|
320 |
-
|
321 |
-
.sp-top {
|
322 |
-
margin-bottom: 3px;
|
323 |
-
}
|
324 |
-
|
325 |
-
.sp-color, .sp-hue, .sp-clear {
|
326 |
-
border: solid 1px #666;
|
327 |
-
}
|
328 |
|
329 |
/* Input */
|
330 |
-
.sp-input-container {
|
331 |
-
|
332 |
-
|
333 |
-
|
334 |
-
}
|
335 |
-
|
336 |
-
.sp-
|
337 |
-
|
338 |
-
}
|
339 |
-
|
340 |
-
.sp-
|
341 |
-
|
342 |
-
|
343 |
-
padding: 4px 5px;
|
344 |
-
margin: 0;
|
345 |
-
width: 100%;
|
346 |
-
background: transparent;
|
347 |
-
border-radius: 3px;
|
348 |
-
color: #222;
|
349 |
-
}
|
350 |
-
|
351 |
-
.sp-input:focus {
|
352 |
-
border: 1px solid orange;
|
353 |
-
}
|
354 |
-
|
355 |
-
.sp-input.sp-validation-error {
|
356 |
-
border: 1px solid red;
|
357 |
-
background: #fdd;
|
358 |
-
}
|
359 |
-
|
360 |
-
.sp-picker-container, .sp-palette-container {
|
361 |
-
float: left;
|
362 |
-
position: relative;
|
363 |
-
padding: 10px;
|
364 |
-
padding-bottom: 300px;
|
365 |
-
margin-bottom: -290px;
|
366 |
-
}
|
367 |
-
|
368 |
-
.sp-picker-container {
|
369 |
-
width: 172px;
|
370 |
-
border-left: solid 1px #fff;
|
371 |
-
}
|
372 |
|
373 |
/* Palettes */
|
374 |
-
.sp-palette-container {
|
375 |
-
|
376 |
-
}
|
377 |
-
|
378 |
-
.sp-palette
|
379 |
-
|
380 |
-
}
|
381 |
-
|
382 |
-
.sp-
|
383 |
-
display: block;
|
384 |
-
position: relative;
|
385 |
-
float: left;
|
386 |
-
width: 24px;
|
387 |
-
height: 15px;
|
388 |
-
margin: 3px;
|
389 |
-
cursor: pointer;
|
390 |
-
border: solid 2px transparent;
|
391 |
-
}
|
392 |
-
|
393 |
-
.sp-palette .sp-thumb-el:hover, .sp-palette .sp-thumb-el.sp-thumb-active {
|
394 |
-
border-color: orange;
|
395 |
-
}
|
396 |
-
|
397 |
-
.sp-thumb-el {
|
398 |
-
position: relative;
|
399 |
-
}
|
400 |
|
401 |
/* Initial */
|
402 |
-
.sp-initial {
|
403 |
-
|
404 |
-
|
405 |
-
|
406 |
-
|
407 |
-
.sp-initial span {
|
408 |
-
width: 30px;
|
409 |
-
height: 25px;
|
410 |
-
border: none;
|
411 |
-
display: block;
|
412 |
-
float: left;
|
413 |
-
margin: 0;
|
414 |
-
}
|
415 |
-
|
416 |
-
.sp-initial .sp-clear-display {
|
417 |
-
background-position: center;
|
418 |
-
}
|
419 |
|
420 |
/* Buttons */
|
421 |
-
.sp-palette-button-container,
|
422 |
-
.sp-button-container {
|
423 |
-
float: right;
|
424 |
-
}
|
425 |
|
426 |
/* Replacer (the little preview div that shows up instead of the <input>) */
|
427 |
-
.sp-replacer {
|
428 |
-
|
429 |
-
|
430 |
-
|
431 |
-
|
432 |
-
|
433 |
-
|
434 |
-
|
435 |
-
|
436 |
-
|
437 |
-
|
438 |
-
|
439 |
-
}
|
440 |
-
|
441 |
-
.sp-
|
442 |
-
border-color: #F0C49B;
|
443 |
-
color: #111;
|
444 |
-
}
|
445 |
-
|
446 |
-
.sp-replacer.sp-disabled {
|
447 |
-
cursor: default;
|
448 |
-
border-color: silver;
|
449 |
-
color: silver;
|
450 |
-
}
|
451 |
-
|
452 |
-
.sp-dd {
|
453 |
-
padding: 2px 0;
|
454 |
-
height: 16px;
|
455 |
-
line-height: 16px;
|
456 |
-
float: left;
|
457 |
-
font-size: 10px;
|
458 |
-
}
|
459 |
-
|
460 |
-
.sp-preview {
|
461 |
-
position: relative;
|
462 |
-
width: 25px;
|
463 |
-
height: 20px;
|
464 |
-
border: solid 1px #222;
|
465 |
-
margin-right: 5px;
|
466 |
-
float: left;
|
467 |
-
z-index: 0;
|
468 |
-
}
|
469 |
-
|
470 |
-
.sp-palette {
|
471 |
-
*width: 220px;
|
472 |
-
max-width: 220px;
|
473 |
-
}
|
474 |
-
|
475 |
-
.sp-palette .sp-thumb-el {
|
476 |
-
width: 16px;
|
477 |
-
height: 16px;
|
478 |
-
margin: 2px 1px;
|
479 |
-
border: solid 1px #d0d0d0;
|
480 |
-
}
|
481 |
-
|
482 |
-
.sp-container {
|
483 |
-
padding-bottom: 0;
|
484 |
-
}
|
485 |
|
486 |
/* Buttons: http://hellohappy.org/css3-buttons/ */
|
487 |
-
.sp-container button {
|
488 |
-
|
489 |
-
|
490 |
-
|
491 |
-
|
492 |
-
|
493 |
-
|
494 |
-
|
495 |
-
|
496 |
-
|
497 |
-
|
498 |
-
|
499 |
-
|
500 |
-
|
501 |
-
|
502 |
-
|
503 |
-
|
504 |
-
|
505 |
-
|
506 |
-
|
507 |
-
|
508 |
-
|
509 |
-
|
510 |
-
|
511 |
-
|
512 |
-
|
513 |
-
|
514 |
-
|
515 |
-
|
516 |
-
|
517 |
-
}
|
518 |
-
|
519 |
-
.
|
520 |
-
|
521 |
-
|
522 |
-
|
523 |
-
|
524 |
-
|
525 |
-
|
526 |
-
|
527 |
-
}
|
528 |
-
|
529 |
-
.
|
530 |
-
|
531 |
-
|
532 |
-
|
533 |
-
|
534 |
-
|
535 |
-
|
536 |
-
|
537 |
-
}
|
538 |
-
|
539 |
-
.
|
540 |
-
|
541 |
-
|
542 |
-
}
|
543 |
-
|
544 |
-
|
545 |
-
|
546 |
-
}
|
547 |
-
|
548 |
-
.
|
549 |
-
|
550 |
-
|
551 |
-
}
|
552 |
-
|
553 |
-
.
|
554 |
-
|
555 |
-
|
556 |
-
|
557 |
-
|
558 |
-
|
559 |
-
|
560 |
-
}
|
561 |
-
|
562 |
-
.
|
563 |
-
|
564 |
-
|
565 |
-
|
566 |
-
|
567 |
-
.
|
568 |
-
|
569 |
-
}
|
570 |
-
|
571 |
-
.
|
572 |
-
|
573 |
-
}
|
574 |
-
|
575 |
-
|
576 |
-
|
577 |
-
|
578 |
-
|
579 |
-
}
|
580 |
-
|
581 |
-
|
582 |
-
|
583 |
-
|
584 |
-
.wp-ulike-
|
585 |
-
|
586 |
-
|
587 |
-
|
588 |
-
|
589 |
-
}
|
590 |
-
.wp-ulike-
|
591 |
-
|
592 |
-
|
593 |
-
|
594 |
-
|
595 |
-
|
596 |
-
|
597 |
-
|
598 |
-
|
599 |
-
}
|
600 |
-
.wp-ulike-
|
601 |
-
|
602 |
-
|
603 |
-
|
604 |
-
|
605 |
-
|
606 |
-
|
607 |
-
|
608 |
-
|
609 |
-
}
|
610 |
-
|
611 |
-
|
612 |
-
|
613 |
-
|
614 |
-
|
615 |
-
}
|
616 |
-
|
617 |
-
|
618 |
-
|
619 |
-
|
620 |
-
}
|
621 |
-
|
622 |
-
.wp-ulike-
|
623 |
-
display: flex;
|
624 |
-
align-items: center;
|
625 |
-
flex-wrap: wrap;
|
626 |
-
justify-content: center;
|
627 |
-
padding: 10px 0;
|
628 |
-
}
|
629 |
-
|
630 |
-
.wp-ulike-row [class^="col"] {
|
631 |
-
float: left;
|
632 |
-
margin: 2%;
|
633 |
-
}
|
634 |
-
|
635 |
-
.rtl .wp-ulike-row [class^="col"] {
|
636 |
-
float: right;
|
637 |
-
}
|
638 |
-
|
639 |
-
.wp-ulike-row::after {
|
640 |
-
content: "";
|
641 |
-
display: table;
|
642 |
-
clear: both;
|
643 |
-
}
|
644 |
-
|
645 |
-
.wp-ulike-row .col-1,
|
646 |
-
.wp-ulike-row .col-2,
|
647 |
-
.wp-ulike-row .col-3,
|
648 |
-
.wp-ulike-row .col-4,
|
649 |
-
.wp-ulike-row .col-5,
|
650 |
-
.wp-ulike-row .col-6,
|
651 |
-
.wp-ulike-row .col-7,
|
652 |
-
.wp-ulike-row .col-8,
|
653 |
-
.wp-ulike-row .col-9,
|
654 |
-
.wp-ulike-row .col-10,
|
655 |
-
.wp-ulike-row .col-11,
|
656 |
-
.wp-ulike-row .col-12 {
|
657 |
-
width: 96%;
|
658 |
-
}
|
659 |
-
.wp-ulike-row .col-1-sm {
|
660 |
-
width: 4.33333%;
|
661 |
-
}
|
662 |
-
.wp-ulike-row .col-2-sm {
|
663 |
-
width: 12.66667%;
|
664 |
-
}
|
665 |
-
.wp-ulike-row .col-3-sm {
|
666 |
-
width: 21%;
|
667 |
-
}
|
668 |
-
.wp-ulike-row .col-4-sm {
|
669 |
-
width: 29.33333%;
|
670 |
-
}
|
671 |
-
.wp-ulike-row .col-5-sm {
|
672 |
-
width: 37.66667%;
|
673 |
-
}
|
674 |
-
.wp-ulike-row .col-6-sm {
|
675 |
-
width: 46%;
|
676 |
-
}
|
677 |
-
.wp-ulike-row .col-7-sm {
|
678 |
-
width: 54.33333%;
|
679 |
-
}
|
680 |
-
.wp-ulike-row .col-8-sm {
|
681 |
-
width: 62.66667%;
|
682 |
-
}
|
683 |
-
.wp-ulike-row .col-9-sm {
|
684 |
-
width: 71%;
|
685 |
-
}
|
686 |
-
.wp-ulike-row .col-10-sm {
|
687 |
-
width: 79.33333%;
|
688 |
-
}
|
689 |
-
.wp-ulike-row .col-11-sm {
|
690 |
-
width: 87.66667%;
|
691 |
-
}
|
692 |
-
.wp-ulike-row .col-12-sm {
|
693 |
-
width: 96%;
|
694 |
-
}
|
695 |
-
|
696 |
-
@media only screen and (min-width: 45em) {
|
697 |
-
.wp-ulike-row .col-1 {
|
698 |
-
width: 4.33333%;
|
699 |
-
}
|
700 |
-
.wp-ulike-row .col-2 {
|
701 |
-
width: 12.66667%;
|
702 |
-
}
|
703 |
-
.wp-ulike-row .col-3 {
|
704 |
-
width: 21%;
|
705 |
-
}
|
706 |
-
.wp-ulike-row .col-4 {
|
707 |
-
width: 29.33333%;
|
708 |
-
}
|
709 |
-
.wp-ulike-row .col-5 {
|
710 |
-
width: 37.66667%;
|
711 |
-
}
|
712 |
-
.wp-ulike-row .col-6 {
|
713 |
-
width: 46%;
|
714 |
-
}
|
715 |
-
.wp-ulike-row .col-7 {
|
716 |
-
width: 54.33333%;
|
717 |
-
}
|
718 |
-
.wp-ulike-row .col-8 {
|
719 |
-
width: 62.66667%;
|
720 |
-
}
|
721 |
-
.wp-ulike-row .col-9 {
|
722 |
-
width: 71%;
|
723 |
-
}
|
724 |
-
.wp-ulike-row .col-10 {
|
725 |
-
width: 79.33333%;
|
726 |
-
}
|
727 |
-
.wp-ulike-row .col-11 {
|
728 |
-
width: 87.66667%;
|
729 |
-
}
|
730 |
-
.wp-ulike-row .col-12 {
|
731 |
-
width: 96%;
|
732 |
-
}
|
733 |
-
.wp-ulike-row .hidden-sm {
|
734 |
-
display: block;
|
735 |
-
}
|
736 |
-
}
|
737 |
-
@media only screen and (max-width: 45em) {
|
738 |
-
.wp-ulike-flex {
|
739 |
-
text-align: center;
|
740 |
-
}
|
741 |
-
}
|
742 |
-
/**
|
743 |
-
* Statistics Page
|
744 |
-
*/
|
745 |
-
.wp-ulike-page-title {
|
746 |
-
font-size: 38px;
|
747 |
-
line-height: 50px;
|
748 |
-
font-weight: 400;
|
749 |
-
margin: 0;
|
750 |
-
}
|
751 |
-
|
752 |
-
.wp-ulike-header {
|
753 |
-
margin: 0 2% 10px;
|
754 |
-
padding: 0 20px 35px;
|
755 |
-
display: flex;
|
756 |
-
justify-content: space-between;
|
757 |
-
position: relative;
|
758 |
-
align-items: center;
|
759 |
-
flex-wrap: wrap;
|
760 |
-
}
|
761 |
-
.wp-ulike-header:after {
|
762 |
-
content: "";
|
763 |
-
position: absolute;
|
764 |
-
bottom: 0;
|
765 |
-
height: 1px;
|
766 |
-
background: #dde3e7;
|
767 |
-
right: 20px;
|
768 |
-
left: 20px;
|
769 |
-
}
|
770 |
-
.wp-ulike-header .wp-ulike-widget-title {
|
771 |
-
text-transform: capitalize;
|
772 |
-
font-size: 22px;
|
773 |
-
font-weight: 500;
|
774 |
-
line-height: normal;
|
775 |
-
color: #3d3d3d;
|
776 |
-
margin: 0;
|
777 |
-
}
|
778 |
-
|
779 |
-
.wp-ulike-button {
|
780 |
-
background-color: #f9faff;
|
781 |
-
padding: 10px 25px;
|
782 |
-
text-decoration: none;
|
783 |
-
text-transform: uppercase;
|
784 |
-
color: #7e8996;
|
785 |
-
border: 1px solid #dde3e7;
|
786 |
-
border-radius: 50em;
|
787 |
-
font-size: 14px;
|
788 |
-
line-height: 20px;
|
789 |
-
}
|
790 |
-
.wp-ulike-button:hover {
|
791 |
-
background-color: #fff;
|
792 |
-
color: #42484e;
|
793 |
-
}
|
794 |
-
|
795 |
-
.wp-ulike-inner {
|
796 |
-
position: relative;
|
797 |
-
padding: 35px 20px;
|
798 |
-
border: 1px solid #e4e6eb;
|
799 |
-
background: #fff;
|
800 |
-
border-radius: 4px;
|
801 |
-
}
|
802 |
-
|
803 |
-
.wp-ulike-logs-count {
|
804 |
-
margin: 0 auto;
|
805 |
-
text-align: center;
|
806 |
-
}
|
807 |
-
.wp-ulike-logs-count .wp-ulike-icon {
|
808 |
-
font-size: 5vw;
|
809 |
-
color: #8B93A6;
|
810 |
-
line-height: 5vh;
|
811 |
-
}
|
812 |
-
.wp-ulike-logs-count .wp-ulike-var {
|
813 |
-
font-size: 3vw;
|
814 |
-
line-height: 4vw;
|
815 |
-
display: block;
|
816 |
-
}
|
817 |
-
.wp-ulike-logs-count .wp-ulike-text {
|
818 |
-
display: block;
|
819 |
-
color: #8B93A6;
|
820 |
-
font-size: 1.5vw;
|
821 |
-
line-height: 2.5vw;
|
822 |
-
}
|
823 |
-
|
824 |
-
.wp-ulike-is-loading {
|
825 |
-
padding: 10px 0;
|
826 |
-
}
|
827 |
-
.wp-ulike-is-loading:before {
|
828 |
-
content: "";
|
829 |
-
position: absolute;
|
830 |
-
left: 0;
|
831 |
-
width: 100%;
|
832 |
-
top: 0;
|
833 |
-
height: 100%;
|
834 |
-
background-color: white;
|
835 |
-
background-image: url(../../../assets/img/svg/statistics.svg);
|
836 |
-
background-repeat: no-repeat;
|
837 |
-
background-position: center center;
|
838 |
-
z-index: 9;
|
839 |
-
}
|
840 |
-
|
841 |
-
.wp-ulike-table {
|
842 |
-
display: table;
|
843 |
-
}
|
844 |
-
.wp-ulike-table .wp-ulike-table-cell {
|
845 |
-
display: table-cell;
|
846 |
-
vertical-align: middle;
|
847 |
-
}
|
848 |
-
|
849 |
-
.wp-ulike-summary-charts .wp-ulike-info {
|
850 |
-
flex-basis: 35%;
|
851 |
-
}
|
852 |
-
.wp-ulike-summary-charts .wp-ulike-icon {
|
853 |
-
font-size: 3vw;
|
854 |
-
color: #8B93A6;
|
855 |
-
line-height: normal;
|
856 |
-
flex-basis: 25%;
|
857 |
-
}
|
858 |
-
.wp-ulike-summary-charts .wp-ulike-var {
|
859 |
-
font-size: 1.8vw;
|
860 |
-
line-height: normal;
|
861 |
-
display: block;
|
862 |
-
}
|
863 |
-
.wp-ulike-summary-charts .wp-ulike-text {
|
864 |
-
display: block;
|
865 |
-
color: #8B93A6;
|
866 |
-
font-size: 1vw;
|
867 |
-
line-height: normal;
|
868 |
-
}
|
869 |
-
|
870 |
-
.wp-ulike-top-likers {
|
871 |
-
margin: 0 2%;
|
872 |
-
}
|
873 |
-
.wp-ulike-top-likers .wp-ulike-users-list {
|
874 |
-
border-bottom: 1px solid #dde3e7;
|
875 |
-
font-size: 15px;
|
876 |
-
padding: 20px 0px;
|
877 |
-
margin: 5px;
|
878 |
-
}
|
879 |
-
.wp-ulike-top-likers .wp-ulike-users-list i {
|
880 |
-
color: #8B93A6;
|
881 |
-
margin: 0 5px;
|
882 |
-
}
|
883 |
-
.wp-ulike-top-likers .wp-ulike-info {
|
884 |
-
width: 60%;
|
885 |
-
}
|
886 |
-
.wp-ulike-top-likers .wp-ulike-counter {
|
887 |
-
width: 20%;
|
888 |
-
}
|
889 |
-
.wp-ulike-top-likers .wp-ulike-total {
|
890 |
-
width: 20%;
|
891 |
-
}
|
892 |
-
|
893 |
-
.wp-ulike-empty-stats {
|
894 |
-
text-align: center;
|
895 |
-
height: 50em;
|
896 |
-
position: relative;
|
897 |
-
}
|
898 |
-
.wp-ulike-empty-stats > div {
|
899 |
-
position: relative;
|
900 |
-
top: 50%;
|
901 |
-
transform: translateY(-50%);
|
902 |
-
}
|
903 |
-
.wp-ulike-empty-stats .wp-ulike-icon {
|
904 |
-
font-size: 110px;
|
905 |
-
color: #8B93A6;
|
906 |
-
}
|
907 |
-
.wp-ulike-empty-stats .wp-ulike-info {
|
908 |
-
font-size: 28px;
|
909 |
-
line-height: 42px;
|
910 |
-
font-weight: 300;
|
911 |
-
margin-top: 50px;
|
912 |
-
}
|
913 |
-
|
914 |
-
.wp-ulike-tops-list {
|
915 |
-
padding: 0 20px;
|
916 |
-
}
|
917 |
-
.wp-ulike-tops-list > ul {
|
918 |
-
font-size: 16px;
|
919 |
-
font-weight: 300;
|
920 |
-
line-height: 26px;
|
921 |
-
color: #3d3d3d;
|
922 |
-
margin: 0;
|
923 |
-
}
|
924 |
-
.wp-ulike-tops-list > ul > li {
|
925 |
-
display: flex;
|
926 |
-
justify-content: space-between;
|
927 |
-
border-bottom: 1px solid #dde3e7;
|
928 |
-
padding: 8px 0;
|
929 |
-
}
|
930 |
-
.wp-ulike-tops-list > ul > li a {
|
931 |
-
text-decoration: none;
|
932 |
-
color: #3d3d3d;
|
933 |
-
}
|
934 |
-
|
935 |
-
/**
|
936 |
-
* About Page
|
937 |
-
*/
|
938 |
-
.wp-ulike-about-page .ulike-badge {
|
939 |
-
background: url(../../../assets/img/wp-ulike-icon.svg) no-repeat scroll center 24px/95px 95px #FF7171;
|
940 |
-
color: #FFFFFF;
|
941 |
-
position: absolute;
|
942 |
-
top: 0px;
|
943 |
-
right: 0px;
|
944 |
-
font-size: 14px;
|
945 |
-
text-align: center;
|
946 |
-
font-weight: 600;
|
947 |
-
margin: 5px 0px 0px;
|
948 |
-
padding-top: 120px;
|
949 |
-
height: 40px;
|
950 |
-
display: inline-block;
|
951 |
-
width: 150px;
|
952 |
-
text-rendering: optimizelegibility;
|
953 |
-
box-shadow: 0px 1px 3px rgba(0, 0, 0, 0.2);
|
954 |
-
}
|
955 |
-
.wp-ulike-about-page .wp_ulike_version {
|
956 |
-
display: inline-block;
|
957 |
-
position: absolute;
|
958 |
-
top: 54px;
|
959 |
-
left: 0;
|
960 |
-
padding: 5px 10px;
|
961 |
-
background: #e74c3c;
|
962 |
-
color: #FFFFFF;
|
963 |
-
font-size: 13px;
|
964 |
-
font-weight: normal;
|
965 |
-
}
|
966 |
-
.wp-ulike-about-page .headline-feature h2 {
|
967 |
-
margin: 1.1em 0px 0.2em;
|
968 |
-
font-size: 2.4em;
|
969 |
-
font-weight: 300;
|
970 |
-
line-height: 1.3;
|
971 |
-
text-align: center;
|
972 |
-
}
|
973 |
-
.wp-ulike-about-page .icon-container {
|
974 |
-
text-align: center;
|
975 |
-
font-size: 6vw;
|
976 |
-
border: 1px solid #757575;
|
977 |
-
padding: 35px 5px;
|
978 |
-
}
|
979 |
-
.wp-ulike-about-page .featured-image img {
|
980 |
-
border: none;
|
981 |
-
}
|
982 |
-
|
983 |
-
/**
|
984 |
-
* Go Pro Page
|
985 |
-
*/
|
986 |
-
.wp-ulike-go-pro-page .has-1-columns, .wp-ulike-go-pro-page .has-2-columns, .wp-ulike-go-pro-page .has-3-columns, .wp-ulike-go-pro-page .has-4-columns {
|
987 |
-
max-width: 1400px;
|
988 |
-
margin-left: 0;
|
989 |
-
margin-right: 0;
|
990 |
-
}
|
991 |
-
.wp-ulike-go-pro-page h1 {
|
992 |
-
margin-bottom: 1em;
|
993 |
-
}
|
994 |
-
.wp-ulike-go-pro-page h2 {
|
995 |
-
text-align: left;
|
996 |
-
}
|
997 |
-
.wp-ulike-go-pro-page .is-section-header {
|
998 |
-
margin-left: 20px;
|
999 |
-
margin-right: 20px;
|
1000 |
-
}
|
1001 |
-
.wp-ulike-go-pro-page .wp-ulike-btn {
|
1002 |
-
margin-top: 5px;
|
1003 |
-
margin-right: 15px;
|
1004 |
-
}
|
1005 |
-
|
1006 |
-
/**
|
1007 |
-
* Logs Page
|
1008 |
-
*/
|
1009 |
-
.wp_ulike_logs .button {
|
1010 |
-
line-height: 20px;
|
1011 |
-
}
|
1012 |
-
.wp_ulike_logs i {
|
1013 |
-
font-size: 1.9em;
|
1014 |
-
}
|
1015 |
-
.wp_ulike_logs i.wp-ulike-icons-thumb_up:before {
|
1016 |
-
color: #4caf50;
|
1017 |
-
}
|
1018 |
-
.wp_ulike_logs i.wp-ulike-icons-thumb_down:before {
|
1019 |
-
color: #f44336;
|
1020 |
-
}
|
1 |
/*
|
2 |
+
/------------------------------------------\ _ __ _ _____ _ _ _ _
|
|
|
3 |
| | / \ | | ___ \ | |(_)| | / /
|
4 |
| | / /\ \ | | |_/ / _| || || |/ / ___
|
5 |
| | / / \ \ | | __/ | | | || || | / _ \
|
19 |
Author: Brian Grinstead
|
20 |
License: MIT
|
21 |
***/
|
22 |
+
.sp-container { position: absolute; top: 0; left: 0; display: inline-block; *display: inline; *zoom: 1; /* https://github.com/bgrins/spectrum/issues/40 */ z-index: 9999994; overflow: hidden; }
|
23 |
+
|
24 |
+
.sp-container.sp-flat { position: relative; }
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
25 |
|
26 |
/* Fix for * { box-sizing: border-box; } */
|
27 |
+
.sp-container, .sp-container * { -webkit-box-sizing: content-box; -moz-box-sizing: content-box; box-sizing: content-box; }
|
|
|
|
|
|
|
|
|
|
|
28 |
|
29 |
/* http://ansciath.tumblr.com/post/7347495869/css-aspect-ratio */
|
30 |
+
.sp-top { position: relative; width: 100%; display: inline-block; }
|
31 |
+
|
32 |
+
.sp-top-inner { position: absolute; top: 0; left: 0; bottom: 0; right: 0; }
|
33 |
+
|
34 |
+
.sp-color { position: absolute; top: 0; left: 0; bottom: 0; right: 20%; }
|
35 |
+
|
36 |
+
.sp-hue { position: absolute; top: 0; right: 0; bottom: 0; left: 84%; height: 100%; }
|
37 |
+
|
38 |
+
.sp-clear-enabled .sp-hue { top: 33px; height: 77.5%; }
|
39 |
+
|
40 |
+
.sp-fill { padding-top: 80%; }
|
41 |
+
|
42 |
+
.sp-sat, .sp-val { position: absolute; top: 0; left: 0; right: 0; bottom: 0; }
|
43 |
+
|
44 |
+
.sp-alpha-enabled .sp-top { margin-bottom: 18px; }
|
45 |
+
|
46 |
+
.sp-alpha-enabled .sp-alpha { display: block; }
|
47 |
+
|
48 |
+
.sp-alpha-handle { position: absolute; top: -4px; bottom: -4px; width: 6px; left: 50%; cursor: pointer; border: 1px solid black; background: white; opacity: .8; }
|
49 |
+
|
50 |
+
.sp-alpha { display: none; position: absolute; bottom: -14px; right: 0; left: 0; height: 8px; }
|
51 |
+
|
52 |
+
.sp-alpha-inner { border: solid 1px #333; }
|
53 |
+
|
54 |
+
.sp-clear { display: none; }
|
55 |
+
|
56 |
+
.sp-clear.sp-clear-display { background-position: center; }
|
57 |
+
|
58 |
+
.sp-clear-enabled .sp-clear { display: block; position: absolute; top: 0px; right: 0; bottom: 0; left: 84%; height: 28px; }
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
59 |
|
60 |
/* Don't allow text selection */
|
61 |
+
.sp-container, .sp-replacer, .sp-preview, .sp-dragger, .sp-slider, .sp-alpha, .sp-clear, .sp-alpha-handle, .sp-container.sp-dragging .sp-input, .sp-container button { -webkit-user-select: none; -moz-user-select: -moz-none; -o-user-select: none; user-select: none; }
|
|
|
|
|
|
|
|
|
|
|
62 |
|
63 |
+
.sp-container.sp-input-disabled .sp-input-container { display: none; }
|
|
|
|
|
64 |
|
65 |
+
.sp-container.sp-buttons-disabled .sp-button-container { display: none; }
|
|
|
|
|
66 |
|
67 |
+
.sp-container.sp-palette-buttons-disabled .sp-palette-button-container { display: none; }
|
|
|
|
|
68 |
|
69 |
+
.sp-palette-only .sp-picker-container { display: none; }
|
|
|
|
|
70 |
|
71 |
+
.sp-palette-disabled .sp-palette-container { display: none; }
|
|
|
|
|
72 |
|
73 |
+
.sp-initial-disabled .sp-initial { display: none; }
|
|
|
|
|
74 |
|
75 |
/* Gradients for hue, saturation and value instead of images. Not pretty... but it works */
|
76 |
+
.sp-sat { background-image: -webkit-gradient(linear, 0 0, 100% 0, from(#FFF), to(rgba(204, 154, 129, 0))); background-image: -webkit-linear-gradient(left, #FFF, rgba(204, 154, 129, 0)); background-image: -moz-linear-gradient(left, #fff, rgba(204, 154, 129, 0)); background-image: -o-linear-gradient(left, #fff, rgba(204, 154, 129, 0)); background-image: -ms-linear-gradient(left, #fff, rgba(204, 154, 129, 0)); background-image: linear-gradient(to right, #ffffff, rgba(204, 154, 129, 0)); -ms-filter: "progid:DXImageTransform.Microsoft.gradient(GradientType = 1, startColorstr=#FFFFFFFF, endColorstr=#00CC9A81)"; filter: progid:DXImageTransform.Microsoft.gradient(GradientType = 1, startColorstr='#FFFFFFFF', endColorstr='#00CC9A81'); }
|
77 |
+
|
78 |
+
.sp-val { background-image: -webkit-gradient(linear, 0 100%, 0 0, from(#000000), to(rgba(204, 154, 129, 0))); background-image: -webkit-linear-gradient(bottom, #000000, rgba(204, 154, 129, 0)); background-image: -moz-linear-gradient(bottom, #000, rgba(204, 154, 129, 0)); background-image: -o-linear-gradient(bottom, #000, rgba(204, 154, 129, 0)); background-image: -ms-linear-gradient(bottom, #000, rgba(204, 154, 129, 0)); background-image: linear-gradient(to top, #000000, rgba(204, 154, 129, 0)); -ms-filter: "progid:DXImageTransform.Microsoft.gradient(startColorstr=#00CC9A81, endColorstr=#FF000000)"; filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#00CC9A81', endColorstr='#FF000000'); }
|
79 |
+
|
80 |
+
.sp-hue { background: -moz-linear-gradient(top, #ff0000 0%, #ffff00 17%, #00ff00 33%, #00ffff 50%, #0000ff 67%, #ff00ff 83%, #ff0000 100%); background: -ms-linear-gradient(top, #ff0000 0%, #ffff00 17%, #00ff00 33%, #00ffff 50%, #0000ff 67%, #ff00ff 83%, #ff0000 100%); background: -o-linear-gradient(top, #ff0000 0%, #ffff00 17%, #00ff00 33%, #00ffff 50%, #0000ff 67%, #ff00ff 83%, #ff0000 100%); background: -webkit-gradient(linear, left top, left bottom, from(#ff0000), color-stop(0.17, #ffff00), color-stop(0.33, #00ff00), color-stop(0.5, #00ffff), color-stop(0.67, #0000ff), color-stop(0.83, #ff00ff), to(#ff0000)); background: -webkit-linear-gradient(top, #ff0000 0%, #ffff00 17%, #00ff00 33%, #00ffff 50%, #0000ff 67%, #ff00ff 83%, #ff0000 100%); background: linear-gradient(to bottom, #ff0000 0%, #ffff00 17%, #00ff00 33%, #00ffff 50%, #0000ff 67%, #ff00ff 83%, #ff0000 100%); }
|
81 |
+
|
82 |
+
/* IE filters do not support multiple color stops. Generate 6 divs, line them up, and do two color gradients for each. Yes, really. */
|
83 |
+
.sp-1 { height: 17%; filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff0000', endColorstr='#ffff00'); }
|
84 |
+
|
85 |
+
.sp-2 { height: 16%; filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffff00', endColorstr='#00ff00'); }
|
86 |
+
|
87 |
+
.sp-3 { height: 17%; filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#00ff00', endColorstr='#00ffff'); }
|
88 |
+
|
89 |
+
.sp-4 { height: 17%; filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#00ffff', endColorstr='#0000ff'); }
|
90 |
+
|
91 |
+
.sp-5 { height: 16%; filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#0000ff', endColorstr='#ff00ff'); }
|
92 |
+
|
93 |
+
.sp-6 { height: 17%; filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff00ff', endColorstr='#ff0000'); }
|
94 |
+
|
95 |
+
.sp-hidden { display: none !important; }
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
96 |
|
97 |
/* Clearfix hack */
|
98 |
+
.sp-cf:before, .sp-cf:after { content: ""; display: table; }
|
|
|
|
|
|
|
99 |
|
100 |
+
.sp-cf:after { clear: both; }
|
|
|
|
|
101 |
|
102 |
+
.sp-cf { *zoom: 1; }
|
|
|
|
|
103 |
|
104 |
/* Mobile devices, make hue slider bigger so it is easier to slide */
|
105 |
+
@media (max-device-width: 480px) { .sp-color { right: 40%; }
|
106 |
+
.sp-hue { left: 63%; }
|
107 |
+
.sp-fill { padding-top: 60%; } }
|
108 |
+
.sp-dragger { border-radius: 5px; height: 5px; width: 5px; border: 1px solid #fff; background: #000; cursor: pointer; position: absolute; top: 0; left: 0; }
|
109 |
+
|
110 |
+
.sp-slider { position: absolute; top: 0; cursor: pointer; height: 3px; left: -1px; right: -1px; border: 1px solid #000; background: white; opacity: .8; }
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
111 |
|
112 |
/*
|
113 |
Theme authors:
|
114 |
Here are the basic themeable display options (colors, fonts, global widths).
|
115 |
See http://bgrins.github.io/spectrum/themes/ for instructions.
|
116 |
*/
|
117 |
+
.sp-container { border-radius: 0; background-color: #ECECEC; border: solid 1px #f0c49B; padding: 0; }
|
118 |
+
|
119 |
+
.sp-container, .sp-container button, .sp-container input, .sp-color, .sp-hue, .sp-clear { font: normal 12px "Lucida Grande", "Lucida Sans Unicode", "Lucida Sans", Geneva, Verdana, sans-serif; -webkit-box-sizing: border-box; -moz-box-sizing: border-box; -ms-box-sizing: border-box; box-sizing: border-box; }
|
120 |
+
|
121 |
+
.sp-top { margin-bottom: 3px; }
|
122 |
+
|
123 |
+
.sp-color, .sp-hue, .sp-clear { border: solid 1px #666; }
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
124 |
|
125 |
/* Input */
|
126 |
+
.sp-input-container { float: right; width: 100px; margin-bottom: 4px; }
|
127 |
+
|
128 |
+
.sp-initial-disabled .sp-input-container { width: 100%; }
|
129 |
+
|
130 |
+
.sp-input { font-size: 12px !important; border: 1px inset; padding: 4px 5px; margin: 0; width: 100%; background: transparent; border-radius: 3px; color: #222; }
|
131 |
+
|
132 |
+
.sp-input:focus { border: 1px solid orange; }
|
133 |
+
|
134 |
+
.sp-input.sp-validation-error { border: 1px solid red; background: #fdd; }
|
135 |
+
|
136 |
+
.sp-picker-container, .sp-palette-container { float: left; position: relative; padding: 10px; padding-bottom: 300px; margin-bottom: -290px; }
|
137 |
+
|
138 |
+
.sp-picker-container { width: 172px; border-left: solid 1px #fff; }
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
139 |
|
140 |
/* Palettes */
|
141 |
+
.sp-palette-container { border-right: solid 1px #ccc; }
|
142 |
+
|
143 |
+
.sp-palette-only .sp-palette-container { border: 0; }
|
144 |
+
|
145 |
+
.sp-palette .sp-thumb-el { display: block; position: relative; float: left; width: 24px; height: 15px; margin: 3px; cursor: pointer; border: solid 2px transparent; }
|
146 |
+
|
147 |
+
.sp-palette .sp-thumb-el:hover, .sp-palette .sp-thumb-el.sp-thumb-active { border-color: orange; }
|
148 |
+
|
149 |
+
.sp-thumb-el { position: relative; }
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
150 |
|
151 |
/* Initial */
|
152 |
+
.sp-initial { float: left; border: solid 1px #333; }
|
153 |
+
|
154 |
+
.sp-initial span { width: 30px; height: 25px; border: none; display: block; float: left; margin: 0; }
|
155 |
+
|
156 |
+
.sp-initial .sp-clear-display { background-position: center; }
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
157 |
|
158 |
/* Buttons */
|
159 |
+
.sp-palette-button-container, .sp-button-container { float: right; }
|
|
|
|
|
|
|
160 |
|
161 |
/* Replacer (the little preview div that shows up instead of the <input>) */
|
162 |
+
.sp-replacer { margin: 0; overflow: hidden; cursor: pointer; padding: 4px; display: inline-block; *zoom: 1; *display: inline; border: solid 1px #91765d; background: #eee; color: #333; vertical-align: middle; }
|
163 |
+
|
164 |
+
.sp-replacer:hover, .sp-replacer.sp-active { border-color: #F0C49B; color: #111; }
|
165 |
+
|
166 |
+
.sp-replacer.sp-disabled { cursor: default; border-color: silver; color: silver; }
|
167 |
+
|
168 |
+
.sp-dd { padding: 2px 0; height: 16px; line-height: 16px; float: left; font-size: 10px; }
|
169 |
+
|
170 |
+
.sp-preview { position: relative; width: 25px; height: 20px; border: solid 1px #222; margin-right: 5px; float: left; z-index: 0; }
|
171 |
+
|
172 |
+
.sp-palette { *width: 220px; max-width: 220px; }
|
173 |
+
|
174 |
+
.sp-palette .sp-thumb-el { width: 16px; height: 16px; margin: 2px 1px; border: solid 1px #d0d0d0; }
|
175 |
+
|
176 |
+
.sp-container { padding-bottom: 0; }
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
177 |
|
178 |
/* Buttons: http://hellohappy.org/css3-buttons/ */
|
179 |
+
.sp-container button { background-color: #eeeeee; background-image: -webkit-linear-gradient(top, #eeeeee, #cccccc); background-image: -moz-linear-gradient(top, #eeeeee, #cccccc); background-image: -ms-linear-gradient(top, #eeeeee, #cccccc); background-image: -o-linear-gradient(top, #eeeeee, #cccccc); background-image: linear-gradient(to bottom, #eeeeee, #cccccc); border: 1px solid #ccc; border-bottom: 1px solid #bbb; border-radius: 3px; color: #333; font-size: 14px; line-height: 1; padding: 5px 4px; text-align: center; text-shadow: 0 1px 0 #eee; vertical-align: middle; }
|
180 |
+
|
181 |
+
.sp-container button:hover { background-color: #dddddd; background-image: -webkit-linear-gradient(top, #dddddd, #bbbbbb); background-image: -moz-linear-gradient(top, #dddddd, #bbbbbb); background-image: -ms-linear-gradient(top, #dddddd, #bbbbbb); background-image: -o-linear-gradient(top, #dddddd, #bbbbbb); background-image: linear-gradient(to bottom, #dddddd, #bbbbbb); border: 1px solid #bbb; border-bottom: 1px solid #999; cursor: pointer; text-shadow: 0 1px 0 #ddd; }
|
182 |
+
|
183 |
+
.sp-container button:active { border: 1px solid #aaa; border-bottom: 1px solid #888; -webkit-box-shadow: inset 0 0 5px 2px #aaaaaa, 0 1px 0 0 #eeeeee; -moz-box-shadow: inset 0 0 5px 2px #aaaaaa, 0 1px 0 0 #eeeeee; -ms-box-shadow: inset 0 0 5px 2px #aaaaaa, 0 1px 0 0 #eeeeee; -o-box-shadow: inset 0 0 5px 2px #aaaaaa, 0 1px 0 0 #eeeeee; box-shadow: inset 0 0 5px 2px #aaaaaa, 0 1px 0 0 #eeeeee; }
|
184 |
+
|
185 |
+
.sp-cancel { font-size: 11px; color: #d93f3f !important; margin: 0; padding: 2px; margin-right: 5px; vertical-align: middle; text-decoration: none; }
|
186 |
+
|
187 |
+
.sp-cancel:hover { color: #d93f3f !important; text-decoration: underline; }
|
188 |
+
|
189 |
+
.sp-palette span:hover, .sp-palette span.sp-thumb-active { border-color: #000; }
|
190 |
+
|
191 |
+
.sp-preview, .sp-alpha, .sp-thumb-el { position: relative; background-image: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAwAAAAMCAIAAADZF8uwAAAAGUlEQVQYV2M4gwH+YwCGIasIUwhT25BVBADtzYNYrHvv4gAAAABJRU5ErkJggg==); }
|
192 |
+
|
193 |
+
.sp-preview-inner, .sp-alpha-inner, .sp-thumb-inner { display: block; position: absolute; top: 0; left: 0; bottom: 0; right: 0; }
|
194 |
+
|
195 |
+
.sp-palette .sp-thumb-inner { background-position: 50% 50%; background-repeat: no-repeat; }
|
196 |
+
|
197 |
+
.sp-palette .sp-thumb-light.sp-thumb-active .sp-thumb-inner { background-image: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABIAAAASCAYAAABWzo5XAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAIVJREFUeNpiYBhsgJFMffxAXABlN5JruT4Q3wfi/0DsT64h8UD8HmpIPCWG/KemIfOJCUB+Aoacx6EGBZyHBqI+WsDCwuQ9mhxeg2A210Ntfo8klk9sOMijaURm7yc1UP2RNCMbKE9ODK1HM6iegYLkfx8pligC9lCD7KmRof0ZhjQACDAAceovrtpVBRkAAAAASUVORK5CYII=); }
|
198 |
+
|
199 |
+
.sp-palette .sp-thumb-dark.sp-thumb-active .sp-thumb-inner { background-image: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABIAAAASCAYAAABWzo5XAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsMAAA7DAcdvqGQAAAAadEVYdFNvZnR3YXJlAFBhaW50Lk5FVCB2My41LjEwMPRyoQAAAMdJREFUOE+tkgsNwzAMRMugEAahEAahEAZhEAqlEAZhEAohEAYh81X2dIm8fKpEspLGvudPOsUYpxE2BIJCroJmEW9qJ+MKaBFhEMNabSy9oIcIPwrB+afvAUFoK4H0tMaQ3XtlrggDhOVVMuT4E5MMG0FBbCEYzjYT7OxLEvIHQLY2zWwQ3D+9luyOQTfKDiFD3iUIfPk8VqrKjgAiSfGFPecrg6HN6m/iBcwiDAo7WiBeawa+Kwh7tZoSCGLMqwlSAzVDhoK+6vH4G0P5wdkAAAAASUVORK5CYII=); }
|
200 |
+
|
201 |
+
.sp-clear-display { background-repeat: no-repeat; background-position: center; background-image: url(data:image/gif;base64,R0lGODlhFAAUAPcAAAAAAJmZmZ2dnZ6enqKioqOjo6SkpKWlpaampqenp6ioqKmpqaqqqqurq/Hx8fLy8vT09PX19ff39/j4+Pn5+fr6+vv7+wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAEAAP8ALAAAAAAUABQAAAihAP9FoPCvoMGDBy08+EdhQAIJCCMybCDAAYUEARBAlFiQQoMABQhKUJBxY0SPICEYHBnggEmDKAuoPMjS5cGYMxHW3IiT478JJA8M/CjTZ0GgLRekNGpwAsYABHIypcAgQMsITDtWJYBR6NSqMico9cqR6tKfY7GeBCuVwlipDNmefAtTrkSzB1RaIAoXodsABiZAEFB06gIBWC1mLVgBa0AAOw==); }
|
202 |
+
|
203 |
+
/** Visual Select */
|
204 |
+
.wp-ulike-visual-select { height: auto; display: inline-block; width: 100%; max-width: 900px; }
|
205 |
+
.wp-ulike-visual-select .radio-img-item { display: inline-block; margin-right: 10px; margin-bottom: 10px; border: 3px solid #d8d8d8; padding: 4px 15px; width: 110px; height: 60px; cursor: pointer; }
|
206 |
+
.wp-ulike-visual-select .radio-img-item.item-checked { -webkit-filter: brightness(40%) sepia(100%) hue-rotate(170deg) saturate(250%); filter: brightness(40%) sepia(100%) hue-rotate(170deg) saturate(250%); }
|
207 |
+
.wp-ulike-visual-select .radio-img-item img { display: block; clear: both; width: 100%; height: 100%; }
|
208 |
+
|
209 |
+
.wp-ulike-container { width: 100%; margin-left: auto; margin-right: auto; }
|
210 |
+
|
211 |
+
.wp-ulike-row { position: relative; width: 100%; }
|
212 |
+
|
213 |
+
.wp-ulike-flex { display: flex; align-items: center; flex-wrap: wrap; justify-content: center; padding: 10px 0; }
|
214 |
+
.wp-ulike-flex.wp-ulike-flex-end { justify-content: end; }
|
215 |
+
.wp-ulike-flex.wp-ulike-flex-start { justify-content: start; }
|
216 |
+
|
217 |
+
.wp-ulike-row [class^="col"] { float: left; margin: 2%; }
|
218 |
+
|
219 |
+
.rtl .wp-ulike-row [class^="col"] { float: right; }
|
220 |
+
|
221 |
+
.wp-ulike-row::after { content: ""; display: table; clear: both; }
|
222 |
+
|
223 |
+
.wp-ulike-row .col-1, .wp-ulike-row .col-2, .wp-ulike-row .col-3, .wp-ulike-row .col-4, .wp-ulike-row .col-5, .wp-ulike-row .col-6, .wp-ulike-row .col-7, .wp-ulike-row .col-8, .wp-ulike-row .col-9, .wp-ulike-row .col-10, .wp-ulike-row .col-11, .wp-ulike-row .col-12 { width: 96%; }
|
224 |
+
.wp-ulike-row .col-1-sm { width: 4.33333%; }
|
225 |
+
.wp-ulike-row .col-2-sm { width: 12.66667%; }
|
226 |
+
.wp-ulike-row .col-3-sm { width: 21%; }
|
227 |
+
.wp-ulike-row .col-4-sm { width: 29.33333%; }
|
228 |
+
.wp-ulike-row .col-5-sm { width: 37.66667%; }
|
229 |
+
.wp-ulike-row .col-6-sm { width: 46%; }
|
230 |
+
.wp-ulike-row .col-7-sm { width: 54.33333%; }
|
231 |
+
.wp-ulike-row .col-8-sm { width: 62.66667%; }
|
232 |
+
.wp-ulike-row .col-9-sm { width: 71%; }
|
233 |
+
.wp-ulike-row .col-10-sm { width: 79.33333%; }
|
234 |
+
.wp-ulike-row .col-11-sm { width: 87.66667%; }
|
235 |
+
.wp-ulike-row .col-12-sm { width: 96%; }
|
236 |
+
|
237 |
+
@media only screen and (min-width: 45em) { .wp-ulike-row .col-1 { width: 4.33333%; }
|
238 |
+
.wp-ulike-row .col-2 { width: 12.66667%; }
|
239 |
+
.wp-ulike-row .col-3 { width: 21%; }
|
240 |
+
.wp-ulike-row .col-4 { width: 29.33333%; }
|
241 |
+
.wp-ulike-row .col-5 { width: 37.66667%; }
|
242 |
+
.wp-ulike-row .col-6 { width: 46%; }
|
243 |
+
.wp-ulike-row .col-7 { width: 54.33333%; }
|
244 |
+
.wp-ulike-row .col-8 { width: 62.66667%; }
|
245 |
+
.wp-ulike-row .col-9 { width: 71%; }
|
246 |
+
.wp-ulike-row .col-10 { width: 79.33333%; }
|
247 |
+
.wp-ulike-row .col-11 { width: 87.66667%; }
|
248 |
+
.wp-ulike-row .col-12 { width: 96%; }
|
249 |
+
.wp-ulike-row .hidden-sm { display: block; } }
|
250 |
+
@media only screen and (max-width: 45em) { .wp-ulike-flex { text-align: center; } }
|
251 |
+
/** Statistics Page */
|
252 |
+
.wp-ulike-page-title { font-size: 38px; line-height: 50px; font-weight: 400; margin: 0; }
|
253 |
+
|
254 |
+
.wp-ulike-header { margin: 0 2% 10px; padding: 0 20px 35px; display: flex; justify-content: space-between; position: relative; align-items: center; flex-wrap: wrap; }
|
255 |
+
.wp-ulike-header:after { content: ""; position: absolute; bottom: 0; height: 1px; background: #dde3e7; right: 20px; left: 20px; }
|
256 |
+
.wp-ulike-header .wp-ulike-widget-title { text-transform: capitalize; font-size: 22px; font-weight: 500; line-height: normal; color: #3d3d3d; margin: 0; }
|
257 |
+
|
258 |
+
.wp-ulike-button { background-color: #f9faff; padding: 10px 25px; text-decoration: none; text-transform: uppercase; color: #7e8996; border: 1px solid #dde3e7; border-radius: 50em; font-size: 14px; line-height: 20px; }
|
259 |
+
.wp-ulike-button:hover { background-color: #fff; color: #42484e; }
|
260 |
+
|
261 |
+
.wp-ulike-inner { position: relative; padding: 35px 20px; border: 1px solid #e4e6eb; background: #fff; border-radius: 4px; }
|
262 |
+
|
263 |
+
.wp-ulike-logs-count { margin: 0 auto; text-align: center; }
|
264 |
+
.wp-ulike-logs-count .wp-ulike-icon { font-size: 5vw; color: #8B93A6; line-height: 5vh; }
|
265 |
+
.wp-ulike-logs-count .wp-ulike-var { font-size: 3vw; line-height: 4vw; display: block; }
|
266 |
+
.wp-ulike-logs-count .wp-ulike-text { display: block; color: #8B93A6; font-size: 1.5vw; line-height: 2.5vw; }
|
267 |
+
|
268 |
+
.wp-ulike-is-loading { padding: 10px 0; }
|
269 |
+
.wp-ulike-is-loading:before { content: ""; position: absolute; left: 0; width: 100%; top: 0; height: 100%; background-color: white; background-image: url(../../../assets/img/svg/statistics.svg); background-repeat: no-repeat; background-position: center center; z-index: 9; }
|
270 |
+
|
271 |
+
.wp-ulike-table { display: table; }
|
272 |
+
.wp-ulike-table .wp-ulike-table-cell { display: table-cell; vertical-align: middle; }
|
273 |
+
|
274 |
+
.wp-ulike-summary-charts .wp-ulike-info { flex-basis: 35%; }
|
275 |
+
.wp-ulike-summary-charts .wp-ulike-icon { font-size: 3vw; color: #8B93A6; line-height: normal; flex-basis: 25%; }
|
276 |
+
.wp-ulike-summary-charts .wp-ulike-var { font-size: 1.8vw; line-height: normal; display: block; }
|
277 |
+
.wp-ulike-summary-charts .wp-ulike-text { display: block; color: #8B93A6; font-size: 1vw; line-height: normal; }
|
278 |
+
|
279 |
+
.wp-ulike-top-likers { margin: 0 2%; }
|
280 |
+
.wp-ulike-top-likers .wp-ulike-users-list { border-bottom: 1px solid #dde3e7; font-size: 15px; padding: 20px 0px; margin: 5px; }
|
281 |
+
.wp-ulike-top-likers .wp-ulike-users-list i { color: #8B93A6; margin: 0 5px; }
|
282 |
+
.wp-ulike-top-likers .wp-ulike-info { width: 60%; }
|
283 |
+
.wp-ulike-top-likers .wp-ulike-counter { width: 20%; }
|
284 |
+
.wp-ulike-top-likers .wp-ulike-total { width: 20%; }
|
285 |
+
|
286 |
+
.wp-ulike-empty-stats { text-align: center; height: 50em; position: relative; }
|
287 |
+
.wp-ulike-empty-stats > div { position: relative; top: 50%; transform: translateY(-50%); }
|
288 |
+
.wp-ulike-empty-stats .wp-ulike-icon { font-size: 110px; color: #8B93A6; }
|
289 |
+
.wp-ulike-empty-stats .wp-ulike-info { font-size: 28px; line-height: 42px; font-weight: 300; margin-top: 50px; }
|
290 |
+
|
291 |
+
.wp-ulike-tops-list { padding: 0 20px; }
|
292 |
+
.wp-ulike-tops-list > ul { font-size: 16px; font-weight: 300; line-height: 26px; color: #3d3d3d; margin: 0; }
|
293 |
+
.wp-ulike-tops-list > ul > li { display: flex; justify-content: space-between; border-bottom: 1px solid #dde3e7; padding: 8px 0; }
|
294 |
+
.wp-ulike-tops-list > ul > li a { text-decoration: none; color: #3d3d3d; }
|
295 |
+
|
296 |
+
/** About Page */
|
297 |
+
.wp-ulike-about-page .ulike-badge { background: url(../../../assets/img/wp-ulike-icon.svg) no-repeat scroll center 24px/95px 95px #FF7171; color: #FFFFFF; position: absolute; top: 0px; right: 0px; font-size: 14px; text-align: center; font-weight: 600; margin: 5px 0px 0px; padding-top: 120px; height: 40px; display: inline-block; width: 150px; text-rendering: optimizelegibility; box-shadow: 0px 1px 3px rgba(0, 0, 0, 0.2); }
|
298 |
+
.wp-ulike-about-page .wp_ulike_version { display: inline-block; position: absolute; top: 54px; left: 0; padding: 5px 10px; background: #e74c3c; color: #FFFFFF; font-size: 13px; font-weight: normal; }
|
299 |
+
.wp-ulike-about-page .headline-feature h2 { margin: 1.1em 0px 0.2em; font-size: 2.4em; font-weight: 300; line-height: 1.3; text-align: center; }
|
300 |
+
.wp-ulike-about-page .icon-container { text-align: center; font-size: 6vw; border: 1px solid #757575; padding: 35px 5px; }
|
301 |
+
.wp-ulike-about-page .featured-image img { border: none; }
|
302 |
+
|
303 |
+
/** Go Pro Page */
|
304 |
+
.wp-ulike-go-pro-page .has-1-columns, .wp-ulike-go-pro-page .has-2-columns, .wp-ulike-go-pro-page .has-3-columns, .wp-ulike-go-pro-page .has-4-columns { max-width: 1400px; margin-left: 0; margin-right: 0; }
|
305 |
+
.wp-ulike-go-pro-page h1 { margin-bottom: 1em; }
|
306 |
+
.wp-ulike-go-pro-page h2 { text-align: left; }
|
307 |
+
.wp-ulike-go-pro-page .is-section-header { margin-left: 20px; margin-right: 20px; }
|
308 |
+
.wp-ulike-go-pro-page .wp-ulike-btn { margin-top: 5px; margin-right: 15px; }
|
309 |
+
|
310 |
+
/** Logs Page */
|
311 |
+
.wp_ulike_logs .button { line-height: 20px; }
|
312 |
+
.wp_ulike_logs i { font-size: 1.9em; }
|
313 |
+
.wp_ulike_logs i.wp-ulike-icons-thumb_up:before { color: #4caf50; }
|
314 |
+
.wp_ulike_logs i.wp-ulike-icons-thumb_down:before { color: #f44336; }
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
admin/assets/js/scripts.js
CHANGED
@@ -366,201 +366,4 @@
|
|
366 |
}
|
367 |
});
|
368 |
});
|
369 |
-
})(jQuery);
|
370 |
-
|
371 |
-
|
372 |
-
/* ================== admin/assets/js/src/statistics.js =================== */
|
373 |
-
|
374 |
-
|
375 |
-
(function ($) {
|
376 |
-
$(".wp_ulike_delete").click(function (e) {
|
377 |
-
e.preventDefault();
|
378 |
-
var parent = $(this).closest("tr");
|
379 |
-
var value = $(this).data("id");
|
380 |
-
var table = $(this).data("table");
|
381 |
-
var nonce = $(this).data("nonce");
|
382 |
-
var r = confirm(wp_ulike_admin.logs_notif);
|
383 |
-
if (r === true) {
|
384 |
-
jQuery.ajax({
|
385 |
-
type: "POST",
|
386 |
-
url: ajaxurl,
|
387 |
-
data: {
|
388 |
-
action: "ulikelogs",
|
389 |
-
id: value,
|
390 |
-
nonce: nonce,
|
391 |
-
table: table
|
392 |
-
},
|
393 |
-
beforeSend: function () {
|
394 |
-
parent.css("background-color", "#fff59d");
|
395 |
-
},
|
396 |
-
success: function (response) {
|
397 |
-
if (response.success) {
|
398 |
-
parent.fadeOut(300);
|
399 |
-
} else {
|
400 |
-
parent.css("background-color", "#ef9a9a");
|
401 |
-
}
|
402 |
-
}
|
403 |
-
});
|
404 |
-
}
|
405 |
-
});
|
406 |
-
|
407 |
-
$.fn.WpUlikeAjaxStats = function () {
|
408 |
-
// local var
|
409 |
-
var theResponse = null;
|
410 |
-
// jQuery ajax
|
411 |
-
$.ajax({
|
412 |
-
type: "POST",
|
413 |
-
dataType: "json",
|
414 |
-
url: ajaxurl,
|
415 |
-
async: false,
|
416 |
-
data: {
|
417 |
-
action: "wp_ulike_ajax_stats",
|
418 |
-
nonce: wp_ulike_admin.nonce_field
|
419 |
-
},
|
420 |
-
success: function (response) {
|
421 |
-
if (response.success) {
|
422 |
-
theResponse = JSON.parse(response.data);
|
423 |
-
} else {
|
424 |
-
theResponse = null;
|
425 |
-
}
|
426 |
-
}
|
427 |
-
});
|
428 |
-
// Return the response text
|
429 |
-
return theResponse;
|
430 |
-
};
|
431 |
-
|
432 |
-
// Charts stack array to save data
|
433 |
-
window.wpUlikechartsInfo = [];
|
434 |
-
|
435 |
-
if (wp_ulike_admin.hook_address.indexOf("wp-ulike-statistics") !== -1) {
|
436 |
-
|
437 |
-
// Get all tables data
|
438 |
-
window.wpUlikeAjaxDataset = $.fn.WpUlikeAjaxStats();
|
439 |
-
|
440 |
-
if (window.wpUlikeAjaxDataset === null) {
|
441 |
-
return;
|
442 |
-
}
|
443 |
-
|
444 |
-
// Get single var component
|
445 |
-
Vue.component("get-var", {
|
446 |
-
props: ["dataset"],
|
447 |
-
data: function () {
|
448 |
-
return {
|
449 |
-
output: "..."
|
450 |
-
};
|
451 |
-
},
|
452 |
-
mounted() {
|
453 |
-
this.output = this.fetchData();
|
454 |
-
// Remove spinner class
|
455 |
-
this.$nextTick(function () {
|
456 |
-
this.removeClass(this.$el.offsetParent);
|
457 |
-
});
|
458 |
-
},
|
459 |
-
methods: {
|
460 |
-
fetchData() {
|
461 |
-
return window.wpUlikeAjaxDataset[this.dataset];
|
462 |
-
},
|
463 |
-
removeClass(element) {
|
464 |
-
element.classList.remove("wp-ulike-is-loading");
|
465 |
-
}
|
466 |
-
}
|
467 |
-
});
|
468 |
-
// Get charts object component
|
469 |
-
Vue.component("get-chart", {
|
470 |
-
props: ["dataset", "identify", "type"],
|
471 |
-
mounted() {
|
472 |
-
if (this.type == "line") {
|
473 |
-
this.planetChartData = this.fetchData();
|
474 |
-
this.createLineChart(this.planetChartData);
|
475 |
-
} else {
|
476 |
-
this.createPieChart();
|
477 |
-
}
|
478 |
-
// Remove spinner class
|
479 |
-
this.$nextTick(function () {
|
480 |
-
this.removeClass(this.$el.offsetParent);
|
481 |
-
});
|
482 |
-
},
|
483 |
-
methods: {
|
484 |
-
fetchData() {
|
485 |
-
return window.wpUlikeAjaxDataset[this.dataset];
|
486 |
-
},
|
487 |
-
createLineChart(chartData) {
|
488 |
-
// Push data stats in dataset options
|
489 |
-
chartData.options["data"] = chartData.data;
|
490 |
-
// And finally draw it
|
491 |
-
this.drawChart({
|
492 |
-
// The type of chart we want to create
|
493 |
-
type: "line",
|
494 |
-
// The data for our dataset
|
495 |
-
data: {
|
496 |
-
labels: chartData.label,
|
497 |
-
datasets: [chartData.options]
|
498 |
-
}
|
499 |
-
});
|
500 |
-
// Set info for this canvas
|
501 |
-
this.setInfo(chartData);
|
502 |
-
},
|
503 |
-
createPieChart() {
|
504 |
-
// Define stack variables
|
505 |
-
var pieData = [],
|
506 |
-
pieBackground = [],
|
507 |
-
pieLabels = [];
|
508 |
-
// Get the info of each chart
|
509 |
-
window.wpUlikechartsInfo.forEach(function (value, key) {
|
510 |
-
pieData.push(value.sum);
|
511 |
-
pieBackground.push(value.background);
|
512 |
-
pieLabels.push(value.label);
|
513 |
-
});
|
514 |
-
// And finally draw it
|
515 |
-
this.drawChart({
|
516 |
-
// The type of chart we want to create
|
517 |
-
type: "pie",
|
518 |
-
// The data for our dataset
|
519 |
-
data: {
|
520 |
-
datasets: [
|
521 |
-
{
|
522 |
-
data: pieData,
|
523 |
-
backgroundColor: pieBackground
|
524 |
-
}
|
525 |
-
],
|
526 |
-
// These labels appear in the legend and in the tooltips when hovering different arcs
|
527 |
-
labels: pieLabels
|
528 |
-
}
|
529 |
-
});
|
530 |
-
},
|
531 |
-
drawChart(chartArgs) {
|
532 |
-
// Get canvas element
|
533 |
-
const ctx = document.getElementById(this.identify);
|
534 |
-
// Draw Chart
|
535 |
-
const chart = new Chart(ctx, chartArgs);
|
536 |
-
},
|
537 |
-
setInfo(chartData) {
|
538 |
-
var sumStack = 0;
|
539 |
-
// Get the sum of total likes
|
540 |
-
chartData.data.forEach(function (num) {
|
541 |
-
sumStack += parseFloat(num) || 0;
|
542 |
-
});
|
543 |
-
// Upgrade wpUlikechartsInfo array
|
544 |
-
window.wpUlikechartsInfo.push({
|
545 |
-
type: this.identify,
|
546 |
-
sum: sumStack,
|
547 |
-
label: chartData.options.label,
|
548 |
-
background: chartData.options.backgroundColor
|
549 |
-
});
|
550 |
-
},
|
551 |
-
removeClass(element) {
|
552 |
-
element.classList.remove("wp-ulike-is-loading");
|
553 |
-
}
|
554 |
-
}
|
555 |
-
});
|
556 |
-
|
557 |
-
new Vue({
|
558 |
-
el: "#wp-ulike-stats-app"
|
559 |
-
});
|
560 |
-
}
|
561 |
-
|
562 |
-
// on document ready
|
563 |
-
$(function () {
|
564 |
-
$(".wp-ulike-match-height").matchHeight();
|
565 |
-
});
|
566 |
})(jQuery);
|
366 |
}
|
367 |
});
|
368 |
});
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
369 |
})(jQuery);
|
admin/assets/js/solo/statistics.js
ADDED
@@ -0,0 +1,195 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
/**
|
2 |
+
* wp ulike admin statistics
|
3 |
+
*/
|
4 |
+
(function ($) {
|
5 |
+
$(".wp_ulike_delete").click(function (e) {
|
6 |
+
e.preventDefault();
|
7 |
+
var parent = $(this).closest("tr");
|
8 |
+
var value = $(this).data("id");
|
9 |
+
var table = $(this).data("table");
|
10 |
+
var nonce = $(this).data("nonce");
|
11 |
+
var r = confirm(wp_ulike_admin.logs_notif);
|
12 |
+
if (r === true) {
|
13 |
+
jQuery.ajax({
|
14 |
+
type: "POST",
|
15 |
+
url: ajaxurl,
|
16 |
+
data: {
|
17 |
+
action: "ulikelogs",
|
18 |
+
id: value,
|
19 |
+
nonce: nonce,
|
20 |
+
table: table
|
21 |
+
},
|
22 |
+
beforeSend: function () {
|
23 |
+
parent.css("background-color", "#fff59d");
|
24 |
+
},
|
25 |
+
success: function (response) {
|
26 |
+
if (response.success) {
|
27 |
+
parent.fadeOut(300);
|
28 |
+
} else {
|
29 |
+
parent.css("background-color", "#ef9a9a");
|
30 |
+
}
|
31 |
+
}
|
32 |
+
});
|
33 |
+
}
|
34 |
+
});
|
35 |
+
|
36 |
+
$.fn.WpUlikeAjaxStats = function () {
|
37 |
+
// local var
|
38 |
+
var theResponse = null;
|
39 |
+
// jQuery ajax
|
40 |
+
$.ajax({
|
41 |
+
type: "POST",
|
42 |
+
dataType: "json",
|
43 |
+
url: ajaxurl,
|
44 |
+
async: false,
|
45 |
+
data: {
|
46 |
+
action: "wp_ulike_ajax_stats",
|
47 |
+
nonce: wp_ulike_admin.nonce_field
|
48 |
+
},
|
49 |
+
success: function (response) {
|
50 |
+
if (response.success) {
|
51 |
+
theResponse = JSON.parse(response.data);
|
52 |
+
} else {
|
53 |
+
theResponse = null;
|
54 |
+
}
|
55 |
+
}
|
56 |
+
});
|
57 |
+
// Return the response text
|
58 |
+
return theResponse;
|
59 |
+
};
|
60 |
+
|
61 |
+
// Charts stack array to save data
|
62 |
+
window.wpUlikechartsInfo = [];
|
63 |
+
|
64 |
+
if (wp_ulike_admin.hook_address.indexOf("wp-ulike-statistics") !== -1) {
|
65 |
+
|
66 |
+
// Get all tables data
|
67 |
+
window.wpUlikeAjaxDataset = $.fn.WpUlikeAjaxStats();
|
68 |
+
|
69 |
+
if (window.wpUlikeAjaxDataset === null) {
|
70 |
+
return;
|
71 |
+
}
|
72 |
+
|
73 |
+
// Get single var component
|
74 |
+
Vue.component("get-var", {
|
75 |
+
props: ["dataset"],
|
76 |
+
data: function () {
|
77 |
+
return {
|
78 |
+
output: "..."
|
79 |
+
};
|
80 |
+
},
|
81 |
+
mounted() {
|
82 |
+
this.output = this.fetchData();
|
83 |
+
// Remove spinner class
|
84 |
+
this.$nextTick(function () {
|
85 |
+
this.removeClass(this.$el.offsetParent);
|
86 |
+
});
|
87 |
+
},
|
88 |
+
methods: {
|
89 |
+
fetchData() {
|
90 |
+
return window.wpUlikeAjaxDataset[this.dataset];
|
91 |
+
},
|
92 |
+
removeClass(element) {
|
93 |
+
element.classList.remove("wp-ulike-is-loading");
|
94 |
+
}
|
95 |
+
}
|
96 |
+
});
|
97 |
+
// Get charts object component
|
98 |
+
Vue.component("get-chart", {
|
99 |
+
props: ["dataset", "identify", "type"],
|
100 |
+
mounted() {
|
101 |
+
if (this.type == "line") {
|
102 |
+
this.planetChartData = this.fetchData();
|
103 |
+
this.createLineChart(this.planetChartData);
|
104 |
+
} else {
|
105 |
+
this.createPieChart();
|
106 |
+
}
|
107 |
+
// Remove spinner class
|
108 |
+
this.$nextTick(function () {
|
109 |
+
this.removeClass(this.$el.offsetParent);
|
110 |
+
});
|
111 |
+
},
|
112 |
+
methods: {
|
113 |
+
fetchData() {
|
114 |
+
return window.wpUlikeAjaxDataset[this.dataset];
|
115 |
+
},
|
116 |
+
createLineChart(chartData) {
|
117 |
+
// Push data stats in dataset options
|
118 |
+
chartData.options["data"] = chartData.data;
|
119 |
+
// And finally draw it
|
120 |
+
this.drawChart({
|
121 |
+
// The type of chart we want to create
|
122 |
+
type: "line",
|
123 |
+
// The data for our dataset
|
124 |
+
data: {
|
125 |
+
labels: chartData.label,
|
126 |
+
datasets: [chartData.options]
|
127 |
+
}
|
128 |
+
});
|
129 |
+
// Set info for this canvas
|
130 |
+
this.setInfo(chartData);
|
131 |
+
},
|
132 |
+
createPieChart() {
|
133 |
+
// Define stack variables
|
134 |
+
var pieData = [],
|
135 |
+
pieBackground = [],
|
136 |
+
pieLabels = [];
|
137 |
+
// Get the info of each chart
|
138 |
+
window.wpUlikechartsInfo.forEach(function (value, key) {
|
139 |
+
pieData.push(value.sum);
|
140 |
+
pieBackground.push(value.background);
|
141 |
+
pieLabels.push(value.label);
|
142 |
+
});
|
143 |
+
// And finally draw it
|
144 |
+
this.drawChart({
|
145 |
+
// The type of chart we want to create
|
146 |
+
type: "pie",
|
147 |
+
// The data for our dataset
|
148 |
+
data: {
|
149 |
+
datasets: [
|
150 |
+
{
|
151 |
+
data: pieData,
|
152 |
+
backgroundColor: pieBackground
|
153 |
+
}
|
154 |
+
],
|
155 |
+
// These labels appear in the legend and in the tooltips when hovering different arcs
|
156 |
+
labels: pieLabels
|
157 |
+
}
|
158 |
+
});
|
159 |
+
},
|
160 |
+
drawChart(chartArgs) {
|
161 |
+
// Get canvas element
|
162 |
+
const ctx = document.getElementById(this.identify);
|
163 |
+
// Draw Chart
|
164 |
+
const chart = new Chart(ctx, chartArgs);
|
165 |
+
},
|
166 |
+
setInfo(chartData) {
|
167 |
+
var sumStack = 0;
|
168 |
+
// Get the sum of total likes
|
169 |
+
chartData.data.forEach(function (num) {
|
170 |
+
sumStack += parseFloat(num) || 0;
|
171 |
+
});
|
172 |
+
// Upgrade wpUlikechartsInfo array
|
173 |
+
window.wpUlikechartsInfo.push({
|
174 |
+
type: this.identify,
|
175 |
+
sum: sumStack,
|
176 |
+
label: chartData.options.label,
|
177 |
+
background: chartData.options.backgroundColor
|
178 |
+
});
|
179 |
+
},
|
180 |
+
removeClass(element) {
|
181 |
+
element.classList.remove("wp-ulike-is-loading");
|
182 |
+
}
|
183 |
+
}
|
184 |
+
});
|
185 |
+
|
186 |
+
new Vue({
|
187 |
+
el: "#wp-ulike-stats-app"
|
188 |
+
});
|
189 |
+
}
|
190 |
+
|
191 |
+
// on document ready
|
192 |
+
$(function () {
|
193 |
+
$(".wp-ulike-match-height").matchHeight();
|
194 |
+
});
|
195 |
+
})(jQuery);
|
admin/classes/class-wp-ulike-admin-assets.php
CHANGED
@@ -98,6 +98,15 @@ if ( ! class_exists( 'wp_ulike_admin_assets' ) ) {
|
|
98 |
true
|
99 |
);
|
100 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
101 |
// Localize scripts
|
102 |
wp_localize_script( 'wp_ulike_admin_scripts', 'wp_ulike_admin', array(
|
103 |
'hook_address' => esc_html( $this->hook ),
|
98 |
true
|
99 |
);
|
100 |
|
101 |
+
// Enqueue statistics script
|
102 |
+
wp_enqueue_script(
|
103 |
+
'wp_ulike_admin_statistics_scripts',
|
104 |
+
WP_ULIKE_ADMIN_URL . '/assets/js/solo/statistics.js',
|
105 |
+
array( 'wp_ulike_admin_scripts'),
|
106 |
+
false,
|
107 |
+
true
|
108 |
+
);
|
109 |
+
|
110 |
// Localize scripts
|
111 |
wp_localize_script( 'wp_ulike_admin_scripts', 'wp_ulike_admin', array(
|
112 |
'hook_address' => esc_html( $this->hook ),
|
admin/classes/class-wp-ulike-admin-pages.php
CHANGED
@@ -30,7 +30,7 @@ if ( ! class_exists( 'wp_ulike_admin_pages' ) ) {
|
|
30 |
'title' => __( 'Post Likes Logs', WP_ULIKE_SLUG ),
|
31 |
'parent_slug' => NULL,
|
32 |
'capability' => wp_ulike_get_user_access_capability('logs'),
|
33 |
-
'path' => '/includes/templates/posts-logs.php',
|
34 |
'menu_slug' => 'wp-ulike-posts-logs',
|
35 |
'load_screen' => true
|
36 |
),
|
@@ -38,7 +38,7 @@ if ( ! class_exists( 'wp_ulike_admin_pages' ) ) {
|
|
38 |
'title' => __( 'Comment Likes Logs', WP_ULIKE_SLUG ),
|
39 |
'parent_slug' => NULL,
|
40 |
'capability' => wp_ulike_get_user_access_capability('logs'),
|
41 |
-
'path' => '/includes/templates/comments-logs.php',
|
42 |
'menu_slug' => 'wp-ulike-comments-logs',
|
43 |
'load_screen' => true
|
44 |
),
|
@@ -46,7 +46,7 @@ if ( ! class_exists( 'wp_ulike_admin_pages' ) ) {
|
|
46 |
'title' => __( 'Activity Likes Logs', WP_ULIKE_SLUG ),
|
47 |
'parent_slug' => NULL,
|
48 |
'capability' => wp_ulike_get_user_access_capability('logs'),
|
49 |
-
'path' => '/includes/templates/activities-logs.php',
|
50 |
'menu_slug' => 'wp-ulike-activities-logs',
|
51 |
'load_screen' => true
|
52 |
),
|
@@ -54,7 +54,7 @@ if ( ! class_exists( 'wp_ulike_admin_pages' ) ) {
|
|
54 |
'title' => __( 'Topics Likes Logs', WP_ULIKE_SLUG ),
|
55 |
'parent_slug' => NULL,
|
56 |
'capability' => wp_ulike_get_user_access_capability('logs'),
|
57 |
-
'path' => '/includes/templates/topics-logs.php',
|
58 |
'menu_slug' => 'wp-ulike-topics-logs',
|
59 |
'load_screen' => true
|
60 |
),
|
@@ -62,7 +62,7 @@ if ( ! class_exists( 'wp_ulike_admin_pages' ) ) {
|
|
62 |
'title' => __( 'Statistics', WP_ULIKE_SLUG ),
|
63 |
'parent_slug' => 'wp-ulike-settings',
|
64 |
'capability' => wp_ulike_get_user_access_capability('stats'),
|
65 |
-
'path' => '/includes/templates/statistics.php',
|
66 |
'menu_slug' => 'wp-ulike-statistics',
|
67 |
'load_screen' => false
|
68 |
),
|
@@ -70,7 +70,7 @@ if ( ! class_exists( 'wp_ulike_admin_pages' ) ) {
|
|
70 |
'title' => __( 'About', WP_ULIKE_SLUG ),
|
71 |
'parent_slug' => 'wp-ulike-settings',
|
72 |
'capability' => wp_ulike_get_user_access_capability('stats'),
|
73 |
-
'path' => '/includes/templates/about.php',
|
74 |
'menu_slug' => 'wp-ulike-about',
|
75 |
'load_screen' => false
|
76 |
)
|
@@ -143,7 +143,7 @@ if ( ! class_exists( 'wp_ulike_admin_pages' ) ) {
|
|
143 |
* @return void
|
144 |
*/
|
145 |
public function load_template(){
|
146 |
-
load_template(
|
147 |
}
|
148 |
|
149 |
}
|
30 |
'title' => __( 'Post Likes Logs', WP_ULIKE_SLUG ),
|
31 |
'parent_slug' => NULL,
|
32 |
'capability' => wp_ulike_get_user_access_capability('logs'),
|
33 |
+
'path' => WP_ULIKE_ADMIN_DIR . '/includes/templates/posts-logs.php',
|
34 |
'menu_slug' => 'wp-ulike-posts-logs',
|
35 |
'load_screen' => true
|
36 |
),
|
38 |
'title' => __( 'Comment Likes Logs', WP_ULIKE_SLUG ),
|
39 |
'parent_slug' => NULL,
|
40 |
'capability' => wp_ulike_get_user_access_capability('logs'),
|
41 |
+
'path' => WP_ULIKE_ADMIN_DIR . '/includes/templates/comments-logs.php',
|
42 |
'menu_slug' => 'wp-ulike-comments-logs',
|
43 |
'load_screen' => true
|
44 |
),
|
46 |
'title' => __( 'Activity Likes Logs', WP_ULIKE_SLUG ),
|
47 |
'parent_slug' => NULL,
|
48 |
'capability' => wp_ulike_get_user_access_capability('logs'),
|
49 |
+
'path' => WP_ULIKE_ADMIN_DIR . '/includes/templates/activities-logs.php',
|
50 |
'menu_slug' => 'wp-ulike-activities-logs',
|
51 |
'load_screen' => true
|
52 |
),
|
54 |
'title' => __( 'Topics Likes Logs', WP_ULIKE_SLUG ),
|
55 |
'parent_slug' => NULL,
|
56 |
'capability' => wp_ulike_get_user_access_capability('logs'),
|
57 |
+
'path' => WP_ULIKE_ADMIN_DIR . '/includes/templates/topics-logs.php',
|
58 |
'menu_slug' => 'wp-ulike-topics-logs',
|
59 |
'load_screen' => true
|
60 |
),
|
62 |
'title' => __( 'Statistics', WP_ULIKE_SLUG ),
|
63 |
'parent_slug' => 'wp-ulike-settings',
|
64 |
'capability' => wp_ulike_get_user_access_capability('stats'),
|
65 |
+
'path' => WP_ULIKE_ADMIN_DIR . '/includes/templates/statistics.php',
|
66 |
'menu_slug' => 'wp-ulike-statistics',
|
67 |
'load_screen' => false
|
68 |
),
|
70 |
'title' => __( 'About', WP_ULIKE_SLUG ),
|
71 |
'parent_slug' => 'wp-ulike-settings',
|
72 |
'capability' => wp_ulike_get_user_access_capability('stats'),
|
73 |
+
'path' => WP_ULIKE_ADMIN_DIR . '/includes/templates/about.php',
|
74 |
'menu_slug' => 'wp-ulike-about',
|
75 |
'load_screen' => false
|
76 |
)
|
143 |
* @return void
|
144 |
*/
|
145 |
public function load_template(){
|
146 |
+
load_template( $this->views[ current_filter() ] );
|
147 |
}
|
148 |
|
149 |
}
|
admin/classes/class-wp-ulike-widget.php
CHANGED
@@ -57,6 +57,11 @@ if ( ! class_exists( 'wp_ulike_widget' ) ) {
|
|
57 |
|
58 |
$posts = wp_ulike_get_most_liked_posts( $numberOf, '', '', $period );
|
59 |
|
|
|
|
|
|
|
|
|
|
|
60 |
foreach ($posts as $post) {
|
61 |
$post_title = stripslashes($post->post_title);
|
62 |
$permalink = get_permalink($post->ID);
|
@@ -100,7 +105,13 @@ if ( ! class_exists( 'wp_ulike_widget' ) ) {
|
|
100 |
// Extract settings
|
101 |
extract($settings);
|
102 |
|
103 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
104 |
foreach ($comments as $comment) {
|
105 |
$comment_author = stripslashes($comment->comment_author);
|
106 |
$post_permalink = get_permalink($comment->comment_post_ID);
|
@@ -212,6 +223,12 @@ if ( ! class_exists( 'wp_ulike_widget' ) ) {
|
|
212 |
extract($settings);
|
213 |
|
214 |
$posts = wp_ulike_get_most_liked_posts( $numberOf, array( 'topic', 'reply' ), 'topic', $period );
|
|
|
|
|
|
|
|
|
|
|
|
|
215 |
foreach ($posts as $post) {
|
216 |
$post_title = function_exists('bbp_get_forum_title') ? bbp_get_forum_title( $post->ID ) : $post->post_title;
|
217 |
$permalink = get_permalink( $post->ID );
|
@@ -264,6 +281,12 @@ if ( ! class_exists( 'wp_ulike_widget' ) ) {
|
|
264 |
}
|
265 |
|
266 |
$activities = wp_ulike_get_most_liked_activities( $numberOf, $period );
|
|
|
|
|
|
|
|
|
|
|
|
|
267 |
foreach ($activities as $activity) {
|
268 |
$activity_permalink = function_exists('bp_activity_get_permalink') ? bp_activity_get_permalink( $activity->id ) : '';
|
269 |
$activity_action = ! empty( $activity->content ) ? $activity->content : $activity->action;
|
57 |
|
58 |
$posts = wp_ulike_get_most_liked_posts( $numberOf, '', '', $period );
|
59 |
|
60 |
+
if( empty( $posts ) ){
|
61 |
+
$period_info = is_array( $period ) ? implode( ' - ', $period ) : $period;
|
62 |
+
return sprintf( '<li>%s "%s" %s</li>', __( 'No results were found in', WP_ULIKE_SLUG ), $period_info, __( 'period', WP_ULIKE_SLUG ) );
|
63 |
+
}
|
64 |
+
|
65 |
foreach ($posts as $post) {
|
66 |
$post_title = stripslashes($post->post_title);
|
67 |
$permalink = get_permalink($post->ID);
|
105 |
// Extract settings
|
106 |
extract($settings);
|
107 |
|
108 |
+
$comments = wp_ulike_get_most_liked_comments( $numberOf, '', $period );
|
109 |
+
|
110 |
+
if( empty( $comments ) ){
|
111 |
+
$period_info = is_array( $period ) ? implode( ' - ', $period ) : $period;
|
112 |
+
return sprintf( '<li>%s "%s" %s</li>', __( 'No results were found in', WP_ULIKE_SLUG ), $period_info, __( 'period', WP_ULIKE_SLUG ) );
|
113 |
+
}
|
114 |
+
|
115 |
foreach ($comments as $comment) {
|
116 |
$comment_author = stripslashes($comment->comment_author);
|
117 |
$post_permalink = get_permalink($comment->comment_post_ID);
|
223 |
extract($settings);
|
224 |
|
225 |
$posts = wp_ulike_get_most_liked_posts( $numberOf, array( 'topic', 'reply' ), 'topic', $period );
|
226 |
+
|
227 |
+
if( empty( $posts ) ){
|
228 |
+
$period_info = is_array( $period ) ? implode( ' - ', $period ) : $period;
|
229 |
+
return sprintf( '<li>%s "%s" %s</li>', __( 'No results were found in', WP_ULIKE_SLUG ), $period_info, __( 'period', WP_ULIKE_SLUG ) );
|
230 |
+
}
|
231 |
+
|
232 |
foreach ($posts as $post) {
|
233 |
$post_title = function_exists('bbp_get_forum_title') ? bbp_get_forum_title( $post->ID ) : $post->post_title;
|
234 |
$permalink = get_permalink( $post->ID );
|
281 |
}
|
282 |
|
283 |
$activities = wp_ulike_get_most_liked_activities( $numberOf, $period );
|
284 |
+
|
285 |
+
if( empty( $activities ) ){
|
286 |
+
$period_info = is_array( $period ) ? implode( ' - ', $period ) : $period;
|
287 |
+
return sprintf( '<li>%s "%s" %s</li>', __( 'No results were found in', WP_ULIKE_SLUG ), $period_info, __( 'period', WP_ULIKE_SLUG ) );
|
288 |
+
}
|
289 |
+
|
290 |
foreach ($activities as $activity) {
|
291 |
$activity_permalink = function_exists('bp_activity_get_permalink') ? bp_activity_get_permalink( $activity->id ) : '';
|
292 |
$activity_action = ! empty( $activity->content ) ? $activity->content : $activity->action;
|
assets/js/wp-ulike.js
CHANGED
@@ -280,13 +280,16 @@
|
|
280 |
// Set sibling general elements
|
281 |
this._setSbilingElement();
|
282 |
this._updateGeneralClassNames(response.data.status);
|
283 |
-
//
|
284 |
-
if
|
285 |
-
|
286 |
-
|
|
|
|
|
|
|
|
|
|
|
287 |
}
|
288 |
-
// Update button status
|
289 |
-
this._updateButton(response.data.btnText, response.data.status);
|
290 |
// Display Notifications
|
291 |
this._sendNotification(response.data.messageType, response.data.message);
|
292 |
// Refresh likers box on data update
|
280 |
// Set sibling general elements
|
281 |
this._setSbilingElement();
|
282 |
this._updateGeneralClassNames(response.data.status);
|
283 |
+
// If data exist
|
284 |
+
if( response.data.data !== null ){
|
285 |
+
// Update counter + check refresh likers box
|
286 |
+
if (response.data.status < 5) {
|
287 |
+
this.__updateCounter(response.data.data);
|
288 |
+
this._refreshTheLikers = true;
|
289 |
+
}
|
290 |
+
// Update button status
|
291 |
+
this._updateButton(response.data.btnText, response.data.status);
|
292 |
}
|
|
|
|
|
293 |
// Display Notifications
|
294 |
this._sendNotification(response.data.messageType, response.data.message);
|
295 |
// Refresh likers box on data update
|
assets/js/wp-ulike.min.js
CHANGED
@@ -1 +1 @@
|
|
1 |
-
!function(i){"use strict";var s="WordpressUlikeNotifications",n={messageType:"success",messageText:"Hello World!",messageElement:"wpulike-message",notifContainer:"wpulike-notification"};function t(e,t){this.element=e,this.$element=i(e),this.settings=i.extend({},n,t),this._defaults=n,this._name=s,this.init()}i.extend(t.prototype,{init:function(){this._message(),this._container(),this._append(),this._remove()},_message:function(){this.$messageElement=i("<div/>").addClass(this.settings.messageElement+" wpulike-"+this.settings.messageType).text(this.settings.messageText)},_container:function(){i("."+this.settings.notifContainer).length||this.$element.append(i("<div/>").addClass(this.settings.notifContainer)),this.$notifContainer=this.$element.find("."+this.settings.notifContainer)},_append:function(){this.$notifContainer.append(this.$messageElement).trigger("WordpressUlikeNotificationAppend")},_remove:function(){var e=this;this.$messageElement.click(function(){i(this).fadeOut(300,function(){i(this).remove(),i("."+e.settings.messageElement).length||e.$notifContainer.remove()}).trigger("WordpressUlikeRemoveNotification")}),setTimeout(function(){e.$messageElement.fadeOut(300,function(){i(this).remove(),i("."+e.settings.messageElement).length||e.$notifContainer.remove()}).trigger("WordpressUlikeRemoveNotification")},8e3)}}),i.fn[s]=function(e){return this.each(function(){new t(this,e)})}}(jQuery,window,document),function(n,e,i){"use strict";var l="WordpressUlike",t=(n(e),n(i)),a={ID:0,nonce:0,type:"",append:"",appendTimeout:2e3,displayLikers:!1,disablePophover:!0,factor:"",counterSelector:".count-box",generalSelector:".wp_ulike_general_class",buttonSelector:".wp_ulike_btn",likersSelector:".wp_ulike_likers_wrapper"},o={"ulike-id":"ID","ulike-nonce":"nonce","ulike-type":"type","ulike-append":"append","ulike-display-likers":"displayLikers","ulike-disable-pophover":"disablePophover","ulike-append-timeout":"appendTimeout","ulike-factor":"factor"};function s(e,t){for(var i in this.element=e,this.$element=n(e),this.settings=n.extend({},a,t),this._defaults=a,this._name=l,this._refreshTheLikers=!1,this.buttonElement=this.$element.find(this.settings.buttonSelector),this.generalElement=this.$element.find(this.settings.generalSelector),this.counterElement=this.generalElement.find(this.settings.counterSelector),o){var s=this.buttonElement.data(i);void 0!==s&&(this.settings[o[i]]=s)}this.init()}n.extend(s.prototype,{init:function(){this.buttonElement.click(this._initLike.bind(this)),this.buttonElement.one("mouseenter",this._updateLikers.bind(this))},_ajax:function(e,t){n.ajax({url:wp_ulike_params.ajax_url,type:"POST",cache:!1,dataType:"json",data:e}).done(t)},_initLike:function(e){e.stopPropagation(),this._maybeUpdateElements(e),this._updateSameButtons(),this.buttonElement.prop("disabled",!0),t.trigger("WordpressUlikeLoading",this.element),this.generalElement.addClass("wp_ulike_is_loading"),this._ajax({action:"wp_ulike_process",id:this.settings.ID,nonce:this.settings.nonce,factor:this.settings.factor,type:this.settings.type},function(e){this.generalElement.removeClass("wp_ulike_is_loading"),e.success?(this._updateMarkup(e),this._appendChild()):this._sendNotification("error",e.data),this.buttonElement.prop("disabled",!1),t.trigger("WordpressUlikeUpdated",this.element)}.bind(this))},_maybeUpdateElements:function(e){this.buttonElement=n(e.currentTarget),this.generalElement=this.buttonElement.closest(this.settings.generalSelector),this.counterElement=this.generalElement.find(this.settings.counterSelector),this.settings.factor=this.buttonElement.data("ulike-factor")},_appendChild:function(){if(""!==this.settings.append){var e=n(this.settings.append);this.buttonElement.append(e),this.settings.appendTimeout&&setTimeout(function(){e.detach()},this.settings.appendTimeout)}},_updateMarkup:function(e){this._setSbilingElement(),this._updateGeneralClassNames(e.data.status),e.data.status<5&&(this.__updateCounter(e.data.data),this._refreshTheLikers=!0),this._updateButton(e.data.btnText,e.data.status),this._sendNotification(e.data.messageType,e.data.message),this._refreshTheLikers&&this._updateLikers()},_updateGeneralClassNames:function(e){var t="wp_ulike_is_not_liked",i="wp_ulike_is_liked",s="wp_ulike_is_unliked",n="wp_ulike_click_is_disabled";switch(this.siblingElement.length&&this.siblingElement.removeClass(this._arrayToString([i,s])),e){case 1:this.generalElement.addClass(i).removeClass(t),this.generalElement.children().first().addClass(n);break;case 2:this.generalElement.addClass(s).removeClass(i);break;case 3:this.generalElement.addClass(i).removeClass(s);break;default:this.generalElement.children().first().addClass(n),this.siblingElement.length&&this.siblingElement.children().first().addClass(n)}},_arrayToString:function(e){return e.join(" ")},_setSbilingElement:function(){this.siblingElement=this.generalElement.siblings()},__updateCounter:function(e){"object"!=typeof e?this.counterElement.text(e):"down"===this.settings.factor?(this.counterElement.text(e.down),this.siblingElement.length&&this.siblingElement.find(this.settings.counterSelector).text(e.up)):(this.counterElement.text(e.up),this.siblingElement.length&&this.siblingElement.find(this.settings.counterSelector).text(e.down)),t.trigger("WordpressUlikeCounterUpdated",[this.buttonElement])},_updateLikers:function(){this.likersElement=this._getLikersElement(),!this.settings.displayLikers||this.likersElement.length&&!this._refreshTheLikers||(this.generalElement.addClass("wp_ulike_is_getting_likers_list"),this._ajax({action:"wp_ulike_get_likers",id:this.settings.ID,nonce:this.settings.nonce,type:this.settings.type,disablePophover:this.settings.disablePophover,refresh:this._refreshTheLikers?1:0},function(e){this.generalElement.removeClass("wp_ulike_is_getting_likers_list"),e.success&&(this.likersElement.length||(this.likersElement=n("<div>",{class:e.data.class}).appendTo(this.$element)),e.data.template?this.likersElement.show().html(e.data.template):this.likersElement.hide()),this._refreshTheLikers=!1}.bind(this)))},_updateSameButtons:function(){var e=void 0!==this.settings.factor?this.settings.factor:"";this.sameButtons=t.find(".wp_"+this.settings.type.toLowerCase()+e+"_"+this.settings.ID),1<this.sameButtons.length&&(this.buttonElement=this.sameButtons,this.generalElement=this.buttonElement.closest(this.settings.generalSelector),this.counterElement=this.generalElement.find(this.settings.counterSelector))},_getLikersElement:function(){return 1<this.generalElement.length?this.generalElement.next(this.settings.likersSelector):this.$element.find(this.settings.likersSelector)},_updateButton:function(e,t){this.buttonElement.hasClass("wp_ulike_put_image")?3!==t&&2!==t||(this.buttonElement.toggleClass("image-unlike"),this.siblingElement.length&&this.siblingElement.find(this.settings.buttonSelector).removeClass("image-unlike")):this.buttonElement.hasClass("wp_ulike_put_text")&&null!==e&&("object"!=typeof e?this.buttonElement.find("span").html(e):"down"===this.settings.factor?(this.buttonElement.find("span").html(e.down),this.siblingElement.length&&this.siblingElement.find(this.settings.buttonSelector).find("span").html(e.up)):(this.buttonElement.find("span").html(e.up),this.siblingElement.length&&this.siblingElement.find(this.settings.buttonSelector).find("span").html(e.down)))},_sendNotification:function(e,t){"1"===wp_ulike_params.notifications&&n(i.body).WordpressUlikeNotifications({messageType:e,messageText:t})}}),n.fn[l]=function(e){return this.each(function(){n.data(this,"plugin_"+l)||n.data(this,"plugin_"+l,new s(this,e))})}}(jQuery,window,document),function(t){t(function(){t(this).bind("DOMNodeInserted",function(e){t(".wpulike").WordpressUlike()})}),t(".wpulike").WordpressUlike()}(jQuery);
|
1 |
+
!function(i){"use strict";var s="WordpressUlikeNotifications",n={messageType:"success",messageText:"Hello World!",messageElement:"wpulike-message",notifContainer:"wpulike-notification"};function t(e,t){this.element=e,this.$element=i(e),this.settings=i.extend({},n,t),this._defaults=n,this._name=s,this.init()}i.extend(t.prototype,{init:function(){this._message(),this._container(),this._append(),this._remove()},_message:function(){this.$messageElement=i("<div/>").addClass(this.settings.messageElement+" wpulike-"+this.settings.messageType).text(this.settings.messageText)},_container:function(){i("."+this.settings.notifContainer).length||this.$element.append(i("<div/>").addClass(this.settings.notifContainer)),this.$notifContainer=this.$element.find("."+this.settings.notifContainer)},_append:function(){this.$notifContainer.append(this.$messageElement).trigger("WordpressUlikeNotificationAppend")},_remove:function(){var e=this;this.$messageElement.click(function(){i(this).fadeOut(300,function(){i(this).remove(),i("."+e.settings.messageElement).length||e.$notifContainer.remove()}).trigger("WordpressUlikeRemoveNotification")}),setTimeout(function(){e.$messageElement.fadeOut(300,function(){i(this).remove(),i("."+e.settings.messageElement).length||e.$notifContainer.remove()}).trigger("WordpressUlikeRemoveNotification")},8e3)}}),i.fn[s]=function(e){return this.each(function(){new t(this,e)})}}(jQuery,window,document),function(n,e,i){"use strict";var l="WordpressUlike",t=(n(e),n(i)),a={ID:0,nonce:0,type:"",append:"",appendTimeout:2e3,displayLikers:!1,disablePophover:!0,factor:"",counterSelector:".count-box",generalSelector:".wp_ulike_general_class",buttonSelector:".wp_ulike_btn",likersSelector:".wp_ulike_likers_wrapper"},o={"ulike-id":"ID","ulike-nonce":"nonce","ulike-type":"type","ulike-append":"append","ulike-display-likers":"displayLikers","ulike-disable-pophover":"disablePophover","ulike-append-timeout":"appendTimeout","ulike-factor":"factor"};function s(e,t){for(var i in this.element=e,this.$element=n(e),this.settings=n.extend({},a,t),this._defaults=a,this._name=l,this._refreshTheLikers=!1,this.buttonElement=this.$element.find(this.settings.buttonSelector),this.generalElement=this.$element.find(this.settings.generalSelector),this.counterElement=this.generalElement.find(this.settings.counterSelector),o){var s=this.buttonElement.data(i);void 0!==s&&(this.settings[o[i]]=s)}this.init()}n.extend(s.prototype,{init:function(){this.buttonElement.click(this._initLike.bind(this)),this.buttonElement.one("mouseenter",this._updateLikers.bind(this))},_ajax:function(e,t){n.ajax({url:wp_ulike_params.ajax_url,type:"POST",cache:!1,dataType:"json",data:e}).done(t)},_initLike:function(e){e.stopPropagation(),this._maybeUpdateElements(e),this._updateSameButtons(),this.buttonElement.prop("disabled",!0),t.trigger("WordpressUlikeLoading",this.element),this.generalElement.addClass("wp_ulike_is_loading"),this._ajax({action:"wp_ulike_process",id:this.settings.ID,nonce:this.settings.nonce,factor:this.settings.factor,type:this.settings.type},function(e){this.generalElement.removeClass("wp_ulike_is_loading"),e.success?(this._updateMarkup(e),this._appendChild()):this._sendNotification("error",e.data),this.buttonElement.prop("disabled",!1),t.trigger("WordpressUlikeUpdated",this.element)}.bind(this))},_maybeUpdateElements:function(e){this.buttonElement=n(e.currentTarget),this.generalElement=this.buttonElement.closest(this.settings.generalSelector),this.counterElement=this.generalElement.find(this.settings.counterSelector),this.settings.factor=this.buttonElement.data("ulike-factor")},_appendChild:function(){if(""!==this.settings.append){var e=n(this.settings.append);this.buttonElement.append(e),this.settings.appendTimeout&&setTimeout(function(){e.detach()},this.settings.appendTimeout)}},_updateMarkup:function(e){this._setSbilingElement(),this._updateGeneralClassNames(e.data.status),null!==e.data.data&&(e.data.status<5&&(this.__updateCounter(e.data.data),this._refreshTheLikers=!0),this._updateButton(e.data.btnText,e.data.status)),this._sendNotification(e.data.messageType,e.data.message),this._refreshTheLikers&&this._updateLikers()},_updateGeneralClassNames:function(e){var t="wp_ulike_is_not_liked",i="wp_ulike_is_liked",s="wp_ulike_is_unliked",n="wp_ulike_click_is_disabled";switch(this.siblingElement.length&&this.siblingElement.removeClass(this._arrayToString([i,s])),e){case 1:this.generalElement.addClass(i).removeClass(t),this.generalElement.children().first().addClass(n);break;case 2:this.generalElement.addClass(s).removeClass(i);break;case 3:this.generalElement.addClass(i).removeClass(s);break;default:this.generalElement.children().first().addClass(n),this.siblingElement.length&&this.siblingElement.children().first().addClass(n)}},_arrayToString:function(e){return e.join(" ")},_setSbilingElement:function(){this.siblingElement=this.generalElement.siblings()},__updateCounter:function(e){"object"!=typeof e?this.counterElement.text(e):"down"===this.settings.factor?(this.counterElement.text(e.down),this.siblingElement.length&&this.siblingElement.find(this.settings.counterSelector).text(e.up)):(this.counterElement.text(e.up),this.siblingElement.length&&this.siblingElement.find(this.settings.counterSelector).text(e.down)),t.trigger("WordpressUlikeCounterUpdated",[this.buttonElement])},_updateLikers:function(){this.likersElement=this._getLikersElement(),!this.settings.displayLikers||this.likersElement.length&&!this._refreshTheLikers||(this.generalElement.addClass("wp_ulike_is_getting_likers_list"),this._ajax({action:"wp_ulike_get_likers",id:this.settings.ID,nonce:this.settings.nonce,type:this.settings.type,disablePophover:this.settings.disablePophover,refresh:this._refreshTheLikers?1:0},function(e){this.generalElement.removeClass("wp_ulike_is_getting_likers_list"),e.success&&(this.likersElement.length||(this.likersElement=n("<div>",{class:e.data.class}).appendTo(this.$element)),e.data.template?this.likersElement.show().html(e.data.template):this.likersElement.hide()),this._refreshTheLikers=!1}.bind(this)))},_updateSameButtons:function(){var e=void 0!==this.settings.factor?this.settings.factor:"";this.sameButtons=t.find(".wp_"+this.settings.type.toLowerCase()+e+"_"+this.settings.ID),1<this.sameButtons.length&&(this.buttonElement=this.sameButtons,this.generalElement=this.buttonElement.closest(this.settings.generalSelector),this.counterElement=this.generalElement.find(this.settings.counterSelector))},_getLikersElement:function(){return 1<this.generalElement.length?this.generalElement.next(this.settings.likersSelector):this.$element.find(this.settings.likersSelector)},_updateButton:function(e,t){this.buttonElement.hasClass("wp_ulike_put_image")?3!==t&&2!==t||(this.buttonElement.toggleClass("image-unlike"),this.siblingElement.length&&this.siblingElement.find(this.settings.buttonSelector).removeClass("image-unlike")):this.buttonElement.hasClass("wp_ulike_put_text")&&null!==e&&("object"!=typeof e?this.buttonElement.find("span").html(e):"down"===this.settings.factor?(this.buttonElement.find("span").html(e.down),this.siblingElement.length&&this.siblingElement.find(this.settings.buttonSelector).find("span").html(e.up)):(this.buttonElement.find("span").html(e.up),this.siblingElement.length&&this.siblingElement.find(this.settings.buttonSelector).find("span").html(e.down)))},_sendNotification:function(e,t){"1"===wp_ulike_params.notifications&&n(i.body).WordpressUlikeNotifications({messageType:e,messageText:t})}}),n.fn[l]=function(e){return this.each(function(){n.data(this,"plugin_"+l)||n.data(this,"plugin_"+l,new s(this,e))})}}(jQuery,window,document),function(t){t(function(){t(this).bind("DOMNodeInserted",function(e){t(".wpulike").WordpressUlike()})}),t(".wpulike").WordpressUlike()}(jQuery);
|
inc/classes/class-wp-ulike-mycred.php
CHANGED
@@ -62,7 +62,7 @@ if ( class_exists( 'myCRED_Hook' ) ) :
|
|
62 |
* @since 2.3
|
63 |
*/
|
64 |
public function status( $id , $key, $user_id, $status ) {
|
65 |
-
$author_id = $this->get_author_ID( $key );
|
66 |
// Check status
|
67 |
if( ! in_array( $status, array( 'like', 'unlike' ) ) ){
|
68 |
return;
|
@@ -193,7 +193,7 @@ if ( class_exists( 'myCRED_Hook' ) ) :
|
|
193 |
* @param string $key
|
194 |
* @return integer
|
195 |
*/
|
196 |
-
protected function get_author_ID( $key ){
|
197 |
// Default value
|
198 |
$author_id = 0;
|
199 |
// Get author ID by it's type
|
62 |
* @since 2.3
|
63 |
*/
|
64 |
public function status( $id , $key, $user_id, $status ) {
|
65 |
+
$author_id = $this->get_author_ID( $id, $key );
|
66 |
// Check status
|
67 |
if( ! in_array( $status, array( 'like', 'unlike' ) ) ){
|
68 |
return;
|
193 |
* @param string $key
|
194 |
* @return integer
|
195 |
*/
|
196 |
+
protected function get_author_ID( $id, $key ){
|
197 |
// Default value
|
198 |
$author_id = 0;
|
199 |
// Get author ID by it's type
|
inc/classes/class-wp-ulike.php
CHANGED
@@ -413,7 +413,7 @@ if ( ! class_exists( 'wp_ulike' ) ) {
|
|
413 |
"type" => esc_attr( $args['method'] ),
|
414 |
"status" => esc_attr( $status ),
|
415 |
"user_status" => esc_attr( $user_status ),
|
416 |
-
"attributes" =>
|
417 |
"style" => esc_html( $args['style'] ),
|
418 |
"button_type" => esc_html( $args['button_type'] ),
|
419 |
"display_likers" => esc_attr( $args['display_likers'] ),
|
413 |
"type" => esc_attr( $args['method'] ),
|
414 |
"status" => esc_attr( $status ),
|
415 |
"user_status" => esc_attr( $user_status ),
|
416 |
+
"attributes" => $args['attributes'],
|
417 |
"style" => esc_html( $args['style'] ),
|
418 |
"button_type" => esc_html( $args['button_type'] ),
|
419 |
"display_likers" => esc_attr( $args['display_likers'] ),
|
inc/frontend-ajax.php
CHANGED
@@ -27,6 +27,7 @@ function wp_ulike_process(){
|
|
27 |
$nonce_token = isset( $_POST['nonce'] ) ? $_POST['nonce'] : NULL;
|
28 |
$factor = isset( $_POST['factor'] ) ? $_POST['factor'] : NULL;
|
29 |
$response = array();
|
|
|
30 |
|
31 |
if( $post_ID == null || ( ! wp_verify_nonce( $nonce_token, $post_type . $post_ID ) && wp_ulike_is_cache_exist() ) ) {
|
32 |
wp_send_json_error( __( 'Error: Something Wrong Happened!', WP_ULIKE_SLUG ) );
|
@@ -57,9 +58,7 @@ function wp_ulike_process(){
|
|
57 |
), $post_ID, $get_settings
|
58 |
);
|
59 |
|
60 |
-
|
61 |
-
|
62 |
-
if( $only_registered_users === '0' || ( $only_registered_users === '1' && is_user_logged_in() ) ) {
|
63 |
$response = array(
|
64 |
'message' => wp_ulike_get_setting( 'wp_ulike_general', 'login_text', __( 'You Should Login To Submit Your Like', WP_ULIKE_SLUG ) ),
|
65 |
'btnText' => NULL,
|
27 |
$nonce_token = isset( $_POST['nonce'] ) ? $_POST['nonce'] : NULL;
|
28 |
$factor = isset( $_POST['factor'] ) ? $_POST['factor'] : NULL;
|
29 |
$response = array();
|
30 |
+
$status = 0;
|
31 |
|
32 |
if( $post_ID == null || ( ! wp_verify_nonce( $nonce_token, $post_type . $post_ID ) && wp_ulike_is_cache_exist() ) ) {
|
33 |
wp_send_json_error( __( 'Error: Something Wrong Happened!', WP_ULIKE_SLUG ) );
|
58 |
), $post_ID, $get_settings
|
59 |
);
|
60 |
|
61 |
+
if( wp_ulike_is_true( wp_ulike_get_setting( $setting, 'only_registered_users' ) ) && ! is_user_logged_in() ) {
|
|
|
|
|
62 |
$response = array(
|
63 |
'message' => wp_ulike_get_setting( 'wp_ulike_general', 'login_text', __( 'You Should Login To Submit Your Like', WP_ULIKE_SLUG ) ),
|
64 |
'btnText' => NULL,
|
inc/general-functions.php
CHANGED
@@ -275,6 +275,13 @@ if( ! function_exists( 'wp_ulike_get_options_info' ) ){
|
|
275 |
'checkboxlabel' => __('Activate', WP_ULIKE_SLUG),
|
276 |
'description' => __('Anonymize the IP address for GDPR Compliance', WP_ULIKE_SLUG)
|
277 |
),
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
278 |
'like_notice' => array(
|
279 |
'default' => __('Thanks! You Liked This.',WP_ULIKE_SLUG),
|
280 |
'label' => __( 'Liked Notice Message', WP_ULIKE_SLUG)
|
@@ -292,10 +299,11 @@ if( ! function_exists( 'wp_ulike_get_options_info' ) ){
|
|
292 |
'title' => '<i class="dashicons-before dashicons-admin-post"></i>' . ' ' . __( 'Posts',WP_ULIKE_SLUG),
|
293 |
'fields' => array(
|
294 |
'theme' => array(
|
295 |
-
'type'
|
296 |
-
'default'
|
297 |
-
'label'
|
298 |
-
'options'
|
|
|
299 |
),
|
300 |
'auto_display' => array(
|
301 |
'type' => 'checkbox',
|
@@ -405,10 +413,11 @@ if( ! function_exists( 'wp_ulike_get_options_info' ) ){
|
|
405 |
'title' => '<i class="dashicons-before dashicons-admin-comments"></i>' . ' ' . __( 'Comments',WP_ULIKE_SLUG),
|
406 |
'fields' => array(
|
407 |
'theme' => array(
|
408 |
-
'type'
|
409 |
-
'default'
|
410 |
-
'label'
|
411 |
-
'options'
|
|
|
412 |
),
|
413 |
'auto_display' => array(
|
414 |
'type' => 'checkbox',
|
@@ -496,10 +505,11 @@ if( ! function_exists( 'wp_ulike_get_options_info' ) ){
|
|
496 |
'title' => '<i class="dashicons-before dashicons-buddypress"></i>' . ' ' . __( 'BuddyPress',WP_ULIKE_SLUG),
|
497 |
'fields' => array(
|
498 |
'theme' => array(
|
499 |
-
'type'
|
500 |
-
'default'
|
501 |
-
'label'
|
502 |
-
'options'
|
|
|
503 |
),
|
504 |
'auto_display' => array(
|
505 |
'type' => 'checkbox',
|
@@ -532,7 +542,7 @@ if( ! function_exists( 'wp_ulike_get_options_info' ) ){
|
|
532 |
),
|
533 |
'logging_method' => array(
|
534 |
'type' => 'select',
|
535 |
-
'default' => '
|
536 |
'label' => __( 'Logging Method',WP_ULIKE_SLUG),
|
537 |
'options' => array(
|
538 |
'do_not_log' => __('Do Not Log', WP_ULIKE_SLUG),
|
@@ -619,10 +629,11 @@ if( ! function_exists( 'wp_ulike_get_options_info' ) ){
|
|
619 |
'title' => '<i class="dashicons-before dashicons-bbpress"></i>' . ' ' . __( 'bbPress',WP_ULIKE_SLUG),
|
620 |
'fields' => array(
|
621 |
'theme' => array(
|
622 |
-
'type'
|
623 |
-
'default'
|
624 |
-
'label'
|
625 |
-
'options'
|
|
|
626 |
),
|
627 |
'auto_display' => array(
|
628 |
'type' => 'checkbox',
|
@@ -648,7 +659,7 @@ if( ! function_exists( 'wp_ulike_get_options_info' ) ){
|
|
648 |
),
|
649 |
'logging_method' => array(
|
650 |
'type' => 'select',
|
651 |
-
'default' => '
|
652 |
'label' => __( 'Logging Method',WP_ULIKE_SLUG),
|
653 |
'options' => array(
|
654 |
'do_not_log' => __('Do Not Log', WP_ULIKE_SLUG),
|
@@ -1536,25 +1547,32 @@ if( ! function_exists( 'wp_ulike_get_popular_items_info' ) ){
|
|
1536 |
$info_args = wp_ulike_get_table_info( $parsed_args['type'] );
|
1537 |
$period_limit = '';
|
1538 |
|
1539 |
-
|
1540 |
-
|
1541 |
-
$period_limit =
|
1542 |
-
|
1543 |
-
|
1544 |
-
|
1545 |
-
|
1546 |
-
|
1547 |
-
|
1548 |
-
|
1549 |
-
|
1550 |
-
|
1551 |
-
|
1552 |
-
|
1553 |
-
|
1554 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1555 |
}
|
1556 |
|
1557 |
-
|
1558 |
$status_type = '';
|
1559 |
if( is_array( $parsed_args['status'] ) ){
|
1560 |
$status_type = sprintf( "`status` IN ('%s')", implode ("','", $parsed_args['status'] ) );
|
@@ -1761,7 +1779,7 @@ if( ! function_exists( 'wp_ulike_display_button' ) ){
|
|
1761 |
function wp_ulike_display_button( array $parsed_args, $only_registered_users ){
|
1762 |
global $wp_ulike_class;
|
1763 |
|
1764 |
-
if(
|
1765 |
// Return ulike template
|
1766 |
return $wp_ulike_class->wp_get_ulike( $parsed_args );
|
1767 |
} else {
|
275 |
'checkboxlabel' => __('Activate', WP_ULIKE_SLUG),
|
276 |
'description' => __('Anonymize the IP address for GDPR Compliance', WP_ULIKE_SLUG)
|
277 |
),
|
278 |
+
'hide_admin_notice' => array(
|
279 |
+
'type' => 'checkbox',
|
280 |
+
'default' => 0,
|
281 |
+
'label' => __('Hide Admin Notices', WP_ULIKE_SLUG),
|
282 |
+
'checkboxlabel' => __('Activate', WP_ULIKE_SLUG),
|
283 |
+
'description' => __('Enabling this option will completely disable all admin notices.', WP_ULIKE_SLUG)
|
284 |
+
),
|
285 |
'like_notice' => array(
|
286 |
'default' => __('Thanks! You Liked This.',WP_ULIKE_SLUG),
|
287 |
'label' => __( 'Liked Notice Message', WP_ULIKE_SLUG)
|
299 |
'title' => '<i class="dashicons-before dashicons-admin-post"></i>' . ' ' . __( 'Posts',WP_ULIKE_SLUG),
|
300 |
'fields' => array(
|
301 |
'theme' => array(
|
302 |
+
'type' => 'visual-select',
|
303 |
+
'default' => 'wpulike-default',
|
304 |
+
'label' => __( 'Themes',WP_ULIKE_SLUG),
|
305 |
+
'options' => call_user_func('wp_ulike_generate_templates_list'),
|
306 |
+
'description' => sprintf( '%s <a target="_blank" href="%s" title="Click">%s</a>', __( 'Display online preview',WP_ULIKE_SLUG), WP_ULIKE_PLUGIN_URI . 'templates/?utm_source=settings-page&utm_campaign=plugin-uri&utm_medium=wp-dash',__( 'Here',WP_ULIKE_SLUG) )
|
307 |
),
|
308 |
'auto_display' => array(
|
309 |
'type' => 'checkbox',
|
413 |
'title' => '<i class="dashicons-before dashicons-admin-comments"></i>' . ' ' . __( 'Comments',WP_ULIKE_SLUG),
|
414 |
'fields' => array(
|
415 |
'theme' => array(
|
416 |
+
'type' => 'visual-select',
|
417 |
+
'default' => 'wpulike-heart',
|
418 |
+
'label' => __( 'Themes',WP_ULIKE_SLUG),
|
419 |
+
'options' => call_user_func('wp_ulike_generate_templates_list'),
|
420 |
+
'description' => sprintf( '%s <a target="_blank" href="%s" title="Click">%s</a>', __( 'Display online preview',WP_ULIKE_SLUG), WP_ULIKE_PLUGIN_URI . 'templates/?utm_source=settings-page&utm_campaign=plugin-uri&utm_medium=wp-dash',__( 'Here',WP_ULIKE_SLUG) )
|
421 |
),
|
422 |
'auto_display' => array(
|
423 |
'type' => 'checkbox',
|
505 |
'title' => '<i class="dashicons-before dashicons-buddypress"></i>' . ' ' . __( 'BuddyPress',WP_ULIKE_SLUG),
|
506 |
'fields' => array(
|
507 |
'theme' => array(
|
508 |
+
'type' => 'visual-select',
|
509 |
+
'default' => 'wpulike-robeen',
|
510 |
+
'label' => __( 'Themes',WP_ULIKE_SLUG),
|
511 |
+
'options' => call_user_func('wp_ulike_generate_templates_list'),
|
512 |
+
'description' => sprintf( '%s <a target="_blank" href="%s" title="Click">%s</a>', __( 'Display online preview',WP_ULIKE_SLUG), WP_ULIKE_PLUGIN_URI . 'templates/?utm_source=settings-page&utm_campaign=plugin-uri&utm_medium=wp-dash',__( 'Here',WP_ULIKE_SLUG) )
|
513 |
),
|
514 |
'auto_display' => array(
|
515 |
'type' => 'checkbox',
|
542 |
),
|
543 |
'logging_method' => array(
|
544 |
'type' => 'select',
|
545 |
+
'default' => 'by_username',
|
546 |
'label' => __( 'Logging Method',WP_ULIKE_SLUG),
|
547 |
'options' => array(
|
548 |
'do_not_log' => __('Do Not Log', WP_ULIKE_SLUG),
|
629 |
'title' => '<i class="dashicons-before dashicons-bbpress"></i>' . ' ' . __( 'bbPress',WP_ULIKE_SLUG),
|
630 |
'fields' => array(
|
631 |
'theme' => array(
|
632 |
+
'type' => 'visual-select',
|
633 |
+
'default' => 'wpulike-default',
|
634 |
+
'label' => __( 'Themes',WP_ULIKE_SLUG),
|
635 |
+
'options' => call_user_func('wp_ulike_generate_templates_list'),
|
636 |
+
'description' => sprintf( '%s <a target="_blank" href="%s" title="Click">%s</a>', __( 'Display online preview',WP_ULIKE_SLUG), WP_ULIKE_PLUGIN_URI . 'templates/?utm_source=settings-page&utm_campaign=plugin-uri&utm_medium=wp-dash',__( 'Here',WP_ULIKE_SLUG) )
|
637 |
),
|
638 |
'auto_display' => array(
|
639 |
'type' => 'checkbox',
|
659 |
),
|
660 |
'logging_method' => array(
|
661 |
'type' => 'select',
|
662 |
+
'default' => 'by_username',
|
663 |
'label' => __( 'Logging Method',WP_ULIKE_SLUG),
|
664 |
'options' => array(
|
665 |
'do_not_log' => __('Do Not Log', WP_ULIKE_SLUG),
|
1547 |
$info_args = wp_ulike_get_table_info( $parsed_args['type'] );
|
1548 |
$period_limit = '';
|
1549 |
|
1550 |
+
if( is_array( $parsed_args['period'] ) && isset( $parsed_args['period']['start'] ) ){
|
1551 |
+
if( $parsed_args['period']['start'] === $parsed_args['period']['end'] ){
|
1552 |
+
$period_limit = sprintf( 'AND DATE(`date_time`) = \'%s\'', $parsed_args['period']['start'] );
|
1553 |
+
} else {
|
1554 |
+
$period_limit = sprintf( 'AND DATE(`date_time`) >= \'%s\' AND DATE(`date_time`) <= \'%s\'', $parsed_args['period']['start'], $parsed_args['period']['end'] );
|
1555 |
+
}
|
1556 |
+
} else {
|
1557 |
+
switch ($parsed_args['period']) {
|
1558 |
+
case "today":
|
1559 |
+
$period_limit = "AND DATE(date_time) = DATE(NOW())";
|
1560 |
+
break;
|
1561 |
+
case "yesterday":
|
1562 |
+
$period_limit = "AND DATE(date_time) = DATE(subdate(current_date, 1))";
|
1563 |
+
break;
|
1564 |
+
case "week":
|
1565 |
+
$period_limit = "AND week(DATE(date_time)) = week(DATE(NOW()))";
|
1566 |
+
break;
|
1567 |
+
case "month":
|
1568 |
+
$period_limit = "AND month(DATE(date_time)) = month(DATE(NOW()))";
|
1569 |
+
break;
|
1570 |
+
case "year":
|
1571 |
+
$period_limit = "AND year(DATE(date_time)) = year(DATE(NOW()))";
|
1572 |
+
break;
|
1573 |
+
}
|
1574 |
}
|
1575 |
|
|
|
1576 |
$status_type = '';
|
1577 |
if( is_array( $parsed_args['status'] ) ){
|
1578 |
$status_type = sprintf( "`status` IN ('%s')", implode ("','", $parsed_args['status'] ) );
|
1779 |
function wp_ulike_display_button( array $parsed_args, $only_registered_users ){
|
1780 |
global $wp_ulike_class;
|
1781 |
|
1782 |
+
if( ! wp_ulike_is_true( $only_registered_users ) || is_user_logged_in() ) {
|
1783 |
// Return ulike template
|
1784 |
return $wp_ulike_class->wp_get_ulike( $parsed_args );
|
1785 |
} else {
|
readme.txt
CHANGED
@@ -5,8 +5,8 @@ Author: Ali Mirzaei
|
|
5 |
Tags: wp ulike, like button, elementor, like, dislike, wordpress youlike plugin, rating, vote, voting, most liked posts, wordpress like page, wordpress like post, wordpress vote page, wordpress vote post, wp like page, wp like post, wp like plugin, buddypress like system, buddypress votes, comment like system, voting button, wordpress, buddypress, statistics, stats likes, bbpress, bbPress like, WP-Translations, forums, community, credit, points, mycred, users, ultimate member, ranking
|
6 |
Requires PHP: 5.4
|
7 |
Requires at least: 3.5.0
|
8 |
-
Tested up to: 5.3
|
9 |
-
Stable tag: 4.0.
|
10 |
License: GPLv2 or later
|
11 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
12 |
|
@@ -188,6 +188,14 @@ define( 'WP_MEMORY_LIMIT', '256M' );
|
|
188 |
|
189 |
== Changelog ==
|
190 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
191 |
= 4.0.1 =
|
192 |
* Added: New myCred option for points to be awarded even when item authors Like/Unlike their own item.
|
193 |
* Fixed: Some important issues in myCred functionality.
|
5 |
Tags: wp ulike, like button, elementor, like, dislike, wordpress youlike plugin, rating, vote, voting, most liked posts, wordpress like page, wordpress like post, wordpress vote page, wordpress vote post, wp like page, wp like post, wp like plugin, buddypress like system, buddypress votes, comment like system, voting button, wordpress, buddypress, statistics, stats likes, bbpress, bbPress like, WP-Translations, forums, community, credit, points, mycred, users, ultimate member, ranking
|
6 |
Requires PHP: 5.4
|
7 |
Requires at least: 3.5.0
|
8 |
+
Tested up to: 5.3.1
|
9 |
+
Stable tag: 4.0.2
|
10 |
License: GPLv2 or later
|
11 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
12 |
|
188 |
|
189 |
== Changelog ==
|
190 |
|
191 |
+
= 4.0.2 =
|
192 |
+
* Added: An option to remove plugin admin notices.
|
193 |
+
* Added: Professional stats panel with date range + status selector options. [PRO]
|
194 |
+
* Added: A new template called "Feedback". [PRO]
|
195 |
+
* Fixed: A important issue with only logged in option.
|
196 |
+
* Fixed: Schema attributes escape issue.
|
197 |
+
* Fixed: Some small issues.
|
198 |
+
|
199 |
= 4.0.1 =
|
200 |
* Added: New myCred option for points to be awarded even when item authors Like/Unlike their own item.
|
201 |
* Fixed: Some important issues in myCred functionality.
|
wp-ulike.php
CHANGED
@@ -10,14 +10,14 @@
|
|
10 |
* Plugin Name: WP ULike
|
11 |
* Plugin URI: https://wpulike.com/?utm_source=wp-plugins&utm_campaign=plugin-uri&utm_medium=wp-dash
|
12 |
* Description: WP ULike plugin allows to integrate a beautiful Ajax Like Button into your wordPress website to allow your visitors to like and unlike pages, posts, comments AND buddypress activities. Its very simple to use and supports many options.
|
13 |
-
* Version: 4.0.
|
14 |
* Author: Ali Mirzaei
|
15 |
* Author URI: https://wpulike.com/?utm_source=wp-plugins&utm_campaign=author-uri&utm_medium=wp-dash
|
16 |
* Text Domain: wp-ulike
|
17 |
* License: GPL2
|
18 |
* License URI: https://www.gnu.org/licenses/gpl-2.0.html
|
19 |
* Domain Path: /lang
|
20 |
-
* Tested up to: 5.3
|
21 |
|
22 |
/------------------------------------------\
|
23 |
_ __ _ _____ _ _ _ _
|
@@ -46,7 +46,7 @@ if ( defined( 'WP_INSTALLING' ) && WP_INSTALLING ) {
|
|
46 |
|
47 |
// Do not change these values
|
48 |
define( 'WP_ULIKE_PLUGIN_URI' , 'https://wpulike.com/' );
|
49 |
-
define( 'WP_ULIKE_VERSION' , '4.0.
|
50 |
define( 'WP_ULIKE_SLUG' , 'wp-ulike' );
|
51 |
define( 'WP_ULIKE_NAME' , __( 'WP ULike', WP_ULIKE_SLUG ));
|
52 |
|
10 |
* Plugin Name: WP ULike
|
11 |
* Plugin URI: https://wpulike.com/?utm_source=wp-plugins&utm_campaign=plugin-uri&utm_medium=wp-dash
|
12 |
* Description: WP ULike plugin allows to integrate a beautiful Ajax Like Button into your wordPress website to allow your visitors to like and unlike pages, posts, comments AND buddypress activities. Its very simple to use and supports many options.
|
13 |
+
* Version: 4.0.2
|
14 |
* Author: Ali Mirzaei
|
15 |
* Author URI: https://wpulike.com/?utm_source=wp-plugins&utm_campaign=author-uri&utm_medium=wp-dash
|
16 |
* Text Domain: wp-ulike
|
17 |
* License: GPL2
|
18 |
* License URI: https://www.gnu.org/licenses/gpl-2.0.html
|
19 |
* Domain Path: /lang
|
20 |
+
* Tested up to: 5.3.1
|
21 |
|
22 |
/------------------------------------------\
|
23 |
_ __ _ _____ _ _ _ _
|
46 |
|
47 |
// Do not change these values
|
48 |
define( 'WP_ULIKE_PLUGIN_URI' , 'https://wpulike.com/' );
|
49 |
+
define( 'WP_ULIKE_VERSION' , '4.0.2' );
|
50 |
define( 'WP_ULIKE_SLUG' , 'wp-ulike' );
|
51 |
define( 'WP_ULIKE_NAME' , __( 'WP ULike', WP_ULIKE_SLUG ));
|
52 |
|