| @@ -258,9 +258,9 @@ | ||
| 258 | 258 | ], |
| 259 | 259 | ], |
| 260 | 260 | [ |
| 261 | 261 | 'social_icon' => [ |
| 262 | - 'value' => 'fab fa-x-twitter', | |
| 262 | + 'value' => 'fab fa-twitter', | |
| 263 | 263 | 'library' => 'fa-brands', |
| 264 | 264 | ], |
| 265 | 265 | ], |
| 266 | 266 | [ |
| @@ -599,9 +599,9 @@ | ||
| 599 | 599 | } |
| 600 | 600 | |
| 601 | 601 | $fallback_defaults = [ |
| 602 | 602 | 'fa fa-facebook', |
| 603 | - 'fa fa-x-twitter', | |
| 603 | + 'fa fa-twitter', | |
| 604 | 604 | 'fa fa-google-plus', |
| 605 | 605 | ]; |
| 606 | 606 | |
| 607 | 607 | $class_animation = ''; |
| @@ -711,49 +711,6 @@ | ||
| 711 | 711 | </span> |
| 712 | 712 | <# } ); #> |
| 713 | 713 | </div> |
| 714 | 714 | <?php |
| 715 | - } | |
| 716 | - | |
| 717 | - public function render_markdown(): string { | |
| 718 | - $settings = $this->get_settings_for_display(); | |
| 719 | - if ( empty( $settings['social_icon_list'] ) ) { | |
| 720 | - return ''; | |
| 721 | - } | |
| 722 | - | |
| 723 | - $migration_allowed = Icons_Manager::is_migration_allowed(); | |
| 724 | - $links = []; | |
| 725 | - | |
| 726 | - foreach ( $settings['social_icon_list'] as $item ) { | |
| 727 | - $url = $item['link']['url'] ?? ''; | |
| 728 | - if ( empty( $url ) ) { | |
| 729 | - continue; | |
| 730 | - } | |
| 731 | - | |
| 732 | - $migrated = isset( $item['__fa4_migrated']['social_icon'] ); | |
| 733 | - $is_new = empty( $item['social'] ) && $migration_allowed; | |
| 734 | - $social = ''; | |
| 735 | - | |
| 736 | - if ( ! empty( $item['social'] ) ) { | |
| 737 | - $social = str_replace( 'fa fa-', '', $item['social'] ); | |
| 738 | - } | |
| 739 | - | |
| 740 | - if ( ( $is_new || $migrated ) && 'svg' !== ( $item['social_icon']['library'] ?? '' ) ) { | |
| 741 | - $parts = explode( ' ', $item['social_icon']['value'] ?? '', 2 ); | |
| 742 | - $social = ! empty( $parts[1] ) ? str_replace( 'fa-', '', $parts[1] ) : ''; | |
| 743 | - } | |
| 744 | - | |
| 745 | - if ( 'svg' === ( $item['social_icon']['library'] ?? '' ) ) { | |
| 746 | - $social = get_post_meta( $item['social_icon']['value']['id'] ?? 0, '_wp_attachment_image_alt', true ); | |
| 747 | - } | |
| 748 | - | |
| 749 | - $label = ucwords( str_replace( '-', ' ', $social ) ); | |
| 750 | - if ( empty( $label ) ) { | |
| 751 | - $label = 'Link'; | |
| 752 | - } | |
| 753 | - | |
| 754 | - $links[] = '- [' . $label . '](' . esc_url( $url ) . ')'; | |
| 755 | - } | |
| 756 | - | |
| 757 | - return implode( "\n", $links ); | |
| 758 | 715 | } |
| 759 | 716 | } |