Completed
Push — master ( c4cd1f...963c86 )
by
unknown
36s
created
sample/sections/editors/ace-editor.php 1 patch
Indentation   +40 added lines, -40 removed lines patch added patch discarded remove patch
@@ -10,48 +10,48 @@
 block discarded – undo
10 10
 defined( 'ABSPATH' ) || exit;
11 11
 
12 12
 Redux::set_section(
13
-	$opt_name,
14
-	array(
15
-		'title'      => esc_html__( 'ACE Editor', 'your-textdomain-here' ),
16
-		'id'         => 'editor-ace',
17
-		'subsection' => true,
18
-		'desc'       => esc_html__( 'For full documentation on the this field, visit: ', 'your-textdomain-here' ) . '<a href="https://devs.redux.io/core-fields/ace-editor.html" target="_blank">https://devs.redux.io/core-fields/ace-editor.html</a>',
19
-		'fields'     => array(
20
-			array(
21
-				'id'       => 'opt-ace-editor-css',
22
-				'type'     => 'ace_editor',
23
-				'title'    => esc_html__( 'CSS Code', 'your-textdomain-here' ),
24
-				'subtitle' => esc_html__( 'Paste your CSS code here.', 'your-textdomain-here' ),
25
-				'mode'     => 'css',
26
-				'theme'    => 'monokai',
27
-				'desc'     => 'Possible modes can be found at <a href="//ace.c9.io" target="_blank">ace.c9.io/</a>.',
28
-				'default'  => '#header{
13
+    $opt_name,
14
+    array(
15
+        'title'      => esc_html__( 'ACE Editor', 'your-textdomain-here' ),
16
+        'id'         => 'editor-ace',
17
+        'subsection' => true,
18
+        'desc'       => esc_html__( 'For full documentation on the this field, visit: ', 'your-textdomain-here' ) . '<a href="https://devs.redux.io/core-fields/ace-editor.html" target="_blank">https://devs.redux.io/core-fields/ace-editor.html</a>',
19
+        'fields'     => array(
20
+            array(
21
+                'id'       => 'opt-ace-editor-css',
22
+                'type'     => 'ace_editor',
23
+                'title'    => esc_html__( 'CSS Code', 'your-textdomain-here' ),
24
+                'subtitle' => esc_html__( 'Paste your CSS code here.', 'your-textdomain-here' ),
25
+                'mode'     => 'css',
26
+                'theme'    => 'monokai',
27
+                'desc'     => 'Possible modes can be found at <a href="//ace.c9.io" target="_blank">ace.c9.io/</a>.',
28
+                'default'  => '#header{
29 29
 	margin: 0 auto;
30 30
 }',
31
-			),
32
-			array(
33
-				'id'       => 'opt-ace-editor-js',
34
-				'type'     => 'ace_editor',
35
-				'title'    => esc_html__( 'JS Code', 'your-textdomain-here' ),
36
-				'subtitle' => esc_html__( 'Paste your JS code here.', 'your-textdomain-here' ),
37
-				'mode'     => 'javascript',
38
-				'theme'    => 'chrome',
39
-				'desc'     => 'Possible modes can be found at <a href="//ace.c9.io" target="_blank">ace.c9.io/</a>.',
40
-				'default'  => 'jQuery(document).ready(function(){\n\n});',
41
-			),
42
-			array(
43
-				'id'         => 'opt-ace-editor-php',
44
-				'type'       => 'ace_editor',
45
-				'full_width' => true,
46
-				'title'      => esc_html__( 'PHP Code', 'your-textdomain-here' ),
47
-				'subtitle'   => esc_html__( 'Paste your PHP code here.', 'your-textdomain-here' ),
48
-				'mode'       => 'php',
49
-				'theme'      => 'chrome',
50
-				'desc'       => 'Possible modes can be found at <a href="//ace.c9.io" target="_blank">ace.c9.io/</a>.',
51
-				'default'    => '<?php
31
+            ),
32
+            array(
33
+                'id'       => 'opt-ace-editor-js',
34
+                'type'     => 'ace_editor',
35
+                'title'    => esc_html__( 'JS Code', 'your-textdomain-here' ),
36
+                'subtitle' => esc_html__( 'Paste your JS code here.', 'your-textdomain-here' ),
37
+                'mode'     => 'javascript',
38
+                'theme'    => 'chrome',
39
+                'desc'     => 'Possible modes can be found at <a href="//ace.c9.io" target="_blank">ace.c9.io/</a>.',
40
+                'default'  => 'jQuery(document).ready(function(){\n\n});',
41
+            ),
42
+            array(
43
+                'id'         => 'opt-ace-editor-php',
44
+                'type'       => 'ace_editor',
45
+                'full_width' => true,
46
+                'title'      => esc_html__( 'PHP Code', 'your-textdomain-here' ),
47
+                'subtitle'   => esc_html__( 'Paste your PHP code here.', 'your-textdomain-here' ),
48
+                'mode'       => 'php',
49
+                'theme'      => 'chrome',
50
+                'desc'       => 'Possible modes can be found at <a href="//ace.c9.io" target="_blank">ace.c9.io/</a>.',
51
+                'default'    => '<?php
52 52
     echo "PHP String";',
53
-			),
54
-		),
55
-	)
53
+            ),
54
+        ),
55
+    )
56 56
 );
57 57
 // phpcs:enable
Please login to merge, or discard this patch.
sample/sections/color-selection/color-palette.php 1 patch
Indentation   +86 added lines, -86 removed lines patch added patch discarded remove patch
@@ -11,91 +11,91 @@
 block discarded – undo
11 11
 defined( 'ABSPATH' ) || exit;
12 12
 
