PluginProbe
Product Labels, Quick View, Buy Now, Pre-Orders, Frequently Bought Together & More for WooCommerce – Merchant / 2.2.8
Product Labels, Quick View, Buy Now, Pre-Orders, Frequently Bought Together & More for WooCommerce – Merchant v2.2.8
2.3.2 2.3.1 2.3.0 2.2.8 2.2.7 trunk 1.10.0 1.10.1 1.10.2 1.10.3 1.10.4 1.10.5 1.11.0 1.11.1 1.11.2 1.6 1.7 1.8 1.8.1 1.8.2 1.8.3 1.9.0 1.9.1 1.9.10 1.9.11 All 60 releases
merchant / inc / modules / cookie-banner / admin / options.php

options.php in Product Labels, Quick View, Buy Now, Pre-Orders, Frequently Bought Together & More for WooCommerce – Merchant 2.2.8, at inc/modules/cookie-banner/admin/options.php

146 lines 3.5 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <?php
2 /**
3 * Merchant - Cookie Banner
4 */
5
6 if ( ! defined( 'ABSPATH' ) ) {
7 exit; // Exit if accessed directly
8 }
9
10 /**
11 * Settings
12 */
13 Merchant_Admin_Options::create( array(
14 'title' => esc_html__( 'Settings', 'merchant' ),
15 'module' => 'cookie-banner',
16 'fields' => array(
17
18 array(
19 'id' => 'theme',
20 'type' => 'select',
21 'title' => esc_html__( 'Theme', 'merchant' ),
22 'options' => array(
23 'merchant-cookie-banner-floating' => esc_html__( 'Floating', 'merchant' ),
24 'merchant-cookie-banner-fixed-bottom' => esc_html__( 'Fixed bottom', 'merchant' ),
25 ),
26 'default' => 'merchant-cookie-banner-floating',
27 ),
28
29 array(
30 'id' => 'bar_text',
31 'type' => 'text',
32 'title' => esc_html__( 'Bar text', 'merchant' ),
33 'default' => esc_html__( '🍪 We\'re using cookies to give you the best experience on our site.', 'merchant' ),
34 ),
35
36 array(
37 'id' => 'privacy_policy_text',
38 'type' => 'text',
39 'title' => esc_html__( 'Privacy policy text', 'merchant' ),
40 'desc' => esc_html__( 'The error will be shown if the user tries to go to checkout without accepting terms & conditions.', 'merchant' ),
41 'default' => esc_html__( 'Learn More', 'merchant' ),
42 ),
43
44 array(
45 'id' => 'privacy_policy_url',
46 'type' => 'url',
47 'title' => esc_html__( 'Privacy policy URL', 'merchant' ),
48 'default' => get_privacy_policy_url(),
49 'placeholder' => 'yoursite.com/privacy-policy',
50 ),
51
52 array(
53 'id' => 'button_text',
54 'type' => 'text',
55 'title' => esc_html__( 'Button text', 'merchant' ),
56 'default' => esc_html__( 'I understand', 'merchant' ),
57 ),
58
59 array(
60 'id' => 'cookie_duration',
61 'type' => 'number',
62 'title' => esc_html__( 'Cookie duration (days)', 'merchant' ),
63 'min' => 1,
64 'step' => 1,
65 'default' => '365',
66 ),
67
68 array(
69 'id' => 'close_button',
70 'type' => 'switcher',
71 'title' => esc_html__( 'Show close \'x\' button', 'merchant' ),
72 'default' => 1,
73 ),
74
75 ),
76 ) );
77
78 /**
79 * Style
80 */
81 Merchant_Admin_Options::create( array(
82 'title' => esc_html__( 'Style', 'merchant' ),
83 'module' => 'cookie-banner',
84 'fields' => array(
85
86 array(
87 'id' => 'modal_width',
88 'type' => 'range',
89 'title' => esc_html__( 'Modal width', 'merchant' ),
90 'min' => 1,
91 'max' => 2000,
92 'step' => 1,
93 'default' => 750,
94 'unit' => 'px',
95 'condition' => array( 'theme', '==', 'floating' ),
96 ),
97
98 array(
99 'id' => 'modal_height',
100 'type' => 'range',
101 'title' => esc_html__( 'Modal height', 'merchant' ),
102 'min' => 1,
103 'max' => 1000,
104 'step' => 1,
105 'default' => 80,
106 'unit' => 'px',
107 ),
108
109 array(
110 'id' => 'background_color',
111 'type' => 'color',
112 'title' => esc_html__( 'Modal background color', 'merchant' ),
113 'default' => '#000000',
114 ),
115
116 array(
117 'id' => 'text_color',
118 'type' => 'color',
119 'title' => esc_html__( 'Text color', 'merchant' ),
120 'default' => '#ffffff',
121 ),
122
123 array(
124 'id' => 'link_color',
125 'type' => 'color',
126 'title' => esc_html__( 'Link color', 'merchant' ),
127 'default' => '#aeaeae',
128 ),
129
130 array(
131 'id' => 'button_background_color',
132 'type' => 'color',
133 'title' => esc_html__( 'Button background color', 'merchant' ),
134 'default' => '#dddddd',
135 ),
136
137 array(
138 'id' => 'button_text_color',
139 'type' => 'color',
140 'title' => esc_html__( 'Button text color', 'merchant' ),
141 'default' => '#151515',
142 ),
143
144 ),
145 ) );
146