PluginProbe
Ultimate Post Kit – Elementor Post Grid, Post Carousel, Post Slider & Blog Layout Widgets / 4.5.6
Ultimate Post Kit – Elementor Post Grid, Post Carousel, Post Slider & Blog Layout Widgets v4.5.6
4.5.6 4.5.5 4.5.4 4.2.1 4.2.2 4.2.3 4.5.0 4.5.2 4.5.3 4.2.0 4.1.18 4.1.17 4.1.16 4.1.15 4.1.14 4.1.13 4.1.12 4.1.11 4.1.10 4.1.9 4.1.8 4.0.9 4.1.0 4.1.1 4.1.2 All 148 releases
ultimate-post-kit / includes / compatiblity / wpml / class-wpml-upk-pro-social-link.php

class-wpml-upk-pro-social-link.php in Ultimate Post Kit – Elementor Post Grid, Post Carousel, Post Slider & Blog Layout Widgets 4.5.6, at includes/compatiblity/wpml/class-wpml-upk-pro-social-link.php

60 lines 1.2 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <?php
2 namespace UltimatePostKit\Includes;
3
4 if ( ! defined( 'ABSPATH' ) ) {
5 exit; // Exit if accessed directly
6 }
7
8 /**
9 * Class WPML_UPK_Pro_Social_Link
10 * Handles translation of repeater items in the Social Link widget
11 */
12 class WPML_UPK_Pro_Social_Link extends WPML_Module_With_Items {
13
14 /**
15 * @return string
16 */
17 public function get_items_field() {
18 return 'share_buttons';
19 }
20
21 /**
22 * @return array
23 */
24 public function get_fields() {
25 return array(
26 'text',
27 'social_link',
28 );
29 }
30
31 /**
32 * @param string $field
33 * @return string
34 */
35 protected function get_title( $field ) {
36 switch ( $field ) {
37 case 'text':
38 return esc_html__( 'Custom Label', 'ultimate-post-kit' );
39 case 'social_link':
40 return esc_html__( 'Link', 'ultimate-post-kit' );
41 default:
42 return '';
43 }
44 }
45
46 /**
47 * @param string $field
48 * @return string
49 */
50 protected function get_editor_type( $field ) {
51 switch ( $field ) {
52 case 'text':
53 case 'social_link':
54 return 'LINE';
55 default:
56 return 'LINE';
57 }
58 }
59 }
60