13 13
 Redux::set_section(
14
-	$opt_name,
15
-	array(
16
-		'title'      => esc_html__( 'Color Palette', 'your-textdomain-here' ),
17
-		'desc'       => esc_html__( 'For full documentation on this field, visit: ', 'your-textdomain-here' ) . '<a href="https://devs.redux.io/core-fields/color-palette.html" target="_blank">https://devs.redux.io/core-fields/palette-color.html</a>',
18
-		'id'         => 'color-palette',
19
-		'subsection' => true,
20
-		'fields'     => array(
21
-			array(
22
-				'id'       => 'opt-color-palette-grey',
23
-				'type'     => 'color_palette',
24
-				'title'    => esc_html__( 'Color Palette Control', 'your-textdomain-here' ),
25
-				'subtitle' => esc_html__( 'User defined colors with round selectors.', 'your-textdomain-here' ),
26
-				'desc'     => esc_html__( 'Set the Widget Title color here.', 'your-textdomain-here' ),
27
-				'default'  => '#888888',
28
-				'options'  => array(
29
-					'colors' => array(
30
-						'#000000',
31
-						'#222222',
32
-						'#444444',
33
-						'#666666',
34
-						'#888888',
35
-						'#aaaaaa',
36
-						'#cccccc',
37
-						'#eeeeee',
38
-						'#ffffff',
39
-					),
40
-					'style'  => 'round',
41
-				),
42
-				'output'   => array(
43
-					'color'     => '.widget-title',
44
-					'important' => true,
45
-				),
46
-			),
47
-			array(
48
-				'id'       => 'opt-color-palette-mui-all',
49
-				'type'     => 'color_palette',
50
-				'title'    => esc_html__( 'Color Palette Control', 'your-textdomain-here' ),
51
-				'subtitle' => esc_html__( 'All Material Design Colors.', 'your-textdomain-here' ),
52
-				'desc'     => esc_html__( 'This is the description field, again good for additional info.', 'your-textdomain-here' ),
53
-				'default'  => '#F44336',
54
-				'options'  => array(
55
-					'colors' => Redux_Helpers::get_material_design_colors( 'all' ),
56
-					'size'   => 17,
57
-				),
58
-			),
59
-			array(
60
-				'id'       => 'opt-color-palette-mui-primary',
61
-				'type'     => 'color_palette',
62
-				'title'    => esc_html__( 'Color Palette Control', 'your-textdomain-here' ),
63
-				'subtitle' => esc_html__( 'Primary Material Design Colors.', 'your-textdomain-here' ),
64
-				'desc'     => esc_html__( 'This is the description field, again good for additional info.', 'your-textdomain-here' ),
65
-				'default'  => '#000000',
66
-				'options'  => array(
67
-					'colors'     => Redux_Helpers::get_material_design_colors(),
68
-					'size'       => 25,
69
-					'box-shadow' => true,
70
-					'margin'     => true,
71
-				),
72
-			),
73
-			array(
74
-				'id'       => 'opt-color-palette-mui-red',
75
-				'type'     => 'color_palette',
76
-				'title'    => esc_html__( 'Color Palette Control', 'your-textdomain-here' ),
77
-				'subtitle' => esc_html__( 'Red Material Design Colors.', 'your-textdomain-here' ),
78
-				'desc'     => esc_html__( 'This is the description field, again good for additional info.', 'your-textdomain-here' ),
79
-				'default'  => '#FF1744',
80
-				'options'  => array(
81
-					'colors' => Redux_Helpers::get_material_design_colors( 'red' ),
82
-					'size'   => 25,
83
-				),
84
-			),
85
-			array(
86
-				'id'       => 'opt-color-palette-mui-a100',
87
-				'type'     => 'color_palette',
88
-				'title'    => esc_html__( 'Color Palette Control', 'your-textdomain-here' ),
89
-				'subtitle' => esc_html__( 'A100 Material Design Colors.', 'your-textdomain-here' ),
90
-				'desc'     => esc_html__( 'This is the description field, again good for additional info.', 'your-textdomain-here' ),
91
-				'default'  => '#FF80AB',
92
-				'options'  => array(
93
-					'colors' => Redux_Helpers::get_material_design_colors( 'A100' ),
94
-					'size'   => 60,
95
-					'style'  => 'round',
96
-				),
97
-			),
98
-		),
99
-	)
14
+    $opt_name,
15
+    array(
16
+        'title'      => esc_html__( 'Color Palette', 'your-textdomain-here' ),
17
+        'desc'       => esc_html__( 'For full documentation on this field, visit: ', 'your-textdomain-here' ) . '<a href="https://devs.redux.io/core-fields/color-palette.html" target="_blank">https://devs.redux.io/core-fields/palette-color.html</a>',
18
+        'id'         => 'color-palette',
19
+        'subsection' => true,
20
+        'fields'     => array(
21
+            array(
22
+                'id'       => 'opt-color-palette-grey',
23
+                'type'     => 'color_palette',
24
+                'title'    => esc_html__( 'Color Palette Control', 'your-textdomain-here' ),
25
+                'subtitle' => esc_html__( 'User defined colors with round selectors.', 'your-textdomain-here' ),
26
+                'desc'     => esc_html__( 'Set the Widget Title color here.', 'your-textdomain-here' ),
27
+                'default'  => '#888888',
28
+                'options'  => array(
29
+                    'colors' => array(
30
+                        '#000000',
31
+                        '#222222',
32
+                        '#444444',
33
+                        '#666666',
34
+                        '#888888',
35
+                        '#aaaaaa',
36
+                        '#cccccc',
37
+                        '#eeeeee',
38
+                        '#ffffff',
39
+                    ),
40
+                    'style'  => 'round',
41
+                ),
42
+                'output'   => array(
43
+                    'color'     => '.widget-title',
44
+                    'important' => true,
45
+                ),
46
+            ),
47
+            array(
48
+                'id'       => 'opt-color-palette-mui-all',
49
+                'type'     => 'color_palette',
50
+                'title'    => esc_html__( 'Color Palette Control', 'your-textdomain-here' ),
51
+                'subtitle' => esc_html__( 'All Material Design Colors.', 'your-textdomain-here' ),
52
+                'desc'     => esc_html__( 'This is the description field, again good for additional info.', 'your-textdomain-here' ),
53
+                'default'  => '#F44336',
54
+                'options'  => array(
55
+                    'colors' => Redux_Helpers::get_material_design_colors( 'all' ),
56
+                    'size'   => 17,
57
+                ),
58
+            ),
59
+            array(
60
+                'id'       => 'opt-color-palette-mui-primary',
61
+                'type'     => 'color_palette',
62
+                'title'    => esc_html__( 'Color Palette Control', 'your-textdomain-here' ),
63
+                'subtitle' => esc_html__( 'Primary Material Design Colors.', 'your-textdomain-here' ),
64
+                'desc'     => esc_html__( 'This is the description field, again good for additional info.', 'your-textdomain-here' ),
65
+                'default'  => '#000000',
66
+                'options'  => array(
67
+                    'colors'     => Redux_Helpers::get_material_design_colors(),
68
+                    'size'       => 25,
69
+                    'box-shadow' => true,
70
+                    'margin'     => true,
71
+                ),
72
+            ),
73
+            array(
74
+                'id'       => 'opt-color-palette-mui-red',
75
+                'type'     => 'color_palette',
76
+                'title'    => esc_html__( 'Color Palette Control', 'your-textdomain-here' ),
77
+                'subtitle' => esc_html__( 'Red Material Design Colors.', 'your-textdomain-here' ),
78
+                'desc'     => esc_html__( 'This is the description field, again good for additional info.', 'your-textdomain-here' ),
79
+                'default'  => '#FF1744',
80
+                'options'  => array(
81
+                    'colors' => Redux_Helpers::get_material_design_colors( 'red' ),
82
+                    'size'   => 25,
83
+                ),
84
+            ),
85
+            array(
86
+                'id'       => 'opt-color-palette-mui-a100',
87
+                'type'     => 'color_palette',
88
+                'title'    => esc_html__( 'Color Palette Control', 'your-textdomain-here' ),
89
+                'subtitle' => esc_html__( 'A100 Material Design Colors.', 'your-textdomain-here' ),
90
+                'desc'     => esc_html__( 'This is the description field, again good for additional info.', 'your-textdomain-here' ),
91
+                'default'  => '#FF80AB',
92
+                'options'  => array(
93
+                    'colors' => Redux_Helpers::get_material_design_colors( 'A100' ),
94
+                    'size'   => 60,
95
+                    'style'  => 'round',
96
+                ),
97
+            ),
98
+        ),
99
+    )
100 100
 );
101 101
 // phpcs:enable
Please login to merge, or discard this patch.
sample/sections/color-selection/link-color.php 1 patch
Indentation   +30 added lines, -30 removed lines patch added patch discarded remove patch
@@ -10,36 +10,36 @@
 block discarded – undo
10 10
 defined( 'ABSPATH' ) || exit;
11 11
 
12 12
 Redux::set_section(
13
-	$opt_name,
14
-	array(
15
-		'title'      => esc_html__( 'Link Color', 'your-textdomain-here' ),
16
-		'desc'       => esc_html__( 'For full documentation on this field, visit: ', 'your-textdomain-here' ) . '<a href="https://devs.redux.io/core-fields/link-color.html" target="_blank">https://devs.redux.io/core-fields/link-color.html</a>',
17
-		'id'         => 'color-link',
18
-		'subsection' => true,
19
-		'fields'     => array(
20
-			array(
21
-				'id'       => 'opt-link-color',
22
-				'type'     => 'link_color',
23
-				'title'    => esc_html__( 'Links Color Option', 'your-textdomain-here' ),
24
-				'subtitle' => esc_html__( 'Only color validation can be done on this field type', 'your-textdomain-here' ),
25
-				'desc'     => esc_html__( 'This is the description field, again good for additional info.', 'your-textdomain-here' ),
26
-				'default'  => array(
27
-					'regular' => '#aaa',
28
-					'hover'   => '#bbb',
29
-					'active'  => '#ccc',
30
-				),
31
-				'output'   => array(
32
-					'a',
33
-					'important' => true,
34
-				),
13
+    $opt_name,
14
+    array(
15
+        'title'      => esc_html__( 'Link Color', 'your-textdomain-here' ),
16
+        'desc'       => esc_html__( 'For full documentation on this field, visit: ', 'your-textdomain-here' ) . '<a href="https://devs.redux.io/core-fields/link-color.html" target="_blank">https://devs.redux.io/core-fields/link-color.html</a>',
17
+        'id'         => 'color-link',
18
+        'subsection' => true,
19
+        'fields'     => array(
20
+            array(
21
+                'id'       => 'opt-link-color',
22
+                'type'     => 'link_color',
23
+                'title'    => esc_html__( 'Links Color Option', 'your-textdomain-here' ),
24
+                'subtitle' => esc_html__( 'Only color validation can be done on this field type', 'your-textdomain-here' ),
25
+                'desc'     => esc_html__( 'This is the description field, again good for additional info.', 'your-textdomain-here' ),
26
+                'default'  => array(
27
+                    'regular' => '#aaa',
28
+                    'hover'   => '#bbb',
29
+                    'active'  => '#ccc',
30
+                ),
31
+                'output'   => array(
32
+                    'a',
33
+                    'important' => true,
34
+                ),
35 35
 
36
-				// phpcs:ignore Squiz.PHP.CommentedOutCode
37
-				// 'regular'   => false, // Disable Regular Color.
38
-				// 'hover'     => false, // Disable Hover Color.
39
-				// 'active'    => false, // Disable Active Color.
40
-				// 'visited'   => true,  // Enable Visited Color.
41
-			),
42
-		),
43
-	)
36
+                // phpcs:ignore Squiz.PHP.CommentedOutCode
37
+                // 'regular'   => false, // Disable Regular Color.
38
+                // 'hover'     => false, // Disable Hover Color.
39
+                // 'active'    => false, // Disable Active Color.
40
+                // 'visited'   => true,  // Enable Visited Color.
41
+            ),
42
+        ),
43
+    )
44 44
 );
45 45
 // phpcs:enable
Please login to merge, or discard this patch.
sample/sections/color-selection/color-rgba.php 1 patch
Indentation   +23 added lines, -23 removed lines patch added patch discarded remove patch
@@ -10,28 +10,28 @@
 block discarded – undo
10 10
 defined( 'ABSPATH' ) || exit;
11 11
 
