Sha256: b97deb81bfc9379cd4b7c7486b9b2fd30ed39ad146ceb5692641ba41f013ebb3
Contents?: true
Size: 878 Bytes
Versions: 31
Compression:
Stored size: 878 Bytes
Contents
# frozen_string_literal: true module Decidim module Core # This interface represents an author who owns a resource. AuthorInterface = GraphQL::InterfaceType.define do name "Author" description "An author" field :name, !types.String, "The author's name" field :nickname, !types.String, "The author's nickname" field :avatarUrl, !types.String, "The author's avatar url" field :profilePath, !types.String, "The author's profile path" field :badge, !types.String, "The author's badge icon" field :deleted, !types.Boolean, "Whether the author's account has been deleted or not" resolve_type ->(obj, _ctx) { return Decidim::Core::UserType if obj.is_a? Decidim::User return Decidim::Core::UserGroupType if obj.is_a? Decidim::UserGroup } end end end
Version data entries
31 entries across 31 versions & 1 rubygems