Skip to content

Commit

Permalink
feat(gatsby-source-contentful): add structured text node type (#8214)
Browse files Browse the repository at this point in the history
This PR adds the support for a new field in contentful called [rich text](https://www.contentful.com/developers/docs/concepts/rich-text/)

> The Rich Text is a new field type that enables a rich text editor in an entry. It allows a content author to format text in a visual way (WYSIWYG) and also embed linked entries as well. 

This is still in a alpha and super early. This Pr is just adding the field type to the schema so we can create transformers for it in the future.
  • Loading branch information
Khaledgarbaya authored and pieh committed Oct 23, 2018
1 parent 3969a94 commit 57f48ef
Show file tree
Hide file tree
Showing 4 changed files with 2,799 additions and 2,652 deletions.
9 changes: 9 additions & 0 deletions packages/gatsby-source-contentful/README.md
Expand Up @@ -124,3 +124,12 @@ like the following:
}
}
```
## **Beta** [Contentful Rich Text](https://www.contentful.com/developers/docs/concepts/rich-text/)

if you want to use the new Rich Text feature you can opt-in by setting the following environment variable

```sh
export GATSBY_CONTENTFUL_RICH_TEXT='enabled'
```


Expand Up @@ -1741,6 +1741,7 @@ Our Lemnos products are made carefully by our craftsmen finely honed skillful te
},
},
],
Array [],
Array [
Object {
"fields": Object {
Expand Down Expand Up @@ -3861,6 +3862,34 @@ Unsere Lemnos Produkte werden sorgfältig von unseren Handwerkern fein geschliff
"productDescription": "Die neu veröffentlichte SoSo Clock von Lemnos heiratet einfaches, sauberes Design und fette, auffällige Features. Sein gesättigtes Ringelblumengesicht ist ein lebhafter Pop der Farbe zu den weißen oder grauen Wänden, aber würde auch gut mit Marine und kastanienbraun paaren. Wo die meisten Uhren am Rande der Uhr Nummern sind, bringt der SoSo sie in die Mitte und lässt einen weiten Raum zwischen den Zahlen und dem leichten Rahmen. Der Stundenzeiger bietet eine schöne Unterbrechung der schwarzen und gelben der Uhr - es ist in einem brillanten Weiß vorgestellt. Trotz seiner kräftigen Farbe und des Kontrastes behält der SoSo eine saubere, reine Ästhetik, die für eine Vielzahl von zeitgenössischen Interieurs geeignet ist.",
},
],
Array [
Object {
"children": Array [],
"description": "",
"displayField": "name",
"id": "uuid-from-gatsby",
"internal": Object {
"contentDigest": "36295a10b54f67251a163b00c188b02e",
"type": "ContentfulContentType",
},
"name": "StTest",
"parent": null,
},
],
Array [
Object {
"children": Array [],
"description": "",
"displayField": "name",
"id": "uuid-from-gatsby",
"internal": Object {
"contentDigest": "36295a10b54f67251a163b00c188b02e",
"type": "ContentfulContentType",
},
"name": "StTest",
"parent": null,
},
],
Array [
Object {
"children": Array [],
Expand Down

0 comments on commit 57f48ef

Please sign in to comment.