hustle-sshare-content.php
3 years ago
hustle-sshare-design.php
3 years ago
hustle-sshare-display.php
3 years ago
hustle-sshare-content.php
52 lines
| 1 | <?php // phpcs:ignore WordPress.Files.FileName.InvalidClassFileName |
| 2 | /** |
| 3 | * File for Hustle_SShare_Content class. |
| 4 | * |
| 5 | * @package Hustle |
| 6 | * @since unknown |
| 7 | */ |
| 8 | |
| 9 | /** |
| 10 | * Hustle_SShare_Content is the base class for the "content" meta of Social Sharing modules. |
| 11 | * |
| 12 | * @since unknwon |
| 13 | */ |
| 14 | class Hustle_SShare_Content extends Hustle_Meta { |
| 15 | |
| 16 | /** |
| 17 | * Get the defaults for this meta. |
| 18 | * |
| 19 | * @since 4.4.1 |
| 20 | * @return array |
| 21 | */ |
| 22 | public function get_defaults() { |
| 23 | return array( |
| 24 | 'social_icons' => array(), |
| 25 | 'counter_enabled' => '1', |
| 26 | ); |
| 27 | } |
| 28 | |
| 29 | /** |
| 30 | * Retrieves the list of social icons. |
| 31 | * |
| 32 | * @since 4.3.0 |
| 33 | * |
| 34 | * @return array |
| 35 | */ |
| 36 | public function get_social_icons() { |
| 37 | $networks = ! empty( $this->data['social_icons'] ) ? $this->data['social_icons'] : array(); |
| 38 | return $networks; |
| 39 | } |
| 40 | |
| 41 | /** |
| 42 | * Returns whether the module has CTA active. |
| 43 | * |
| 44 | * @since 4.3.1 |
| 45 | * |
| 46 | * @return boolean |
| 47 | */ |
| 48 | public function has_cta() { |
| 49 | return false; |
| 50 | } |
| 51 | } |
| 52 |