Wishlist_Detail_Share

Summary

No summary available.

Source

File: src/BigCommerce/Templates/Wishlist_Detail_Share.php

class Wishlist_Detail_Share extends Controller {
	const WISHLIST   = 'wishlist';
	const PUBLIC_URL = 'public_url';

	protected $wrapper_tag        = 'div';
	protected $wrapper_classes    = [ 'bc-manage-wish-list-share' ];
	protected $wrapper_attributes = [ 'data-js' => 'bc-manage-wish-list-share' ];

	protected $template = 'components/wishlist/detail-share.php';

	protected function parse_options( array $options ) {
		$defaults = [
			self::WISHLIST => null,
		];

		return wp_parse_args( $options, $defaults );
	}

	public function get_data() {
		/** @var Wishlist $wishlist */
		$wishlist = $this->options[ self::WISHLIST ];

		return [
			self::WISHLIST   => $wishlist,
			self::PUBLIC_URL => $wishlist->public_url(),
		];
	}

}

Methods


User Contributed Notes

You must log in before being able to contribute a note or feedback.