PluginProbe ʕ •ᴥ•ʔ
Shortcodes and extra features for Phlox theme / 2.9.21
Shortcodes and extra features for Phlox theme v2.9.21
2.17.21 2.17.20 trunk 1.0.0 1.0.1 1.0.2 1.0.3 1.0.6 1.0.9 1.1.0 1.3.0 1.3.1 1.3.10 1.3.14 1.3.2 1.3.3 1.3.6 1.4.0 1.4.1 1.4.2 1.5.0 1.5.2 1.6.0 1.6.2 1.6.4 1.7.0 1.7.2 2.10.0 2.10.1 2.10.3 2.10.5 2.10.7 2.10.8 2.10.9 2.11.0 2.11.1 2.11.2 2.12.0 2.14.0 2.15.0 2.15.2 2.15.4 2.15.5 2.15.6 2.15.7 2.15.8 2.15.9 2.16.0 2.16.1 2.16.2 2.16.3 2.16.4 2.17.0 2.17.1 2.17.12 2.17.13 2.17.14 2.17.15 2.17.16 2.17.2 2.17.3 2.17.4 2.17.5 2.17.6 2.17.8 2.17.9 2.4.12 2.4.13 2.4.14 2.4.16 2.4.18 2.4.19 2.4.9 2.5.0 2.5.1 2.5.10 2.5.11 2.5.12 2.5.13 2.5.14 2.5.15 2.5.16 2.5.17 2.5.19 2.5.2 2.5.20 2.5.3 2.5.7 2.5.8 2.5.9 2.6.0 2.6.1 2.6.10 2.6.12 2.6.13 2.6.14 2.6.15 2.6.16 2.6.17 2.6.19 2.6.2 2.6.20 2.6.4 2.6.5 2.6.7 2.7.0 2.7.1 2.7.10 2.7.11 2.7.12 2.7.13 2.7.14 2.7.2 2.7.3 2.7.4 2.7.5 2.7.6 2.7.7 2.7.8 2.7.9 2.8.0 2.8.1 2.8.2 2.8.3 2.8.4 2.8.5 2.8.6 2.8.7 2.8.9 2.9.0 2.9.12 2.9.14 2.9.15 2.9.16 2.9.17 2.9.18 2.9.19 2.9.2 2.9.20 2.9.21 2.9.22 2.9.3 2.9.4 2.9.5 2.9.6 2.9.7 2.9.8
auxin-elements / includes / elements / text.php
auxin-elements / includes / elements Last commit date
about-widget.php 4 years ago accordion-widget.php 4 years ago accordion.php 4 years ago attachment-url.php 4 years ago audio.php 4 years ago before-after.php 4 years ago button.php 4 years ago code.php 4 years ago contact-box.php 4 years ago contact-form.php 4 years ago custom-list.php 4 years ago divider.php 4 years ago dropcap.php 4 years ago facebook.php 4 years ago flickr.php 4 years ago gallery.php 4 years ago general-element-fields.php 4 years ago gmap.php 4 years ago highlight.php 4 years ago image.php 4 years ago instagram-feed.php 4 years ago latest-items.php 4 years ago latest-posts-slider.php 4 years ago popular-posts-widget.php 4 years ago products-grid.php 4 years ago quote.php 4 years ago recent-posts-grid-carousel.php 3 years ago recent-posts-land-style.php 4 years ago recent-posts-masonry.php 4 years ago recent-posts-tiles-carousel.php 3 years ago recent-posts-tiles.php 4 years ago recent-posts-timeline.php 4 years ago recent-posts-widget.php 4 years ago recent-products.php 3 years ago related-posts.php 8 years ago sample-element.php 4 years ago search.php 4 years ago socials-list.php 4 years ago staff.php 4 years ago tab-widget.php 4 years ago tabs.php 4 years ago testimonial.php 4 years ago text.php 3 years ago touch-slider.php 4 years ago video.php 4 years ago
text.php
1211 lines
1 <?php
2 /**
3 * Text element
4 *
5 *
6 * @package Auxin
7 * @license LICENSE.txt
8 * @author averta
9 * @link http://phlox.pro/
10 * @copyright (c) 2010-2022 averta
11 */
12 function auxin_get_text_master_array( $master_array ) {
13
14 $master_array['aux_text'] = array(
15 'name' => __('Info Box', 'auxin-elements'),
16 'auxin_output_callback' => 'auxin_widget_column_callback',
17 'base' => 'aux_text',
18 'description' => __('Iconic text block.', 'auxin-elements'),
19 'class' => 'aux-widget-text',
20 'show_settings_on_create' => true,
21 'weight' => 1,
22 'is_widget' => false,
23 'is_shortcode' => true,
24 'is_vc' => true,
25 'category' => THEME_NAME,
26 'group' => '',
27 'admin_enqueue_js' => '',
28 'admin_enqueue_css' => '',
29 'front_enqueue_js' => '',
30 'front_enqueue_css' => '',
31 'icon' => 'aux-element aux-pb-icons-text',
32 'custom_markup' => '',
33 'js_view' => '',
34 'html_template' => '',
35 'deprecated' => '',
36 'content_element' => '',
37 'as_parent' => '',
38 'as_child' => '',
39 'params' => array(
40 array(
41 'heading' => __('Title','auxin-elements'),
42 'description' => __('Text title, leave it empty if you don`t need title.', 'auxin-elements'),
43 'param_name' => 'title',
44 'type' => 'textfield',
45 'value' => '',
46 'def_value' => '',
47 'holder' => 'textfield',
48 'class' => 'title',
49 'description' => '',
50 'admin_label' => false,
51 'dependency' => '',
52 'weight' => '',
53 'group' => '' ,
54 'edit_field_class' => ''
55 ),
56 array(
57 'heading' => __('Subtitle','auxin-elements'),
58 'description' => '',
59 'param_name' => 'subtitle',
60 'type' => 'textfield',
61 'value' => '',
62 'def_value' => '',
63 'holder' => 'textfield',
64 'class' => 'subtitle',
65 'description' => '',
66 'admin_label' => false,
67 'dependency' => '',
68 'weight' => '',
69 'group' => '' ,
70 'edit_field_class' => ''
71 ),
72 array(
73 'heading' => __('Title Link','auxin-elements'),
74 'description' => '',
75 'param_name' => 'title_link',
76 'type' => 'textfield',
77 'value' => '',
78 'def_value' => '',
79 'holder' => 'textfield',
80 'class' => 'title_link',
81 'admin_label' => false,
82 'dependency' => '',
83 'weight' => '',
84 'group' => '' ,
85 'edit_field_class' => ''
86 ),
87 array(
88 'heading' => __('Wrapper Style','auxin-elements'),
89 'description' => '',
90 'param_name' => 'wrapper_style',
91 'type' => 'aux_visual_select',
92 'def_value' => 'simple',
93 'choices' => array(
94 'simple' => array(
95 'label' => __('Simple', 'auxin-elements'),
96 'image' => AUXIN_URL . 'images/visual-select/text-normal.svg'
97 ),
98 'outline' => array(
99 'label' => __('Outlined', 'auxin-elements'),
100 'image' => AUXIN_URL . 'images/visual-select/text-outline.svg'
101 ),
102 'box' => array(
103 'label' => __('Boxed', 'auxin-elements'),
104 'image' => AUXIN_URL . 'images/visual-select/text-boxed.svg'
105 )
106 ),
107 'holder' => '',
108 'class' => 'wrapper_style',
109 'admin_label' => false,
110 'dependency' => '',
111 'weight' => '',
112 'group' => __( 'Wrapper Layout', 'auxin-elements' ),
113 'edit_field_class' => ''
114 ),
115 array(
116 'heading' => __('Text Align','auxin-elements'),
117 'description' => '',
118 'param_name' => 'text_align',
119 'type' => 'aux_visual_select',
120 'def_value' => '',
121 'choices' => array(
122 'left' => array(
123 'label' => __('Left', 'auxin-elements'),
124 'css_class' => 'axiAdminIcon-text-align-left',
125 ),
126 'center' => array(
127 'label' => __('Center', 'auxin-elements'),
128 'css_class' => 'axiAdminIcon-text-align-center'
129 ),
130 'right' => array(
131 'label' => __('Right', 'auxin-elements'),
132 'css_class' => 'axiAdminIcon-text-align-right'
133 )
134 ),
135 'holder' => '',
136 'class' => 'text_align',
137 'admin_label' => false,
138 'dependency' => '',
139 'weight' => '',
140 'group' => __( 'Wrapper Layout', 'auxin-elements' ),
141 'edit_field_class' => ''
142 ),
143 array(
144 'heading' => __('Text Align on Small Screens','auxin-elements'),
145 'description' => '',
146 'param_name' => 'text_align_resp',
147 'type' => 'aux_visual_select',
148 'def_value' => '',
149 'choices' => array(
150 'left' => array(
151 'label' => __('Left', 'auxin-elements'),
152 'css_class' => 'axiAdminIcon-text-align-left',
153 ),
154 'center' => array(
155 'label' => __('Center', 'auxin-elements'),
156 'css_class' => 'axiAdminIcon-text-align-center'
157 ),
158 'right' => array(
159 'label' => __('Right', 'auxin-elements'),
160 'css_class' => 'axiAdminIcon-text-align-right'
161 )
162 ),
163 'holder' => '',
164 'class' => 'text_align_resp',
165 'admin_label' => false,
166 'dependency' => '',
167 'weight' => '',
168 'group' => __( 'Wrapper Layout', 'auxin-elements' ),
169 'edit_field_class' => ''
170 ),
171 array(
172 'heading' => __('Text Color Scheme','auxin-elements'),
173 'description' => '',
174 'param_name' => 'text_color_mode',
175 'type' => 'dropdown',
176 'def_value' => '',
177 'value' => array(
178 '' => __( 'Default' , 'auxin-elements' ),
179 'dark' => __( 'Dark' , 'auxin-elements' ),
180 'light' => __( 'Light' , 'auxin-elements' )
181 ),
182 'holder' => '',
183 'class' => 'text_color_mode',
184 'admin_label' => false,
185 'dependency' => '',
186 'weight' => '',
187 'group' => __( 'Wrapper Layout', 'auxin-elements' ),
188 'edit_field_class' => ''
189 ),
190
191 array(
192 'heading' => __('Wrapper Background Type', 'auxin-elements' ),
193 'description' => '',
194 'param_name' => 'wrapper_type',
195 'type' => 'dropdown',
196 'def_value' => '',
197 'value' => array(
198 'color' => __( 'Single Color' , 'auxin-elements' ),
199 'image' => __( 'Background Image' , 'auxin-elements' )
200 ),
201 'holder' => '',
202 'class' => 'wrapper_type',
203 'admin_label' => false,
204 'dependency' => '',
205 'weight' => '',
206 'group' => __( 'Wrapper Layout', 'auxin-elements' ),
207 'edit_field_class' => ''
208 ),
209
210 array(
211 'heading' => __('Wrapper Background Color', 'auxin-elements'),
212 'description' => '',
213 'param_name' => 'wrapper_bg_color',
214 'type' => 'colorpicker',
215 'def_value' => '',
216 'value' => '',
217 'holder' => '',
218 'class' => 'wrapper_bg_color',
219 'admin_label' => false,
220 'dependency' => array(
221 'element' => 'wrapper_type',
222 'value' => array('color')
223 ),
224 'weight' => '',
225 'group' => __( 'Wrapper Layout', 'auxin-elements' ),
226 'edit_field_class' => ''
227 ),
228 array(
229 'heading' => __('Wrapper Background image', 'auxin-elements'),
230 'description' => '',
231 'param_name' => 'wrapper_bg_image',
232 'type' => 'attach_image',
233 'def_value' => '',
234 'value' => '',
235 'holder' => '',
236 'class' => 'wrapper_bg_image',
237 'admin_label' => false,
238 'dependency' => array(
239 'element' => 'wrapper_type',
240 'value' => array('image')
241 ),
242 'weight' => '',
243 'group' => __( 'Wrapper Layout', 'auxin-elements' ),
244 'edit_field_class' => ''
245 ),
246 array(
247 'heading' => __('Wrapper Background Image Display', 'auxin-elements'),
248 'description' => '',
249 'param_name' => 'background_display',
250 'type' => 'dropdown',
251 'value' => array(
252 'cover' => __( 'Cover', 'auxin-elements' ),
253 'tile' => __( 'Tiled Image', 'auxin-elements' ),
254 'center' => __( 'Centered, with original size', 'auxin-elements' ),
255 'fixed' => __( 'Fixed', 'auxin-elements' )
256 ),
257 'holder' => '',
258 'class' => 'background_display',
259 'admin_label' => false,
260 'dependency' => array(
261 'element' => 'wrapper_type',
262 'value' => array('image')
263 ),
264 'weight' => '',
265 'group' => __( 'Wrapper Layout', 'auxin-elements' ),
266 'edit_field_class' => ''
267 ),
268 array(
269 'heading' => __('Wrapper Background Overlay', 'auxin-elements'),
270 'description' => '',
271 'param_name' => 'overlay_color',
272 'type' => 'colorpicker',
273 'def_value' => '',
274 'value' => '',
275 'holder' => '',
276 'class' => 'overlay_color',
277 'admin_label' => false,
278 'dependency' => array(
279 'element' => 'wrapper_type',
280 'value' => array('image')
281 ),
282 'weight' => '',
283 'group' => __( 'Wrapper Layout', 'auxin-elements' ),
284 'edit_field_class' => ''
285 ),
286 array(
287 'heading' => __('Header Background Type', 'auxin-elements' ),
288 'description' => '',
289 'param_name' => 'header_type',
290 'type' => 'dropdown',
291 'def_value' => '',
292 'value' => array(
293 'color' => __( 'Single Color' , 'auxin-elements' ),
294 'image' => __( 'Background Image' , 'auxin-elements' )
295 ),
296 'holder' => '',
297 'class' => 'header_type',
298 'admin_label' => false,
299 'dependency' => '',
300 'weight' => '',
301 'group' => __( 'Wrapper Layout', 'auxin-elements' ),
302 'edit_field_class' => ''
303 ),
304 array(
305 'heading' => __( 'Header Background color', 'auxin-elements' ),
306 'description' => '',
307 'param_name' => 'header_bg_color',
308 'type' => 'colorpicker',
309 'def_value' => '',
310 'value' => '',
311 'holder' => '',
312 'class' => '',
313 'admin_label' => '',
314 'dependency' => array(
315 'element' => 'header_type',
316 'value' => array('color')
317 ),
318 'weight' => '',
319 'group' => __( 'Wrapper Layout', 'auxin-elements' ),
320 'edit_field_class' => ''
321
322 ),
323 array(
324 'heading' => __('Header Background image', 'auxin-elements'),
325 'description' => '',
326 'param_name' => 'header_bg_img',
327 'type' => 'attach_image',
328 'def_value' => '',
329 'value' => '',
330 'holder' => '',
331 'class' => 'wrapper_bg_image',
332 'admin_label' => false,
333 'dependency' => array(
334 'element' => 'header_type',
335 'value' => array('image')
336 ),
337 'weight' => '',
338 'group' => __( 'Wrapper Layout', 'auxin-elements' ),
339 'edit_field_class' => ''
340 ),
341 array(
342 'heading' => __('Header Background Image Display', 'auxin-elements'),
343 'description' => '',
344 'param_name' => 'header_img_display',
345 'type' => 'dropdown',
346 'value' => array(
347 'cover' => __( 'Cover', 'auxin-elements' ),
348 'tile' => __( 'Tiled Image', 'auxin-elements' ),
349 'center' => __( 'Centered, with original size', 'auxin-elements' ),
350 'fixed' => __( 'Fixed', 'auxin-elements' )
351 ),
352 'holder' => '',
353 'class' => 'background_display',
354 'admin_label' => false,
355 'dependency' => array(
356 'element' => 'header_type',
357 'value' => array('image')
358 ),
359 'weight' => '',
360 'group' => __( 'Wrapper Layout', 'auxin-elements' ),
361 'edit_field_class' => ''
362 ),
363 array(
364 'heading' => __('Icon or image', 'auxin-elements' ),
365 'description' => __('Please choose an icon from avaialable icons.', 'auxin-elements'),
366 'heading' => __('Display Icon or Image', 'auxin-elements'),
367 'description' => '',
368 'param_name' => 'icon_or_image',
369 'type' => 'dropdown',
370 'def_value' => 'icon',
371 'value' => array(
372 'icon' => __( 'Icon' , 'auxin-elements' ),
373 'image' => __( 'Image' , 'auxin-elements' ),
374 ),
375 'holder' => '',
376 'class' => 'icon_or_image',
377 'admin_label' => false,
378 'dependency' => '',
379 'weight' => '',
380 'group' => __( 'Icon & Image', 'auxin-elements' ),
381 'edit_field_class' => ''
382 ),
383 array(
384 'heading' => __('Icon', 'auxin-elements' ),
385 'description' => __('Please choose an icon from the list.', 'auxin-elements'),
386 'param_name' => 'icon',
387 'type' => 'aux_iconpicker',
388 'value' => '',
389 'def_value' => '',
390 'holder' => 'textfield',
391 'class' => 'aux_iconpicker',
392 'admin_label' => false,
393 'dependency' => array(
394 'element' => 'icon_or_image',
395 'value' => array('icon')
396 ),
397 'weight' => '',
398 'group' => __( 'Icon & Image', 'auxin-elements' ),
399 'edit_field_class' => ''
400 ),
401 array(
402 'heading' => __('Image','auxin-elements'),
403 'description' => '',
404 'param_name' => 'image',
405 'type' => 'attach_image',
406 'def_value' => '',
407 'value' => '',
408 'holder' => '',
409 'class' => 'image',
410 'admin_label' => false,
411 'dependency' => array(
412 'element' => 'icon_or_image',
413 'value' => array('image')
414 ),
415 'weight' => '',
416 'group' => __( 'Icon & Image', 'auxin-elements' ),
417 'edit_field_class' => ''
418 ),
419 array(
420 'heading' => __('Image Size','auxin-elements'),
421 'description' => '',
422 'param_name' => 'image_size',
423 'type' => 'dropdown',
424 'def_value' => '',
425 'value' => array(
426 'full' => __( 'Orginal Size' , 'auxin-elements' ),
427 'large' => __( 'Large' , 'auxin-elements' ),
428 'medium' => __( 'Medium' , 'auxin-elements' ),
429 'thumbnail' => __( 'Thumbnail' , 'auxin-elements' )
430 ),
431 'holder' => '',
432 'class' => 'image_size',
433 'admin_label' => false,
434 'dependency' => array(
435 'element' => 'icon_or_image',
436 'value' => array('image')
437 ),
438 'weight' => '',
439 'group' => __( 'Icon & Image', 'auxin-elements' ),
440 'edit_field_class' => ''
441 ),
442 array(
443 'heading' => __('Icon color','auxin-elements'),
444 'description' => __('Choose a color for icon.','auxin-elements'),
445 'param_name' => 'icon_color',
446 'type' => 'colorpicker',
447 'def_value' => '#888',
448 'value' => '',
449 'holder' => '',
450 'class' => 'icon_color',
451 'admin_label' => false,
452 'dependency' => array(
453 'element' => 'icon_or_image',
454 'value' => array('icon')
455 ),
456 'weight' => '',
457 'group' => __( 'Icon & Image', 'auxin-elements' ),
458 'edit_field_class' => ''
459 ),
460 array(
461 'heading' => __('Icon size','auxin-elements'),
462 'description' => '',
463 'param_name' => 'icon_size',
464 'type' => 'dropdown',
465 'def_value' => '',
466 'value' => array(
467 'small' => __( 'Small' , 'auxin-elements' ),
468 'medium' => __( 'Medium' , 'auxin-elements' ),
469 'large' => __( 'Large' , 'auxin-elements' ),
470 'x-large' => __( 'X-Large' , 'auxin-elements' )
471 ),
472 'holder' => '',
473 'class' => 'icon_size',
474 'admin_label' => false,
475 'dependency' => array(
476 'element' => 'icon_or_image',
477 'value' => array('icon')
478 ),
479 'weight' => '',
480 'group' => __( 'Icon & Image', 'auxin-elements' ),
481 'edit_field_class' => ''
482 ),
483 array(
484 'heading' => __('Icon background color','auxin-elements'),
485 'description' => __('Choose a color for background of icon.','auxin-elements'),
486 'param_name' => 'icon_bg_color',
487 'type' => 'colorpicker',
488 'def_value' => '',
489 'value' => '',
490 'holder' => '',
491 'class' => 'icon_bg_color',
492 'admin_label' => false,
493 'dependency' => array(
494 'element' => 'icon_or_image',
495 'value' => array('icon')
496 ),
497 'weight' => '',
498 'group' => __( 'Icon & Image', 'auxin-elements' ),
499 'edit_field_class' => ''
500 ),
501 array(
502 'heading' => __( 'Icon/Image outline color', 'auxin-elements' ),
503 'description' => __( 'Choose a color for the border around the icon or image.', 'auxin-elements' ),
504 'param_name' => 'icon_border_color',
505 'type' => 'colorpicker',
506 'def_value' => '',
507 'value' => '',
508 'holder' => '',
509 'class' => 'icon_border_color',
510 'admin_label' => false,
511 'weight' => '',
512 'group' => 'Icon & Image',
513 'edit_field_class' => ''
514 ),
515
516 array(
517 'heading' => __( 'Icon/Image outline width', 'auxin-elements' ),
518 'description' => __( 'Choose a width for the border around the icon or image.', 'auxin-elements' ),
519 'param_name' => 'icon_border_width',
520 'type' => 'textfield',
521 'def_value' => '1',
522 'value' => '',
523 'holder' => '',
524 'class' => 'icon_border_width',
525 'admin_label' => false,
526 'weight' => '',
527 'group' => __( 'Icon & Image', 'auxin-elements' ),
528 'edit_field_class' => ''
529 ),
530 array(
531 'heading' => __('Icon background shape','auxin-elements'),
532 'description' => '',
533 'param_name' => 'icon_shape',
534 'type' => 'aux_visual_select',
535 'choices' => array(
536 'circle' => array(
537 'label' => __('Circle', 'auxin-elements'),
538 'image' => AUXIN_URL . 'images/visual-select/icon-style-circle.svg'
539 ),
540 'semi-circle' => array(
541 'label' => __('Semi-circle', 'auxin-elements'),
542 'image' => AUXIN_URL . 'images/visual-select/icon-style-semi-circle.svg'
543 ),
544 'round-rect' => array(
545 'label' => __('Round Rectangle', 'auxin-elements'),
546 'image' => AUXIN_URL . 'images/visual-select/icon-style-round-rectangle.svg'
547 ),
548 'cross-rect' => array(
549 'label' => __('Cross Rectangle', 'auxin-elements'),
550 'image' => AUXIN_URL . 'images/visual-select/icon-style-cross-rectangle.svg'
551 ),
552 'rect' => array(
553 'label' => __('Rectangle', 'auxin-elements'),
554 'image' => AUXIN_URL . 'images/visual-select/icon-style-rectangle.svg'
555 )
556 ),
557 'holder' => '',
558 'class' => 'icon_shape',
559 'dependency' => array(
560 'element' => 'icon_or_image',
561 'value' => array('icon')
562 ),
563 'admin_label' => false,
564 'weight' => '',
565 'group' =>__( 'Icon & Image', 'auxin-elements' ),
566 'edit_field_class' => ''
567 ),
568 array(
569 'heading' => __('Image shape','auxin-elements'),
570 'description' => '',
571 'param_name' => 'img_shape',
572 'type' => 'aux_visual_select',
573 'choices' => array(
574 'default' => array(
575 'label' => __('Default Aspect', 'auxin-elements'),
576 'image' => AUXIN_URL . 'images/visual-select/icon-style-rectangle.svg'
577 ),
578 'circle' => array(
579 'label' => __('Circle', 'auxin-elements'),
580 'image' => AUXIN_URL . 'images/visual-select/icon-style-circle.svg'
581 ),
582 'semi-circle' => array(
583 'label' => __('Semi-circle', 'auxin-elements'),
584 'image' => AUXIN_URL . 'images/visual-select/icon-style-semi-circle.svg'
585 ),
586 'round-rect' => array(
587 'label' => __('Round Rectangle', 'auxin-elements'),
588 'image' => AUXIN_URL . 'images/visual-select/icon-style-round-rectangle.svg'
589 ),
590 'rect' => array(
591 'label' => __('Rectangle', 'auxin-elements'),
592 'image' => AUXIN_URL . 'images/visual-select/icon-style-rectangle.svg'
593 )
594 ),
595 'holder' => '',
596 'dependency' => array(
597 'element' => 'icon_or_image',
598 'value' => array('image')
599 ),
600 'class' => 'img_shape',
601 'admin_label' => false,
602 'weight' => '',
603 'group' => __( 'Icon & Image', 'auxin-elements' ),
604 'edit_field_class' => ''
605 ),
606 array(
607 'heading' => __('Image or icon position','auxin-elements'),
608 'description' => '',
609 'param_name' => 'image_position',
610 'type' => 'aux_visual_select',
611 'def_value' => '',
612 'choices' => array(
613 'top' => array(
614 'label' => __('Top', 'auxin-elements'),
615 'image' => AUXIN_URL . 'images/visual-select/column-icon-top.svg'
616 ),
617 'left' => array(
618 'label' => __('Left', 'auxin-elements'),
619 'image' => AUXIN_URL . 'images/visual-select/column-icon-left.svg'
620 ),
621 'right' => array(
622 'label' => __('Right', 'auxin-elements'),
623 'image' => AUXIN_URL . 'images/visual-select/column-icon-right.svg'
624 )
625 ),
626 'holder' => '',
627 'class' => 'image_position',
628 'admin_label' => false,
629 'dependency' => '',
630 'weight' => '',
631 'group' => __( 'Icon & Image', 'auxin-elements' ),
632 'edit_field_class' => ''
633 ),
634 array(
635 'heading' => __('Display button', 'auxin-elements' ),
636 'description' => __('Display a button in text widget', 'auxin-elements' ),
637 'param_name' => 'display_button',
638 'type' => 'checkbox',
639 'def_value' => '',
640 'value' => '',
641 'class' => 'display_button',
642 'admin_label' => false,
643 'dependency' => '',
644 'weight' => '',
645 'group' => __( 'Button', 'auxin-elements' ),
646 'edit_field_class' => ''
647 ),
648 array(
649 'heading' => __('Button label', 'auxin-elements' ),
650 'description' => __('The label of button.', 'auxin-elements' ),
651 'param_name' => 'btn_label',
652 'type' => 'textfield',
653 'value' => '',
654 'holder' => 'textfield',
655 'class' => 'label',
656 'admin_label' => false,
657 'dependency' => array(
658 'element' => 'display_button',
659 'value' => array('1', 'true'),
660 ),
661 'weight' => '',
662 'group' => __( 'Button', 'auxin-elements' ),
663 'edit_field_class' => ''
664 ),
665 array(
666 'heading' => __('Button size','auxin-elements' ),
667 'description' => '',
668 'param_name' => 'btn_size',
669 'type' => 'dropdown',
670 'def_value' => 'medium',
671 'value' => array(
672 'exlarge' => __('Exlarge', 'auxin-elements' ),
673 'large' => __('Large' , 'auxin-elements' ),
674 'medium' => __('Medium' , 'auxin-elements' ),
675 'small' => __('Small' , 'auxin-elements' ),
676 'tiny' => __('Tiny' , 'auxin-elements' )
677 ),
678 'holder' => '',
679 'class' => 'round',
680 'admin_label' => false,
681 'dependency' => array(
682 'element' => 'display_button',
683 'value' => array('1', 'true'),
684 ),
685 'weight' => '',
686 'group' => __( 'Button', 'auxin-elements' ),
687 'edit_field_class' => ''
688 ),
689 array(
690 'heading' => __('Button shape style','auxin-elements' ),
691 'description' => '',
692 'param_name' => 'btn_border',
693 'type' => 'aux_visual_select',
694 'value' => '',
695 'class' => 'border',
696 'admin_label' => false,
697 'dependency' => array(
698 'element' => 'display_button',
699 'value' => array('1', 'true'),
700 ),
701 'weight' => '',
702 'group' => __( 'Button', 'auxin-elements' ),
703 'edit_field_class' => '',
704 'choices' => array(
705 'none' => array(
706 'label' => __('Box', 'auxin-elements' ),
707 'image' => AUXIN_URL . 'images/visual-select/button-normal.svg'
708 ),
709 'round' => array(
710 'label' => __('Round', 'auxin-elements' ),
711 'image' => AUXIN_URL . 'images/visual-select/button-curved.svg'
712 ),
713 'curve' => array(
714 'label' => __('Curve', 'auxin-elements' ),
715 'image' => AUXIN_URL . 'images/visual-select/button-rounded.svg'
716 )
717 )
718 ),
719 array(
720 'heading' => __('Button style','auxin-elements' ),
721 'description' => '',
722 'param_name' => 'btn_style',
723 'type' => 'aux_visual_select',
724 'value' => '',
725 'class' => 'style',
726 'admin_label' => false,
727 'dependency' => array(
728 'element' => 'display_button',
729 'value' => array('1', 'true'),
730 ),
731 'weight' => '',
732 'group' => __( 'Button', 'auxin-elements' ),
733 'edit_field_class' => '',
734 'choices' => array(
735 'none' => array(
736 'label' => __('Normal', 'auxin-elements' ),
737 'image' => AUXIN_URL . 'images/visual-select/button-normal.svg'
738 ),
739 '3d' => array(
740 'label' => __('3D', 'auxin-elements' ),
741 'image' => AUXIN_URL . 'images/visual-select/button-3d.svg'
742 ),
743 'outline' => array(
744 'label' => __('Outline', 'auxin-elements' ),
745 'image' => AUXIN_URL . 'images/visual-select/button-outline.svg'
746 )
747 )
748 ),
749 array(
750 'heading' => __('Uppercase label','auxin-elements' ),
751 'description' => '',
752 'param_name' => 'btn_uppercase',
753 'type' => 'aux_switch',
754 'value' => '1',
755 'class' => 'uppercase',
756 'admin_label' => false,
757 'dependency' => array(
758 'element' => 'display_button',
759 'value' => array('1', 'true'),
760 ),
761 'weight' => '',
762 'group' => __( 'Button', 'auxin-elements' ),
763 'edit_field_class' => ''
764 ),
765 array(
766 'heading' => __('Darken the label','auxin-elements' ),
767 'description' => __('Darken label of button while mouse over it.','auxin-elements' ),
768 'param_name' => 'btn_dark',
769 'type' => 'aux_switch',
770 'value' => '0',
771 'class' => 'dark',
772 'admin_label' => false,
773 'dependency' => array(
774 'element' => 'display_button',
775 'value' => array('1', 'true'),
776 ),
777 'weight' => '',
778 'group' => __( 'Button', 'auxin-elements' ),
779 'edit_field_class' => ''
780 ),
781 array(
782 'heading' => __('Icon for button','auxin-elements' ),
783 'description' => '',
784 'param_name' => 'btn_icon',
785 'type' => 'aux_iconpicker',
786 'value' => '',
787 'class' => 'icon-name',
788 'admin_label' => false,
789 'dependency' => array(
790 'element' => 'display_button',
791 'value' => array('1', 'true'),
792 ),
793 'weight' => '',
794 'group' => __( 'Button', 'auxin-elements' ),
795 'edit_field_class' => ''
796 ),
797 array(
798 'heading' => __('Icon alignment','auxin-elements' ),
799 'description' => '',
800 'param_name' => 'btn_icon_align',
801 'type' => 'dropdown',
802 'def_value' => 'default',
803 'value' => array(
804 'default' => __('Default' , 'auxin-elements' ),
805 'left' => __('Left' , 'auxin-elements' ),
806 'right' => __('Right' , 'auxin-elements' ),
807 'over' => __('Over' , 'auxin-elements' ),
808 'left-animate' => __('Animate from Left' , 'auxin-elements' ),
809 'right-animate' => __('Animate from Right' , 'auxin-elements' )
810 ),
811 'holder' => '',
812 'class' => 'icon-align',
813 'admin_label' => false,
814 'dependency' => array(
815 'element' => 'display_button',
816 'value' => array('1', 'true'),
817 ),
818 'weight' => '',
819 'group' => __( 'Button', 'auxin-elements' ),
820 'edit_field_class' => ''
821 ),
822 array(
823 'heading' => __('Color of button','auxin-elements' ),
824 'description' => '',
825 'param_name' => 'btn_color_name',
826 'type' => 'aux_visual_select',
827 'value' => 'carmine-pink',
828 'choices' => auxin_get_famous_colors_list(),
829 'holder' => '',
830 'class' => 'color',
831 'admin_label' => false,
832 'dependency' => array(
833 'element' => 'display_button',
834 'value' => array('1', 'true'),
835 ),
836 'weight' => '',
837 'group' => __( 'Button', 'auxin-elements' ),
838 'edit_field_class' => ''
839 ),
840 array(
841 'heading' => __('Link','auxin-elements' ),
842 'description' => __('If you want to link your button.', 'auxin-elements' ),
843 'param_name' => 'btn_link',
844 'type' => 'textfield',
845 'value' => '',
846 'holder' => '',
847 'class' => 'link',
848 'admin_label' => false,
849 'dependency' => array(
850 'element' => 'display_button',
851 'value' => array('1', 'true'),
852 ),
853 'weight' => '',
854 'group' => __( 'Button', 'auxin-elements' ),
855 'edit_field_class' => ''
856 ),
857 array(
858 'heading' => __('Open link in','auxin-elements' ),
859 'description' => '',
860 'param_name' => 'btn_target',
861 'type' => 'dropdown',
862 'def_value' => '_self',
863 'value' => array(
864 '_self' => __('Current page' , 'auxin-elements' ),
865 '_blank' => __('New page', 'auxin-elements' )
866 ),
867 'holder' => '',
868 'class' => 'btn_target',
869 'admin_label' => false,
870 'dependency' => array(
871 'element' => 'display_button',
872 'value' => array('1', 'true'),
873 ),
874 'weight' => '',
875 'group' => __( 'Button', 'auxin-elements' ),
876 'edit_field_class' => ''
877 ),
878 array(
879 'heading' => __('Content','auxin-elements'),
880 'description' => __('Enter a text as a text content.','auxin-elements'),
881 'param_name' => 'content',
882 'type' => 'textarea_html',
883 'value' => '',
884 'def_value' => '',
885 'holder' => 'div',
886 'class' => 'content',
887 'admin_label' => false,
888 'dependency' => '',
889 'weight' => '',
890 'group' => '' ,
891 'edit_field_class' => ''
892 ),
893 array(
894 'heading' => __('Footer Shape','auxin-elements'),
895 'description' => '',
896 'param_name' => 'footer_shape',
897 'type' => 'aux_visual_select',
898 'def_value' => 'simple',
899 'choices' => array(
900 'none' => array(
901 'label' => __('None', 'auxin-elements'),
902 'image' => AUXIN_URL . 'images/visual-select/text-normal.svg'
903 ),
904 'wave' => array(
905 'label' => __('Wave', 'auxin-elements'),
906 'image' => AUXIN_URL . 'images/visual-select/text-outline.svg'
907 ),
908 'tail' => array(
909 'label' => __('Tail', 'auxin-elements'),
910 'image' => AUXIN_URL . 'images/visual-select/text-boxed.svg'
911 )
912 ),
913 'holder' => '',
914 'class' => 'footer_shape',
915 'admin_label' => false,
916 'dependency' => '',
917 'weight' => '',
918 'group' => __( 'Wrapper Layout', 'auxin-elements' ),
919 'edit_field_class' => ''
920 ),
921 array(
922 'heading' => __( 'Footer Shape color', 'auxin-elements' ),
923 'description' => __( 'Select color for shape', 'auxin-elements' ),
924 'param_name' => 'footer_shape_color',
925 'type' => 'colorpicker',
926 'value' => '',
927 'class' => 'footer_shape_color',
928 'dependency' => array(
929 'element' => 'footer_shape',
930 'value' => array('tail', 'wave')
931 ),
932 'group' => __( 'Wrapper Layout', 'auxin-elements' ),
933 ),
934 array(
935 'heading' => __('Extra class name','auxin-elements'),
936 'description' => __('If you wish to style particular content element differently, then use this field to add a class name and then refer to it in your css file.', 'auxin-elements'),
937 'param_name' => 'extra_classes',
938 'type' => 'textfield',
939 'value' => '',
940 'def_value' => '',
941 'holder' => 'textfield',
942 'class' => 'extra_classes',
943 'admin_label' => false,
944 'dependency' => '',
945 'weight' => '',
946 'group' => '' ,
947 'edit_field_class' => ''
948 )
949 )
950 );
951
952 return $master_array;
953 }
954
955 add_filter( 'auxin_master_array_shortcodes', 'auxin_get_text_master_array', 10, 1 );
956
957 // This is the widget call back in fact the front end out put of this widget comes from this function
958 function auxin_widget_column_callback( $atts, $shortcode_content = null ){
959
960 global $aux_content_width;
961
962 // Defining default attributes
963 $default_atts = array(
964 'title' => '', // section title
965 'subtitle' => '', // Text as subtitle under the title
966 'title_link' => '', // the link on title
967 'wrapper_style' => 'simple', // box, outline,
968 'text_align' => 'center', // left, right, center
969 'text_align_resp' => 'center', // left, right, center
970 'text_color_mode' => 'dark', // dark, light
971 'wrapper_type' => '', // color, image
972 'wrapper_bg_color' => '',
973 'wrapper_bg_image' => '',
974 'background_display' => 'center', // center, fixed , cover, tile
975 'overlay_color' => '',
976 'header_type' => 'color', //color, image
977 'header_bg_color' => '',
978 'header_bg_img' => '',
979 'header_img_display' => 'center', // center, fixed , cover, tile
980 'icon_or_image' => 'icon', //icon, image
981 'icon' => '', // icon on column side
982 'image' => '', // image on column side
983 'size' => 'medium_large', // image size
984 'width' => '', // final width of image
985 'height' => '', // final height of imageone
986 'lightbox' => 'no', // open in lightbox or not
987 'preloadable' => '0',
988 'preload_preview' => '0',
989 'preload_bgcolor' => '',
990 'icon_size' => 'large', // small, medium, large, x-large
991 'icon_shape' => '', // circle, semi-circle, round-rect, rect, fill, ...
992 'img_shape' => '', // circle, semi-circle, round-rect, rect, fill, ...
993 'image_position' => 'top', // top,left,right
994 'content' => '', // the content
995 'display_button' => '0',
996 'btn_label' => '',
997 'btn_size' => '',
998 'btn_border' => '',
999 'btn_style' => '',
1000 'btn_uppercase' => '',
1001 'btn_dark' => '',
1002 'btn_icon' => '',
1003 'btn_icon_align' => '',
1004 'btn_color_name' => '',
1005 'btn_link' => '',
1006 'btn_target' => '',
1007 'btn_nofollow' => false,
1008 'footer_shape' => '',
1009 'footer_shape_color' => '',
1010 'icon_svg_inline' => '',
1011 'extra_classes' => '', // custom css class names for this element
1012 'custom_el_id' => '', // custom id attribute for this element
1013 'base_class' => 'aux-widget-text' // base class name for container
1014 );
1015
1016
1017 $result = auxin_get_widget_scafold( $atts, $default_atts );
1018
1019 extract( $result['parsed_atts'] );
1020
1021 if( empty( $size ) ){
1022 $size = 'medium_large';
1023 }
1024 if( 'custom' == $size ){
1025 $size = array( 'width' => $width, 'height' => $height );
1026 }
1027
1028 if( ! empty( $image ) && is_numeric( $image ) ) {
1029 $image = auxin_get_the_responsive_attachment( $image,
1030 array(
1031 'quality' => 100,
1032 'preloadable' => auxin_is_true( $preloadable ),
1033 'preload_preview' => $preload_preview,
1034 'preload_bgcolor' => $preload_bgcolor,
1035 'size' => $size,
1036 'crop' => true,
1037 'add_hw' => true,
1038 'upscale' => false,
1039 'original_src' => 'full' === $size ? true : false,
1040 'attr' => array( 'class' => "aux-attachment aux-featured-image aux-attachment-id-$image" )
1041 )
1042 );
1043 }
1044
1045 if ( ! empty( $wrapper_bg_image ) && is_numeric( $wrapper_bg_image ) ){
1046 $wrapper_bg_image = wp_get_attachment_image_url( $wrapper_bg_image, 'full' );
1047 }
1048
1049 if ( ! empty( $header_bg_img ) && is_numeric( $header_bg_img ) ){
1050 $header_bg_img = wp_get_attachment_image_url( $header_bg_img, 'full' );
1051 }
1052
1053 $content = empty( $content ) ? $shortcode_content : $content;
1054
1055 // Box Main Classes
1056
1057 $main_classes = 'aux-widget-advanced-text ';
1058 $main_classes .= 'aux-wrap-style-' . esc_attr( $wrapper_style ) . ' ';
1059 $main_classes .= 'aux-ico-pos-' . esc_attr( $image_position ) . ' ';
1060 $main_classes .= 'aux-text-' . esc_attr( $text_align ) . ' ';
1061 $main_classes .= 'aux-text-resp-' . esc_attr( $text_align_resp ) . ' ';
1062 if( $text_color_mode ){
1063 $main_classes .= 'aux-text-color-' . esc_attr( $text_color_mode ) . ' ';
1064 }
1065 $main_classes .= 'aux-text-widget-bg-' . esc_attr( $background_display ) . ' ';
1066 $main_classes .= empty( $header_bg_color ) ? '' : 'aux-text-fill-header ' ;
1067 $main_classes .= empty( $header_bg_img ) ? '' : 'aux-text-img-header ' ;
1068 $main_classes .= empty( $header_bg_img ) ? '' : 'aux-text-img-header ' ;
1069 $main_classes .= empty( $content ) ? 'aux-text-no-content ' : ' ' ;
1070 $main_classes .= ! empty( $icon ) && empty( $icon_bg_color ) && ( 'top' != $image_position ) ? 'aux-text-padding-fix ' : '';
1071 $main_classes .= ! empty( $header_bg_color ) && ( 'top' != $image_position ) ? 'aux-text-header-fix ' : '';
1072
1073 //---------------------------------------------
1074 // Overlay Inline Styles
1075
1076 $overlay_style = '';
1077 $overlay_style .= empty( $overlay_color ) ? '' : 'background-color: ' . esc_attr( $overlay_color ) . '; ';
1078
1079 $overlay_style = ! empty( $overlay_style ) ? 'style="' . $overlay_style . '"' : '';
1080
1081 //---------------------------------------------
1082 // Box Inline Styles
1083
1084 $main_styles = '';
1085 $main_styles .= empty( $wrapper_bg_color ) ? '' : 'background-color: ' . esc_attr( $wrapper_bg_color ) . '; ';
1086 $main_styles .= empty( $wrapper_bg_image ) ? '' : 'background-image: url(' . esc_attr( $wrapper_bg_image ) . '); ';
1087
1088 $main_styles = ! empty( $main_styles ) ? 'style="' . $main_styles . '"' : '';
1089
1090 //---------------------------------------------
1091 // Header Inline Styles
1092
1093 $header_styles = '';
1094 $header_styles .= empty( $header_bg_color ) ? '' : 'background-color: ' . esc_attr( $header_bg_color ) . '; ';
1095 $header_styles .= empty( $header_bg_img ) ? '' : 'background-image: url(' . esc_attr( $header_bg_img ) . '); ';
1096
1097 $header_styles = ! empty( $header_styles ) ? 'style="' . $header_styles . '"' : '';
1098 //---------------------------------------------
1099 // Header Classnames
1100
1101 $header_classess = '';
1102 $header_classess .= empty( $header_bg_img ) ? '' : 'aux-text-widget-bg-' . esc_attr( $header_img_display ) . ' ';
1103
1104 //---------------------------------------------
1105 // Icon Classnames
1106
1107 $icon_box_classnames = '';
1108 $icon_box_classnames .= ! empty ( $icon_size ) ? 'aux-ico-' . esc_attr( $icon_size ) . ' ' : '';
1109 $icon_box_classnames .= ! empty ( $icon ) ? 'aux-ico-shape-' . esc_attr( $icon_shape ) . ' ' : '';
1110 $icon_box_classnames .= ! empty ( $image ) ? 'aux-img-box aux-ico-shape-' . esc_attr( $img_shape ) . ' ' : '';
1111 $icon_box_classnames .= empty( $icon_bg_color ) ? 'aux-ico-clear' : '';
1112
1113 $icon_classname = empty( $icon ) ? '' : $icon ;
1114
1115 //---------------------------------------------
1116 // Footer Classnames
1117
1118 $footer_classess = '';
1119 $footer_classess .= empty( $footer_shape ) ? '' : 'aux-border-shape-' . esc_attr( $footer_shape ) . ' ';
1120
1121 //---------------------------------------------
1122 // Footer Inline Styles
1123
1124 $footer_styles = '';
1125 $footer_styles .= ! empty ( $footer_shape_color ) && 'wave' === $footer_shape ? 'fill: ' . esc_attr( $footer_shape_color) . '; ' : '';
1126 $footer_styles .= ! empty ( $footer_shape_color ) && 'tail' === $footer_shape ? 'border-top-color: ' . esc_attr( $footer_shape_color) . '; ' : '';
1127
1128 $footer_styles = ! empty( $footer_styles ) ? 'style="' . $footer_styles . '"' : '';
1129
1130 //---------------------------------------------
1131
1132 $btn_atts = array(
1133 'label' => $btn_label,
1134 'size' => $btn_size,
1135 'border' => $btn_border,
1136 'style' => $btn_style,
1137 'uppercase' => $btn_uppercase,
1138 'dark' => $btn_dark,
1139 'icon' => $btn_icon,
1140 'icon_align' => $btn_icon_align,
1141 'color_name' => $btn_color_name,
1142 'link' => $btn_link,
1143 'target' => $btn_target,
1144 'nofollow' => $btn_nofollow
1145 );
1146
1147 ob_start();
1148 // widget header ------------------------------
1149 echo wp_kses_post( $result['widget_header'] );
1150 ?>
1151 <div class="<?php echo esc_attr( $main_classes ) ;?>" <?php echo wp_kses_post( $main_styles ); ?>>
1152 <?php if ( ! empty( $overlay_color ) ) { ?>
1153 <div class="aux-text-widget-overlay" <?php echo wp_kses_post( $overlay_style ) ; ?>></div>
1154 <?php } ?>
1155
1156 <?php if( ! empty( $icon ) || ! empty( $image ) || ! empty( $header_bg_img ) || ! empty( $icon_svg_inline ) ) { ?>
1157 <div class="aux-text-widget-header <?php echo esc_attr( $header_classess ) ;?>" <?php echo wp_kses_post( $header_styles ) ; ?> >
1158 <div class="aux-ico-box <?php echo esc_attr( $icon_box_classnames ) ;?> ">
1159 <?php if ( ! empty( $icon ) ){ ;?>
1160 <span class="aux-ico <?php echo esc_attr( $icon_classname ) ;?>" > </span>
1161 <?php } elseif ( ! empty( $image ) ) { ?>
1162 <?php echo wp_kses_post( $image ); ?>
1163 <?php } else { ?>
1164 <?php echo wp_kses_post( $icon_svg_inline ) ;?>
1165 <?php }; ?>
1166 </div>
1167 </div>
1168 <?php } ?>
1169
1170 <div class="aux-text-inner aux-text-widget-content">
1171 <?php if( ! empty( $title ) && empty( $title_link ) ) { ?>
1172 <h4 class="col-title"><?php echo auxin_kses( $title ); ?></h4>
1173 <?php } elseif( ! empty( $title ) && ! empty( $title_link ) ) { ?>
1174 <h4 class="col-title"><a href="<?php echo esc_url( $title_link ); ?>"><?php echo auxin_kses( $title ); ?></a></h4>
1175 <?php } if( ! empty( $subtitle ) ) { ?>
1176 <h5 class="col-subtitle"><?php echo auxin_kses( $subtitle ); ?></h5>
1177
1178 <?php } if( ! empty( $content ) ) { ?>
1179 <div class="widget-content">
1180 <?php $encoding_flag = defined('ENT_HTML401') ? ENT_HTML401 : ENT_QUOTES; ?>
1181 <?php echo do_shortcode( html_entity_decode( $content, $encoding_flag, 'UTF-8') ); ?>
1182 </div>
1183 <?php } if ( auxin_is_true( $display_button ) ) {
1184 echo auxin_widget_button_callback( $btn_atts );
1185 } ?>
1186 </div>
1187 </div>
1188 <?php if ( ! empty( $footer_classess ) ) { ?>
1189 <div class="aux-text-widget-footer">
1190 <div class="<?php echo esc_attr( $footer_classess ); ?>"<?php echo wp_kses_post( $footer_styles ); ?>>
1191 <?php if ( 'wave' === $footer_shape ){?>
1192 <svg width="100%" height="16">
1193 <defs>
1194 <pattern id="pattern-shape-wave" x="16" y="0" width="35" height="16" patternUnits="userSpaceOnUse" >
1195 <path d="M16 16 L35 0 L-2 0 Z" />
1196 </pattern>
1197 </defs>
1198 <rect x="0" y="0" width="100%" height="17" style="fill: url(#pattern-shape-wave);" />
1199 </svg>
1200 <?php }?>
1201 </div>
1202 </div>
1203 <?php } ?>
1204
1205 <?php
1206 // widget footer ------------------------------
1207 echo wp_kses_post( $result['widget_footer'] );
1208
1209 return ob_get_clean();
1210 }
1211