# typed: strict
class Domain::UserPolicy < ApplicationPolicy
  extend T::Sig

  sig { returns(T::Boolean) }
  def show?
    true
  end

  sig { returns(T::Boolean) }
  def index?
    true
  end

  sig { returns(T::Boolean) }
  def search_by_name?
    true
  end

  sig { returns(T::Boolean) }
  def user_favorite_posts?
    true
  end

  sig { returns(T::Boolean) }
  def user_created_posts?
    true
  end

  sig { returns(T::Boolean) }
  def view_page_scanned_at_timestamps?
    is_role_admin?
  end

  sig { returns(T::Boolean) }
  def view_log_entries?
    is_role_admin?
  end

  sig { returns(T::Boolean) }
  def followed_by?
    is_role_admin? || is_role_moderator? || is_role_user?
  end

  sig { returns(T::Boolean) }
  def following?
    is_role_admin? || is_role_moderator? || is_role_user?
  end
end
