PluginProbe
Visualizer – Tables & Charts Manager with Built-in AI Generator / 2.2.0
Visualizer – Tables & Charts Manager with Built-in AI Generator v2.2.0
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 | classes/Visualizer/Render/Sidebar.php +60 -193 3.0.92.2.0 View file →
@@ -83,16 +83,8 @@
83 83 */
84 84 protected $_alignments;
85 85
86 86 /**
87 - * Whether this chart supports animation or not.
88 - *
89 - * @access protected
90 - * @var bool
91 - */
92 - protected $_supportsAnimation = true;
93 -
94 - /**
95 87 * Constructor.
96 88 *
97 89 * @since 1.0.0
98 90 *
@@ -161,40 +153,10 @@
161 153 self::_renderSectionEnd();
162 154
163 155 $this->_renderActionSettings();
164 156 self::_renderGroupEnd();
165 -
166 - self::_renderGroupStart( esc_html__( 'Manual Configuration', 'visualizer' ) );
167 - self::_renderSectionStart();
168 - self::_renderSectionDescription( __( 'Configure the graph by providing configuration variables right from the', 'visualizer' ) . ' <a href="https://developers.google.com/chart/interactive/docs/reference" target="_blank">Google Visualization</a> API.' );
169 -
170 - $example = '
171 -{
172 - "vAxis": {
173 - "ticks": [5, 10, 15, 20],
174 - "titleTextStyle": {
175 - "color": "red"
176 - },
177 - "textPosition": "in"
178 157 }
179 -}';
180 158
181 - self::_renderTextAreaItem(
182 - esc_html__( 'Configuration', 'visualizer' ),
183 - 'manual',
184 - $this->manual,
185 - sprintf(
186 - esc_html__( 'One per line in valid JSON (key:value) format e.g. %s', 'visualizer' ), '<br><code>' . $example . '</code>'
187 - ),
188 - '',
189 - array( 'rows' => 5 )
190 - );
191 -
192 - self::_renderSectionEnd();
193 - self::_renderGroupEnd();
194 -
195 - }
196 -
197 159 /**
198 160 * Renders chart action buttons group.
199 161 *
200 162 * @access protected
@@ -199,10 +161,8 @@
199 161 *
200 162 * @access protected
201 163 */
202 164 protected function _renderActionSettings() {
203 - global $wp_version;
204 - $disable_actions = version_compare( $wp_version, '4.7.0', '<' );
205 165 self::_renderSectionStart( esc_html__( 'Actions', 'visualizer' ), false );
206 166 self::_renderCheckboxItem(
207 167 esc_html__( 'Print', 'visualizer' ),
208 168 'actions[]',
@@ -207,10 +167,9 @@
207 167 esc_html__( 'Print', 'visualizer' ),
208 168 'actions[]',
209 169 isset( $this->actions ) && in_array( 'print', $this->actions ) ? true : false,
210 170 'print',
211 - $disable_actions ? '<span class="viz-section-error">' . esc_html__( 'Upgrade to at least WordPress 4.7 to use this.', 'visualizer' ) . '</span>' : esc_html__( 'To enable printing the data.', 'visualizer' ),
212 - $disable_actions
171 + esc_html__( 'To enable printing the data.', 'visualizer' )
213 172 );
214 173 self::_renderCheckboxItem(
215 174 esc_html__( 'CSV', 'visualizer' ),
216 175 'actions[]',
@@ -215,20 +174,19 @@
215 174 esc_html__( 'CSV', 'visualizer' ),
216 175 'actions[]',
217 176 isset( $this->actions ) && in_array( 'csv;application/csv', $this->actions ) ? true : false,
218 177 'csv;application/csv',
219 - $disable_actions ? '<span class="viz-section-error">' . esc_html__( 'Upgrade to at least WordPress 4.7 to use this.', 'visualizer' ) . '</span>' : esc_html__( 'To enable downloading the data as a CSV.', 'visualizer' ),
220 - $disable_actions
178 + esc_html__( 'To enable downloading the data as a CSV.', 'visualizer' )
221 179 );
222 180
223 - $disabled = ! ( class_exists( 'PHPExcel' ) && extension_loaded( 'zip' ) && extension_loaded( 'xml' ) && version_compare( PHP_VERSION, '5.2.0', '>' ) );
181 + $disabled = ! ( extension_loaded( 'zip' ) && extension_loaded( 'xml' ) && version_compare( PHP_VERSION, '5.2.0', '>' ) );
224 182 self::_renderCheckboxItem(
225 183 esc_html__( 'Excel', 'visualizer' ),
226 184 'actions[]',
227 185 isset( $this->actions ) && in_array( 'xls;application/vnd.ms-excel', $this->actions ) ? true : false,
228 186 'xls;application/vnd.ms-excel',
229 - $disable_actions ? '<span class="viz-section-error">' . esc_html__( 'Upgrade to at least WordPress 4.7 to use this.', 'visualizer' ) . '</span>' : ( $disabled ? '<span class="viz-section-error">' . esc_html__( 'Enable the ZIP and XML extensions to use this setting.', 'visualizer' ) . '</span>' : esc_html__( 'To enable downloading the data as an Excel spreadsheet.', 'visualizer' ) ),
230 - $disable_actions || $disabled
187 + $disabled ? '<span class="section-error">' . esc_html__( 'Enable the ZIP and XML extensions to use this setting.', 'visualizer' ) . '</span>' : esc_html__( 'To enable downloading the data as an Excel spreadsheet.', 'visualizer' ),
188 + $disabled
231 189 );
232 190 self::_renderCheckboxItem(
233 191 esc_html__( 'Copy', 'visualizer' ),
234 192 'actions[]',
@@ -233,10 +191,9 @@
233 191 esc_html__( 'Copy', 'visualizer' ),
234 192 'actions[]',
235 193 isset( $this->actions ) && in_array( 'copy', $this->actions ) ? true : false,
236 194 'copy',
237 - $disable_actions ? '<span class="viz-section-error">' . esc_html__( 'Upgrade to at least WordPress 4.7 to use this.', 'visualizer' ) . '</span>' : esc_html__( 'To enable copying the data to the clipboard.', 'visualizer' ),
238 - $disable_actions
195 + esc_html__( 'To enable copying the data to the clipboard.', 'visualizer' )
239 196 );
240 197 self::_renderSectionEnd();
241 198 }
242 199
@@ -257,15 +214,15 @@
257 214 $this->_renderChartTitleSettings();
258 215 self::_renderSectionEnd();
259 216
260 217 self::_renderSectionStart( esc_html__( 'Font Styles', 'visualizer' ), false );
261 - echo '<div class="viz-section-item">';
218 + echo '<div class="section-item">';
262 219 echo '<a class="more-info" href="javascript:;">[?]</a>';
263 220 echo '<b>', esc_html__( 'Family And Size', 'visualizer' ), '</b>';
264 221
265 - echo '<table class="viz-section-table" cellspacing="0" cellpadding="0" border="0">';
222 + echo '<table class="section-table" cellspacing="0" cellpadding="0" border="0">';
266 223 echo '<tr>';
267 - echo '<td class="viz-section-table-column">';
224 + echo '<td class="section-table-column">';
268 225 echo '<select name="fontName" class="control-select">';
269 226 echo '<option></option>';
270 227 foreach ( self::$_fontFamilies as $font => $label ) {
271 228 echo '<option value="', $font, '"', selected( $font, $this->fontName, false ), '>';
@@ -273,9 +230,9 @@
273 230 echo '</option>';
274 231 }
275 232 echo '</select>';
276 233 echo '</td>';
277 - echo '<td class="viz-section-table-column">';
234 + echo '<td class="section-table-column">';
278 235 echo '<select name="fontSize" class="control-select">';
279 236 echo '<option></option>';
280 237 for ( $i = 7; $i <= 20; $i++ ) {
281 238 echo '<option value="', $i, '"', selected( $i, $this->fontSize, false ), '>', $i, '</option>';
@@ -284,9 +241,9 @@
284 241 echo '</td>';
285 242 echo '</tr>';
286 243 echo '</table>';
287 244
288 - echo '<p class="viz-section-description">';
245 + echo '<p class="section-description">';
289 246 esc_html_e( 'The default font family and size for all text in the chart.', 'visualizer' );
290 247 echo '</p>';
291 248 echo '</div>';
292 249 self::_renderSectionEnd();
@@ -318,61 +275,12 @@
318 275
319 276 self::_renderSectionStart( esc_html__( 'Tooltip', 'visualizer' ), false );
320 277 $this->_renderTooltipSettigns();
321 278 self::_renderSectionEnd();
322 -
323 - $this->_renderAnimationSettings();
324 -
325 279 self::_renderGroupEnd();
326 280 }
327 281
328 282 /**
329 - * Renders animation settings section.
330 - *
331 - * @access protected
332 - */
333 - protected function _renderAnimationSettings() {
334 - if ( ! $this->_supportsAnimation ) {
335 - return;
336 - }
337 -
338 - self::_renderSectionStart( esc_html__( 'Animation', 'visualizer' ), false );
339 -
340 - self::_renderCheckboxItem(
341 - esc_html__( 'Animate on startup', 'visualizer' ),
342 - 'animation[startup]',
343 - $this->animation['startup'],
344 - true,
345 - esc_html__( 'Determines if the chart will animate on the initial draw.', 'visualizer' )
346 - );
347 -
348 - self::_renderTextItem(
349 - esc_html__( 'Duration', 'visualizer' ),
350 - 'animation[duration]',
351 - isset( $this->animation['duration'] ) ? $this->animation['duration'] : 0,
352 - esc_html__( 'The duration of the animation, in milliseconds', 'visualizer' ),
353 - 0,
354 - 'number'
355 - );
356 -
357 - self::_renderSelectItem(
358 - esc_html__( 'Easing', 'visualizer' ),
359 - 'animation[easing]',
360 - isset( $this->animation['easing'] ) ? $this->animation['easing'] : null,
361 - array(
362 - 'linear' => esc_html__( 'Constant speed', 'visualizer' ),
363 - 'in' => esc_html__( 'Start slow and speed up', 'visualizer' ),
364 - 'out' => esc_html__( 'Start fast and slow down', 'visualizer' ),
365 - 'inAndOut' => esc_html__( 'Start slow, speed up, then slow down', 'visualizer' ),
366 - ),
367 - esc_html__( 'The easing function applied to the animation.', 'visualizer' )
368 - );
369 -
370 - self::_renderSectionEnd();
371 -
372 - }
373 -
374 - /**
375 283 * Renders tooltip settings section.
376 284 *
377 285 * @since 1.4.0
378 286 *
@@ -412,29 +320,29 @@
412 320 self::_renderGroupStart( esc_html__( 'Layout & Chart Area', 'visualizer' ) );
413 321 self::_renderSectionStart( esc_html__( 'Layout', 'visualizer' ), false );
414 322 self::_renderSectionDescription( esc_html__( 'Configure the total size of the chart. Two formats are supported: a number, or a number followed by %. A simple number is a value in pixels; a number followed by % is a percentage.', 'visualizer' ) );
415 323
416 - echo '<div class="viz-section-item">';
324 + echo '<div class="section-item">';
417 325 echo '<a class="more-info" href="javascript:;">[?]</a>';
418 326 echo '<b>', esc_html__( 'Width And Height Of Chart', 'visualizer' ), '</b>';
419 327
420 - echo '<table class="viz-section-table" cellspacing="0" cellpadding="0" border="0">';
328 + echo '<table class="section-table" cellspacing="0" cellpadding="0" border="0">';
421 329 echo '<tr>';
422 - echo '<td class="viz-section-table-column">';
330 + echo '<td class="section-table-column">';
423 331 echo '<input type="text" name="width" class="control-text" value="', esc_attr( $this->width ), '" placeholder="100%">';
424 332 echo '</td>';
425 - echo '<td class="viz-section-table-column">';
333 + echo '<td class="section-table-column">';
426 334 echo '<input type="text" name="height" class="control-text" value="', esc_attr( $this->height ), '" placeholder="400">';
427 335 echo '</td>';
428 336 echo '</tr>';
429 337 echo '</table>';
430 338
431 - echo '<p class="viz-section-description">';
339 + echo '<p class="section-description">';
432 340 esc_html_e( 'Determines the total width and height of the chart.', 'visualizer' );
433 341 echo '</p>';
434 342 echo '</div>';
435 343
436 - echo '<div class="viz-section-delimiter"></div>';
344 + echo '<div class="section-delimiter"></div>';
437 345
438 346 self::_renderSectionDescription( esc_html__( 'Configure the background color for the main area of the chart and the chart border width and color.', 'visualizer' ) );
439 347
440 348 self::_renderTextItem(
@@ -459,9 +367,9 @@
459 367 $background_color,
460 368 '#fff'
461 369 );
462 370
463 - echo '<div class="viz-section-item">';
371 + echo '<div class="section-item">';
464 372 echo '<label>';
465 373 echo '<input type="checkbox" class="control-checkbox" name="backgroundColor[fill]" value="transparent"', checked( $background_color, 'transparent', false ), '> ';
466 374 esc_html_e( 'Transparent background', 'visualizer' );
467 375 echo '</label>';
@@ -470,44 +378,44 @@
470 378
471 379 self::_renderSectionStart( esc_html__( 'Chart Area', 'visualizer' ), false );
472 380 self::_renderSectionDescription( esc_html__( 'Configure the placement and size of the chart area (where the chart itself is drawn, excluding axis and legends). Two formats are supported: a number, or a number followed by %. A simple number is a value in pixels; a number followed by % is a percentage.', 'visualizer' ) );
473 381
474 - echo '<div class="viz-section-item">';
382 + echo '<div class="section-item">';
475 383 echo '<a class="more-info" href="javascript:;">[?]</a>';
476 384 echo '<b>', esc_html__( 'Left And Top Margins', 'visualizer' ), '</b>';
477 385
478 - echo '<table class="viz-section-table" cellspacing="0" cellpadding="0" border="0">';
386 + echo '<table class="section-table" cellspacing="0" cellpadding="0" border="0">';
479 387 echo '<tr>';
480 - echo '<td class="viz-section-table-column">';
388 + echo '<td class="section-table-column">';
481 389 echo '<input type="text" name="chartArea[left]" class="control-text" value="', $this->chartArea['left'] || $this->chartArea['left'] === '0' ? esc_attr( $this->chartArea['left'] ) : '', '" placeholder="20%">';
482 390 echo '</td>';
483 - echo '<td class="viz-section-table-column">';
391 + echo '<td class="section-table-column">';
484 392 echo '<input type="text" name="chartArea[top]" class="control-text" value="', $this->chartArea['top'] || $this->chartArea['top'] === '0' ? esc_attr( $this->chartArea['top'] ) : '', '" placeholder="20%">';
485 393 echo '</td>';
486 394 echo '</tr>';
487 395 echo '</table>';
488 396
489 - echo '<p class="viz-section-description">';
397 + echo '<p class="section-description">';
490 398 esc_html_e( 'Determines how far to draw the chart from the left and top borders.', 'visualizer' );
491 399 echo '</p>';
492 400 echo '</div>';
493 401
494 - echo '<div class="viz-section-item">';
402 + echo '<div class="section-item">';
495 403 echo '<a class="more-info" href="javascript:;">[?]</a>';
496 404 echo '<b>', esc_html__( 'Width And Height Of Chart Area', 'visualizer' ), '</b>';
497 405
498 - echo '<table class="viz-section-table" cellspacing="0" cellpadding="0" border="0">';
406 + echo '<table class="section-table" cellspacing="0" cellpadding="0" border="0">';
499 407 echo '<tr>';
500 - echo '<td class="viz-section-table-column">';
408 + echo '<td class="section-table-column">';
501 409 echo '<input type="text" name="chartArea[width]" class="control-text" value="', ! empty( $this->chartArea['width'] ) ? esc_attr( $this->chartArea['width'] ) : '', '" placeholder="60%">';
502 410 echo '</td>';
503 - echo '<td class="viz-section-table-column">';
411 + echo '<td class="section-table-column">';
504 412 echo '<input type="text" name="chartArea[height]" class="control-text" value="', ! empty( $this->chartArea['height'] ) ? esc_attr( $this->chartArea['height'] ) : '', '" placeholder="60%">';
505 413 echo '</td>';
506 414 echo '</tr>';
507 415 echo '</table>';
508 416
509 - echo '<p class="viz-section-description">';
417 + echo '<p class="section-description">';
510 418 esc_html_e( 'Determines the width and hight of the chart area.', 'visualizer' );
511 419 echo '</p>';
512 420 echo '</div>';
513 421 self::_renderSectionEnd();
@@ -519,37 +427,27 @@
519 427 *
520 428 * @since 1.0.0
521 429 *
522 430 * @static
523 - * @access public
431 + * @access protected
524 432 * @param string $title The title of the select item.
525 433 * @param string $name The name of the select item.
526 434 * @param string $value The actual value of the select item.
527 435 * @param array $options The array of select options.
528 436 * @param string $desc The description of the select item.
529 - * @param bool $multiple Is this a multiple select box.
530 - * @param array $classes Any additional classes.
531 - * @param array $attributes Custom attributes.
532 437 */
533 - public static function _renderSelectItem( $title, $name, $value, array $options, $desc, $multiple = false, $classes = array(), $attributes = array() ) {
534 - $atts = '';
535 - if ( $attributes ) {
536 - foreach ( $attributes as $k => $v ) {
537 - $atts .= ' data-visualizer-' . $k . '=' . esc_attr( $v );
538 - }
539 - }
540 - echo '<div class="viz-section-item">';
438 + protected static function _renderSelectItem( $title, $name, $value, array $options, $desc ) {
439 + echo '<div class="section-item">';
541 440 echo '<a class="more-info" href="javascript:;">[?]</a>';
542 441 echo '<b>', $title, '</b>';
543 - echo '<select class="control-select ', implode( ' ', $classes ) , '" name="', $name, '" ', ( $multiple ? 'multiple' : '' ), ' ' , $atts, '>';
442 + echo '<select class="control-select" name="', $name, '">';
544 443 foreach ( $options as $key => $label ) {
545 - $extra = $multiple && is_array( $value ) ? ( in_array( $key, $value ) ? 'selected' : '' ) : selected( $key, $value, false );
546 - echo '<option value="', $key, '"', $extra, '>';
444 + echo '<option value="', $key, '"', selected( $key, $value, false ), '>';
547 445 echo $label;
548 446 echo '</option>';
549 447 }
550 448 echo '</select>';
551 - echo '<p class="viz-section-description">', $desc, '</p>';
449 + echo '<p class="section-description">', $desc, '</p>';
552 450 echo '</div>';
553 451 }
554 452
555 453 /**
@@ -564,9 +462,9 @@
564 462 * @param string $value The actual value of the select item.
565 463 * @param string $default The default value of the color picker.
566 464 */
567 465 protected static function _renderColorPickerItem( $title, $name, $value, $default ) {
568 - echo '<div class="viz-section-item">';
466 + echo '<div class="section-item">';
569 467 echo '<b>', $title, '</b>';
570 468 echo '<div>';
571 469 echo '<input type="text" class="color-picker-hex" name="', $name, '" maxlength="7" placeholder="', esc_attr__( 'Hex Value', 'visualizer' ), '" value="', is_null( $value ) ? $default : esc_attr( $value ), '" data-default-color="', $default, '">';
572 470 echo '</div>';
@@ -584,23 +482,15 @@
584 482 * @param string $name The name of the select item.
585 483 * @param string $value The actual value of the select item.
586 484 * @param string $desc The description of the select item.
587 485 * @param string $placeholder The placeholder for the input.
588 - * @param string $type The type for the input (out of number, email, tel etc., default is text).
589 - * @param array $custom_attributes The custom attributes.
590 486 */
591 - protected static function _renderTextItem( $title, $name, $value, $desc, $placeholder = '', $type = 'text', $custom_attributes = array() ) {
592 - $attributes = '';
593 - if ( $custom_attributes ) {
594 - foreach ( $custom_attributes as $k => $v ) {
595 - $attributes .= ' ' . $k . '="' . esc_attr( $v ) . '"';
596 - }
597 - }
598 - echo '<div class="viz-section-item">';
487 + protected static function _renderTextItem( $title, $name, $value, $desc, $placeholder = '' ) {
488 + echo '<div class="section-item">';
599 489 echo '<a class="more-info" href="javascript:;">[?]</a>';
600 490 echo '<b>', $title, '</b>';
601 - echo '<input type="', $type, '" class="control-text" ', $attributes, ' name="', $name, '" value="', esc_attr( $value ), '" placeholder="', $placeholder, '">';
602 - echo '<p class="viz-section-description">', $desc, '</p>';
491 + echo '<input type="text" class="control-text" name="', $name, '" value="', esc_attr( $value ), '" placeholder="', $placeholder, '">';
492 + echo '<p class="section-description">', $desc, '</p>';
603 493 echo '</div>';
604 494 }
605 495
606 496 /**
@@ -608,18 +498,15 @@
608 498 *
609 499 * @since 1.0.0
610 500 *
611 501 * @static
612 - * @access public
502 + * @access protected
613 503 * @param string $title The title of this group.
614 - * @param string $html Any additional HTML.
615 - * @param string $class Any additional classes.
616 504 */
617 - public static function _renderGroupStart( $title, $html = '', $class = '' ) {
618 - echo '<li class="viz-group ' . $class . '">';
619 - echo '<h3 class="viz-group-title">', $title, '</h3>';
620 - echo $html;
621 - echo '<ul class="viz-group-content">';
505 + protected static function _renderGroupStart( $title ) {
506 + echo '<li class="group">';
507 + echo '<h3 class="group-title">', $title, '</h3>';
508 + echo '<ul class="group-content">';
622 509 }
623 510
624 511 /**
625 512 * Renders the ending of a group.
@@ -626,11 +513,11 @@
626 513 *
627 514 * @since 1.0.0
628 515 *
629 516 * @static
630 - * @access public
517 + * @access protected
631 518 */
632 - public static function _renderGroupEnd() {
519 + protected static function _renderGroupEnd() {
633 520 echo '</ul>';
634 521 echo '</li>';
635 522 }
636 523
@@ -639,21 +526,21 @@
639 526 *
640 527 * @since 1.0.0
641 528 *
642 529 * @static
643 - * @access public
530 + * @access protected
644 531 * @param string $title The title of this section. If the title is empty, no title will be displayed.
645 532 * @param boolean $open Determines whether the section items block has to be expanded or collapsed.
646 533 */
647 - public static function _renderSectionStart( $title = false, $open = true ) {
534 + protected static function _renderSectionStart( $title = false, $open = true ) {
648 535
649 536 if ( ! empty( $title ) ) {
650 - echo '<li class="viz-subsection">';
651 - echo '<span class="viz-section-title">', $title, '</span>';
537 + echo '<li class="subsection">';
538 + echo '<span class="section-title">', $title, '</span>';
652 539 } else {
653 540 echo '<li class=" ">';
654 541 }
655 - echo '<div class="viz-section-items section-items', $open ? ' open' : '', '">';
542 + echo '<div class="section-items', $open ? ' open' : '', '">';
656 543 }
657 544
658 545 /**
659 546 * Renders the ending of a section.
@@ -659,15 +546,13 @@
659 546 * Renders the ending of a section.
660 547 *
661 548 * @since 1.0.0
662 549 *
663 - * @public
550 + * @static
664 551 * @access protected
665 - * @param string $html Any addition HTML to add.
666 552 */
667 - public static function _renderSectionEnd( $html = '' ) {
553 + protected static function _renderSectionEnd() {
668 554 echo '</div>';
669 - echo $html;
670 555 echo '</li>';
671 556 }
672 557
673 558 /**
@@ -675,14 +560,14 @@
675 560 *
676 561 * @since 1.0.0
677 562 *
678 563 * @static
679 - * @access public
564 + * @access protected
680 565 * @param string $description The description text.
681 566 */
682 - public static function _renderSectionDescription( $description ) {
683 - echo '<div class="viz-section-item">';
684 - echo '<div class="viz-section-description">', $description, '</div>';
567 + protected static function _renderSectionDescription( $description ) {
568 + echo '<div class="section-item">';
569 + echo '<div class="section-description">', $description, '</div>';
685 570 echo '</div>';
686 571 }
687 572
688 573 /**
@@ -721,31 +606,13 @@
721 606 /**
722 607 * Render a checkbox item
723 608 */
724 609 protected static function _renderCheckboxItem( $title, $name, $value, $default, $desc, $disabled = false ) {
725 - echo '<div class="viz-section-item">';
610 + echo '<div class="section-item">';
726 611 echo '<a class="more-info" href="javascript:;">[?]</a>';
727 612 echo '<b>', $title, '</b>';
728 - echo '<input type="checkbox" class="control-check" value="', $default, '" name="', $name, '" ', ( $value == $default ? 'checked' : '' ), ' ', ( $disabled ? 'disabled=disabled' : '' ), '>';
729 - echo '<p class="viz-section-description">', $desc, '</p>';
730 - echo '</div>';
731 - }
732 -
733 - /**
734 - * Render a textarea item.
735 - */
736 - protected static function _renderTextAreaItem( $title, $name, $value, $desc, $placeholder = '', $custom_attributes = array() ) {
737 - $attributes = '';
738 - if ( $custom_attributes ) {
739 - foreach ( $custom_attributes as $k => $v ) {
740 - $attributes .= ' ' . $k . '="' . esc_attr( $v ) . '"';
741 - }
742 - }
743 - echo '<div class="viz-section-item">';
744 - echo '<a class="more-info" href="javascript:;">[?]</a>';
745 - echo '<b>', $title, '</b>';
746 - echo '<textarea class="control-text" ', $attributes, ' name="', $name, '" placeholder="', $placeholder, '">', $value, '</textarea>';
747 - echo '<p class="viz-section-description">', $desc, '</p>';
613 + echo '<input type="checkbox" class="control-check" value="', $default, '" name="', $name, '" ', ($value == $default ? 'checked' : ''), ' ', ($disabled ? 'disabled=disabled' : ''), '>';
614 + echo '<p class="section-description">', $desc, '</p>';
748 615 echo '</div>';
749 616 }
750 617
751 618 }