12 12
 Redux::set_section(
13
-	$opt_name,
14
-	array(
15
-		'title'      => esc_html__( 'Color RGBA', 'your-textdomain-here' ),
16
-		'desc'       => esc_html__( 'For full documentation on this field, visit: ', 'your-textdomain-here' ) . '<a href="https://devs.redux.io/core-fields/color-rgba.html" target="_blank">https://devs.redux.io/core-fields/color-rgba.html</a>',
17
-		'id'         => 'color-rgba',
18
-		'subsection' => true,
19
-		'fields'     => array(
20
-			array(
21
-				'id'       => 'opt-color-rgba',
22
-				'type'     => 'color_rgba',
23
-				'title'    => esc_html__( 'Color RGBA', 'your-textdomain-here' ),
24
-				'subtitle' => esc_html__( 'Gives you the RGBA color.', 'your-textdomain-here' ),
25
-				'default'  => array(
26
-					'color' => '#7e33dd',
27
-					'alpha' => .8,
28
-				),
29
-				'output'   => array(
30
-					'color'     => '.posted-on, .wp-block-post-date a',
31
-					'important' => true,
32
-				),
33
-			),
34
-		),
35
-	)
13
+    $opt_name,
14
+    array(
15
+        'title'      => esc_html__( 'Color RGBA', 'your-textdomain-here' ),
16
+        'desc'       => esc_html__( 'For full documentation on this field, visit: ', 'your-textdomain-here' ) . '<a href="https://devs.redux.io/core-fields/color-rgba.html" target="_blank">https://devs.redux.io/core-fields/color-rgba.html</a>',
17
+        'id'         => 'color-rgba',
18
+        'subsection' => true,
19
+        'fields'     => array(
20
+            array(
21
+                'id'       => 'opt-color-rgba',
22
+                'type'     => 'color_rgba',
23
+                'title'    => esc_html__( 'Color RGBA', 'your-textdomain-here' ),
24
+                'subtitle' => esc_html__( 'Gives you the RGBA color.', 'your-textdomain-here' ),
25
+                'default'  => array(
26
+                    'color' => '#7e33dd',
27
+                    'alpha' => .8,
28
+                ),
29
+                'output'   => array(
30
+                    'color'     => '.posted-on, .wp-block-post-date a',
31
+                    'important' => true,
32
+                ),
33
+            ),
34
+        ),
35
+    )
36 36
 );
37 37
 // phpcs:enable
Please login to merge, or discard this patch.
sample/sections/color-selection/color-gradient.php 1 patch
Indentation   +29 added lines, -29 removed lines patch added patch discarded remove patch
@@ -10,34 +10,34 @@
 block discarded – undo
10 10
 defined( 'ABSPATH' ) || exit;
11 11
 
12 12
 Redux::set_section(
13
-	$opt_name,
14
-	array(
15
-		'title'      => esc_html__( 'Color Gradient', 'your-textdomain-here' ),
16
-		'desc'       => esc_html__( 'For full documentation on this field, visit: ', 'your-textdomain-here' ) . '<a href="https://devs.redux.io/core-fields/color-gradient.html" target="_blank">https://devs.redux.io/core-fields/color-gradient.html</a>',
17
-		'id'         => 'color-gradient',
18
-		'subsection' => true,
19
-		'fields'     => array(
20
-			array(
21
-				'id'             => 'opt-color-header',
22
-				'type'           => 'color_gradient',
23
-				'title'          => esc_html__( 'Header Gradient Color Option', 'your-textdomain-here' ),
24
-				'subtitle'       => esc_html__( 'Only color validation can be done on this field type', 'your-textdomain-here' ),
25
-				'desc'           => esc_html__( 'This is the description field, again good for additional info.', 'your-textdomain-here' ),
26
-				'output'         => '.site-header, header',
27
-				'gradient-type'  => true,
28
-				'gradient-reach' => true,
29
-				'gradient-angle' => true,
30
-				'preview'        => true,
31
-				'default'        => array(
32
-					'from'           => '#1e73be',
33
-					'to'             => '#00897e',
34
-					'gradient-reach' => array(
35
-						'to'   => 50,
36
-						'from' => 0,
37
-					),
38
-				),
39
-			),
40
-		),
41
-	)
13
+    $opt_name,
14
+    array(
15
+        'title'      => esc_html__( 'Color Gradient', 'your-textdomain-here' ),
16
+        'desc'       => esc_html__( 'For full documentation on this field, visit: ', 'your-textdomain-here' ) . '<a href="https://devs.redux.io/core-fields/color-gradient.html" target="_blank">https://devs.redux.io/core-fields/color-gradient.html</a>',
17
+        'id'         => 'color-gradient',
18
+        'subsection' => true,
19
+        'fields'     => array(
20
+            array(
21
+                'id'             => 'opt-color-header',
22
+                'type'           => 'color_gradient',
23
+                'title'          => esc_html__( 'Header Gradient Color Option', 'your-textdomain-here' ),
24
+                'subtitle'       => esc_html__( 'Only color validation can be done on this field type', 'your-textdomain-here' ),
25
+                'desc'           => esc_html__( 'This is the description field, again good for additional info.', 'your-textdomain-here' ),
26
+                'output'         => '.site-header, header',
27
+                'gradient-type'  => true,
28
+                'gradient-reach' => true,
29
+                'gradient-angle' => true,
30
+                'preview'        => true,
31
+                'default'        => array(
32
+                    'from'           => '#1e73be',
33
+                    'to'             => '#00897e',
34
+                    'gradient-reach' => array(
35
+                        'to'   => 50,
36
+                        'from' => 0,
37
+                    ),
38
+                ),
39
+            ),
40
+        ),
41
+    )
42 42
 );
43 43
 // phpcs:enable
Please login to merge, or discard this patch.
sample/sections/color-selection/color.php 1 patch
Indentation   +35 added lines, -35 removed lines patch added patch discarded remove patch
@@ -10,40 +10,40 @@
 block discarded – undo
10 10
 defined( 'ABSPATH' ) || exit;
11 11
 
12 12
 Redux::set_section(
13
-	$opt_name,
14
-	array(
15
-		'title'      => esc_html__( 'Color', 'your-textdomain-here' ),
16
-		'id'         => 'opt-color',
17
-		'desc'       => esc_html__( 'For full documentation on this field, visit: ', 'your-textdomain-here' ) . '<a href="https://devs.redux.io/core-fields/color.html" target="_blank">https://devs.redux.io/core-fields/color.html</a>',
18
-		'subsection' => true,
19
-		'fields'     => array(
20
-			array(
21
-				'id'          => 'opt-color-title',
22
-				'type'        => 'color',
23
-				'output'      => array(
24
-					'color'     => '.site-title, .wp-block-site-title a',
25
-					'important' => true,
26
-				),
27
-				'title'       => esc_html__( 'Site Title Color', 'your-textdomain-here' ),
28
-				'subtitle'    => esc_html__( 'Pick a title color for the theme (default: #000).', 'your-textdomain-here' ),
29
-				'default'     => '#000000',
30
-				// 'color_alpha' => true,
31
-				'transparent' => false,
32
-				'validate'    => 'color',
33
-			),
34
-			array(
35
-				'id'          => 'opt-color-footer',
36
-				'type'        => 'color',
37
-				'title'       => esc_html__( 'Footer Background Color', 'your-textdomain-here' ),
38
-				'subtitle'    => esc_html__( 'Pick a background color for the footer (default: #dd9933).', 'your-textdomain-here' ),
39
-				'default'     => '#dd9933',
40
-				'transparent' => false,
41
-				'validate'    => 'color',
42
-				'output'      => array(
43
-					'background-color' => '.footer, #site-footer, .site-footer, footer',
44
-				),
45
-			),
46
-		),
47
-	)
13
+    $opt_name,
14
+    array(
15
+        'title'      => esc_html__( 'Color', 'your-textdomain-here' ),
16
+        'id'         => 'opt-color',
17
+        'desc'       => esc_html__( 'For full documentation on this field, visit: ', 'your-textdomain-here' ) . '<a href="https://devs.redux.io/core-fields/color.html" target="_blank">https://devs.redux.io/core-fields/color.html</a>',
18
+        'subsection' => true,
19
+        'fields'     => array(
20
+            array(
21
+                'id'          => 'opt-color-title',
22
+                'type'        => 'color',
23
+                'output'      => array(
24
+                    'color'     => '.site-title, .wp-block-site-title a',
25
+                    'important' => true,
26
+                ),
27
+                'title'       => esc_html__( 'Site Title Color', 'your-textdomain-here' ),
28
+                'subtitle'    => esc_html__( 'Pick a title color for the theme (default: #000).', 'your-textdomain-here' ),
29
+                'default'     => '#000000',
30
+                // 'color_alpha' => true,
31
+                'transparent' => false,
32
+                'validate'    => 'color',
33
+            ),
34
+            array(
35
+                'id'          => 'opt-color-footer',
36
+                'type'        => 'color',
37
+                'title'       => esc_html__( 'Footer Background Color', 'your-textdomain-here' ),
38
+                'subtitle'    => esc_html__( 'Pick a background color for the footer (default: #dd9933).', 'your-textdomain-here' ),
39
+                'default'     => '#dd9933',
40
+                'transparent' => false,
41
+                'validate'    => 'color',
42
+                'output'      => array(
43
+                    'background-color' => '.footer, #site-footer, .site-footer, footer',
44
+                ),
45
+            ),
46
+        ),
47
+    )
48 48
 );
49 49
 // phpcs:enable
Please login to merge, or discard this patch.
sample/sections/color-selection/palette.php 1 patch
Indentation   +38 added lines, -38 removed lines patch added patch discarded remove patch
@@ -10,43 +10,43 @@
 block discarded – undo
