@kiwicom/smart-faq
Version:
242 lines (234 loc) • 5.22 kB
JavaScript
/**
* @flow
* @relayHash 5656e8242f22fbe828dac42baeac59d0
*/
/* eslint-disable */
'use strict';
/*::
import type { ConcreteRequest } from 'relay-runtime';
type ArticleContent_article$ref = any;
export type ArticleDetailQueryVariables = {|
id: string,
categoryId: string,
isSubcategory: boolean,
|};
export type ArticleDetailQueryResponse = {|
+FAQArticle: ?{|
+title: ?string,
+$fragmentRefs: ArticleContent_article$ref,
|},
+FAQCategory?: ?{|
+title: ?string,
+id: string,
+ancestors: ?$ReadOnlyArray<?{|
+id: string,
+title: ?string,
|}>,
|},
|};
export type ArticleDetailQuery = {|
variables: ArticleDetailQueryVariables,
response: ArticleDetailQueryResponse,
|};
*/
/*
query ArticleDetailQuery(
$id: ID!
$categoryId: ID!
$isSubcategory: Boolean!
) {
FAQArticle(id: $id) {
title
...ArticleContent_article
id
}
FAQCategory(id: $categoryId) @include(if: $isSubcategory) {
title
id
ancestors {
id
title
}
}
}
fragment ArticleContent_article on FAQArticle {
id
originalId: id(opaque: false)
title
perex
content
}
*/
const node/*: ConcreteRequest*/ = (function(){
var v0 = [
{
"kind": "LocalArgument",
"name": "id",
"type": "ID!",
"defaultValue": null
},
{
"kind": "LocalArgument",
"name": "categoryId",
"type": "ID!",
"defaultValue": null
},
{
"kind": "LocalArgument",
"name": "isSubcategory",
"type": "Boolean!",
"defaultValue": null
}
],
v1 = [
{
"kind": "Variable",
"name": "id",
"variableName": "id",
"type": "ID!"
}
],
v2 = {
"kind": "ScalarField",
"alias": null,
"name": "title",
"args": null,
"storageKey": null
},
v3 = {
"kind": "ScalarField",
"alias": null,
"name": "id",
"args": null,
"storageKey": null
},
v4 = {
"kind": "Condition",
"passingValue": true,
"condition": "isSubcategory",
"selections": [
{
"kind": "LinkedField",
"alias": null,
"name": "FAQCategory",
"storageKey": null,
"args": [
{
"kind": "Variable",
"name": "id",
"variableName": "categoryId",
"type": "ID!"
}
],
"concreteType": "FAQCategory",
"plural": false,
"selections": [
(v2/*: any*/),
(v3/*: any*/),
{
"kind": "LinkedField",
"alias": null,
"name": "ancestors",
"storageKey": null,
"args": null,
"concreteType": "FAQCategory",
"plural": true,
"selections": [
(v3/*: any*/),
(v2/*: any*/)
]
}
]
}
]
};
return {
"kind": "Request",
"fragment": {
"kind": "Fragment",
"name": "ArticleDetailQuery",
"type": "RootQuery",
"metadata": null,
"argumentDefinitions": (v0/*: any*/),
"selections": [
{
"kind": "LinkedField",
"alias": null,
"name": "FAQArticle",
"storageKey": null,
"args": (v1/*: any*/),
"concreteType": "FAQArticle",
"plural": false,
"selections": [
(v2/*: any*/),
{
"kind": "FragmentSpread",
"name": "ArticleContent_article",
"args": null
}
]
},
(v4/*: any*/)
]
},
"operation": {
"kind": "Operation",
"name": "ArticleDetailQuery",
"argumentDefinitions": (v0/*: any*/),
"selections": [
{
"kind": "LinkedField",
"alias": null,
"name": "FAQArticle",
"storageKey": null,
"args": (v1/*: any*/),
"concreteType": "FAQArticle",
"plural": false,
"selections": [
(v2/*: any*/),
(v3/*: any*/),
{
"kind": "ScalarField",
"alias": "originalId",
"name": "id",
"args": [
{
"kind": "Literal",
"name": "opaque",
"value": false,
"type": "Boolean"
}
],
"storageKey": "id(opaque:false)"
},
{
"kind": "ScalarField",
"alias": null,
"name": "perex",
"args": null,
"storageKey": null
},
{
"kind": "ScalarField",
"alias": null,
"name": "content",
"args": null,
"storageKey": null
}
]
},
(v4/*: any*/)
]
},
"params": {
"operationKind": "query",
"name": "ArticleDetailQuery",
"id": null,
"text": "query ArticleDetailQuery(\n $id: ID!\n $categoryId: ID!\n $isSubcategory: Boolean!\n) {\n FAQArticle(id: $id) {\n title\n ...ArticleContent_article\n id\n }\n FAQCategory(id: $categoryId) @include(if: $isSubcategory) {\n title\n id\n ancestors {\n id\n title\n }\n }\n}\n\nfragment ArticleContent_article on FAQArticle {\n id\n originalId: id(opaque: false)\n title\n perex\n content\n}\n",
"metadata": {}
}
};
})();
// prettier-ignore
(node/*: any*/).hash = '65b4847f742f5438129863eb7001d18c';
module.exports = node;