diff --git a/messages/en.json b/messages/en.json index df25ee6..b87111f 100644 --- a/messages/en.json +++ b/messages/en.json @@ -26,5 +26,7 @@ "docs/recipes/plugins": "Plugins Recipes", "docs/recipes/custom-blocks": "Custom Blocks Recipes", "docs/recipes/all": "All Recipes", - "docs/read-more": "Read more" + "docs/read-more": "Read more", + "docs/lorem": "Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nam vel ligula sagittis, dignissim nisi non, interdum elit. Vivamus eget dolor egestas, hendrerit urna a, finibus enim. Phasellus mollis mollis dui ut mattis. In ut purus sem. Quisque volutpat ornare consequat.", + "docs/lorem-short": "Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod." } diff --git a/messages/pt.json b/messages/pt.json index 077bb4a..75040c6 100644 --- a/messages/pt.json +++ b/messages/pt.json @@ -26,5 +26,7 @@ "docs/recipes/plugins": "Plugins Recipes", "docs/recipes/custom-blocks": "Custom Blocks Recipes", "docs/recipes/all": "All Recipes", - "docs/read-more": "Read more" + "docs/read-more": "Read more", + "docs/lorem": "Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nam vel ligula sagittis, dignissim nisi non, interdum elit. Vivamus eget dolor egestas, hendrerit urna a, finibus enim. Phasellus mollis mollis dui ut mattis. In ut purus sem. Quisque volutpat ornare consequat.", + "docs/lorem-short": "Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod." } \ No newline at end of file diff --git a/react/Home.tsx b/react/Home.tsx index 79c8285..9fb0053 100644 --- a/react/Home.tsx +++ b/react/Home.tsx @@ -42,8 +42,7 @@ const Home: FunctionComponent = ({ intl }) => {

- Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed - do eiusmod. +

@@ -74,8 +73,7 @@ const Home: FunctionComponent = ({ intl }) => {

- Lorem ipsum dolor sit amet, consectetur adipiscing elit, - sed do eiusmod. +

@@ -87,8 +85,7 @@ const Home: FunctionComponent = ({ intl }) => {

- Lorem ipsum dolor sit amet, consectetur adipiscing elit, - sed do eiusmod. +

@@ -100,8 +97,7 @@ const Home: FunctionComponent = ({ intl }) => {

- Lorem ipsum dolor sit amet, consectetur adipiscing elit, - sed do eiusmod. +

diff --git a/react/RecipesList.tsx b/react/RecipesList.tsx index 4b29c54..499521a 100644 --- a/react/RecipesList.tsx +++ b/react/RecipesList.tsx @@ -69,11 +69,7 @@ const RecipesList: FunctionComponent = ({

- Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nam - vel ligula sagittis, dignissim nisi non, interdum elit. - Vivamus eget dolor egestas, hendrerit urna a, finibus enim. - Phasellus mollis mollis dui ut mattis. In ut purus sem. - Quisque volutpat ornare consequat. +

{RecipeListQuery.getRecipeList.map((recipe: Recipe) => ( @@ -108,7 +104,9 @@ interface Props { function getShortRecipePath(path: string) { // the path will always be something like: dist/vtex.docs-graphql/Recipes//.md - return path.substring(31, path.length - 3) + const PATH_PREFIX = 'dist/vtex.docs-graphql/Recipes/' + const FILE_EXTENSION = '.md' + return path.substring(PATH_PREFIX.length, path.length - FILE_EXTENSION.length) } export default compose( diff --git a/react/components/Community.tsx b/react/components/Community.tsx index 06c8593..1b953a3 100644 --- a/react/components/Community.tsx +++ b/react/components/Community.tsx @@ -17,8 +17,7 @@ const Community: FunctionComponent = ({ intl }) => (

- Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do - eiusmod. +