10 10
 defined( 'ABSPATH' ) || exit;
11 11
 
12 12
 Redux::set_section(
13
-	$opt_name,
14
-	array(
15
-		'title'      => esc_html__( 'Palette', 'your-textdomain-here' ),
16
-		'desc'       => esc_html__( 'For full documentation on this field, visit: ', 'your-textdomain-here' ) . '<a href="https://devs.redux.io/core-fields/palette-color.html" target="_blank">https://devs.redux.io/core-fields/palette-color.html</a>',
17
-		'id'         => 'palette',
18
-		'subsection' => true,
19
-		'fields'     => array(
20
-			array(
21
-				'id'       => 'opt-palette-color',
22
-				'type'     => 'palette',
23
-				'title'    => esc_html__( 'Palette Color Option', 'your-textdomain-here' ),
24
-				'subtitle' => esc_html__( 'Only color validation can be done on this field type', 'your-textdomain-here' ),
25
-				'desc'     => esc_html__( 'This is the description field, again good for additional info.', 'your-textdomain-here' ),
26
-				'default'  => 'red',
27
-				'palettes' => array(
28
-					'red'  => array(
29
-						'#ef9a9a',
30
-						'#f44336',
31
-						'#ff1744',
32
-					),
33
-					'pink' => array(
34
-						'#fce4ec',
35
-						'#f06292',
36
-						'#e91e63',
37
-						'#ad1457',
38
-						'#f50057',
39
-					),
40
-					'cyan' => array(
41
-						'#e0f7fa',
42
-						'#80deea',
43
-						'#26c6da',
44
-						'#0097a7',
45
-						'#00e5ff',
46
-					),
47
-				),
48
-			),
49
-		),
50
-	)
13
+    $opt_name,
14
+    array(
15
+        'title'      => esc_html__( 'Palette', 'your-textdomain-here' ),
16
+        'desc'       => esc_html__( 'For full documentation on this field, visit: ', 'your-textdomain-here' ) . '<a href="https://devs.redux.io/core-fields/palette-color.html" target="_blank">https://devs.redux.io/core-fields/palette-color.html</a>',
17
+        'id'         => 'palette',
18
+        'subsection' => true,
19
+        'fields'     => array(
20
+            array(
21
+                'id'       => 'opt-palette-color',
22
+                'type'     => 'palette',
23
+                'title'    => esc_html__( 'Palette Color Option', 'your-textdomain-here' ),
24
+                'subtitle' => esc_html__( 'Only color validation can be done on this field type', 'your-textdomain-here' ),
25
+                'desc'     => esc_html__( 'This is the description field, again good for additional info.', 'your-textdomain-here' ),
26
+                'default'  => 'red',
27
+                'palettes' => array(
28
+                    'red'  => array(
29
+                        '#ef9a9a',
30
+                        '#f44336',
31
+                        '#ff1744',
32
+                    ),
33
+                    'pink' => array(
34
+                        '#fce4ec',
35
+                        '#f06292',
36
+                        '#e91e63',
37
+                        '#ad1457',
38
+                        '#f50057',
39
+                    ),
40
+                    'cyan' => array(
41
+                        '#e0f7fa',
42
+                        '#80deea',
43
+                        '#26c6da',
44
+                        '#0097a7',
45
+                        '#00e5ff',
46
+                    ),
47
+                ),
48
+            ),
49
+        ),
50
+    )
51 51
 );
52 52
 // phpcs:enable
Please login to merge, or discard this patch.
sample/sections/extensions/users.php 2 patches
Indentation   +189 added lines, -189 removed lines patch added patch discarded remove patch
@@ -10,206 +10,206 @@
 block discarded – undo
10 10
 defined( 'ABSPATH' ) || exit;
11 11
 
12 12
 if ( ! class_exists( 'Redux_Users' ) ) {
13
-	return;
13
+    return;
14 14
 }
15 15
 
16 16
 // Change the priority the Redux_Users boxes appear.
17 17
 Redux_Users::set_Args(
18
-	$opt_name,
19
-	array(
20
-		'user_priority' => 50,
21
-	)
18
+    $opt_name,
19
+    array(
20
+        'user_priority' => 50,
21
+    )
22 22
 );
23 23
 
