@@ -10,55 +10,55 @@ |
||
| 10 | 10 | defined( 'ABSPATH' ) || exit; |
| 11 | 11 | |
| 12 | 12 | Redux::set_section( |
| 13 | - $opt_name, |
|
| 14 | - array( |
|
| 15 | - 'title' => esc_html__( 'Switch', 'your-textdomain-here' ), |
|
| 16 | - 'id' => 'switch_buttonset-switch', |
|
| 17 | - 'desc' => esc_html__( 'For full documentation on this field, visit: ', 'your-textdomain-here' ) . '<a href="https://devs.redux.io/core-fields/switch.html" target="_blank">https://devs.redux.io/core-fields/switch.html</a>', |
|
| 18 | - 'subsection' => true, |
|
| 19 | - 'fields' => array( |
|
| 20 | - array( |
|
| 21 | - 'id' => 'switch-on', |
|
| 22 | - 'type' => 'switch', |
|
| 23 | - 'title' => esc_html__( 'Switch On', 'your-textdomain-here' ), |
|
| 24 | - 'subtitle' => esc_html__( 'Look, it\'s on!', 'your-textdomain-here' ), |
|
| 25 | - 'default' => true, |
|
| 26 | - ), |
|
| 27 | - array( |
|
| 28 | - 'id' => 'switch-off', |
|
| 29 | - 'type' => 'switch', |
|
| 30 | - 'title' => esc_html__( 'Switch Off', 'your-textdomain-here' ), |
|
| 31 | - 'subtitle' => esc_html__( 'Look, it\'s on!', 'your-textdomain-here' ), |
|
| 32 | - 'default' => false, |
|
| 33 | - ), |
|
| 34 | - array( |
|
| 35 | - 'id' => 'switch-parent', |
|
| 36 | - 'type' => 'switch', |
|
| 37 | - 'title' => esc_html__( 'Switch - Nested Children, Enable to show', 'your-textdomain-here' ), |
|
| 38 | - 'subtitle' => esc_html__( 'Look, it\'s on! Also hidden child elements!', 'your-textdomain-here' ), |
|
| 39 | - 'default' => false, |
|
| 40 | - 'on' => 'Enabled', |
|
| 41 | - 'off' => 'Disabled', |
|
| 42 | - ), |
|
| 43 | - array( |
|
| 44 | - 'id' => 'switch-child1', |
|
| 45 | - 'type' => 'switch', |
|
| 46 | - 'required' => array( 'switch-parent', '=', true ), |
|
| 47 | - 'title' => esc_html__( 'Switch - This and the next switch required for patterns to show', 'your-textdomain-here' ), |
|
| 48 | - 'subtitle' => esc_html__( 'Also called a "fold" parent.', 'your-textdomain-here' ), |
|
| 49 | - 'desc' => esc_html__( 'Items set with a fold to this ID will hide unless this is set to the appropriate value.', 'your-textdomain-here' ), |
|
| 50 | - 'default' => false, |
|
| 51 | - ), |
|
| 52 | - array( |
|
| 53 | - 'id' => 'switch-child2', |
|
| 54 | - 'type' => 'switch', |
|
| 55 | - 'required' => array( 'switch-parent', '=', true ), |
|
| 56 | - 'title' => esc_html__( 'Switch2 - Enable the above switch and this one for patterns to show', 'your-textdomain-here' ), |
|
| 57 | - 'subtitle' => esc_html__( 'Also called a "fold" parent.', 'your-textdomain-here' ), |
|
| 58 | - 'desc' => esc_html__( 'Items set with a fold to this ID will hide unless this is set to the appropriate value.', 'your-textdomain-here' ), |
|
| 59 | - 'default' => false, |
|
| 60 | - ), |
|
| 61 | - ), |
|
| 62 | - ) |
|
| 13 | + $opt_name, |
|
| 14 | + array( |
|
| 15 | + 'title' => esc_html__( 'Switch', 'your-textdomain-here' ), |
|
| 16 | + 'id' => 'switch_buttonset-switch', |
|
| 17 | + 'desc' => esc_html__( 'For full documentation on this field, visit: ', 'your-textdomain-here' ) . '<a href="https://devs.redux.io/core-fields/switch.html" target="_blank">https://devs.redux.io/core-fields/switch.html</a>', |
|
| 18 | + 'subsection' => true, |
|
| 19 | + 'fields' => array( |
|
| 20 | + array( |
|
| 21 | + 'id' => 'switch-on', |
|
| 22 | + 'type' => 'switch', |
|
| 23 | + 'title' => esc_html__( 'Switch On', 'your-textdomain-here' ), |
|
| 24 | + 'subtitle' => esc_html__( 'Look, it\'s on!', 'your-textdomain-here' ), |
|
| 25 | + 'default' => true, |
|
| 26 | + ), |
|
| 27 | + array( |
|
| 28 | + 'id' => 'switch-off', |
|
| 29 | + 'type' => 'switch', |
|
| 30 | + 'title' => esc_html__( 'Switch Off', 'your-textdomain-here' ), |
|
| 31 | + 'subtitle' => esc_html__( 'Look, it\'s on!', 'your-textdomain-here' ), |
|
| 32 | + 'default' => false, |
|
| 33 | + ), |
|
| 34 | + array( |
|
| 35 | + 'id' => 'switch-parent', |
|
| 36 | + 'type' => 'switch', |
|
| 37 | + 'title' => esc_html__( 'Switch - Nested Children, Enable to show', 'your-textdomain-here' ), |
|
| 38 | + 'subtitle' => esc_html__( 'Look, it\'s on! Also hidden child elements!', 'your-textdomain-here' ), |
|
| 39 | + 'default' => false, |
|
| 40 | + 'on' => 'Enabled', |
|
| 41 | + 'off' => 'Disabled', |
|
| 42 | + ), |
|
| 43 | + array( |
|
| 44 | + 'id' => 'switch-child1', |
|
| 45 | + 'type' => 'switch', |
|
| 46 | + 'required' => array( 'switch-parent', '=', true ), |
|
| 47 | + 'title' => esc_html__( 'Switch - This and the next switch required for patterns to show', 'your-textdomain-here' ), |
|
| 48 | + 'subtitle' => esc_html__( 'Also called a "fold" parent.', 'your-textdomain-here' ), |
|
| 49 | + 'desc' => esc_html__( 'Items set with a fold to this ID will hide unless this is set to the appropriate value.', 'your-textdomain-here' ), |
|
| 50 | + 'default' => false, |
|
| 51 | + ), |
|
| 52 | + array( |
|
| 53 | + 'id' => 'switch-child2', |
|
| 54 | + 'type' => 'switch', |
|
| 55 | + 'required' => array( 'switch-parent', '=', true ), |
|
| 56 | + 'title' => esc_html__( 'Switch2 - Enable the above switch and this one for patterns to show', 'your-textdomain-here' ), |
|
| 57 | + 'subtitle' => esc_html__( 'Also called a "fold" parent.', 'your-textdomain-here' ), |
|
| 58 | + 'desc' => esc_html__( 'Items set with a fold to this ID will hide unless this is set to the appropriate value.', 'your-textdomain-here' ), |
|
| 59 | + 'default' => false, |
|
| 60 | + ), |
|
| 61 | + ), |
|
| 62 | + ) |
|
| 63 | 63 | ); |
| 64 | 64 | // phpcs:enable |
@@ -10,45 +10,45 @@ |
||
| 10 | 10 | defined( 'ABSPATH' ) || exit; |
| 11 | 11 | |
| 12 | 12 | Redux::set_section( |
| 13 | - $opt_name, |
|
| 14 | - array( |
|
| 15 | - 'title' => esc_html__( 'Button Set', 'your-textdomain-here' ), |
|
| 16 | - 'id' => 'switch_buttonset-set', |
|
| 17 | - 'desc' => esc_html__( 'For full documentation on this field, visit: ', 'your-textdomain-here' ) . '<a href="https://devs.redux.io/core-fields/button-set.html" target="_blank">https://devs.redux.io/core-fields/button-set.html</a>', |
|
| 18 | - 'subsection' => true, |
|
| 19 | - 'fields' => array( |
|
| 20 | - array( |
|
| 21 | - 'id' => 'opt-button-set', |
|
| 22 | - 'type' => 'button_set', |
|
| 23 | - 'title' => esc_html__( 'Button Set Option', 'your-textdomain-here' ), |
|
| 24 | - 'subtitle' => esc_html__( 'No 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' ), |
|
| 13 | + $opt_name, |
|
| 14 | + array( |
|
| 15 | + 'title' => esc_html__( 'Button Set', 'your-textdomain-here' ), |
|
| 16 | + 'id' => 'switch_buttonset-set', |
|
| 17 | + 'desc' => esc_html__( 'For full documentation on this field, visit: ', 'your-textdomain-here' ) . '<a href="https://devs.redux.io/core-fields/button-set.html" target="_blank">https://devs.redux.io/core-fields/button-set.html</a>', |
|
| 18 | + 'subsection' => true, |
|
| 19 | + 'fields' => array( |
|
| 20 | + array( |
|
| 21 | + 'id' => 'opt-button-set', |
|
| 22 | + 'type' => 'button_set', |
|
| 23 | + 'title' => esc_html__( 'Button Set Option', 'your-textdomain-here' ), |
|
| 24 | + 'subtitle' => esc_html__( 'No 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 | 26 | |
| 27 | - // Must provide key => value pairs for radio options. |
|
| 28 | - 'options' => array( |
|
| 29 | - '1' => 'Opt 1', |
|
| 30 | - '2' => 'Opt 2', |
|
| 31 | - '3' => 'Opt 3', |
|
| 32 | - ), |
|
| 33 | - 'default' => '2', |
|
| 34 | - ), |
|
| 35 | - array( |
|
| 36 | - 'id' => 'opt-button-set-multi', |
|
| 37 | - 'type' => 'button_set', |
|
| 38 | - 'title' => esc_html__( 'Button Set, Multi Select', 'your-textdomain-here' ), |
|
| 39 | - 'subtitle' => esc_html__( 'No validation can be done on this field type', 'your-textdomain-here' ), |
|
| 40 | - 'desc' => esc_html__( 'This is the description field, again good for additional info.', 'your-textdomain-here' ), |
|
| 41 | - 'multi' => true, |
|
| 27 | + // Must provide key => value pairs for radio options. |
|
| 28 | + 'options' => array( |
|
| 29 | + '1' => 'Opt 1', |
|
| 30 | + '2' => 'Opt 2', |
|
| 31 | + '3' => 'Opt 3', |
|
| 32 | + ), |
|
| 33 | + 'default' => '2', |
|
| 34 | + ), |
|
| 35 | + array( |
|
| 36 | + 'id' => 'opt-button-set-multi', |
|
| 37 | + 'type' => 'button_set', |
|
| 38 | + 'title' => esc_html__( 'Button Set, Multi Select', 'your-textdomain-here' ), |
|
| 39 | + 'subtitle' => esc_html__( 'No validation can be done on this field type', 'your-textdomain-here' ), |
|
| 40 | + 'desc' => esc_html__( 'This is the description field, again good for additional info.', 'your-textdomain-here' ), |
|
| 41 | + 'multi' => true, |
|
| 42 | 42 | |
| 43 | - // Must provide key => value pairs for radio options. |
|
| 44 | - 'options' => array( |
|
| 45 | - '1' => 'Opt 1', |
|
| 46 | - '2' => 'Opt 2', |
|
| 47 | - '3' => 'Opt 3', |
|
| 48 | - ), |
|
| 49 | - 'default' => array( '2', '3' ), |
|
| 50 | - ), |
|
| 51 | - ), |
|
| 52 | - ) |
|
| 43 | + // Must provide key => value pairs for radio options. |
|
| 44 | + 'options' => array( |
|
| 45 | + '1' => 'Opt 1', |
|
| 46 | + '2' => 'Opt 2', |
|
| 47 | + '3' => 'Opt 3', |
|
| 48 | + ), |
|
| 49 | + 'default' => array( '2', '3' ), |
|
| 50 | + ), |
|
| 51 | + ), |
|
| 52 | + ) |
|
| 53 | 53 | ); |
| 54 | 54 | // phpcs:enable |
@@ -10,45 +10,45 @@ |
||
| 10 | 10 | defined( 'ABSPATH' ) || exit; |
| 11 | 11 | |
| 12 | 12 | Redux::set_section( |
| 13 | - $opt_name, |
|
| 14 | - array( |
|
| 15 | - 'title' => esc_html__( 'Sortable', 'your-textdomain-here' ), |
|
| 16 | - 'id' => 'basic-sortable', |
|
| 17 | - 'subsection' => true, |
|
| 18 | - 'desc' => esc_html__( 'For full documentation on this field, visit: ', 'your-textdomain-here' ) . '<a href="https://devs.redux.io/core-fields/sortable.html" target="_blank">https://devs.redux.io/core-fields/sortable.html</a>', |
|
| 19 | - 'fields' => array( |
|
| 20 | - array( |
|
| 21 | - 'id' => 'opt-sortable', |
|
| 22 | - 'type' => 'sortable', |
|
| 23 | - 'title' => esc_html__( 'Sortable Text Option', 'your-textdomain-here' ), |
|
| 24 | - 'subtitle' => esc_html__( 'Define and reorder these however you want.', 'your-textdomain-here' ), |
|
| 25 | - 'desc' => esc_html__( 'This is the description field, again good for additional info.', 'your-textdomain-here' ), |
|
| 26 | - 'label' => true, |
|
| 27 | - 'options' => array( |
|
| 28 | - 'Text One' => 'Item 1', |
|
| 29 | - 'Text Two' => 'Item 2', |
|
| 30 | - 'Text Three' => 'Item 3', |
|
| 31 | - ), |
|
| 32 | - ), |
|
| 33 | - array( |
|
| 34 | - 'id' => 'opt-check-sortable', |
|
| 35 | - 'type' => 'sortable', |
|
| 36 | - 'mode' => 'toggle', // toggle or text. |
|
| 37 | - 'title' => esc_html__( 'Sortable Toggle Option', 'your-textdomain-here' ), |
|
| 38 | - 'subtitle' => esc_html__( 'Define and reorder these however you want.', 'your-textdomain-here' ), |
|
| 39 | - 'desc' => esc_html__( 'This is the description field, again good for additional info.', 'your-textdomain-here' ), |
|
| 40 | - 'options' => array( |
|
| 41 | - 'cb1' => 'Option One', |
|
| 42 | - 'cb2' => 'Option Two', |
|
| 43 | - 'cb3' => 'Option Three', |
|
| 44 | - ), |
|
| 45 | - 'default' => array( |
|
| 46 | - 'cb1' => false, |
|
| 47 | - 'cb2' => true, |
|
| 48 | - 'cb3' => false, |
|
| 49 | - ), |
|
| 50 | - ), |
|
| 51 | - ), |
|
| 52 | - ) |
|
| 13 | + $opt_name, |
|
| 14 | + array( |
|
| 15 | + 'title' => esc_html__( 'Sortable', 'your-textdomain-here' ), |
|
| 16 | + 'id' => 'basic-sortable', |
|
| 17 | + 'subsection' => true, |
|
| 18 | + 'desc' => esc_html__( 'For full documentation on this field, visit: ', 'your-textdomain-here' ) . '<a href="https://devs.redux.io/core-fields/sortable.html" target="_blank">https://devs.redux.io/core-fields/sortable.html</a>', |
|
| 19 | + 'fields' => array( |
|
| 20 | + array( |
|
| 21 | + 'id' => 'opt-sortable', |
|
| 22 | + 'type' => 'sortable', |
|
| 23 | + 'title' => esc_html__( 'Sortable Text Option', 'your-textdomain-here' ), |
|
| 24 | + 'subtitle' => esc_html__( 'Define and reorder these however you want.', 'your-textdomain-here' ), |
|
| 25 | + 'desc' => esc_html__( 'This is the description field, again good for additional info.', 'your-textdomain-here' ), |
|
| 26 | + 'label' => true, |
|
| 27 | + 'options' => array( |
|
| 28 | + 'Text One' => 'Item 1', |
|
| 29 | + 'Text Two' => 'Item 2', |
|
| 30 | + 'Text Three' => 'Item 3', |
|
| 31 | + ), |
|
| 32 | + ), |
|
| 33 | + array( |
|
| 34 | + 'id' => 'opt-check-sortable', |
|
| 35 | + 'type' => 'sortable', |
|
| 36 | + 'mode' => 'toggle', // toggle or text. |
|
| 37 | + 'title' => esc_html__( 'Sortable Toggle Option', 'your-textdomain-here' ), |
|
| 38 | + 'subtitle' => esc_html__( 'Define and reorder these however you want.', 'your-textdomain-here' ), |
|
| 39 | + 'desc' => esc_html__( 'This is the description field, again good for additional info.', 'your-textdomain-here' ), |
|
| 40 | + 'options' => array( |
|
| 41 | + 'cb1' => 'Option One', |
|
| 42 | + 'cb2' => 'Option Two', |
|
| 43 | + 'cb3' => 'Option Three', |
|
| 44 | + ), |
|
| 45 | + 'default' => array( |
|
| 46 | + 'cb1' => false, |
|
| 47 | + 'cb2' => true, |
|
| 48 | + 'cb3' => false, |
|
| 49 | + ), |
|
| 50 | + ), |
|
| 51 | + ), |
|
| 52 | + ) |
|
| 53 | 53 | ); |
| 54 | 54 | // phpcs:enable |
@@ -10,58 +10,58 @@ |
||
| 10 | 10 | defined( 'ABSPATH' ) || exit; |
| 11 | 11 | |
| 12 | 12 | Redux::set_section( |
| 13 | - $opt_name, |
|
| 14 | - array( |
|
| 15 | - 'title' => esc_html__( 'Checkbox', 'your-textdomain-here' ), |
|
| 16 | - 'id' => 'basic-checkbox', |
|
| 17 | - 'subsection' => true, |
|
| 18 | - 'customizer_width' => '450px', |
|
| 19 | - 'desc' => esc_html__( 'For full documentation on this field, visit: ', 'your-textdomain-here' ) . '<a href="https://devs.redux.io/core-fields/checkbox.html" target="_blank">https://devs.redux.io/core-fields/checkbox.html</a>', |
|
| 20 | - 'fields' => array( |
|
| 21 | - array( |
|
| 22 | - 'id' => 'opt-checkbox', |
|
| 23 | - 'type' => 'checkbox', |
|
| 24 | - 'title' => esc_html__( 'Checkbox Option', 'your-textdomain-here' ), |
|
| 25 | - 'subtitle' => esc_html__( 'No validation can be done on this field type', 'your-textdomain-here' ), |
|
| 26 | - 'desc' => esc_html__( 'This is the description field, again good for additional info.', 'your-textdomain-here' ), |
|
| 27 | - 'default' => '1', // 1 = on | 0 = off. |
|
| 28 | - ), |
|
| 29 | - array( |
|
| 30 | - 'id' => 'opt-multi-check', |
|
| 31 | - 'type' => 'checkbox', |
|
| 32 | - 'title' => esc_html__( 'Multi Checkbox Option', 'your-textdomain-here' ), |
|
| 33 | - 'subtitle' => esc_html__( 'No validation can be done on this field type', 'your-textdomain-here' ), |
|
| 34 | - 'desc' => esc_html__( 'This is the description field, again good for additional info.', 'your-textdomain-here' ), |
|
| 13 | + $opt_name, |
|
| 14 | + array( |
|
| 15 | + 'title' => esc_html__( 'Checkbox', 'your-textdomain-here' ), |
|
| 16 | + 'id' => 'basic-checkbox', |
|
| 17 | + 'subsection' => true, |
|
| 18 | + 'customizer_width' => '450px', |
|
| 19 | + 'desc' => esc_html__( 'For full documentation on this field, visit: ', 'your-textdomain-here' ) . '<a href="https://devs.redux.io/core-fields/checkbox.html" target="_blank">https://devs.redux.io/core-fields/checkbox.html</a>', |
|
| 20 | + 'fields' => array( |
|
| 21 | + array( |
|
| 22 | + 'id' => 'opt-checkbox', |
|
| 23 | + 'type' => 'checkbox', |
|
| 24 | + 'title' => esc_html__( 'Checkbox Option', 'your-textdomain-here' ), |
|
| 25 | + 'subtitle' => esc_html__( 'No validation can be done on this field type', 'your-textdomain-here' ), |
|
| 26 | + 'desc' => esc_html__( 'This is the description field, again good for additional info.', 'your-textdomain-here' ), |
|
| 27 | + 'default' => '1', // 1 = on | 0 = off. |
|
| 28 | + ), |
|
| 29 | + array( |
|
| 30 | + 'id' => 'opt-multi-check', |
|
| 31 | + 'type' => 'checkbox', |
|
| 32 | + 'title' => esc_html__( 'Multi Checkbox Option', 'your-textdomain-here' ), |
|
| 33 | + 'subtitle' => esc_html__( 'No validation can be done on this field type', 'your-textdomain-here' ), |
|
| 34 | + 'desc' => esc_html__( 'This is the description field, again good for additional info.', 'your-textdomain-here' ), |
|
| 35 | 35 | |
| 36 | - // Must provide key => value pairs for multi checkbox options. |
|
| 37 | - 'options' => array( |
|
| 38 | - '1' => 'Opt 1', |
|
| 39 | - '2' => 'Opt 2', |
|
| 40 | - '3' => 'Opt 3', |
|
| 41 | - ), |
|
| 42 | - 'default' => array( |
|
| 43 | - '1' => '1', |
|
| 44 | - '2' => '0', |
|
| 45 | - '3' => '0', |
|
| 46 | - ), |
|
| 47 | - ), |
|
| 48 | - array( |
|
| 49 | - 'id' => 'opt-checkbox-data', |
|
| 50 | - 'type' => 'checkbox', |
|
| 51 | - 'title' => esc_html__( 'Multi Checkbox Option (with menu data)', 'your-textdomain-here' ), |
|
| 52 | - 'subtitle' => esc_html__( 'No validation can be done on this field type', 'your-textdomain-here' ), |
|
| 53 | - 'desc' => esc_html__( 'This is the description field, again good for additional info.', 'your-textdomain-here' ), |
|
| 54 | - 'data' => 'menu', |
|
| 55 | - ), |
|
| 56 | - array( |
|
| 57 | - 'id' => 'opt-checkbox-sidebar', |
|
| 58 | - 'type' => 'checkbox', |
|
| 59 | - 'title' => esc_html__( 'Multi Checkbox Option (with sidebar data)', 'your-textdomain-here' ), |
|
| 60 | - 'subtitle' => esc_html__( 'No validation can be done on this field type', 'your-textdomain-here' ), |
|
| 61 | - 'desc' => esc_html__( 'This is the description field, again good for additional info.', 'your-textdomain-here' ), |
|
| 62 | - 'data' => 'sidebars', |
|
| 63 | - ), |
|
| 64 | - ), |
|
| 65 | - ) |
|
| 36 | + // Must provide key => value pairs for multi checkbox options. |
|
| 37 | + 'options' => array( |
|
| 38 | + '1' => 'Opt 1', |
|
| 39 | + '2' => 'Opt 2', |
|
| 40 | + '3' => 'Opt 3', |
|
| 41 | + ), |
|
| 42 | + 'default' => array( |
|
| 43 | + '1' => '1', |
|
| 44 | + '2' => '0', |
|
| 45 | + '3' => '0', |
|
| 46 | + ), |
|
| 47 | + ), |
|
| 48 | + array( |
|
| 49 | + 'id' => 'opt-checkbox-data', |
|
| 50 | + 'type' => 'checkbox', |
|
| 51 | + 'title' => esc_html__( 'Multi Checkbox Option (with menu data)', 'your-textdomain-here' ), |
|
| 52 | + 'subtitle' => esc_html__( 'No validation can be done on this field type', 'your-textdomain-here' ), |
|
| 53 | + 'desc' => esc_html__( 'This is the description field, again good for additional info.', 'your-textdomain-here' ), |
|
| 54 | + 'data' => 'menu', |
|
| 55 | + ), |
|
| 56 | + array( |
|
| 57 | + 'id' => 'opt-checkbox-sidebar', |
|
| 58 | + 'type' => 'checkbox', |
|
| 59 | + 'title' => esc_html__( 'Multi Checkbox Option (with sidebar data)', 'your-textdomain-here' ), |
|
| 60 | + 'subtitle' => esc_html__( 'No validation can be done on this field type', 'your-textdomain-here' ), |
|
| 61 | + 'desc' => esc_html__( 'This is the description field, again good for additional info.', 'your-textdomain-here' ), |
|
| 62 | + 'data' => 'sidebars', |
|
| 63 | + ), |
|
| 64 | + ), |
|
| 65 | + ) |
|
| 66 | 66 | ); |
| 67 | 67 | // phpcs:enable |
@@ -10,22 +10,22 @@ |
||
| 10 | 10 | defined( 'ABSPATH' ) || exit; |
| 11 | 11 | |
| 12 | 12 | Redux::set_section( |
| 13 | - $opt_name, |
|
| 14 | - array( |
|
| 15 | - 'title' => esc_html__( 'Textarea', 'your-textdomain-here' ), |
|
| 16 | - 'id' => 'basic-textarea', |
|
| 17 | - 'desc' => esc_html__( 'For full documentation on this field, visit: ', 'your-textdomain-here' ) . '<a href="https://devs.redux.io/core-fields/textarea.html" target="_blank">https://devs.redux.io/core-fields/textarea.html</a>', |
|
| 18 | - 'subsection' => true, |
|
| 19 | - 'fields' => array( |
|
| 20 | - array( |
|
| 21 | - 'id' => 'opt-textarea', |
|
| 22 | - 'type' => 'textarea', |
|
| 23 | - 'title' => esc_html__( 'Textarea Option - HTML Validated Custom', 'your-textdomain-here' ), |
|
| 24 | - 'subtitle' => esc_html__( 'Subtitle', 'your-textdomain-here' ), |
|
| 25 | - 'desc' => esc_html__( 'This is the description field, again good for additional info.', 'your-textdomain-here' ), |
|
| 26 | - 'default' => 'Default Text', |
|
| 27 | - ), |
|
| 28 | - ), |
|
| 29 | - ) |
|
| 13 | + $opt_name, |
|
| 14 | + array( |
|
| 15 | + 'title' => esc_html__( 'Textarea', 'your-textdomain-here' ), |
|
| 16 | + 'id' => 'basic-textarea', |
|
| 17 | + 'desc' => esc_html__( 'For full documentation on this field, visit: ', 'your-textdomain-here' ) . '<a href="https://devs.redux.io/core-fields/textarea.html" target="_blank">https://devs.redux.io/core-fields/textarea.html</a>', |
|
| 18 | + 'subsection' => true, |
|
| 19 | + 'fields' => array( |
|
| 20 | + array( |
|
| 21 | + 'id' => 'opt-textarea', |
|
| 22 | + 'type' => 'textarea', |
|
| 23 | + 'title' => esc_html__( 'Textarea Option - HTML Validated Custom', 'your-textdomain-here' ), |
|
| 24 | + 'subtitle' => esc_html__( 'Subtitle', 'your-textdomain-here' ), |
|
| 25 | + 'desc' => esc_html__( 'This is the description field, again good for additional info.', 'your-textdomain-here' ), |
|
| 26 | + 'default' => 'Default Text', |
|
| 27 | + ), |
|
| 28 | + ), |
|
| 29 | + ) |
|
| 30 | 30 | ); |
| 31 | 31 | // phpcs:enable |
@@ -10,38 +10,38 @@ |
||
| 10 | 10 | defined( 'ABSPATH' ) || exit; |
| 11 | 11 | |
| 12 | 12 | Redux::set_section( |
| 13 | - $opt_name, |
|
| 14 | - array( |
|
| 15 | - 'title' => esc_html__( 'Radio', 'your-textdomain-here' ), |
|
| 16 | - 'id' => 'basic-radio', |
|
| 17 | - 'subsection' => true, |
|
| 18 | - 'customizer_width' => '500px', |
|
| 19 | - 'desc' => esc_html__( 'For full documentation on this field, visit: ', 'your-textdomain-here' ) . '<a href="https://devs.redux.io/core-fields/radio.html" target="_blank">https://devs.redux.io/core-fields/radio.html</a>', |
|
| 20 | - 'fields' => array( |
|
| 21 | - array( |
|
| 22 | - 'id' => 'opt-radio', |
|
| 23 | - 'type' => 'radio', |
|
| 24 | - 'title' => esc_html__( 'Radio Option', 'your-textdomain-here' ), |
|
| 25 | - 'subtitle' => esc_html__( 'No validation can be done on this field type', 'your-textdomain-here' ), |
|
| 26 | - 'desc' => esc_html__( 'This is the description field, again good for additional info.', 'your-textdomain-here' ), |
|
| 13 | + $opt_name, |
|
| 14 | + array( |
|
| 15 | + 'title' => esc_html__( 'Radio', 'your-textdomain-here' ), |
|
| 16 | + 'id' => 'basic-radio', |
|
| 17 | + 'subsection' => true, |
|
| 18 | + 'customizer_width' => '500px', |
|
| 19 | + 'desc' => esc_html__( 'For full documentation on this field, visit: ', 'your-textdomain-here' ) . '<a href="https://devs.redux.io/core-fields/radio.html" target="_blank">https://devs.redux.io/core-fields/radio.html</a>', |
|
| 20 | + 'fields' => array( |
|
| 21 | + array( |
|
| 22 | + 'id' => 'opt-radio', |
|
| 23 | + 'type' => 'radio', |
|
| 24 | + 'title' => esc_html__( 'Radio Option', 'your-textdomain-here' ), |
|
| 25 | + 'subtitle' => esc_html__( 'No validation can be done on this field type', 'your-textdomain-here' ), |
|
| 26 | + 'desc' => esc_html__( 'This is the description field, again good for additional info.', 'your-textdomain-here' ), |
|
| 27 | 27 | |
| 28 | - // Must provide key => value pairs for radio options. |
|
| 29 | - 'options' => array( |
|
| 30 | - '1' => 'Opt 1', |
|
| 31 | - '2' => 'Opt 2', |
|
| 32 | - '3' => 'Opt 3', |
|
| 33 | - ), |
|
| 34 | - 'default' => '2', |
|
| 35 | - ), |
|
| 36 | - array( |
|
| 37 | - 'id' => 'opt-radio-data', |
|
| 38 | - 'type' => 'radio', |
|
| 39 | - 'title' => esc_html__( 'Radio Option w/ Menu Data', 'your-textdomain-here' ), |
|
| 40 | - 'subtitle' => esc_html__( 'No validation can be done on this field type', 'your-textdomain-here' ), |
|
| 41 | - 'desc' => esc_html__( 'This is the description field, again good for additional info.', 'your-textdomain-here' ), |
|
| 42 | - 'data' => 'menu', |
|
| 43 | - ), |
|
| 44 | - ), |
|
| 45 | - ) |
|
| 28 | + // Must provide key => value pairs for radio options. |
|
| 29 | + 'options' => array( |
|
| 30 | + '1' => 'Opt 1', |
|
| 31 | + '2' => 'Opt 2', |
|
| 32 | + '3' => 'Opt 3', |
|
| 33 | + ), |
|
| 34 | + 'default' => '2', |
|
| 35 | + ), |
|
| 36 | + array( |
|
| 37 | + 'id' => 'opt-radio-data', |
|
| 38 | + 'type' => 'radio', |
|
| 39 | + 'title' => esc_html__( 'Radio Option w/ Menu Data', 'your-textdomain-here' ), |
|
| 40 | + 'subtitle' => esc_html__( 'No validation can be done on this field type', 'your-textdomain-here' ), |
|
| 41 | + 'desc' => esc_html__( 'This is the description field, again good for additional info.', 'your-textdomain-here' ), |
|
| 42 | + 'data' => 'menu', |
|
| 43 | + ), |
|
| 44 | + ), |
|
| 45 | + ) |
|
| 46 | 46 | ); |
| 47 | 47 | // phpcs:enable |
@@ -10,21 +10,21 @@ |
||
| 10 | 10 | defined( 'ABSPATH' ) || exit; |
| 11 | 11 | |
| 12 | 12 | Redux::set_section( |
| 13 | - $opt_name, |
|
| 14 | - array( |
|
| 15 | - 'title' => esc_html__( 'Multi Text', 'your-textdomain-here' ), |
|
| 16 | - 'id' => 'basic-multi-text', |
|
| 17 | - 'desc' => esc_html__( 'For full documentation on this field, visit: ', 'your-textdomain-here' ) . '<a href="https://devs.redux.io/core-fields/multi-text.html" target="_blank">https://devs.redux.io/core-fields/multi-text.html</a>', |
|
| 18 | - 'subsection' => true, |
|
| 19 | - 'fields' => array( |
|
| 20 | - array( |
|
| 21 | - 'id' => 'opt-multitext', |
|
| 22 | - 'type' => 'multi_text', |
|
| 23 | - 'title' => esc_html__( 'Multi Text Option', 'your-textdomain-here' ), |
|
| 24 | - 'subtitle' => esc_html__( 'Field subtitle', 'your-textdomain-here' ), |
|
| 25 | - 'desc' => esc_html__( 'Field Description', 'your-textdomain-here' ), |
|
| 26 | - ), |
|
| 27 | - ), |
|
| 28 | - ) |
|
| 13 | + $opt_name, |
|
| 14 | + array( |
|
| 15 | + 'title' => esc_html__( 'Multi Text', 'your-textdomain-here' ), |
|
| 16 | + 'id' => 'basic-multi-text', |
|
| 17 | + 'desc' => esc_html__( 'For full documentation on this field, visit: ', 'your-textdomain-here' ) . '<a href="https://devs.redux.io/core-fields/multi-text.html" target="_blank">https://devs.redux.io/core-fields/multi-text.html</a>', |
|
| 18 | + 'subsection' => true, |
|
| 19 | + 'fields' => array( |
|
| 20 | + array( |
|
| 21 | + 'id' => 'opt-multitext', |
|
| 22 | + 'type' => 'multi_text', |
|
| 23 | + 'title' => esc_html__( 'Multi Text Option', 'your-textdomain-here' ), |
|
| 24 | + 'subtitle' => esc_html__( 'Field subtitle', 'your-textdomain-here' ), |
|
| 25 | + 'desc' => esc_html__( 'Field Description', 'your-textdomain-here' ), |
|
| 26 | + ), |
|
| 27 | + ), |
|
| 28 | + ) |
|
| 29 | 29 | ); |
| 30 | 30 | // phpcs:enable |
@@ -10,20 +10,20 @@ |
||
| 10 | 10 | defined( 'ABSPATH' ) || exit; |
| 11 | 11 | |
| 12 | 12 | Redux::set_section( |
| 13 | - $opt_name, |
|
| 14 | - array( |
|
| 15 | - 'title' => esc_html__( 'Password', 'your-textdomain-here' ), |
|
| 16 | - 'id' => 'basic-password', |
|
| 17 | - 'desc' => esc_html__( 'For full documentation on this field, visit: ', 'your-textdomain-here' ) . '<a href="https://devs.redux.io/core-fields/password.html" target="_blank">https://devs.redux.io/core-fields/password.html</a>', |
|
| 18 | - 'subsection' => true, |
|
| 19 | - 'fields' => array( |
|
| 20 | - array( |
|
| 21 | - 'id' => 'password', |
|
| 22 | - 'type' => 'password', |
|
| 23 | - 'username' => true, |
|
| 24 | - 'title' => 'Password Field', |
|
| 25 | - ), |
|
| 26 | - ), |
|
| 27 | - ) |
|
| 13 | + $opt_name, |
|
| 14 | + array( |
|
| 15 | + 'title' => esc_html__( 'Password', 'your-textdomain-here' ), |
|
| 16 | + 'id' => 'basic-password', |
|
| 17 | + 'desc' => esc_html__( 'For full documentation on this field, visit: ', 'your-textdomain-here' ) . '<a href="https://devs.redux.io/core-fields/password.html" target="_blank">https://devs.redux.io/core-fields/password.html</a>', |
|
| 18 | + 'subsection' => true, |
|
| 19 | + 'fields' => array( |
|
| 20 | + array( |
|
| 21 | + 'id' => 'password', |
|
| 22 | + 'type' => 'password', |
|
| 23 | + 'username' => true, |
|
| 24 | + 'title' => 'Password Field', |
|
| 25 | + ), |
|
| 26 | + ), |
|
| 27 | + ) |
|
| 28 | 28 | ); |
| 29 | 29 | // phpcs:enable |
@@ -10,50 +10,50 @@ |
||
| 10 | 10 | defined( 'ABSPATH' ) || exit; |
| 11 | 11 | |
| 12 | 12 | Redux::set_section( |
| 13 | - $opt_name, |
|
| 14 | - array( |
|
| 15 | - 'title' => esc_html__( 'Text', '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/text.html" target="_blank">https://devs.redux.io/core-fields/text.html</a>', |
|
| 17 | - 'id' => 'basic-text', |
|
| 18 | - 'subsection' => true, |
|
| 19 | - 'customizer_width' => '700px', |
|
| 20 | - 'fields' => array( |
|
| 21 | - array( |
|
| 22 | - 'id' => 'text-example', |
|
| 23 | - 'type' => 'text', |
|
| 24 | - 'title' => esc_html__( 'Text Field', 'your-textdomain-here' ), |
|
| 25 | - 'subtitle' => esc_html__( 'Subtitle', 'your-textdomain-here' ), |
|
| 26 | - 'desc' => esc_html__( 'Field Description', 'your-textdomain-here' ), |
|
| 27 | - 'default' => 'Default Text', |
|
| 28 | - ), |
|
| 29 | - array( |
|
| 30 | - 'id' => 'text-example-hint', |
|
| 31 | - 'type' => 'text', |
|
| 32 | - 'title' => esc_html__( 'Text Field w/ Hint', 'your-textdomain-here' ), |
|
| 33 | - 'subtitle' => esc_html__( 'Subtitle', 'your-textdomain-here' ), |
|
| 34 | - 'desc' => esc_html__( 'Field Description', 'your-textdomain-here' ), |
|
| 35 | - 'default' => 'Default Text', |
|
| 36 | - 'hint' => array( |
|
| 37 | - 'title' => 'Hint Title', |
|
| 38 | - 'content' => 'Hint content about this field!', |
|
| 39 | - ), |
|
| 40 | - ), |
|
| 41 | - array( |
|
| 42 | - 'id' => 'text-placeholder', |
|
| 43 | - 'type' => 'text', |
|
| 44 | - 'title' => esc_html__( 'Text Field w/ placeholder using custom data object.', 'your-textdomain-here' ), |
|
| 45 | - 'subtitle' => esc_html__( 'Subtitle', 'your-textdomain-here' ), |
|
| 46 | - 'desc' => esc_html__( 'Field Description', 'your-textdomain-here' ), |
|
| 47 | - 'placeholder' => array( |
|
| 48 | - 'box1' => 'Box One Placeholder', |
|
| 49 | - 'box2' => 'Box Two Placeholder', |
|
| 50 | - ), |
|
| 51 | - 'data' => array( |
|
| 52 | - 'box1' => 'Box One Title', |
|
| 53 | - 'box2' => 'Box Two Title', |
|
| 54 | - ), |
|
| 55 | - ), |
|
| 56 | - ), |
|
| 57 | - ) |
|
| 13 | + $opt_name, |
|
| 14 | + array( |
|
| 15 | + 'title' => esc_html__( 'Text', '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/text.html" target="_blank">https://devs.redux.io/core-fields/text.html</a>', |
|
| 17 | + 'id' => 'basic-text', |
|
| 18 | + 'subsection' => true, |
|
| 19 | + 'customizer_width' => '700px', |
|
| 20 | + 'fields' => array( |
|
| 21 | + array( |
|
| 22 | + 'id' => 'text-example', |
|
| 23 | + 'type' => 'text', |
|
| 24 | + 'title' => esc_html__( 'Text Field', 'your-textdomain-here' ), |
|
| 25 | + 'subtitle' => esc_html__( 'Subtitle', 'your-textdomain-here' ), |
|
| 26 | + 'desc' => esc_html__( 'Field Description', 'your-textdomain-here' ), |
|
| 27 | + 'default' => 'Default Text', |
|
| 28 | + ), |
|
| 29 | + array( |
|
| 30 | + 'id' => 'text-example-hint', |
|
| 31 | + 'type' => 'text', |
|
| 32 | + 'title' => esc_html__( 'Text Field w/ Hint', 'your-textdomain-here' ), |
|
| 33 | + 'subtitle' => esc_html__( 'Subtitle', 'your-textdomain-here' ), |
|
| 34 | + 'desc' => esc_html__( 'Field Description', 'your-textdomain-here' ), |
|
| 35 | + 'default' => 'Default Text', |
|
| 36 | + 'hint' => array( |
|
| 37 | + 'title' => 'Hint Title', |
|
| 38 | + 'content' => 'Hint content about this field!', |
|
| 39 | + ), |
|
| 40 | + ), |
|
| 41 | + array( |
|
| 42 | + 'id' => 'text-placeholder', |
|
| 43 | + 'type' => 'text', |
|
| 44 | + 'title' => esc_html__( 'Text Field w/ placeholder using custom data object.', 'your-textdomain-here' ), |
|
| 45 | + 'subtitle' => esc_html__( 'Subtitle', 'your-textdomain-here' ), |
|
| 46 | + 'desc' => esc_html__( 'Field Description', 'your-textdomain-here' ), |
|
| 47 | + 'placeholder' => array( |
|
| 48 | + 'box1' => 'Box One Placeholder', |
|
| 49 | + 'box2' => 'Box Two Placeholder', |
|
| 50 | + ), |
|
| 51 | + 'data' => array( |
|
| 52 | + 'box1' => 'Box One Title', |
|
| 53 | + 'box2' => 'Box Two Title', |
|
| 54 | + ), |
|
| 55 | + ), |
|
| 56 | + ), |
|
| 57 | + ) |
|
| 58 | 58 | ); |
| 59 | 59 | // phpcs:enable |