<?php

namespace Dev4Press\Plugin\coreSocial\Networks;

use Dev4Press\Plugin\coreSocial\Base\Network;

if ( ! defined( 'ABSPATH' ) ) {
	exit;
}

class LinkedIn extends Network {
	protected string $network = 'linkedin';

	public static function instance() : LinkedIn {
		static $instance = null;

		if ( ! isset( $instance ) ) {
			$instance = new LinkedIn();
		}

		return $instance;
	}

	public function get_share_link( string $url, string $title, string $image_url = '', string $item = 'post', int $item_id = 0 ) : string {
		return sprintf( 'https://www.linkedin.com/sharing/share-offsite/?url=%1$s', esc_attr( $url ) );
	}
}
