From 666329dad473d5b7172294ed5a29b36db47b3708 Mon Sep 17 00:00:00 2001 From: illiakovalenko Date: Mon, 28 Nov 2022 11:20:12 +0200 Subject: [PATCH] Revert "Rename "App Route" to "Page" (#1159)" This reverts commit e1d1a02737ad562f285d086ab8dbcd7ea0964ea1. --- .../graph-ql-integrated-demo.sitecore.graphql | 6 +++--- .../sitecore/definitions/routes.sitecore.ts | 4 ++-- .../graph-ql-connected-demo.component.graphql | 6 +++--- .../angular/src/graphql-fragment-types.ts | 6 +++--- .../GraphQL-IntegratedDemo.sitecore.graphql | 6 +++--- .../sitecore/definitions/routes.sitecore.ts | 6 +++--- .../GraphQL-ConnectedDemo.dynamic.graphql | 6 +++--- .../graphql/GraphQL-ConnectedDemo.dynamic.tsx | 14 +++++++------- .../src/temp/GraphQLIntrospectionResult.json | 16 ++++++++-------- .../GraphQL-IntegratedDemo.sitecore.graphql | 6 +++--- .../sitecore/definitions/routes.sitecore.js | 4 ++-- .../GraphQL-ConnectedDemo/query.graphql | 6 +++--- .../react/src/temp/GraphQLFragmentTypes.json | 6 +++--- .../GraphQL-IntegratedDemo.sitecore.graphql | 6 +++--- .../vue/sitecore/definitions/routes.sitecore.js | 4 ++-- .../GraphQL/GraphQL-ConnectedDemo.query.graphql | 6 +++--- .../vue/src/temp/GraphQLFragmentTypes.json | 6 +++--- 17 files changed, 57 insertions(+), 57 deletions(-) diff --git a/packages/create-sitecore-jss/src/templates/angular/sitecore/definitions/components/graph-ql-integrated-demo.sitecore.graphql b/packages/create-sitecore-jss/src/templates/angular/sitecore/definitions/components/graph-ql-integrated-demo.sitecore.graphql index 4957d52dd6..ec92e138ac 100644 --- a/packages/create-sitecore-jss/src/templates/angular/sitecore/definitions/components/graph-ql-integrated-demo.sitecore.graphql +++ b/packages/create-sitecore-jss/src/templates/angular/sitecore/definitions/components/graph-ql-integrated-demo.sitecore.graphql @@ -42,8 +42,8 @@ query IntegratedDemoQuery($datasource: String!, $contextItem: String!, $language # (as long as the GraphQLData helper is used) contextItem: item(path: $contextItem, language: $language) { id - # Get the page title from the page template - ...on <%- helper.getAppPrefix(appPrefix, appName, false) %>Page { + # Get the page title from the app route template + ...on <%- helper.getAppPrefix(appPrefix, appName, false) %>AppRoute { pageTitle { value } @@ -56,7 +56,7 @@ query IntegratedDemoQuery($datasource: String!, $contextItem: String!, $language # typing fragments can be used anywhere! # so in this case, we're grabbing the 'pageTitle' # field on all child route items. - ...on <%- helper.getAppPrefix(appPrefix, appName, false) %>Page { + ...on <%- helper.getAppPrefix(appPrefix, appName, false) %>AppRoute { pageTitle { jsonValue value diff --git a/packages/create-sitecore-jss/src/templates/angular/sitecore/definitions/routes.sitecore.ts b/packages/create-sitecore-jss/src/templates/angular/sitecore/definitions/routes.sitecore.ts index dde035088b..34cbb98fe6 100644 --- a/packages/create-sitecore-jss/src/templates/angular/sitecore/definitions/routes.sitecore.ts +++ b/packages/create-sitecore-jss/src/templates/angular/sitecore/definitions/routes.sitecore.ts @@ -16,7 +16,7 @@ export default function addRoutesToManifest(manifest: Manifest): Promise { // which routes can use by setting `template: YourCustomRouteTypeName` in their definition. const appTemplateSection = 'Page Metadata'; manifest.setDefaultRouteType({ - name: '<%- helper.getAppPrefix(appPrefix, appName) %>Page', + name: '<%- helper.getAppPrefix(appPrefix, appName) %>App Route', fields: [ { name: 'pageTitle', @@ -25,7 +25,7 @@ export default function addRoutesToManifest(manifest: Manifest): Promise { type: CommonFieldTypes.SingleLineText, }, ], - insertOptions: ['<%- helper.getAppPrefix(appPrefix, appName) %>Page'], + insertOptions: ['<%- helper.getAppPrefix(appPrefix, appName) %>App Route'], }); return mergeFs('./data/routes') // relative to process invocation (i.e. your package.json) diff --git a/packages/create-sitecore-jss/src/templates/angular/src/app/components/graph-ql-connected-demo/graph-ql-connected-demo.component.graphql b/packages/create-sitecore-jss/src/templates/angular/src/app/components/graph-ql-connected-demo/graph-ql-connected-demo.component.graphql index 424cf904d5..07f114c18a 100644 --- a/packages/create-sitecore-jss/src/templates/angular/src/app/components/graph-ql-connected-demo/graph-ql-connected-demo.component.graphql +++ b/packages/create-sitecore-jss/src/templates/angular/src/app/components/graph-ql-connected-demo/graph-ql-connected-demo.component.graphql @@ -40,8 +40,8 @@ query ConnectedDemoQuery($datasource: String!, $contextItem: String!, $language: # $contextItem should be set to the ID of the current context item (the route item) contextItem: item(path: $contextItem, language: $language) { id - # Get the page title from the page template - ...on <%- helper.getAppPrefix(appPrefix, appName, false) %>Page { + # Get the page title from the app route template + ...on <%- helper.getAppPrefix(appPrefix, appName, false) %>AppRoute { pageTitle { value } @@ -54,7 +54,7 @@ query ConnectedDemoQuery($datasource: String!, $contextItem: String!, $language: # typing fragments can be used anywhere! # so in this case, we're grabbing the 'pageTitle' # field on all child route items. - ...on <%- helper.getAppPrefix(appPrefix, appName, false) %>Page { + ...on <%- helper.getAppPrefix(appPrefix, appName, false) %>AppRoute { pageTitle { jsonValue value diff --git a/packages/create-sitecore-jss/src/templates/angular/src/graphql-fragment-types.ts b/packages/create-sitecore-jss/src/templates/angular/src/graphql-fragment-types.ts index cd809843ca..8244546283 100644 --- a/packages/create-sitecore-jss/src/templates/angular/src/graphql-fragment-types.ts +++ b/packages/create-sitecore-jss/src/templates/angular/src/graphql-fragment-types.ts @@ -153,7 +153,7 @@ export default { name: '<%- helper.getAppPrefix(appPrefix, appName, false) %>ContentBlock', }, { - name: 'C__<%- helper.getAppPrefix(appPrefix, appName, false) %>Page', + name: 'C__<%- helper.getAppPrefix(appPrefix, appName, false) %>AppRoute', }, { name: 'JsonRendering', @@ -192,13 +192,13 @@ export default { }, { kind: 'INTERFACE', - name: '<%- helper.getAppPrefix(appPrefix, appName, false) %>Page', + name: '<%- helper.getAppPrefix(appPrefix, appName, false) %>AppRoute', possibleTypes: [ { name: '<%- helper.getAppPrefix(appPrefix, appName, false) %>ExampleCustomRouteType', }, { - name: 'C__<%- helper.getAppPrefix(appPrefix, appName, false) %>Page', + name: 'C__<%- helper.getAppPrefix(appPrefix, appName, false) %>AppRoute', }, ], }, diff --git a/packages/create-sitecore-jss/src/templates/nextjs-styleguide/sitecore/definitions/components/graphql/GraphQL-IntegratedDemo.sitecore.graphql b/packages/create-sitecore-jss/src/templates/nextjs-styleguide/sitecore/definitions/components/graphql/GraphQL-IntegratedDemo.sitecore.graphql index 2a7806032a..c4c88c519b 100644 --- a/packages/create-sitecore-jss/src/templates/nextjs-styleguide/sitecore/definitions/components/graphql/GraphQL-IntegratedDemo.sitecore.graphql +++ b/packages/create-sitecore-jss/src/templates/nextjs-styleguide/sitecore/definitions/components/graphql/GraphQL-IntegratedDemo.sitecore.graphql @@ -42,8 +42,8 @@ query IntegratedDemoQuery($datasource: String!, $contextItem: String!, $language # (as long as the GraphQLData helper is used) contextItem: item(path: $contextItem, language: $language) { id - # Get the page title from the page template - ...on <%- helper.getAppPrefix(appPrefix, appName, false) %>Page { + # Get the page title from the app route template + ...on <%- helper.getAppPrefix(appPrefix, appName, false) %>AppRoute { pageTitle { value } @@ -56,7 +56,7 @@ query IntegratedDemoQuery($datasource: String!, $contextItem: String!, $language # typing fragments can be used anywhere! # so in this case, we're grabbing the 'pageTitle' # field on all child route items. - ...on <%- helper.getAppPrefix(appPrefix, appName, false) %>Page { + ...on <%- helper.getAppPrefix(appPrefix, appName, false) %>AppRoute { pageTitle { jsonValue value diff --git a/packages/create-sitecore-jss/src/templates/nextjs-styleguide/sitecore/definitions/routes.sitecore.ts b/packages/create-sitecore-jss/src/templates/nextjs-styleguide/sitecore/definitions/routes.sitecore.ts index 8d3682b2ef..ff4a23b52c 100644 --- a/packages/create-sitecore-jss/src/templates/nextjs-styleguide/sitecore/definitions/routes.sitecore.ts +++ b/packages/create-sitecore-jss/src/templates/nextjs-styleguide/sitecore/definitions/routes.sitecore.ts @@ -24,8 +24,8 @@ export default function addRoutesToManifest(manifest: Manifest): Promise { const appTemplateSection = 'Page Metadata'; manifest.setDefaultRouteType({ - name: '<%- helper.getAppPrefix(appPrefix, appName) %>Page', - displayName: 'Page', + name: '<%- helper.getAppPrefix(appPrefix, appName) %>App Route', + displayName: 'App Route', fields: [ { name: 'pageTitle', @@ -34,7 +34,7 @@ export default function addRoutesToManifest(manifest: Manifest): Promise { type: CommonFieldTypes.SingleLineText, }, ], - insertOptions: ['<%- helper.getAppPrefix(appPrefix, appName) %>Page'], + insertOptions: ['<%- helper.getAppPrefix(appPrefix, appName) %>App Route'], }); return mergeFs('./data/routes') // relative to process invocation (i.e. your package.json) diff --git a/packages/create-sitecore-jss/src/templates/nextjs-styleguide/src/components/graphql/GraphQL-ConnectedDemo.dynamic.graphql b/packages/create-sitecore-jss/src/templates/nextjs-styleguide/src/components/graphql/GraphQL-ConnectedDemo.dynamic.graphql index 625492455a..79c90f9b29 100644 --- a/packages/create-sitecore-jss/src/templates/nextjs-styleguide/src/components/graphql/GraphQL-ConnectedDemo.dynamic.graphql +++ b/packages/create-sitecore-jss/src/templates/nextjs-styleguide/src/components/graphql/GraphQL-ConnectedDemo.dynamic.graphql @@ -40,8 +40,8 @@ query ConnectedDemoQuery($datasource: String!, $contextItem: String!, $language: # $contextItem should be set to the ID of the current context item (the route item) contextItem: item(path: $contextItem, language: $language) { id - # Get the page title from the page template - ...on <%- helper.getAppPrefix(appPrefix, appName, false) %>Page { + # Get the page title from the app route template + ...on <%- helper.getAppPrefix(appPrefix, appName, false) %>AppRoute { pageTitle { value } @@ -54,7 +54,7 @@ query ConnectedDemoQuery($datasource: String!, $contextItem: String!, $language: # typing fragments can be used anywhere! # so in this case, we're grabbing the 'pageTitle' # field on all child route items. - ...on <%- helper.getAppPrefix(appPrefix, appName, false) %>Page { + ...on <%- helper.getAppPrefix(appPrefix, appName, false) %>AppRoute { pageTitle { jsonValue value diff --git a/packages/create-sitecore-jss/src/templates/nextjs-styleguide/src/components/graphql/GraphQL-ConnectedDemo.dynamic.tsx b/packages/create-sitecore-jss/src/templates/nextjs-styleguide/src/components/graphql/GraphQL-ConnectedDemo.dynamic.tsx index 650fe13c94..44af181900 100644 --- a/packages/create-sitecore-jss/src/templates/nextjs-styleguide/src/components/graphql/GraphQL-ConnectedDemo.dynamic.tsx +++ b/packages/create-sitecore-jss/src/templates/nextjs-styleguide/src/components/graphql/GraphQL-ConnectedDemo.dynamic.tsx @@ -12,18 +12,18 @@ import { import NextLink from 'next/link'; import { ConnectedDemoQueryDocument, - <%- helper.getAppPrefix(appPrefix, appName, false) %>Page as Page, + <%- helper.getAppPrefix(appPrefix, appName, false) %>AppRoute as AppRoute, Item, <%- helper.getAppPrefix(appPrefix, appName, false) %>GraphQlConnectedDemo as GrapQLConnectedDemoDatasource, } from './GraphQL-ConnectedDemo.dynamic.graphql'; import { ComponentProps } from 'lib/component-props'; import config from 'temp/config'; -type PageItem = Page & Item; +type RouteItem = AppRoute & Item; type GraphQLConnectedDemoData = { datasource: GrapQLConnectedDemoDatasource; - contextItem: PageItem; + contextItem: RouteItem; }; type GraphQLConnectedDemoProps = ComponentProps & GraphQLConnectedDemoData; @@ -80,12 +80,12 @@ const GraphQLConnectedDemo = (props: GraphQLConnectedDemoProps): JSX.Element => children:
    {props.contextItem.children.results.map((child) => { - const pageItem = child as PageItem; + const routeItem = child as RouteItem; return ( -
  • - {pageItem.pageTitle?.value} - (editable title too! ) +
  • + {routeItem.pageTitle?.value} + (editable title too! )
  • ); })} diff --git a/packages/create-sitecore-jss/src/templates/nextjs/src/temp/GraphQLIntrospectionResult.json b/packages/create-sitecore-jss/src/templates/nextjs/src/temp/GraphQLIntrospectionResult.json index 7b8a27f9d9..e31e5d3dc4 100644 --- a/packages/create-sitecore-jss/src/templates/nextjs/src/temp/GraphQLIntrospectionResult.json +++ b/packages/create-sitecore-jss/src/templates/nextjs/src/temp/GraphQLIntrospectionResult.json @@ -2179,7 +2179,7 @@ }, { "kind": "OBJECT", - "name": "C__<%- helper.getAppPrefix(appPrefix, appName, false) %>Page", + "name": "C__<%- helper.getAppPrefix(appPrefix, appName, false) %>AppRoute", "ofType": null }, { @@ -17760,7 +17760,7 @@ "interfaces": [ { "kind": "INTERFACE", - "name": "<%- helper.getAppPrefix(appPrefix, appName, false) %>Page", + "name": "<%- helper.getAppPrefix(appPrefix, appName, false) %>AppRoute", "ofType": null }, { @@ -18219,8 +18219,8 @@ }, { "kind": "OBJECT", - "name": "C__<%- helper.getAppPrefix(appPrefix, appName, false) %>Page", - "description": "/sitecore/templates/Project/<%- helper.getAppPrefix(appPrefix, appName, false) %>/<%- helper.getAppPrefix(appPrefix, appName, false) %>-Page template (ID: {787584C0-A057-5876-9836-F8B3708F0CAF}). NOTE: This is a concrete type. Favor using interfaces instead of this type (e.g. <%- helper.getAppPrefix(appPrefix, appName, false) %>Page) for reliable querying.", + "name": "C__<%- helper.getAppPrefix(appPrefix, appName, false) %>AppRoute", + "description": "/sitecore/templates/Project/<%- helper.getAppPrefix(appPrefix, appName, false) %>/<%- helper.getAppPrefix(appPrefix, appName, false) %>-App Route template (ID: {787584C0-A057-5876-9836-F8B3708F0CAF}). NOTE: This is a concrete type. Favor using interfaces instead of this type (e.g. <%- helper.getAppPrefix(appPrefix, appName, false) %>AppRoute) for reliable querying.", "fields": [ { "name": "ancestors", @@ -18643,7 +18643,7 @@ "interfaces": [ { "kind": "INTERFACE", - "name": "<%- helper.getAppPrefix(appPrefix, appName, false) %>Page", + "name": "<%- helper.getAppPrefix(appPrefix, appName, false) %>AppRoute", "ofType": null }, { @@ -21496,8 +21496,8 @@ }, { "kind": "INTERFACE", - "name": "<%- helper.getAppPrefix(appPrefix, appName, false) %>Page", - "description": "/sitecore/templates/Project/<%- helper.getAppPrefix(appPrefix, appName, false) %>/<%- helper.getAppPrefix(appPrefix, appName, false) %>-Page template (ID: {787584C0-A057-5876-9836-F8B3708F0CAF}). Also implements Route.", + "name": "<%- helper.getAppPrefix(appPrefix, appName, false) %>AppRoute", + "description": "/sitecore/templates/Project/<%- helper.getAppPrefix(appPrefix, appName, false) %>/<%- helper.getAppPrefix(appPrefix, appName, false) %>-App Route template (ID: {787584C0-A057-5876-9836-F8B3708F0CAF}). Also implements Route.", "fields": [ { "name": "pageTitle", @@ -21523,7 +21523,7 @@ }, { "kind": "OBJECT", - "name": "C__<%- helper.getAppPrefix(appPrefix, appName, false) %>Page", + "name": "C__<%- helper.getAppPrefix(appPrefix, appName, false) %>AppRoute", "ofType": null } ] diff --git a/packages/create-sitecore-jss/src/templates/react/sitecore/definitions/components/GraphQL-IntegratedDemo.sitecore.graphql b/packages/create-sitecore-jss/src/templates/react/sitecore/definitions/components/GraphQL-IntegratedDemo.sitecore.graphql index 2a7806032a..c4c88c519b 100644 --- a/packages/create-sitecore-jss/src/templates/react/sitecore/definitions/components/GraphQL-IntegratedDemo.sitecore.graphql +++ b/packages/create-sitecore-jss/src/templates/react/sitecore/definitions/components/GraphQL-IntegratedDemo.sitecore.graphql @@ -42,8 +42,8 @@ query IntegratedDemoQuery($datasource: String!, $contextItem: String!, $language # (as long as the GraphQLData helper is used) contextItem: item(path: $contextItem, language: $language) { id - # Get the page title from the page template - ...on <%- helper.getAppPrefix(appPrefix, appName, false) %>Page { + # Get the page title from the app route template + ...on <%- helper.getAppPrefix(appPrefix, appName, false) %>AppRoute { pageTitle { value } @@ -56,7 +56,7 @@ query IntegratedDemoQuery($datasource: String!, $contextItem: String!, $language # typing fragments can be used anywhere! # so in this case, we're grabbing the 'pageTitle' # field on all child route items. - ...on <%- helper.getAppPrefix(appPrefix, appName, false) %>Page { + ...on <%- helper.getAppPrefix(appPrefix, appName, false) %>AppRoute { pageTitle { jsonValue value diff --git a/packages/create-sitecore-jss/src/templates/react/sitecore/definitions/routes.sitecore.js b/packages/create-sitecore-jss/src/templates/react/sitecore/definitions/routes.sitecore.js index d5ec001eb3..c87e3c5bc5 100644 --- a/packages/create-sitecore-jss/src/templates/react/sitecore/definitions/routes.sitecore.js +++ b/packages/create-sitecore-jss/src/templates/react/sitecore/definitions/routes.sitecore.js @@ -28,7 +28,7 @@ export default function addRoutesToManifest(manifest) { const appTemplateSection = 'Page Metadata'; manifest.setDefaultRouteType({ - name: '<%- helper.getAppPrefix(appPrefix, appName) %>Page', + name: '<%- helper.getAppPrefix(appPrefix, appName) %>App Route', fields: [ { name: 'pageTitle', @@ -37,7 +37,7 @@ export default function addRoutesToManifest(manifest) { type: CommonFieldTypes.SingleLineText, }, ], - insertOptions: ['<%- helper.getAppPrefix(appPrefix, appName) %>Page'], + insertOptions: ['<%- helper.getAppPrefix(appPrefix, appName) %>App Route'], }); return mergeFs('./data/routes') // relative to process invocation (i.e. your package.json) diff --git a/packages/create-sitecore-jss/src/templates/react/src/components/GraphQL-ConnectedDemo/query.graphql b/packages/create-sitecore-jss/src/templates/react/src/components/GraphQL-ConnectedDemo/query.graphql index 370bdebe50..c40eb414ff 100644 --- a/packages/create-sitecore-jss/src/templates/react/src/components/GraphQL-ConnectedDemo/query.graphql +++ b/packages/create-sitecore-jss/src/templates/react/src/components/GraphQL-ConnectedDemo/query.graphql @@ -40,8 +40,8 @@ query ConnectedDemoQuery($datasource: String!, $contextItem: String!, $language: # $contextItem should be set to the ID of the current context item (the route item) contextItem: item(path: $contextItem, language: $language) { id - # Get the page title from the page template - ...on <%- helper.getAppPrefix(appPrefix, appName, false) %>Page { + # Get the page title from the app route template + ...on <%- helper.getAppPrefix(appPrefix, appName, false) %>AppRoute { pageTitle { value } @@ -54,7 +54,7 @@ query ConnectedDemoQuery($datasource: String!, $contextItem: String!, $language: # typing fragments can be used anywhere! # so in this case, we're grabbing the 'pageTitle' # field on all child route items. - ...on <%- helper.getAppPrefix(appPrefix, appName, false) %>Page { + ...on <%- helper.getAppPrefix(appPrefix, appName, false) %>AppRoute { pageTitle { jsonValue value diff --git a/packages/create-sitecore-jss/src/templates/react/src/temp/GraphQLFragmentTypes.json b/packages/create-sitecore-jss/src/templates/react/src/temp/GraphQLFragmentTypes.json index 58af040057..f4a50cbbc7 100644 --- a/packages/create-sitecore-jss/src/templates/react/src/temp/GraphQLFragmentTypes.json +++ b/packages/create-sitecore-jss/src/templates/react/src/temp/GraphQLFragmentTypes.json @@ -141,7 +141,7 @@ "name": "<%- helper.getAppPrefix(appPrefix, appName, false) %>ContentBlock" }, { - "name": "C__<%- helper.getAppPrefix(appPrefix, appName, false) %>Page" + "name": "C__<%- helper.getAppPrefix(appPrefix, appName, false) %>AppRoute" }, { "name": "JsonRendering" @@ -180,13 +180,13 @@ }, { "kind": "INTERFACE", - "name": "<%- helper.getAppPrefix(appPrefix, appName, false) %>Page", + "name": "<%- helper.getAppPrefix(appPrefix, appName, false) %>AppRoute", "possibleTypes": [ { "name": "<%- helper.getAppPrefix(appPrefix, appName, false) %>ExampleCustomRouteType" }, { - "name": "C__<%- helper.getAppPrefix(appPrefix, appName, false) %>Page" + "name": "C__<%- helper.getAppPrefix(appPrefix, appName, false) %>AppRoute" } ] }, diff --git a/packages/create-sitecore-jss/src/templates/vue/sitecore/definitions/components/GraphQL-IntegratedDemo.sitecore.graphql b/packages/create-sitecore-jss/src/templates/vue/sitecore/definitions/components/GraphQL-IntegratedDemo.sitecore.graphql index 25ed95ea57..c46af12479 100644 --- a/packages/create-sitecore-jss/src/templates/vue/sitecore/definitions/components/GraphQL-IntegratedDemo.sitecore.graphql +++ b/packages/create-sitecore-jss/src/templates/vue/sitecore/definitions/components/GraphQL-IntegratedDemo.sitecore.graphql @@ -42,8 +42,8 @@ query IntegratedDemoQuery($datasource: String!, $contextItem: String!, $language # (as long as the GraphQLData helper is used) contextItem: item(path: $contextItem, language: $language) { id - # Get the page title from the page template - ...on <%- helper.getAppPrefix(appPrefix, appName, false) %>Page { + # Get the page title from the app route template + ...on <%- helper.getAppPrefix(appPrefix, appName, false) %>AppRoute { pageTitle { value } @@ -56,7 +56,7 @@ query IntegratedDemoQuery($datasource: String!, $contextItem: String!, $language # typing fragments can be used anywhere! # so in this case, we're grabbing the 'pageTitle' # field on all child route items. - ...on <%- helper.getAppPrefix(appPrefix, appName, false) %>Page { + ...on <%- helper.getAppPrefix(appPrefix, appName, false) %>AppRoute { pageTitle { jsonValue value diff --git a/packages/create-sitecore-jss/src/templates/vue/sitecore/definitions/routes.sitecore.js b/packages/create-sitecore-jss/src/templates/vue/sitecore/definitions/routes.sitecore.js index a05b84a638..ccda38244d 100644 --- a/packages/create-sitecore-jss/src/templates/vue/sitecore/definitions/routes.sitecore.js +++ b/packages/create-sitecore-jss/src/templates/vue/sitecore/definitions/routes.sitecore.js @@ -22,7 +22,7 @@ export default function addRoutesToManifest(manifest) { const appTemplateSection = 'Page Metadata'; manifest.setDefaultRouteType({ - name: '<%- helper.getAppPrefix(appPrefix, appName) %>Page', + name: '<%- helper.getAppPrefix(appPrefix, appName) %>App Route', fields: [ { name: 'pageTitle', @@ -31,7 +31,7 @@ export default function addRoutesToManifest(manifest) { type: CommonFieldTypes.SingleLineText, }, ], - insertOptions: ['<%- helper.getAppPrefix(appPrefix, appName) %>Page'], + insertOptions: ['<%- helper.getAppPrefix(appPrefix, appName) %>App Route'], }); return mergeFs('./data/routes') // relative to process invocation (i.e. your package.json) diff --git a/packages/create-sitecore-jss/src/templates/vue/src/components/GraphQL/GraphQL-ConnectedDemo.query.graphql b/packages/create-sitecore-jss/src/templates/vue/src/components/GraphQL/GraphQL-ConnectedDemo.query.graphql index 840b9da4c7..007489a978 100644 --- a/packages/create-sitecore-jss/src/templates/vue/src/components/GraphQL/GraphQL-ConnectedDemo.query.graphql +++ b/packages/create-sitecore-jss/src/templates/vue/src/components/GraphQL/GraphQL-ConnectedDemo.query.graphql @@ -40,8 +40,8 @@ query ConnectedDemoQuery($datasource: String!, $contextItem: String!, $language: # $contextItem should be set to the ID of the current context item (the route item) contextItem: item(path: $contextItem, language: $language) { id - # Get the page title from the page template - ...on <%- helper.getAppPrefix(appPrefix, appName, false) %>Page { + # Get the page title from the app route template + ...on <%- helper.getAppPrefix(appPrefix, appName, false) %>AppRoute { pageTitle { value } @@ -54,7 +54,7 @@ query ConnectedDemoQuery($datasource: String!, $contextItem: String!, $language: # typing fragments can be used anywhere! # so in this case, we're grabbing the 'pageTitle' # field on all child route items. - ...on <%- helper.getAppPrefix(appPrefix, appName, false) %>Page { + ...on <%- helper.getAppPrefix(appPrefix, appName, false) %>AppRoute { pageTitle { jsonValue value diff --git a/packages/create-sitecore-jss/src/templates/vue/src/temp/GraphQLFragmentTypes.json b/packages/create-sitecore-jss/src/templates/vue/src/temp/GraphQLFragmentTypes.json index 4cc2f11061..cf3550b1dc 100644 --- a/packages/create-sitecore-jss/src/templates/vue/src/temp/GraphQLFragmentTypes.json +++ b/packages/create-sitecore-jss/src/templates/vue/src/temp/GraphQLFragmentTypes.json @@ -144,7 +144,7 @@ "name": "<%- helper.getAppPrefix(appPrefix, appName, false) %>ContentBlock" }, { - "name": "C__<%- helper.getAppPrefix(appPrefix, appName, false) %>Page" + "name": "C__<%- helper.getAppPrefix(appPrefix, appName, false) %>AppRoute" }, { "name": "JsonRendering" @@ -246,13 +246,13 @@ }, { "kind": "INTERFACE", - "name": "<%- helper.getAppPrefix(appPrefix, appName, false) %>Page", + "name": "<%- helper.getAppPrefix(appPrefix, appName, false) %>AppRoute", "possibleTypes": [ { "name": "<%- helper.getAppPrefix(appPrefix, appName, false) %>ExampleCustomRouteType" }, { - "name": "C__<%- helper.getAppPrefix(appPrefix, appName, false) %>Page" + "name": "C__<%- helper.getAppPrefix(appPrefix, appName, false) %>AppRoute" } ] },