24 24
 Redux_Users::set_profile(
25
-	$opt_name,
26
-	array(
27
-		'id'       => 'demo-users',
28
-		'title'    => esc_html__( 'Cool Options', 'your-textdomain-here' ),
29
-		'style'    => 'wp',
30
-		'sections' => array(
31
-			array(
32
-				'title'  => esc_html__( 'User Settings', 'your-textdomain-here' ),
33
-				'icon'   => 'el-icon-home',
34
-				'fields' => array(
35
-					array(
36
-						'id'    => 'user-text',
37
-						'type'  => 'text',
38
-						'title' => esc_html__( 'Input 1', 'your-textdomain-here' ),
39
-					),
40
-					array(
41
-						'id'    => 'user-text-2',
42
-						'type'  => 'text',
43
-						'title' => esc_html__( 'Input 2', 'your-textdomain-here' ),
44
-					),
45
-					array(
46
-						'id'    => 'user-text-3',
47
-						'type'  => 'text',
48
-						'title' => esc_html__( 'Input 3', 'your-textdomain-here' ),
49
-					),
50
-					array(
51
-						'id'       => 'user-web-fonts',
52
-						'type'     => 'media',
53
-						'title'    => esc_html__( 'Web Fonts', 'your-textdomain-here' ),
54
-						'compiler' => 'true',
55
-						'mode'     => false,
56
-						// Can be set to false allowing for any media type, or can also be set to any mime type.
57
-						'desc'     => esc_html__( 'Basic media uploader with disabled URL input field.', 'your-textdomain-here' ),
58
-						'subtitle' => esc_html__( 'Upload any media using the WordPress native uploader', 'your-textdomain-here' ),
59
-					),
60
-					array(
61
-						'id'       => 'user-section-media-start',
62
-						'type'     => 'section',
63
-						'title'    => esc_html__( 'Media Options', 'your-textdomain-here' ),
64
-						'subtitle' => esc_html__( 'With the "section" field you can create indent option sections.', 'your-textdomain-here' ),
65
-						'indent'   => true,
66
-					),
67
-					array(
68
-						'id'       => 'user-mediaurl',
69
-						'type'     => 'media',
70
-						'url'      => true,
71
-						'title'    => esc_html__( 'Media w/ URL', 'your-textdomain-here' ),
72
-						'compiler' => 'true',
73
-						'desc'     => esc_html__( 'Basic media uploader with disabled URL input field.', 'your-textdomain-here' ),
74
-						'subtitle' => esc_html__( 'Upload any media using the WordPress native uploader', 'your-textdomain-here' ),
75
-						'default'  => array( 'url' => 'https://s.wordpress.org/style/images/codeispoetry.png' ),
76
-					),
77
-					array(
78
-						'id'     => 'user-section-media-end',
79
-						'type'   => 'section',
80
-						'indent' => false,
81
-					),
82
-					array(
83
-						'id'       => 'user-media-nourl',
84
-						'type'     => 'media',
85
-						'title'    => esc_html__( 'Media w/o URL', 'your-textdomain-here' ),
86
-						'desc'     => esc_html__( 'This represents the minimalistic view. It does not have the preview box or the display URL in an input box. ', 'your-textdomain-here' ),
87
-						'subtitle' => esc_html__( 'Upload any media using the WordPress native uploader', 'your-textdomain-here' ),
88
-					),
89
-					array(
90
-						'id'       => 'user-media-nopreview',
91
-						'type'     => 'media',
92
-						'preview'  => false,
93
-						'title'    => esc_html__( 'Media No Preview', 'your-textdomain-here' ),
94
-						'desc'     => esc_html__( 'This represents the minimalistic view. It does not have the preview box or the display URL in an input box. ', 'your-textdomain-here' ),
95
-						'subtitle' => esc_html__( 'Upload any media using the WordPress native uploader', 'your-textdomain-here' ),
96
-					),
97
-					array(
98
-						'id'       => 'user-gallery',
99
-						'type'     => 'gallery',
100
-						'title'    => esc_html__( 'Add/Edit Gallery', 'your-textdomain-here' ),
101
-						'subtitle' => esc_html__( 'Create a new Gallery by selecting existing or uploading new images using the WordPress native uploader', 'your-textdomain-here' ),
102
-						'desc'     => esc_html__( 'This is the description field, again good for additional info.', 'your-textdomain-here' ),
103
-					),
104
-					array(
105
-						'id'      => 'user-slider-one',
106
-						'type'    => 'slider',
107
-						'title'   => esc_html__( 'JQuery UI Slider Example 1', 'your-textdomain-here' ),
108
-						'desc'    => esc_html__( 'JQuery UI slider description. Min: 1, max: 500, step: 3, default value: 45', 'your-textdomain-here' ),
109
-						'default' => '46',
110
-						'min'     => '1',
111
-						'step'    => '3',
112
-						'max'     => '500',
113
-					),
114
-					array(
115
-						'id'      => 'user-slider-two',
116
-						'type'    => 'slider',
117
-						'title'   => esc_html__( 'JQuery UI Slider Example 2 w/ Steps (5)', 'your-textdomain-here' ),
118
-						'desc'    => esc_html__( 'JQuery UI slider description. Min: 0, max: 300, step: 5, default value: 75', 'your-textdomain-here' ),
119
-						'default' => '0',
120
-						'min'     => '0',
121
-						'step'    => '5',
122
-						'max'     => '300',
123
-					),
124
-					array(
125
-						'id'      => 'user-spinner',
126
-						'type'    => 'spinner',
127
-						'title'   => esc_html__( 'JQuery UI Spinner Example 1', 'your-textdomain-here' ),
128
-						'desc'    => esc_html__( 'JQuery UI spinner description. Min:20, max: 100, step:20, default value: 40', 'your-textdomain-here' ),
129
-						'default' => '40',
130
-						'min'     => '20',
131
-						'step'    => '20',
132
-						'max'     => '100',
133
-					),
134
-					array(
135
-						'id'       => 'user-switch-parent',
136
-						'type'     => 'switch',
137
-						'title'    => esc_html__( 'Switch - Nested Children, Enable to show', 'your-textdomain-here' ),
138
-						'subtitle' => esc_html__( 'Look, it\'s on! Also hidden child elements!', 'your-textdomain-here' ),
139
-						'default'  => 0,
140
-						'on'       => 'Enabled',
141
-						'off'      => 'Disabled',
142
-					),
143
-					array(
144
-						'id'       => 'user-switch-child',
145
-						'type'     => 'switch',
146
-						'required' => array( 'user-switch-parent', '=', '1' ),
147
-						'title'    => esc_html__( 'Switch - This and the next switch required for patterns to show', 'your-textdomain-here' ),
148
-						'subtitle' => esc_html__( 'Also called a "fold" parent.', 'your-textdomain-here' ),
149
-						'desc'     => esc_html__( 'Items set with a fold to this ID will hide unless this is set to the appropriate value.', 'your-textdomain-here' ),
150
-						'default'  => false,
151
-					),
152
-				),
153
-			),
154
-			array(
155
-				'title'  => esc_html__( 'Home Layout', 'your-textdomain-here' ),
156
-				'icon'   => 'el-icon-home',
157
-				'fields' => array(
158
-					array(
159
-						'id'       => 'user-homepage_blocks',
160
-						'type'     => 'sorter',
161
-						'title'    => 'Homepage Layout Manager',
162
-						'desc'     => 'Organize how you want the layout to appear on the homepage',
163
-						'compiler' => 'true',
164
-						'required' => array( 'layout', '=', '1' ),
165
-						'options'  => array(
166
-							'enabled'  => array(
167
-								'highlights' => 'Highlights',
168
-								'slider'     => 'Slider',
169
-								'staticpage' => 'Static Page',
170
-								'services'   => 'Services',
171
-							),
172
-							'disabled' => array(),
173
-						),
174
-					),
25
+    $opt_name,
26
+    array(
27
+        'id'       => 'demo-users',
28
+        'title'    => esc_html__( 'Cool Options', 'your-textdomain-here' ),
29
+        'style'    => 'wp',
30
+        'sections' => array(
31
+            array(
32
+                'title'  => esc_html__( 'User Settings', 'your-textdomain-here' ),
33
+                'icon'   => 'el-icon-home',
34
+                'fields' => array(
35
+                    array(
36
+                        'id'    => 'user-text',
37
+                        'type'  => 'text',
38
+                        'title' => esc_html__( 'Input 1', 'your-textdomain-here' ),
39
+                    ),
40
+                    array(
41
+                        'id'    => 'user-text-2',
42
+                        'type'  => 'text',
43
+                        'title' => esc_html__( 'Input 2', 'your-textdomain-here' ),
44
+                    ),
45
+                    array(
46
+                        'id'    => 'user-text-3',
47
+                        'type'  => 'text',
48
+                        'title' => esc_html__( 'Input 3', 'your-textdomain-here' ),
49
+                    ),
50
+                    array(
51
+                        'id'       => 'user-web-fonts',
52
+                        'type'     => 'media',
53
+                        'title'    => esc_html__( 'Web Fonts', 'your-textdomain-here' ),
54
+                        'compiler' => 'true',
55
+                        'mode'     => false,
56
+                        // Can be set to false allowing for any media type, or can also be set to any mime type.
57
+                        'desc'     => esc_html__( 'Basic media uploader with disabled URL input field.', 'your-textdomain-here' ),
58
+                        'subtitle' => esc_html__( 'Upload any media using the WordPress native uploader', 'your-textdomain-here' ),
59
+                    ),
60
+                    array(
61
+                        'id'       => 'user-section-media-start',
62
+                        'type'     => 'section',
63
+                        'title'    => esc_html__( 'Media Options', 'your-textdomain-here' ),
64
+                        'subtitle' => esc_html__( 'With the "section" field you can create indent option sections.', 'your-textdomain-here' ),
65
+                        'indent'   => true,
66
+                    ),
67
+                    array(
68
+                        'id'       => 'user-mediaurl',
69
+                        'type'     => 'media',
70
+                        'url'      => true,
71
+                        'title'    => esc_html__( 'Media w/ URL', 'your-textdomain-here' ),
72
+                        'compiler' => 'true',
73
+                        'desc'     => esc_html__( 'Basic media uploader with disabled URL input field.', 'your-textdomain-here' ),
74
+                        'subtitle' => esc_html__( 'Upload any media using the WordPress native uploader', 'your-textdomain-here' ),
75
+                        'default'  => array( 'url' => 'https://s.wordpress.org/style/images/codeispoetry.png' ),
76
+                    ),
77
+                    array(
78
+                        'id'     => 'user-section-media-end',
79
+                        'type'   => 'section',
80
+                        'indent' => false,
81
+                    ),
82
+                    array(
83
+                        'id'       => 'user-media-nourl',
84
+                        'type'     => 'media',
85
+                        'title'    => esc_html__( 'Media w/o URL', 'your-textdomain-here' ),
86
+                        'desc'     => esc_html__( 'This represents the minimalistic view. It does not have the preview box or the display URL in an input box. ', 'your-textdomain-here' ),
87
+                        'subtitle' => esc_html__( 'Upload any media using the WordPress native uploader', 'your-textdomain-here' ),
88
+                    ),
89
+                    array(
90
+                        'id'       => 'user-media-nopreview',
91
+                        'type'     => 'media',
92
+                        'preview'  => false,
93
+                        'title'    => esc_html__( 'Media No Preview', 'your-textdomain-here' ),
94
+                        'desc'     => esc_html__( 'This represents the minimalistic view. It does not have the preview box or the display URL in an input box. ', 'your-textdomain-here' ),
95
+                        'subtitle' => esc_html__( 'Upload any media using the WordPress native uploader', 'your-textdomain-here' ),
96
+                    ),
97
+                    array(
98
+                        'id'       => 'user-gallery',
99
+                        'type'     => 'gallery',
100
+                        'title'    => esc_html__( 'Add/Edit Gallery', 'your-textdomain-here' ),
101
+                        'subtitle' => esc_html__( 'Create a new Gallery by selecting existing or uploading new images using the WordPress native uploader', 'your-textdomain-here' ),
102
+                        'desc'     => esc_html__( 'This is the description field, again good for additional info.', 'your-textdomain-here' ),
103
+                    ),
104
+                    array(
105
+                        'id'      => 'user-slider-one',
106
+                        'type'    => 'slider',
107
+                        'title'   => esc_html__( 'JQuery UI Slider Example 1', 'your-textdomain-here' ),
108
+                        'desc'    => esc_html__( 'JQuery UI slider description. Min: 1, max: 500, step: 3, default value: 45', 'your-textdomain-here' ),
109
+                        'default' => '46',
110
+                        'min'     => '1',
111
+                        'step'    => '3',
112
+                        'max'     => '500',
113
+                    ),
114
+                    array(
115
+                        'id'      => 'user-slider-two',
116
+                        'type'    => 'slider',
117
+                        'title'   => esc_html__( 'JQuery UI Slider Example 2 w/ Steps (5)', 'your-textdomain-here' ),
118
+                        'desc'    => esc_html__( 'JQuery UI slider description. Min: 0, max: 300, step: 5, default value: 75', 'your-textdomain-here' ),
119
+                        'default' => '0',
120
+                        'min'     => '0',
121
+                        'step'    => '5',
122
+                        'max'     => '300',
123
+                    ),
124
+                    array(
125
+                        'id'      => 'user-spinner',
126
+                        'type'    => 'spinner',
127
+                        'title'   => esc_html__( 'JQuery UI Spinner Example 1', 'your-textdomain-here' ),
128
+                        'desc'    => esc_html__( 'JQuery UI spinner description. Min:20, max: 100, step:20, default value: 40', 'your-textdomain-here' ),
129
+                        'default' => '40',
130
+                        'min'     => '20',
131
+                        'step'    => '20',
132
+                        'max'     => '100',
133
+                    ),
134
+                    array(
135
+                        'id'       => 'user-switch-parent',
136
+                        'type'     => 'switch',
137
+                        'title'    => esc_html__( 'Switch - Nested Children, Enable to show', 'your-textdomain-here' ),
138
+                        'subtitle' => esc_html__( 'Look, it\'s on! Also hidden child elements!', 'your-textdomain-here' ),
139
+                        'default'  => 0,
140
+                        'on'       => 'Enabled',
141
+                        'off'      => 'Disabled',
142
+                    ),
143
+                    array(
144
+                        'id'       => 'user-switch-child',
145
+                        'type'     => 'switch',
146
+                        'required' => array( 'user-switch-parent', '=', '1' ),
147
+                        'title'    => esc_html__( 'Switch - This and the next switch required for patterns to show', 'your-textdomain-here' ),
148
+                        'subtitle' => esc_html__( 'Also called a "fold" parent.', 'your-textdomain-here' ),
149
+                        'desc'     => esc_html__( 'Items set with a fold to this ID will hide unless this is set to the appropriate value.', 'your-textdomain-here' ),
150
+                        'default'  => false,
151
+                    ),
152
+                ),
153
+            ),
154
+            array(
155
+                'title'  => esc_html__( 'Home Layout', 'your-textdomain-here' ),
156
+                'icon'   => 'el-icon-home',
157
+                'fields' => array(
158
+                    array(
159
+                        'id'       => 'user-homepage_blocks',
160
+                        'type'     => 'sorter',
161
+                        'title'    => 'Homepage Layout Manager',
162
+                        'desc'     => 'Organize how you want the layout to appear on the homepage',
163
+                        'compiler' => 'true',
164
+                        'required' => array( 'layout', '=', '1' ),
165
+                        'options'  => array(
166
+                            'enabled'  => array(
167
+                                'highlights' => 'Highlights',
168
+                                'slider'     => 'Slider',
169
+                                'staticpage' => 'Static Page',
170
+                                'services'   => 'Services',
171
+                            ),
172
+                            'disabled' => array(),
173
+                        ),
174
+                    ),
175 175
 
176
-					array(
177
-						'id'       => 'user-presets',
178
-						'type'     => 'image_select',
179
-						'presets'  => true,
180
-						'title'    => esc_html__( 'Preset', 'your-textdomain-here' ),
181
-						'subtitle' => esc_html__( 'This allows you to set a json string or array to override multiple preferences in your theme.', 'your-textdomain-here' ),
182
-						'default'  => 0,
183
-						'desc'     => esc_html__( 'This allows you to set a json string or array to override multiple preferences in your theme.', 'your-textdomain-here' ),
184
-						'options'  => array(
185
-							'1' => array(
186
-								'alt'     => 'Preset 1',
187
-								'img'     => Redux_Core::$url . '../sample/presets/preset1.png',
188
-								'presets' => array(
189
-									'switch-on'     => 1,
190
-									'switch-off'    => 1,
191
-									'switch-custom' => 1,
192
-								),
193
-							),
194
-							'2' => array(
195
-								'alt'     => 'Preset 2',
196
-								'img'     => Redux_Core::$url . '../sample/presets/preset2.png',
197
-								'presets' => "{'slider1':'1', 'slider2':'0', 'switch-on':'0'}",
198
-							),
199
-						),
200
-					),
201
-				),
202
-			),
203
-		),
204
-	)
176
+                    array(
177
+                        'id'       => 'user-presets',
178
+                        'type'     => 'image_select',
179
+                        'presets'  => true,
180
+                        'title'    => esc_html__( 'Preset', 'your-textdomain-here' ),
181
+                        'subtitle' => esc_html__( 'This allows you to set a json string or array to override multiple preferences in your theme.', 'your-textdomain-here' ),
182
+                        'default'  => 0,
183
+                        'desc'     => esc_html__( 'This allows you to set a json string or array to override multiple preferences in your theme.', 'your-textdomain-here' ),
184
+                        'options'  => array(
185
+                            '1' => array(
186
+                                'alt'     => 'Preset 1',
187
+                                'img'     => Redux_Core::$url . '../sample/presets/preset1.png',
188
+                                'presets' => array(
189
+                                    'switch-on'     => 1,
190
+                                    'switch-off'    => 1,
191
+                                    'switch-custom' => 1,
192
+                                ),
193
+                            ),
194
+                            '2' => array(
195
+                                'alt'     => 'Preset 2',
196
+                                'img'     => Redux_Core::$url . '../sample/presets/preset2.png',
197
+                                'presets' => "{'slider1':'1', 'slider2':'0', 'switch-on':'0'}",
198
+                            ),
199
+                        ),
200
+                    ),
201
+                ),
202
+            ),
203
+        ),
204
+    )
205 205
 );
