<?php
/**
  * Ahead WebSoft Technologies Pvt Ltd.
  * @copyright  Copyright 2006-2026 Ahead WebSoft Technologies Pvt Ltd.
  * @license    https://www.socialengine.com/policies
*/
?>

<?php
  $uniqueId = 'savecollection_icon_' . $this->contentType . '_' . $this->contentId;
  $iconClass = $this->isSaved ? 'fa-regular fa-bookmark' : 'fa-regular fa-bookmark';
  $stateClass = $this->isSaved ? 'savecollection_icon_saved' : 'savecollection_icon_unsaved';
  $ariaLabel = $this->isSaved ? $this->translate('Remove from Saved') : $this->translate('Save');
?>
<div class="savecollection_button">
<a href="javascript:void(0);"
   id="<?php echo $uniqueId; ?>"
   class="savecollection_icon <?php echo $stateClass; ?>"
   data-content-type="<?php echo $this->escape($this->contentType); ?>"
   data-content-id="<?php echo (int) $this->contentId; ?>"
   data-saved="<?php echo $this->isSaved ? '1' : '0'; ?>"
   title="<?php echo $ariaLabel; ?>"
   aria-label="<?php echo $ariaLabel; ?>"
   role="button">
  <i class="<?php echo $iconClass; ?>"></i>
	<span><?php echo $this->isSaved ? $this->translate("Saved") : $this->translate("Save"); ?></span>
</a>
</div>