mirror of
https://github.com/BradNut/graphbrainz
synced 2025-09-08 17:40:32 +00:00
20 lines
498 B
JavaScript
20 lines
498 B
JavaScript
|
|
import {
|
||
|
|
GraphQLObjectType,
|
||
|
|
GraphQLString,
|
||
|
|
GraphQLBoolean
|
||
|
|
} from 'graphql/type'
|
||
|
|
import MBID from './mbid'
|
||
|
|
import { getHyphenated } from './helpers'
|
||
|
|
|
||
|
|
export default new GraphQLObjectType({
|
||
|
|
name: 'Alias',
|
||
|
|
fields: () => ({
|
||
|
|
name: { type: GraphQLString },
|
||
|
|
sortName: { type: GraphQLString, resolve: getHyphenated },
|
||
|
|
locale: { type: GraphQLString },
|
||
|
|
primary: { type: GraphQLBoolean },
|
||
|
|
type: { type: GraphQLString },
|
||
|
|
typeID: { type: MBID, resolve: getHyphenated }
|
||
|
|
})
|
||
|
|
})
|