206 206
 
207 207
 // Recovering user data.
208 208
 $data = Redux_Users::get_user_meta(
209
-	array(
210
-		'key'      => 'user-text', /* If you're only looking for a key within the meta, otherwise all values will be returned. */
211
-		'opt_name' => $opt_name,   // Optional, but needed to recover default values for unset values.
212
-		'user'     => '',          // User id, else current user ID is returned.
213
-	)
209
+    array(
210
+        'key'      => 'user-text', /* If you're only looking for a key within the meta, otherwise all values will be returned. */
211
+        'opt_name' => $opt_name,   // Optional, but needed to recover default values for unset values.
212
+        'user'     => '',          // User id, else current user ID is returned.
213
+    )
214 214
 );
215 215
 // phpcs:enable
Please login to merge, or discard this patch.
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -208,8 +208,8 @@
 block discarded – undo
208 208
 $data = Redux_Users::get_user_meta(
209 209
 	array(
210 210
 		'key'      => 'user-text', /* If you're only looking for a key within the meta, otherwise all values will be returned. */
211
-		'opt_name' => $opt_name,   // Optional, but needed to recover default values for unset values.
212
-		'user'     => '',          // User id, else current user ID is returned.
211
+		'opt_name' => $opt_name, // Optional, but needed to recover default values for unset values.
212
+		'user'     => '', // User id, else current user ID is returned.
213 213
 	)
214 214
 );
215 215
 // phpcs:enable
Please login to merge, or discard this patch.
sample/sections/extensions/taxonomy.php 1 patch
Indentation   +201 added lines, -201 removed lines patch added patch discarded remove patch
@@ -10,219 +10,219 @@
 block discarded – undo
10 10
 defined( 'ABSPATH' ) || exit;
11 11
 
12 12
 if ( ! class_exists( 'Redux_Taxonomy' ) ) {
13
-	return;
13
+    return;
14 14
 }
15 15
 
16 16
 // Change the priority the Redux_Taxonomy boxes appear.
17 17
 Redux_Taxonomy::set_args(
18
-	$opt_name,
19
-	array(
20
-		'taxonomy_priority' => 55,
21
-	)
18
+    $opt_name,
19
+    array(
20
+        'taxonomy_priority' => 55,
21
+    )
22 22
 );
23 23
 
