codemirror-graphql
Advanced tools
Comparing version 0.1.1 to 0.2.0
@@ -141,3 +141,3 @@ /** | ||
// Fragment type conditions | ||
if (kind === 'FragmentDefinition' && step === 3 || kind === 'InlineFragment' && step === 2 || kind === 'NamedType' && (state.prevState.kind === 'FragmentDefinition' || state.prevState.kind === 'InlineFragment')) { | ||
if (kind === 'TypeCondition' && step === 1 || kind === 'NamedType' && state.prevState.kind === 'TypeCondition') { | ||
var possibleTypes; | ||
@@ -144,0 +144,0 @@ if (typeInfo.parentType) { |
13
mode.js
@@ -288,3 +288,3 @@ /** | ||
// A Name Token which will decorate the state with a `type` | ||
// A Name Token which will decorate the previous state with a `type` | ||
function type(style) { | ||
@@ -297,3 +297,3 @@ return { | ||
update: function update(state, token) { | ||
state.type = token.value; | ||
state.prevState.type = token.value; | ||
} | ||
@@ -340,5 +340,5 @@ }; | ||
// Note: instead of "Operation", these rules have been separated out. | ||
Query: [word('query'), name('def'), opt('VariableDefinitions'), list('Directive'), 'SelectionSet'], | ||
Query: [word('query'), opt(name('def')), opt('VariableDefinitions'), list('Directive'), 'SelectionSet'], | ||
ShortQuery: ['SelectionSet'], | ||
Mutation: [word('mutation'), name('def'), opt('VariableDefinitions'), list('Directive'), 'SelectionSet'], | ||
Mutation: [word('mutation'), opt(name('def')), opt('VariableDefinitions'), list('Directive'), 'SelectionSet'], | ||
VariableDefinitions: [p('('), list('VariableDefinition'), p(')')], | ||
@@ -358,4 +358,5 @@ VariableDefinition: ['Variable', p(':'), 'Type', opt('DefaultValue')], | ||
FragmentSpread: [p('...'), name('def'), list('Directive')], | ||
InlineFragment: [p('...'), word('on'), type('atom'), list('Directive'), 'SelectionSet'], | ||
FragmentDefinition: [word('fragment'), name('def'), word('on'), type('atom'), list('Directive'), 'SelectionSet'], | ||
InlineFragment: [p('...'), opt('TypeCondition'), list('Directive'), 'SelectionSet'], | ||
FragmentDefinition: [word('fragment'), name('def'), 'TypeCondition', list('Directive'), 'SelectionSet'], | ||
TypeCondition: [word('on'), type('atom')], | ||
// Variables could be parsed in cases where only Const is expected by spec. | ||
@@ -362,0 +363,0 @@ Value: function Value(token) { |
{ | ||
"name": "codemirror-graphql", | ||
"version": "0.1.1", | ||
"version": "0.2.0", | ||
"description": "GraphQL mode and helpers for CodeMirror.", | ||
@@ -49,3 +49,3 @@ "contributors": [ | ||
"peerDependencies": { | ||
"graphql": "^0.4.2", | ||
"graphql": "^0.4.7", | ||
"codemirror": "^5.6.0" | ||
@@ -61,8 +61,8 @@ }, | ||
"eslint": "1.2.1", | ||
"flow-bin": "0.14.0", | ||
"graphql": "0.4.2", | ||
"jsdom": "3.0.0", | ||
"flow-bin": "0.16.0", | ||
"graphql": "0.4.7", | ||
"jsdom": "6.5.1", | ||
"mocha": "2.2.5", | ||
"sane": "1.2.0" | ||
"sane": "1.3.0" | ||
} | ||
} |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Unidentified License
License(Experimental) Something that seems like a license was found, but its contents could not be matched with a known license.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Unidentified License
License(Experimental) Something that seems like a license was found, but its contents could not be matched with a known license.
Found 1 instance in 1 package
760
31738