PluginProbe
Visualizer – Tables & Charts Manager with Built-in AI Generator / 4.0.8
Visualizer – Tables & Charts Manager with Built-in AI Generator v4.0.8
4.0.8 4.0.7 4.0.6 4.0.5 4.0.4 4.0.3 3.0.5 3.0.6 3.0.7 3.0.8 3.0.9 3.1.0 3.1.1 3.1.2 3.1.3 3.10.0 3.10.1 3.10.10 3.10.11 3.10.12 3.10.13 3.10.14 3.10.15 3.10.2 3.10.3 All 149 releases
← All changes | templates/setup-wizard.php +362 -192 3.10.14.0.8 View file →
@@ -5,19 +5,29 @@
5 5 * @category Visualizer
6 6 * @package Templates
7 7 */
8 8
9 -$dashboard_url = add_query_arg(
10 - array(
11 - 'action' => 'visualizer_dismiss_wizard',
12 - 'status' => 0,
9 +$dashboard_url = wp_nonce_url(
10 + add_query_arg(
11 + array(
12 + 'action' => 'visualizer_dismiss_wizard',
13 + 'status' => 0,
14 + ),
15 + admin_url( 'admin.php' )
13 16 ),
14 - admin_url( 'admin.php' )
17 + 'visualizer_dismiss_wizard'
15 18 );
16 19
17 20 $chart_id = ! empty( $this->wizard_data['chart_id'] ) ? (int) $this->wizard_data['chart_id'] : '';
21 +$chart_type_default = ! empty( $this->wizard_data['chart_type'] ) ? $this->wizard_data['chart_type'] : 'pie';
18 22 $wp_optimole_active = is_plugin_active( 'optimole-wp/optimole-wp.php' );
19 -$last_step_number = 5;
23 +$wp_otter_active = is_plugin_active( 'otter-blocks/otter-blocks.php' );
24 +$wp_spc_active = is_plugin_active( 'wp-cloudflare-page-cache/wp-cloudflare-super-page-cache.php' );
25 +$last_step_number = 3;
26 +
27 +// Check if we are in the Live Preview which is used to showcase only the plugin features without any other distractions. Ideal for marketing purposes (like Live Preview on WordPress.org or on the plugin's website)
28 +$is_live_preview = ! empty( $_GET['env'] ) ? ( 'preview' === sanitize_key( $_GET['env'] ) ) : false;
29 +
20 30 ?>
21 31 <div class="vz-wizard-wrap vz-wrap">
22 32 <div class="vz-header--small">
23 33 <div class="container">
@@ -22,16 +32,15 @@
22 32 <div class="vz-header--small">
23 33 <div class="container">
24 34 <div class="vz-logo">
25 35 <div class="vz-logo-icon">
26 - <img src="<?php echo esc_url( VISUALIZER_ABSURL . 'images/visualizer-logo.svg' ); ?>" width="136" height="54"
27 - alt="">
36 + <img src="<?php echo esc_url( VISUALIZER_ABSURL . 'images/visualizer-logo.svg' ); ?>" width="136" height="54" alt="">
28 37 </div>
29 38 </div>
30 39 <div class="back-btn">
31 - <a href="<?php echo esc_url( $dashboard_url ); ?>" class="btn-link"><span
32 - class="dashicons dashicons-arrow-left-alt"></span>
33 - <?php esc_html_e( 'Go to dashboard', 'visualizer' ); ?></a>
40 + <a href="<?php echo esc_url( $dashboard_url ); ?>" class="btn-link">
41 + <span class="dashicons dashicons-arrow-left-alt"></span><?php esc_html_e( 'Go to dashboard', 'visualizer' ); ?>
42 + </a>
34 43 </div>
35 44 </div>
36 45 </div>
37 46 <div class="container">
@@ -47,32 +56,15 @@
47 56 <a class="nav-link" href="#step-2">
48 57 2
49 58 </a>
50 59 </li>
51 - <li class="nav-item">
52 - <a class="nav-link" href="#step-3">
53 - 3
54 - </a>
55 - </li>
56 - <?php if ( ! $wp_optimole_active ) : ?>
60 + <?php if ( ! $is_live_preview ) { ?>
57 61 <li class="nav-item">
58 - <a class="nav-link" href="#step-4">
59 - 4
62 + <a class="nav-link" href="#step-3">
63 + 3
60 64 </a>
61 65 </li>
62 - <li class="nav-item">
63 - <a class="nav-link" href="#step-5">
64 - 5
65 - </a>
66 - </li>
67 - <?php else : ?>
68 - <?php $last_step_number = 4; ?>
69 - <li class="nav-item">
70 - <a class="nav-link" href="#step-4">
71 - 4
72 - </a>
73 - </li>
74 - <?php endif; ?>
66 + <?php } ?>
75 67 </ul>
76 68 <div class="tab-content">
77 69 <div id="step-1" class="tab-pane" role="tabpanel" aria-labelledby="step-1">
78 70 <div class="vz-accordion-item">
@@ -78,11 +70,11 @@
78 70 <div class="vz-accordion-item">
79 71 <div class="vz-accordion-item__title">
80 72 <div class="vz-accordion-item__button">
81 73 <h2 class="h2 pb-8">
82 - <?php esc_html_e( 'Select chart from the below available options', 'visualizer' ); ?></h2>
74 + <?php esc_html_e( 'Select a chart from the options available below', 'visualizer' ); ?></h2>
83 75 <p class="p">
84 - <?php esc_html_e( 'Pro tip: Keep your requirements in mind and select best chart for it', 'visualizer' ); ?>
76 + <?php esc_html_e( 'Pro tip: Keep your requirements in mind and choose the best chart to meet them.', 'visualizer' ); ?>
85 77 </p>
86 78 </div>
87 79 </div>
88 80 <div class="vz-accordion-item__content border-top">
@@ -91,9 +83,9 @@
91 83 <div class="vz-chart-list">
92 84 <ul>
93 85 <li>
94 86 <label class="vz-chart-option" for="vz-chart-1">
95 - <input type="radio" class="vz-radio-btn" id="vz-chart-1" name="visualizer[wizard_data][chart_type]" value="pie">
87 + <input type="radio" class="vz-radio-btn" id="vz-chart-1" name="visualizer[wizard_data][chart_type]" value="pie" <?php echo checked( $chart_type_default, 'pie', false ); ?>>
96 88 <h3 class="h3"><?php esc_html_e( 'Pie/Donut chart', 'visualizer' ); ?></h3>
97 89 <div class="img type-box-pie"></div>
98 90 <div class="bg"></div>
99 91 </label>
@@ -99,9 +91,9 @@
99 91 </label>
100 92 </li>
101 93 <li>
102 94 <label class="vz-chart-option" for="vz-chart-2">
103 - <input type="radio" class="vz-radio-btn" id="vz-chart-2" name="visualizer[wizard_data][chart_type]" value="bar">
95 + <input type="radio" class="vz-radio-btn" id="vz-chart-2" name="visualizer[wizard_data][chart_type]" value="bar" <?php echo checked( $chart_type_default, 'bar', false ); ?>>
104 96 <h3 class="h3"><?php esc_html_e( 'Bar chart', 'visualizer' ); ?></h3>
105 97 <div class="img type-box-bar"></div>
106 98 <div class="bg"></div>
107 99 </label>
@@ -107,9 +99,9 @@
107 99 </label>
108 100 </li>
109 101 <li>
110 102 <label class="vz-chart-option" for="vz-chart-3">
111 - <input type="radio" class="vz-radio-btn" id="vz-chart-3" name="visualizer[wizard_data][chart_type]" value="line">
103 + <input type="radio" class="vz-radio-btn" id="vz-chart-3" name="visualizer[wizard_data][chart_type]" value="line" <?php echo checked( $chart_type_default, 'line', false ); ?>>
112 104 <h3 class="h3"><?php esc_html_e( 'Line chart', 'visualizer' ); ?></h3>
113 105 <div class="img type-box-line"></div>
114 106 <div class="bg"></div>
115 107 </label>
@@ -115,9 +107,9 @@
115 107 </label>
116 108 </li>
117 109 <li>
118 110 <label class="vz-chart-option" for="vz-chart-4">
119 - <input type="radio" class="vz-radio-btn" id="vz-chart-4" name="visualizer[wizard_data][chart_type]" value="tabular">
111 + <input type="radio" class="vz-radio-btn" id="vz-chart-4" name="visualizer[wizard_data][chart_type]" value="tabular" <?php echo checked( $chart_type_default, 'tabular', false ); ?>>
120 112 <h3 class="h3"><?php esc_html_e( 'Table', 'visualizer' ); ?></h3>
121 113 <div class="img type-box-tabular"></div>
122 114 <div class="bg"></div>
123 115 </label>
@@ -127,9 +119,9 @@
127 119 <label class="vz-chart-option">
128 120 <input type="radio" class="vz-radio-btn" id="vz-chart-5" readonly>
129 121 <div class="vz-pro-label-wrap">
130 122 <h3><?php esc_html_e( 'Geo chart', 'visualizer' ); ?></h3>
131 - <span class="pro-label"><?php esc_html_e( 'PRO', 'visualizer' ); ?></span>
123 + <span class="pro-label"><?php esc_html_e( 'PREMIUM', 'visualizer' ); ?></span>
132 124 </div>
133 125 <div class="img type-box-geo"></div>
134 126 <div class="bg"></div>
135 127 </label>
@@ -141,27 +133,210 @@
141 133 </div>
142 134 </div>
143 135 </li>
144 136 <li>
145 - <div class="vz-power-pro">
146 - <h3 class="h3"><?php esc_html_e( 'Discover the power of PRO!', 'visualizer' ); ?></h3>
147 - <ul>
148 - <li><?php esc_html_e( '11 more chart types', 'visualizer' ); ?></li>
149 - <li><?php esc_html_e( 'Private charts', 'visualizer' ); ?></li>
150 - <li><?php esc_html_e( 'Auto-sync with online files', 'visualizer' ); ?></li>
151 - <li>
152 - <?php esc_html_e( 'Frontend Actions(Print, Export, Copy, Download', 'visualizer' ); ?>)
153 - </li>
154 - <li><?php esc_html_e( 'Create charts from WordPress tables', 'visualizer' ); ?></li>
155 - </ul>
156 - <a href="<?php echo esc_url( tsdk_utmify( Visualizer_Plugin::PRO_TEASER_URL, 'setupWizard' ) ); ?>" class="btn btn-secondary" target="_blank"><?php esc_html_e( 'View more features', 'visualizer' ); ?></a>
137 + <div class="vz-pro-option">
138 + <label class="vz-chart-option">
139 + <input type="radio" class="vz-radio-btn" id="vz-chart-6" readonly>
140 + <div class="vz-pro-label-wrap">
141 + <h3><?php esc_html_e( 'Area chart', 'visualizer' ); ?></h3>
142 + <span class="pro-label"><?php esc_html_e( 'PREMIUM', 'visualizer' ); ?></span>
143 + </div>
144 + <div class="img type-box-area"></div>
145 + <div class="bg"></div>
146 + </label>
147 + <div class="pro-overlay">
148 + <div class="pro-box">
149 + <a href="<?php echo esc_url( tsdk_utmify( Visualizer_Plugin::PRO_TEASER_URL, 'setupWizard' ) ); ?>"
150 + class="btn btn-secondary" target="_blank"><?php esc_html_e( 'Upgrade to Pro', 'visualizer' ); ?></a>
151 + </div>
152 + </div>
157 153 </div>
158 154 </li>
155 + <li>
156 + <div class="vz-pro-option">
157 + <label class="vz-chart-option">
158 + <input type="radio" class="vz-radio-btn" id="vz-chart-7" readonly>
159 + <div class="vz-pro-label-wrap">
160 + <h3><?php esc_html_e( 'Column chart', 'visualizer' ); ?></h3>
161 + <span class="pro-label"><?php esc_html_e( 'PREMIUM', 'visualizer' ); ?></span>
162 + </div>
163 + <div class="img type-box-column"></div>
164 + <div class="bg"></div>
165 + </label>
166 + <div class="pro-overlay">
167 + <div class="pro-box">
168 + <a href="<?php echo esc_url( tsdk_utmify( Visualizer_Plugin::PRO_TEASER_URL, 'setupWizard' ) ); ?>"
169 + class="btn btn-secondary" target="_blank"><?php esc_html_e( 'Upgrade to Pro', 'visualizer' ); ?></a>
170 + </div>
171 + </div>
172 + </div>
173 + </li>
174 + <li>
175 + <div class="vz-pro-option">
176 + <label class="vz-chart-option">
177 + <input type="radio" class="vz-radio-btn" id="vz-chart-8" readonly>
178 + <div class="vz-pro-label-wrap">
179 + <h3><?php esc_html_e( 'Bubble chart', 'visualizer' ); ?></h3>
180 + <span class="pro-label"><?php esc_html_e( 'PREMIUM', 'visualizer' ); ?></span>
181 + </div>
182 + <div class="img type-box-bubble"></div>
183 + <div class="bg"></div>
184 + </label>
185 + <div class="pro-overlay">
186 + <div class="pro-box">
187 + <a href="<?php echo esc_url( tsdk_utmify( Visualizer_Plugin::PRO_TEASER_URL, 'setupWizard' ) ); ?>"
188 + class="btn btn-secondary" target="_blank"><?php esc_html_e( 'Upgrade to Pro', 'visualizer' ); ?></a>
189 + </div>
190 + </div>
191 + </div>
192 + </li>
193 + <li>
194 + <div class="vz-pro-option">
195 + <label class="vz-chart-option">
196 + <input type="radio" class="vz-radio-btn" id="vz-chart-9" readonly>
197 + <div class="vz-pro-label-wrap">
198 + <h3><?php esc_html_e( 'Scatter chart', 'visualizer' ); ?></h3>
199 + <span class="pro-label"><?php esc_html_e( 'PREMIUM', 'visualizer' ); ?></span>
200 + </div>
201 + <div class="img type-box-scatter"></div>
202 + <div class="bg"></div>
203 + </label>
204 + <div class="pro-overlay">
205 + <div class="pro-box">
206 + <a href="<?php echo esc_url( tsdk_utmify( Visualizer_Plugin::PRO_TEASER_URL, 'setupWizard' ) ); ?>"
207 + class="btn btn-secondary" target="_blank"><?php esc_html_e( 'Upgrade to Pro', 'visualizer' ); ?></a>
208 + </div>
209 + </div>
210 + </div>
211 + </li>
212 + <li>
213 + <div class="vz-pro-option">
214 + <label class="vz-chart-option">
215 + <input type="radio" class="vz-radio-btn" id="vz-chart-10" readonly>
216 + <div class="vz-pro-label-wrap">
217 + <h3><?php esc_html_e( 'Gauge chart', 'visualizer' ); ?></h3>
218 + <span class="pro-label"><?php esc_html_e( 'PREMIUM', 'visualizer' ); ?></span>
219 + </div>
220 + <div class="img type-box-gauge"></div>
221 + <div class="bg"></div>
222 + </label>
223 + <div class="pro-overlay">
224 + <div class="pro-box">
225 + <a href="<?php echo esc_url( tsdk_utmify( Visualizer_Plugin::PRO_TEASER_URL, 'setupWizard' ) ); ?>"
226 + class="btn btn-secondary" target="_blank"><?php esc_html_e( 'Upgrade to Pro', 'visualizer' ); ?></a>
227 + </div>
228 + </div>
229 + </div>
230 + </li>
231 + <li>
232 + <div class="vz-pro-option">
233 + <label class="vz-chart-option">
234 + <input type="radio" class="vz-radio-btn" id="vz-chart-11" readonly>
235 + <div class="vz-pro-label-wrap">
236 + <h3><?php esc_html_e( 'Candlestick chart', 'visualizer' ); ?></h3>
237 + <span class="pro-label"><?php esc_html_e( 'PREMIUM', 'visualizer' ); ?></span>
238 + </div>
239 + <div class="img type-box-candlestick"></div>
240 + <div class="bg"></div>
241 + </label>
242 + <div class="pro-overlay">
243 + <div class="pro-box">
244 + <a href="<?php echo esc_url( tsdk_utmify( Visualizer_Plugin::PRO_TEASER_URL, 'setupWizard' ) ); ?>"
245 + class="btn btn-secondary" target="_blank"><?php esc_html_e( 'Upgrade to Pro', 'visualizer' ); ?></a>
246 + </div>
247 + </div>
248 + </div>
249 + </li>
250 + <li>
251 + <div class="vz-pro-option">
252 + <label class="vz-chart-option">
253 + <input type="radio" class="vz-radio-btn" id="vz-chart-12" readonly>
254 + <div class="vz-pro-label-wrap">
255 + <h3><?php esc_html_e( 'Timeline', 'visualizer' ); ?></h3>
256 + <span class="pro-label"><?php esc_html_e( 'PREMIUM', 'visualizer' ); ?></span>
257 + </div>
258 + <div class="img type-box-timeline"></div>
259 + <div class="bg"></div>
260 + </label>
261 + <div class="pro-overlay">
262 + <div class="pro-box">
263 + <a href="<?php echo esc_url( tsdk_utmify( Visualizer_Plugin::PRO_TEASER_URL, 'setupWizard' ) ); ?>"
264 + class="btn btn-secondary" target="_blank"><?php esc_html_e( 'Upgrade to Pro', 'visualizer' ); ?></a>
265 + </div>
266 + </div>
267 + </div>
268 + </li>
269 + <li>
270 + <div class="vz-pro-option">
271 + <label class="vz-chart-option">
272 + <input type="radio" class="vz-radio-btn" id="vz-chart-13" readonly>
273 + <div class="vz-pro-label-wrap">
274 + <h3><?php esc_html_e( 'Combo', 'visualizer' ); ?></h3>
275 + <span class="pro-label"><?php esc_html_e( 'PREMIUM', 'visualizer' ); ?></span>
276 + </div>
277 + <div class="img type-box-combo"></div>
278 + <div class="bg"></div>
279 + </label>
280 + <div class="pro-overlay">
281 + <div class="pro-box">
282 + <a href="<?php echo esc_url( tsdk_utmify( Visualizer_Plugin::PRO_TEASER_URL, 'setupWizard' ) ); ?>"
283 + class="btn btn-secondary" target="_blank"><?php esc_html_e( 'Upgrade to Pro', 'visualizer' ); ?></a>
284 + </div>
285 + </div>
286 + </div>
287 + </li>
288 + <li>
289 + <div class="vz-pro-option">
290 + <label class="vz-chart-option">
291 + <input type="radio" class="vz-radio-btn" id="vz-chart-14" readonly>
292 + <div class="vz-pro-label-wrap">
293 + <h3><?php esc_html_e( 'Polar Area', 'visualizer' ); ?></h3>
294 + <span class="pro-label"><?php esc_html_e( 'PREMIUM', 'visualizer' ); ?></span>
295 + </div>
296 + <div class="img type-box-polarArea"></div>
297 + <div class="bg"></div>
298 + </label>
299 + <div class="pro-overlay">
300 + <div class="pro-box">
301 + <a href="<?php echo esc_url( tsdk_utmify( Visualizer_Plugin::PRO_TEASER_URL, 'setupWizard' ) ); ?>"
302 + class="btn btn-secondary" target="_blank"><?php esc_html_e( 'Upgrade to Pro', 'visualizer' ); ?></a>
303 + </div>
304 + </div>
305 + </div>
306 + </li>
307 + <li>
308 + <div class="vz-pro-option">
309 + <label class="vz-chart-option">
310 + <input type="radio" class="vz-radio-btn" id="vz-chart-15" readonly>
311 + <div class="vz-pro-label-wrap">
312 + <h3><?php esc_html_e( 'Radar', 'visualizer' ); ?></h3>
313 + <span class="pro-label"><?php esc_html_e( 'PREMIUM', 'visualizer' ); ?></span>
314 + </div>
315 + <div class="img type-box-radar"></div>
316 + <div class="bg"></div>
317 + </label>
318 + <div class="pro-overlay">
319 + <div class="pro-box">
320 + <a href="<?php echo esc_url( tsdk_utmify( Visualizer_Plugin::PRO_TEASER_URL, 'setupWizard' ) ); ?>"
321 + class="btn btn-secondary" target="_blank"><?php esc_html_e( 'Upgrade to Pro', 'visualizer' ); ?></a>
322 + </div>
323 + </div>
324 + </div>
325 + </li>
159 326 </ul>
160 327 </div>
161 328 </div>
162 329 <div class="form-block">
163 330 <button class="btn btn-primary disabled" data-step_number="1"><?php esc_html_e( 'Save And Continue', 'visualizer' ); ?> <span class="dashicons dashicons-arrow-right-alt"></span></button>
331 + <span class="spinner"></span>
332 + <div class="vz-import-status" style="display: none;">
333 + <div class="vz-error-notice notice notice-error hidden"></div>
334 + <p class="p pb-8" data-import_message="<?php esc_attr_e( 'Done! Demo data has been successfully imported.', 'visualizer' ); ?>" data-import_initial="<?php esc_attr_e( 'Importing demo data for your selected chart...', 'visualizer' ); ?>"><?php esc_html_e( 'Importing demo data for your selected chart...', 'visualizer' ); ?></p>
335 + <div class="vz-progress">
336 + <div class="vz-progress-bar"></div>
337 + </div>
338 + </div>
164 339 </div>
165 340 </div>
166 341 </div>
167 342 </div>
@@ -169,84 +344,47 @@
169 344 <div id="step-2" class="tab-pane" role="tabpanel" aria-labelledby="step-2">
170 345 <div class="vz-accordion-item">
171 346 <div class="vz-accordion-item__title">
172 347 <div class="vz-accordion-item__button">
173 - <h2 class="h2 pb-8"><?php esc_html_e( 'You\'re almost done!', 'visualizer' ); ?></h2>
174 - <p class="p"><?php esc_html_e( 'We use demo data during the import process, don&#x92;t worry you can customize it later', 'visualizer' ); ?></p>
348 + <h2 class="h2 pb-8"><?php esc_html_e( 'Insert a chart into the draft page', 'visualizer' ); ?></h2>
349 + <p class="p"><?php esc_html_e( 'Create a draft page featuring a Visualizer chart with just one click.', 'visualizer' ); ?></p>
175 350 </div>
176 - <div class="vz-progress">
177 - <div class="vz-progress-bar" style="width: 100%;"></div>
178 - </div>
179 351 </div>
180 - <div class="vz-accordion-item__content">
352 + <div class="vz-accordion-item__content border-top">
181 353 <div class="vz-form-wrap">
182 354 <div class="form-block">
183 - <div class="vz-error-notice notice notice-error hidden"></div>
184 - <div class="pb-30">
355 + <div class="vz-accordion-item vz-features-accordion mb-0">
185 356 <div class="vz-shortcode-preview-box">
186 - <div class="vz-shortcode-preview-title border-0">
187 - <div class="icon">
188 - <img src="<?php echo esc_url( VISUALIZER_ABSURL . 'images/database-icon.png' ); ?>" alt="">
357 + <div class="vz-accordion-item__title vz-accordion-checkbox__title vz-accordion-title--static">
358 + <div class="vz-checkbox">
359 + <input type="checkbox" class="vz-checkbox-btn" id="insert_shortcode" checked <?php echo $is_live_preview ? 'disabled' : ''; ?>>
189 360 </div>
190 - <div class="txt">
191 - <h4 class="h4 pb-4"><?php esc_html_e( 'Importing demo data', 'visualizer' ); ?></h4>
192 - <p class="p" data-import_message="<?php esc_attr_e( 'Done! Demo data imported successfully', 'visualizer' ); ?>"><?php esc_html_e( 'Hold on! we are importing demo data for your selected chart', 'visualizer' ); ?></p>
361 + <div>
362 + <div class="vz-accordion__step-title h4 pb-4"><?php esc_html_e( 'Create a draft page', 'visualizer' ); ?></div>
363 + <p class="help-text"><?php esc_html_e( 'We will automatically create a draft page with Visualizer chart for preview', 'visualizer' ); ?></p>
193 364 </div>
194 365 </div>
195 - </div>
196 - </div>
197 - <p class="help-text help-text-primary pb-16"><?php esc_html_e( 'Import data from other Charts, WordPress, DataBase, or Manual Data with Visualizer', 'visualizer' ); ?> <a href="<?php echo esc_url( tsdk_utmify( Visualizer_Plugin::PRO_TEASER_URL, 'setupWizard' ) ); ?>" target="_blank"><?php esc_html_e( 'Premium version', 'visualizer' ); ?></a></p>
198 - </div>
199 - <div class="form-block"><button class="btn btn-primary disabled" data-step_number="3"><?php esc_html_e( 'Continue', 'visualizer' ); ?> <span class="dashicons dashicons-arrow-right-alt"></span></button>
200 - </div>
201 - </div>
202 - </div>
203 - </div>
204 - </div>
205 - <div id="step-3" class="tab-pane" role="tabpanel" aria-labelledby="step-3">
206 - <div class="vz-accordion-item">
207 - <div class="vz-accordion-item__title">
208 - <div class="vz-accordion-item__button">
209 - <h2 class="h2 pb-8"><?php esc_html_e( 'Insert chart into the draft page', 'visualizer' ); ?></h2>
210 - <p class="p"><?php esc_html_e( 'Create a draft page with a Visualizer chart with just one click', 'visualizer' ); ?></p>
211 - </div>
212 - </div>
213 - <div class="vz-accordion-item__content border-top">
214 - <div class="vz-form-wrap">
215 - <div class="form-block">
216 - <div class="vz-accordion">
217 - <div class="vz-accordion-item vz-features-accordion mb-0">
218 - <div class="vz-shortcode-preview-box">
219 - <div class="vz-accordion-item__title vz-accordion-checkbox__title">
220 - <div class="vz-checkbox">
221 - <input type="checkbox" class="vz-checkbox-btn" id="insert_shortcode" checked>
222 - </div>
223 - <button type="button" class="vz-accordion-item__button">
224 - <div class="vz-accordion__step-title h4 pb-4"><?php esc_html_e( 'Create a draft page', 'visualizer' ); ?></div>
225 - <p class="help-text"><?php esc_html_e( 'We will automatically create a draft page with Visualizer chart for preview', 'visualizer' ); ?></p>
226 - <div class="vz-accordion__icon"><span class="dashicons dashicons-arrow-down-alt2"></span>
366 + <div class="vz-accordion-item__content vz-accordion-content--static">
367 + <div class="vz-shortcode-preview-content">
368 + <?php $shortcode = '[visualizer id="{{chart_id}}" class=""]'; ?>
369 + <?php if ( $is_live_preview ) { ?>
370 + <p class="pb-16"><?php esc_html_e( 'Charts are added in the page/post via Gutenberg Blocks.', 'visualizer' ); ?></p>
371 + <p class="pb-16"><?php esc_html_e( 'Alternatively, you can use a shortcode with the following structure:', 'visualizer' ); ?></p>
372 + <?php } else { ?>
373 + <h4 class="h4 pb-16"><?php esc_html_e( 'Chart preview', 'visualizer' ); ?></h4>
374 + <div class="vz-chart pb-30">
375 + <?php
376 + if ( ! empty( $_GET['preview_chart'] ) ) {
377 + $shortcode = str_replace( '{{chart_id}}', $chart_id, $shortcode );
378 + echo do_shortcode( $shortcode );
379 + }
380 + ?>
227 381 </div>
228 - </button>
229 - </div>
230 - <div class="vz-accordion-item__content">
231 - <div class="vz-shortcode-preview-content">
232 - <div class="vz-shortcode-preview">
233 - <h4 class="h4 pb-16"><?php esc_html_e( 'Chart preview', 'visualizer' ); ?></h4>
234 - <div class="vz-chart pb-30">
235 - <?php
236 - $shortcode = '[visualizer id="{{chart_id}}" lazy="" class=""]';
237 - if ( ! empty( $_GET['preview_chart'] ) ) {
238 - $shortcode = str_replace( '{{chart_id}}', $chart_id, $shortcode );
239 - echo do_shortcode( $shortcode );
240 - }
241 - ?>
242 - </div>
243 - <div class="vz-code-box">
244 - <input type="text" id="basic_shortcode" value="<?php echo esc_attr( $shortcode ); ?>" redonly>
245 - <button type="button" class="vz-copy-code-btn" data-clipboard-target="#basic_shortcode"><?php esc_html_e( 'click to copy', 'visualizer' ); ?> <img src="<?php echo esc_url( VISUALIZER_ABSURL . 'images/copy.svg' ); ?>" alt="">
246 - </button>
247 - </div>
248 - </div>
382 + <?php } ?>
383 + <div class="vz-code-box">
384 + <input type="text" id="basic_shortcode" value="<?php echo esc_attr( $shortcode ); ?>" readonly>
385 + <button type="button" class="vz-copy-code-btn" data-clipboard-target="#basic_shortcode"><?php esc_html_e( 'click to copy', 'visualizer' ); ?> <img src="<?php echo esc_url( VISUALIZER_ABSURL . 'images/copy.svg' ); ?>" alt="">
386 + </button>
249 387 </div>
250 388 </div>
251 389 </div>
252 390 </div>
@@ -259,96 +397,128 @@
259 397 </div>
260 398 </div>
261 399 </div>
262 400 </div>
263 - <?php if ( ! $wp_optimole_active ) : ?>
264 - <div id="step-4" class="tab-pane" role="tabpanel" aria-labelledby="step-4">
265 - <div class="vz-accordion-item">
266 - <div class="vz-accordion-item__title">
267 - <div class="vz-accordion-item__button">
268 - <h2 class="h2 pb-8"><?php esc_html_e( 'Extra Features', 'visualizer' ); ?></h2>
269 - <p class="p"><?php esc_html_e( 'We\'re confident you\'ll see the improvements. Otherwise, you can remove it anytime', 'visualizer' ); ?></p>
401 + <?php if ( ! $is_live_preview ) { ?>
402 + <div id="step-<?php echo esc_attr( $last_step_number ); ?>" class="tab-pane" role="tabpanel" aria-labelledby="step-<?php echo esc_attr( $last_step_number ); ?>">
403 + <div class="vz-accordion-item">
404 + <div class="vz-accordion-item__title">
405 + <div class="vz-accordion-item__button">
406 + <h2 class="h2 pb-8"><?php esc_html_e( 'You\'re all set!', 'visualizer' ); ?></h2>
407 + <p class="p"><?php esc_html_e( 'Optionally enhance your site and stay updated.', 'visualizer' ); ?></p>
408 + </div>
270 409 </div>
271 - </div>
272 - <div class="vz-accordion-item__content border-top">
273 - <div class="vz-form-wrap">
274 - <div class="form-block">
275 - <div class="vz-error-notice notice notice-error hidden"></div>
276 - <div class="vz-accordion">
277 - <div class="vz-accordion-item vz-features-accordion mb-0">
278 - <div class="vz-accordion-item__title vz-accordion-checkbox__title">
279 - <div class="vz-checkbox">
280 - <input type="checkbox" class="vz-checkbox-btn" checked>
410 + <div class="vz-accordion-item__content border-top">
411 + <div class="vz-form-wrap">
412 + <div class="form-block no-sep vz-final-block">
413 + <div class="vz-error-notice notice notice-error hidden"></div>
414 + <div class="vz-final-options">
415 + <div class="vz-option-card">
416 + <label class="vz-option-check">
417 + <input type="checkbox" id="enable_performance" <?php echo $wp_optimole_active ? 'checked disabled' : 'checked'; ?>>
418 + </label>
419 + <div class="vz-option-icon">
420 + <img src="<?php echo esc_url( VISUALIZER_ABSURL . 'images/boost-logo.png' ); ?>" width="37" height="30" alt="">
281 421 </div>
282 - <button type="button" class="vz-accordion-item__button">
283 - <div class="vz-accordion__step-title h4 pb-4"><?php esc_html_e( 'Enable perfomance features for your website.', 'visualizer' ); ?></div>
284 - <p class="help-text"><?php esc_html_e( 'Optimise and speed up your site with our trusted addon - It&#x92;s Free', 'visualizer' ); ?></p>
285 - <div class="vz-accordion__icon"><span class="dashicons dashicons-arrow-down-alt2"></span>
422 + <div class="vz-option-body">
423 + <div class="vz-option-title">
424 + <?php esc_html_e( 'Boost your website speed', 'visualizer' ); ?>
425 + <span class="pro-label free-label"><?php esc_html_e( 'Free', 'visualizer' ); ?></span>
286 426 </div>
287 - </button>
427 + <p class="help-text">
428 + <?php
429 + if ( $wp_optimole_active ) {
430 + esc_html_e( 'Optimole is already active on your site.', 'visualizer' );
431 + } else {
432 + esc_html_e( 'Improve your website speed and images by 80% with Optimole.', 'visualizer' );
433 + }
434 + ?>
435 + </p>
436 + </div>
437 + <span class="vz-install-status" data-install-status="optimole-wp"></span>
288 438 </div>
289 - <div class="vz-accordion-item__content">
290 - <div class="vz-features-list">
291 - <ul>
292 - <li>
293 - <div class="icon">
294 - <img src="<?php echo esc_url( VISUALIZER_ABSURL . 'images/boost-logo.png' ); ?>" width="37" height="30" alt="">
295 - </div>
296 - <div class="txt">
297 - <div class="h4 pb-4"><?php esc_html_e( 'Boost your website speed', 'visualizer' ); ?> <span class="pro-label free-label"><?php esc_html_e( 'Free', 'visualizer' ); ?></span></div>
298 - <p class="help-text"><?php esc_html_e( 'Improve your website speed and images by 80% with', 'visualizer' ); ?> <a href="<?php echo esc_url( tsdk_utmify( 'https://optimole.com/', 'VisualizerSetupWizard' ) ); ?>" target="_blank"><?php esc_html_e( 'Optimole', 'visualizer' ); ?></a></p>
299 - </div>
300 - </li>
301 - </ul>
439 + <div class="vz-option-card">
440 + <label class="vz-option-check">
441 + <input type="checkbox" id="enable_otter_blocks" <?php echo $wp_otter_active ? 'checked disabled' : 'checked'; ?>>
442 + </label>
443 + <div class="vz-option-icon">
444 + <img src="<?php echo esc_url( VISUALIZER_ABSURL . 'images/otter-logo.png' ); ?>" width="28" height="28" alt="">
302 445 </div>
446 + <div class="vz-option-body">
447 + <div class="vz-option-title">
448 + <?php esc_html_e( 'Build better pages', 'visualizer' ); ?>
449 + <span class="pro-label free-label"><?php esc_html_e( 'Free', 'visualizer' ); ?></span>
450 + </div>
451 + <p class="help-text">
452 + <?php
453 + if ( $wp_otter_active ) {
454 + esc_html_e( 'Otter Blocks is already active on your site.', 'visualizer' );
455 + } else {
456 + esc_html_e( 'Add powerful Gutenberg blocks for layouts, forms, and more with Otter Blocks.', 'visualizer' );
457 + }
458 + ?>
459 + </p>
460 + </div>
461 + <span class="vz-install-status" data-install-status="otter-blocks"></span>
303 462 </div>
463 + <div class="vz-option-card">
464 + <label class="vz-option-check">
465 + <input type="checkbox" id="enable_page_cache" <?php echo $wp_spc_active ? 'checked disabled' : 'checked'; ?>>
466 + </label>
467 + <div class="vz-option-icon">
468 + <img src="<?php echo esc_url( VISUALIZER_ABSURL . 'images/spc-logo.svg' ); ?>" width="28" height="28" alt="">
469 + </div>
470 + <div class="vz-option-body">
471 + <div class="vz-option-title">
472 + <?php esc_html_e( 'Cache your pages', 'visualizer' ); ?>
473 + <span class="pro-label free-label"><?php esc_html_e( 'Free', 'visualizer' ); ?></span>
474 + </div>
475 + <p class="help-text">
476 + <?php
477 + if ( $wp_spc_active ) {
478 + esc_html_e( 'Super Page Cache is already active on your site.', 'visualizer' );
479 + } else {
480 + esc_html_e( 'Make your site load faster with Super Page Cache for Cloudflare.', 'visualizer' );
481 + }
482 + ?>
483 + </p>
484 + </div>
485 + <span class="vz-install-status" data-install-status="wp-cloudflare-page-cache"></span>
486 + </div>
487 + <div class="vz-option-card vz-option-card--newsletter">
488 + <label class="vz-option-check">
489 + <input type="checkbox" id="enable_newsletter" checked>
490 + </label>
491 + <div class="vz-option-icon">
492 + <span class="dashicons dashicons-email-alt"></span>
493 + </div>
494 + <div class="vz-option-body">
495 + <div class="vz-option-title"><?php esc_html_e( 'Stay in the loop', 'visualizer' ); ?></div>
496 + <p class="help-text">
497 + <?php esc_html_e( 'Get tutorials, tips, and special offers at', 'visualizer' ); ?>
498 + <span class="vz-email-text" data-email="<?php echo esc_attr( get_bloginfo( 'admin_email' ) ); ?>"><?php echo esc_html( get_bloginfo( 'admin_email' ) ); ?></span>
499 + <button type="button" class="vz-change-email"><?php esc_html_e( 'Change', 'visualizer' ); ?></button>
500 + <?php esc_html_e( '· Unsubscribe anytime.', 'visualizer' ); ?>
501 + </p>
502 + <div class="vz-option-input" style="display: none;">
503 + <input type="email" class="form-control" id="vz_subscribe_email" value="<?php echo esc_attr( get_bloginfo( 'admin_email' ) ); ?>">
504 + <button type="button" class="btn btn-primary vz-save-email"><?php esc_html_e( 'Save', 'visualizer' ); ?></button>
505 + </div>
506 + </div>
507 + </div>
304 508 </div>
305 509 </div>
306 - </div>
307 - <div class="form-block">
308 - <button class="btn btn-primary vz-wizard-install-plugin" data-step_number="4"><?php esc_html_e( 'Improve now', 'visualizer' ); ?>
309 - <button class="btn btn-primary next-btn skip-improvement" style="display: none;"><?php esc_html_e( 'Skip Improvement', 'visualizer' ); ?></button>
310 - <span class="spinner"></span>
311 - </div>
312 - </div>
313 - </div>
314 - </div>
315 - </div>
316 - <?php endif; ?>
317 - <div id="step-<?php echo esc_attr( $last_step_number ); ?>" class="tab-pane" role="tabpanel" aria-labelledby="step-5">
318 - <div class="vz-accordion-item">
319 - <div class="vz-accordion-item__title">
320 - <div class="vz-accordion-item__button">
321 - <h2 class="h2 pb-8"><?php esc_html_e( 'Updates, tutorials, special offers & more', 'visualizer' ); ?></h2>
322 - <p class="p"><?php esc_html_e( 'Get exclusive access of Visualizer newsletter', 'visualizer' ); ?></p>
323 - </div>
324 - </div>
325 - <div class="vz-accordion-item__content border-top">
326 - <div class="vz-form-wrap">
327 - <div class="form-block">
328 - <div class="vz-newsletter-wrap">
329 - <div class="vz-newsletter">
330 - <p class="p pb-30"><?php esc_html_e( 'Let us know your email so that we can send you product updates, helpful tutorials, exclusive offers and more useful stuff.', 'visualizer' ); ?></p>
331 - <div class="vz-form-group">
332 - <input type="email" class="form-control" id="vz_subscribe_email" placeholder="<?php echo esc_attr( get_bloginfo( 'admin_email' ) ); ?>">
333 - </div>
510 + <div class="form-block">
511 + <div class="vz-btn-group">
512 + <button class="btn btn-primary vz-subscribe" data-vz_subscribe="true"><?php esc_html_e( 'Finish Setup', 'visualizer' ); ?></button>
513 + <span class="spinner"></span>
334 514 </div>
335 - <div class="vz-newsletter-img">
336 - <img src="<?php echo esc_url( VISUALIZER_ABSURL . 'images/newsletter-img.png' ); ?>" alt="">
337 - </div>
338 515 </div>
339 516 </div>
340 - <div class="form-block">
341 - <div class="vz-btn-group">
342 - <button class="btn btn-primary vz-subscribe" data-vz_subscribe="true"><?php esc_html_e( 'Send Me Access', 'visualizer' ); ?></button>
343 - <button class="btn btn-outline-primary vz-subscribe" data-vz_subscribe="false"><?php esc_html_e( 'Skip, Don&#x92;t give me access', 'visualizer' ); ?></button>
344 - <span class="spinner"></span>
345 - </div>
346 - </div>
347 517 </div>
348 518 </div>
349 519 </div>
350 - </div>
520 + <?php } ?>
351 521 </div>
352 522 </div>
353 523 </div>
354 524 </div>