24 24
 Redux_Taxonomy::set_term(
25
-	$opt_name,
26
-	array(
27
-		'id'             => 'demo-taxonomy',
28
-		'title'          => esc_html__( 'Cool Options', 'your-textdomain-here' ),
25
+    $opt_name,
26
+    array(
27
+        'id'             => 'demo-taxonomy',
28
+        'title'          => esc_html__( 'Cool Options', 'your-textdomain-here' ),
29 29
 
30
-		// Slug for every taxonomy you want.
31
-		'taxonomy_types' => array( 'category', 'post_tag' ),
30
+        // Slug for every taxonomy you want.
31
+        'taxonomy_types' => array( 'category', 'post_tag' ),
32 32
 
33
-		'add_visibility' => true,
33
+        'add_visibility' => true,
34 34
 
35
-		// Can be set on term, section, or field level. Denote what fields to be displayed on the added {TERM} pages.
36
-		'sections'       => array(
37
-			array(
38
-				'title'  => esc_html__( 'Home Settings', 'your-textdomain-here' ),
39
-				'icon'   => 'el-icon-home',
40
-				'fields' => array(
41
-					array(
42
-						'id'             => 'tax-text',
43
-						'type'           => 'text',
44
-						'add_visibility' => true,
45
-						'title'          => esc_html__( 'Input 1', 'your-textdomain-here' ),
46
-					),
47
-					array(
48
-						'id'             => 'tax-button-set',
49
-						'type'           => 'button_set',
50
-						'title'          => esc_html__( 'Button Set Option', 'your-textdomain-here' ),
51
-						'subtitle'       => esc_html__( 'No validation can be done on this field type', 'your-textdomain-here' ),
52
-						'desc'           => esc_html__( 'This is the description field, again good for additional info.', 'your-textdomain-here' ),
53
-						'add_visibility' => true,
54
-						'options'        => array(
55
-							'1' => 'Opt 1',
56
-							'2' => 'Opt 2',
57
-							'3' => 'Opt 3',
58
-						),
59
-						'default'        => '2',
60
-					),
61
-					array(
62
-						'id'             => 'tax-text-2',
63
-						'type'           => 'text',
64
-						'add_visibility' => true,
65
-						'title'          => esc_html__( 'Input 2', 'your-textdomain-here' ),
66
-					),
67
-					array(
68
-						'id'       => 'tax-web-fonts',
69
-						'type'     => 'media',
70
-						'title'    => esc_html__( 'Web Fonts', 'your-textdomain-here' ),
71
-						'compiler' => 'true',
72
-						'mode'     => false,
73
-						// Can be set to false to allow any media type, or can also be set to any mime type.
74
-						'desc'     => esc_html__( 'Basic media uploader with disabled URL input field.', 'your-textdomain-here' ),
75
-						'subtitle' => esc_html__( 'Upload any media using the WordPress native uploader', 'your-textdomain-here' ),
76
-					),
77
-					array(
78
-						'id'       => 'tax-section-media-start',
79
-						'type'     => 'section',
80
-						'title'    => esc_html__( 'Media Options', 'your-textdomain-here' ),
81
-						'subtitle' => esc_html__( 'With the "section" field you can create indent option sections.', 'your-textdomain-here' ),
82
-						'indent'   => true,
83
-					),
84
-					array(
85
-						'id'       => 'tax-media-url',
86
-						'type'     => 'media',
87
-						'url'      => true,
88
-						'title'    => esc_html__( 'Media w/ URL', 'your-textdomain-here' ),
89
-						'compiler' => 'true',
90
-						'desc'     => esc_html__( 'Basic media uploader with disabled URL input field.', 'your-textdomain-here' ),
91
-						'subtitle' => esc_html__( 'Upload any media using the WordPress native uploader', 'your-textdomain-here' ),
92
-						'default'  => array( 'url' => 'https://s.wordpress.org/style/images/codeispoetry.png' ),
93
-					),
94
-					array(
95
-						'id'     => 'tax-section-media-end',
96
-						'type'   => 'section',
97
-						'indent' => false,
98
-					),
99
-					array(
100
-						'id'       => 'tax-media-no-url',
101
-						'type'     => 'media',
102
-						'title'    => esc_html__( 'Media w/o URL', 'your-textdomain-here' ),
103
-						'desc'     => esc_html__( 'This represents the minimalistic view. It does not have the preview box or the display URL in an input box. ', 'your-textdomain-here' ),
104
-						'subtitle' => esc_html__( 'Upload any media using the WordPress native uploader', 'your-textdomain-here' ),
105
-					),
106
-					array(
107
-						'id'       => 'tax-media-no-preview',
108
-						'type'     => 'media',
109
-						'preview'  => false,
110
-						'title'    => esc_html__( 'Media No Preview', 'your-textdomain-here' ),
111
-						'desc'     => esc_html__( 'This represents the minimalistic view. It does not have the preview box or the display URL in an input box. ', 'your-textdomain-here' ),
112
-						'subtitle' => esc_html__( 'Upload any media using the WordPress native uploader', 'your-textdomain-here' ),
113
-					),
114
-					array(
115
-						'id'       => 'tax-gallery',
116
-						'type'     => 'gallery',
117
-						'title'    => esc_html__( 'Add/Edit Gallery', 'your-textdomain-here' ),
118
-						'subtitle' => esc_html__( 'Create a new Gallery by selecting existing or uploading new images using the WordPress native uploader', 'your-textdomain-here' ),
119
-						'desc'     => esc_html__( 'This is the description field, again good for additional info.', 'your-textdomain-here' ),
120
-					),
121
-					array(
122
-						'id'      => 'tax-slider',
123
-						'type'    => 'slider',
124
-						'title'   => esc_html__( 'JQuery UI Slider Example 1', 'your-textdomain-here' ),
125
-						'desc'    => esc_html__( 'JQuery UI slider description. Min: 1, max: 500, step: 3, default value: 45', 'your-textdomain-here' ),
126
-						'default' => '46',
127
-						'min'     => '1',
128
-						'step'    => '3',
129
-						'max'     => '500',
130
-					),
131
-					array(
132
-						'id'      => 'tax-slider-2',
133
-						'type'    => 'slider',
134
-						'title'   => esc_html__( 'JQuery UI Slider Example 2 w/ Steps (5)', 'your-textdomain-here' ),
135
-						'desc'    => esc_html__( 'JQuery UI slider description. Min: 0, max: 300, step: 5, default value: 75', 'your-textdomain-here' ),
136
-						'default' => '0',
137
-						'min'     => '0',
138
-						'step'    => '5',
139
-						'max'     => '300',
140
-					),
141
-					array(
142
-						'id'      => 'tax-spinner',
143
-						'type'    => 'spinner',
144
-						'title'   => esc_html__( 'Spinner Example 1', 'your-textdomain-here' ),
145
-						'desc'    => esc_html__( 'Spinner description. Min:20, max: 100, step:20, default value: 40', 'your-textdomain-here' ),
146
-						'default' => '40',
147
-						'min'     => '20',
148
-						'step'    => '20',
149
-						'max'     => '100',
150
-					),
151
-					array(
152
-						'id'       => 'tax-switch-parent',
153
-						'type'     => 'switch',
154
-						'title'    => esc_html__( 'Switch - Nested Children, Enable to show', 'your-textdomain-here' ),
155
-						'subtitle' => esc_html__( 'Look, it\'s on! Also hidden child elements!', 'your-textdomain-here' ),
156
-						'default'  => 0,
157
-						'on'       => 'Enabled',
158
-						'off'      => 'Disabled',
159
-					),
160
-					array(
161
-						'id'       => 'tax-switch-child',
162
-						'type'     => 'switch',
163
-						'required' => array( 'tax-switch-parent', '=', '1' ),
164
-						'title'    => esc_html__( 'Switch - This and the next switch required for patterns to show', 'your-textdomain-here' ),
165
-						'subtitle' => esc_html__( 'Also called a "fold" parent.', 'your-textdomain-here' ),
166
-						'desc'     => esc_html__( 'Items set with a fold to this ID will hide unless this is set to the appropriate value.', 'your-textdomain-here' ),
167
-						'default'  => false,
168
-					),
169
-				),
170
-			),
35
+        // Can be set on term, section, or field level. Denote what fields to be displayed on the added {TERM} pages.
36
+        'sections'       => array(
37
+            array(
38
+                'title'  => esc_html__( 'Home Settings', 'your-textdomain-here' ),
39
+                'icon'   => 'el-icon-home',
40
+                'fields' => array(
41
+                    array(
42
+                        'id'             => 'tax-text',
43
+                        'type'           => 'text',
44
+                        'add_visibility' => true,
45
+                        'title'          => esc_html__( 'Input 1', 'your-textdomain-here' ),
46
+                    ),
47
+                    array(
48
+                        'id'             => 'tax-button-set',
49
+                        'type'           => 'button_set',
50
+                        'title'          => esc_html__( 'Button Set Option', 'your-textdomain-here' ),
51
+                        'subtitle'       => esc_html__( 'No validation can be done on this field type', 'your-textdomain-here' ),
52
+                        'desc'           => esc_html__( 'This is the description field, again good for additional info.', 'your-textdomain-here' ),
53
+                        'add_visibility' => true,
54
+                        'options'        => array(
55
+                            '1' => 'Opt 1',
56
+                            '2' => 'Opt 2',
57
+                            '3' => 'Opt 3',
58
+                        ),
59
+                        'default'        => '2',
60
+                    ),
61
+                    array(
62
+                        'id'             => 'tax-text-2',
63
+                        'type'           => 'text',
64
+                        'add_visibility' => true,
65
+                        'title'          => esc_html__( 'Input 2', 'your-textdomain-here' ),
66
+                    ),
67
+                    array(
68
+                        'id'       => 'tax-web-fonts',
69
+                        'type'     => 'media',
70
+                        'title'    => esc_html__( 'Web Fonts', 'your-textdomain-here' ),
71
+                        'compiler' => 'true',
72
+                        'mode'     => false,
73
+                        // Can be set to false to allow any media type, or can also be set to any mime type.
74
+                        'desc'     => esc_html__( 'Basic media uploader with disabled URL input field.', 'your-textdomain-here' ),
75
+                        'subtitle' => esc_html__( 'Upload any media using the WordPress native uploader', 'your-textdomain-here' ),
76
+                    ),
77
+                    array(
78
+                        'id'       => 'tax-section-media-start',
79
+                        'type'     => 'section',
80
+                        'title'    => esc_html__( 'Media Options', 'your-textdomain-here' ),
81
+                        'subtitle' => esc_html__( 'With the "section" field you can create indent option sections.', 'your-textdomain-here' ),
82
+                        'indent'   => true,
83
+                    ),
84
+                    array(
85
+                        'id'       => 'tax-media-url',
86
+                        'type'     => 'media',
87
+                        'url'      => true,
88
+                        'title'    => esc_html__( 'Media w/ URL', 'your-textdomain-here' ),
89
+                        'compiler' => 'true',
90
+                        'desc'     => esc_html__( 'Basic media uploader with disabled URL input field.', 'your-textdomain-here' ),
91
+                        'subtitle' => esc_html__( 'Upload any media using the WordPress native uploader', 'your-textdomain-here' ),
92
+                        'default'  => array( 'url' => 'https://s.wordpress.org/style/images/codeispoetry.png' ),
93
+                    ),
94
+                    array(
95
+                        'id'     => 'tax-section-media-end',
96
+                        'type'   => 'section',
97
+                        'indent' => false,
98
+                    ),
99
+                    array(
100
+                        'id'       => 'tax-media-no-url',
101
+                        'type'     => 'media',
102
+                        'title'    => esc_html__( 'Media w/o URL', 'your-textdomain-here' ),
103
+                        'desc'     => esc_html__( 'This represents the minimalistic view. It does not have the preview box or the display URL in an input box. ', 'your-textdomain-here' ),
104
+                        'subtitle' => esc_html__( 'Upload any media using the WordPress native uploader', 'your-textdomain-here' ),
105
+                    ),
106
+                    array(
107
+                        'id'       => 'tax-media-no-preview',
108
+                        'type'     => 'media',
109
+                        'preview'  => false,
110
+                        'title'    => esc_html__( 'Media No Preview', 'your-textdomain-here' ),
111
+                        'desc'     => esc_html__( 'This represents the minimalistic view. It does not have the preview box or the display URL in an input box. ', 'your-textdomain-here' ),
112
+                        'subtitle' => esc_html__( 'Upload any media using the WordPress native uploader', 'your-textdomain-here' ),
113
+                    ),
114
+                    array(
115
+                        'id'       => 'tax-gallery',
116
+                        'type'     => 'gallery',
117
+                        'title'    => esc_html__( 'Add/Edit Gallery', 'your-textdomain-here' ),
118
+                        'subtitle' => esc_html__( 'Create a new Gallery by selecting existing or uploading new images using the WordPress native uploader', 'your-textdomain-here' ),
119
+                        'desc'     => esc_html__( 'This is the description field, again good for additional info.', 'your-textdomain-here' ),
120
+                    ),
121
+                    array(
122
+                        'id'      => 'tax-slider',
123
+                        'type'    => 'slider',
124
+                        'title'   => esc_html__( 'JQuery UI Slider Example 1', 'your-textdomain-here' ),
125
+                        'desc'    => esc_html__( 'JQuery UI slider description. Min: 1, max: 500, step: 3, default value: 45', 'your-textdomain-here' ),
126
+                        'default' => '46',
127
+                        'min'     => '1',
128
+                        'step'    => '3',
129
+                        'max'     => '500',
130
+                    ),
131
+                    array(
132
+                        'id'      => 'tax-slider-2',
133
+                        'type'    => 'slider',
134
+                        'title'   => esc_html__( 'JQuery UI Slider Example 2 w/ Steps (5)', 'your-textdomain-here' ),
135
+                        'desc'    => esc_html__( 'JQuery UI slider description. Min: 0, max: 300, step: 5, default value: 75', 'your-textdomain-here' ),
136
+                        'default' => '0',
137
+                        'min'     => '0',
138
+                        'step'    => '5',
139
+                        'max'     => '300',
140
+                    ),
141
+                    array(
142
+                        'id'      => 'tax-spinner',
143
+                        'type'    => 'spinner',
144
+                        'title'   => esc_html__( 'Spinner Example 1', 'your-textdomain-here' ),
145
+                        'desc'    => esc_html__( 'Spinner description. Min:20, max: 100, step:20, default value: 40', 'your-textdomain-here' ),
146
+                        'default' => '40',
147
+                        'min'     => '20',
148
+                        'step'    => '20',
149
+                        'max'     => '100',
150
+                    ),
151
+                    array(
152
+                        'id'       => 'tax-switch-parent',
153
+                        'type'     => 'switch',
154
+                        'title'    => esc_html__( 'Switch - Nested Children, Enable to show', 'your-textdomain-here' ),
155
+                        'subtitle' => esc_html__( 'Look, it\'s on! Also hidden child elements!', 'your-textdomain-here' ),
156
+                        'default'  => 0,
157
+                        'on'       => 'Enabled',
158
+                        'off'      => 'Disabled',
159
+                    ),
160
+                    array(
161
+                        'id'       => 'tax-switch-child',
162
+                        'type'     => 'switch',
163
+                        'required' => array( 'tax-switch-parent', '=', '1' ),
164
+                        'title'    => esc_html__( 'Switch - This and the next switch required for patterns to show', 'your-textdomain-here' ),
165
+                        'subtitle' => esc_html__( 'Also called a "fold" parent.', 'your-textdomain-here' ),
166
+                        'desc'     => esc_html__( 'Items set with a fold to this ID will hide unless this is set to the appropriate value.', 'your-textdomain-here' ),
167
+                        'default'  => false,
168
+                    ),
169
+                ),
170
+            ),
171 171
 
172
-			array(
173
-				'title'  => esc_html__( 'Home Layout', 'your-textdomain-here' ),
174
-				// translators: %s = Redux GitHub URL.
175
-				'desc'   => sprintf( esc_html__( 'Redux Framework was created with the developer in mind. It allows for any theme developer to have an advanced theme panel with most of the features a developer would need. For more information check out the GitHub repo at: %s', 'your-textdomain-here' ), '<a href="https://github.com/reduxframework/redux-framework">https://github.com/reduxframework/redux-framework</a>' ),
176
-				'icon'   => 'el-icon-home',
177
-				'fields' => array(
178
-					array(
179
-						'id'             => 'tax-homepage_blocks',
180
-						'type'           => 'sorter',
181
-						'title'          => 'Homepage Layout Manager',
182
-						'desc'           => 'Organize how you want the layout to appear on the homepage',
183
-						'compiler'       => 'true',
184
-						'add_visibility' => true,
172
+            array(
173
+                'title'  => esc_html__( 'Home Layout', 'your-textdomain-here' ),
174
+                // translators: %s = Redux GitHub URL.
175
+                'desc'   => sprintf( esc_html__( 'Redux Framework was created with the developer in mind. It allows for any theme developer to have an advanced theme panel with most of the features a developer would need. For more information check out the GitHub repo at: %s', 'your-textdomain-here' ), '<a href="https://github.com/reduxframework/redux-framework">https://github.com/reduxframework/redux-framework</a>' ),
176
+                'icon'   => 'el-icon-home',
177
+                'fields' => array(
178
+                    array(
179
+                        'id'             => 'tax-homepage_blocks',
180
+                        'type'           => 'sorter',
181
+                        'title'          => 'Homepage Layout Manager',
182
+                        'desc'           => 'Organize how you want the layout to appear on the homepage',
183
+                        'compiler'       => 'true',
184
+                        'add_visibility' => true,
185 185
 
186
-						'options'        => array(
187
-							'enabled'  => array(
188
-								'highlights' => 'Highlights',
189
-								'slider'     => 'Slider',
190
-								'staticpage' => 'Static Page',
191
-							),
192
-							'disabled' => array(
193
-								'services' => 'Services',
194
-							),
195
-						),
196
-					),
186
+                        'options'        => array(
187
+                            'enabled'  => array(
188
+                                'highlights' => 'Highlights',
189
+                                'slider'     => 'Slider',
190
+                                'staticpage' => 'Static Page',
191
+                            ),
192
+                            'disabled' => array(
193
+                                'services' => 'Services',
194
+                            ),
195
+                        ),
196
+                    ),
197 197
 
198
-					array(
199
-						'id'       => 'tax-presets',
200
-						'type'     => 'image_select',
201
-						'presets'  => true,
202
-						'title'    => esc_html__( 'Preset', 'your-textdomain-here' ),
203
-						'subtitle' => esc_html__( 'This allows you to set a json string or array to override multiple preferences in your theme.', 'your-textdomain-here' ),
204
-						'default'  => 0,
205
-						'desc'     => esc_html__( 'This allows you to set a json string or array to override multiple preferences in your theme.', 'your-textdomain-here' ),
206
-						'options'  => array(
207
-							'1' => array(
208
-								'alt'     => 'Preset 1',
209
-								'img'     => ReduxFramework::$_url . '../sample/presets/preset1.png',
210
-								'presets' => array(
211
-									'switch-on'     => 1,
212
-									'switch-off'    => 1,
213
-									'switch-custom' => 1,
214
-								),
215
-							),
216
-							'2' => array(
217
-								'alt'     => 'Preset 2',
218
-								'img'     => ReduxFramework::$_url . '../sample/presets/preset2.png',
219
-								'presets' => '{"slider1":"1", "slider2":"0", "switch-on":"0"}',
220
-							),
221
-						),
222
-					),
223
-				),
224
-			),
225
-		),
226
-	)
198
+                    array(
199
+                        'id'       => 'tax-presets',
200
+                        'type'     => 'image_select',
201
+                        'presets'  => true,
202
+                        'title'    => esc_html__( 'Preset', 'your-textdomain-here' ),
203
+                        'subtitle' => esc_html__( 'This allows you to set a json string or array to override multiple preferences in your theme.', 'your-textdomain-here' ),
204
+                        'default'  => 0,
205
+                        'desc'     => esc_html__( 'This allows you to set a json string or array to override multiple preferences in your theme.', 'your-textdomain-here' ),
206
+                        'options'  => array(
207
+                            '1' => array(
208
+                                'alt'     => 'Preset 1',
209
+                                'img'     => ReduxFramework::$_url . '../sample/presets/preset1.png',
210
+                                'presets' => array(
211
+                                    'switch-on'     => 1,
212
+                                    'switch-off'    => 1,
213
+                                    'switch-custom' => 1,
214
+                                ),
215
+                            ),
216
+                            '2' => array(
217
+                                'alt'     => 'Preset 2',
218
+                                'img'     => ReduxFramework::$_url . '../sample/presets/preset2.png',
219
+                                'presets' => '{"slider1":"1", "slider2":"0", "switch-on":"0"}',
220
+                            ),
221
+                        ),
222
+                    ),
223
+                ),
224
+            ),
225
+        ),
226
+    )
227 227
 );
228 228
 // phpcs:enable
Please login to merge, or discard this patch.