Skip to content
This repository has been archived by the owner on Jan 20, 2025. It is now read-only.

Translate docs/recipes/sourcing-data #65

Conversation

weronikadominiak
Copy link

No description provided.

@weronikadominiak weronikadominiak changed the title docs/recipes/sourcing-data translation Translate docs/recipes/sourcing-data Jun 9, 2021
Copy link
Contributor

@mbiesiad mbiesiad left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please fix mentioned issues (ie. can't be typos here, in docs).

@@ -1,19 +1,20 @@
---
title: "Recipes: Sourcing Data"
w ---
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Probably 'missclick'. Please, remove.


## Adding data to GraphQL
Do pozyskania danych w Gatsby używa się wtyczek, które pozyskują dane z określonych źrodeł (np. `gatsby-source-filesystem` pobiera dane z plików systemowych, `gatsby-source-wordpress` pobiera dane z WordPress Api, itp.). Możesz również pozyskać dane samodzielnie samodzielnie.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please use "API" (that's the correct form, ie.: https://en.wikipedia.org/wiki/API).


## Adding data to GraphQL
Do pozyskania danych w Gatsby używa się wtyczek, które pozyskują dane z określonych źrodeł (np. `gatsby-source-filesystem` pobiera dane z plików systemowych, `gatsby-source-wordpress` pobiera dane z WordPress Api, itp.). Możesz również pozyskać dane samodzielnie samodzielnie.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

"samodzielnie" doubled here, please remove redundant one.


Gatsby's [GraphQL data layer](/docs/graphql-concepts/) uses nodes to model chunks of data. Gatsby source plugins add source nodes that you can query for, but you can also create source nodes yourself. To add custom data to the GraphQL data layer yourself, Gatsby provides methods you can leverage.
[Warstwa danych GraphQL](/docs/graphql-concepts/) wykorzystuje node'y, by zmodelować porcje danych. Wtyczki źródeł dodają źródłowe node'y, które możesz pozyskać poprzez wykonanie odpowiedniego zpaytania. Możesz także stworzyć źródłowe node'y samodzielnie - Gatsby zapewnia metody, które możesz wykorzystać by dodać niestandardowe dane do warstwy danych GraphQL.
Copy link
Contributor

@mbiesiad mbiesiad Jun 9, 2021

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Typo (zpaytania). Need to be fixed, suggested:
zapytania


> _Note: After making changes in `gatsby-node.js` you need to re-run `gatsby develop` for the changes to take effect._
> _Uwaga: Po dokonaniu zmian w `gatsby-node.js` muisz ponownie uruchomić komendę `gatsby develop` aby zaobserwować te zmiany._
Copy link
Contributor

@mbiesiad mbiesiad Jun 9, 2021

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Typo (muisz). Please change to 'musisz'.


3. Query the data (in GraphiQL or in your components).
3. Wykonaj zapytanie (w GraphiQL lub w Twoim komponencie).
Copy link
Contributor

@mbiesiad mbiesiad Jun 9, 2021

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If I'm not mistaken, here should be 'twoim' used (written with lowercase letters). But it should be confirmed if nothing has changed.


You can source Markdown data and use Gatsby's [`createPages` API](/docs/actions/#createPage) to create pages dynamically.
## Pozyskiwanie danych z Markdownu dla blog postów i stron z GraphQL
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

"blog postów" should be changed.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actually, it would be great to change a little bit, like 'wraz z GraphQL' or 'korzystając z GraphQL'.


You can source Markdown data and use Gatsby's [`createPages` API](/docs/actions/#createPage) to create pages dynamically.
## Pozyskiwanie danych z Markdownu dla blog postów i stron z GraphQL
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actually, it would be great to change a little bit, like 'wraz z GraphQL' or 'korzystając z GraphQL'.


This recipe shows how to create pages from Markdown files on your local filesystem using Gatsby's GraphQL data layer.
Możesz pozyskać dane z Markdownu i użyć [`createPages` API](/docs/actions/#createPage) by dynamicznie stworzyć strony.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

'aby' could be better IMO, anyway, comma needed here.


This recipe shows how to create pages from Markdown files on your local filesystem using Gatsby's GraphQL data layer.
Możesz pozyskać dane z Markdownu i użyć [`createPages` API](/docs/actions/#createPage) by dynamicznie stworzyć strony.
Ten przepis pokazuje w jaki sposób z plikow Markdown ulokowanych na twoim lokalnym systemie stworzyć strony z użyciem warstwy danych GraphQl.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

plikow -> plików
previously used 'Twoim', here 'twoim', must be unified.
GraphQl -> GraphQL


### Prerequisites
### Wymagania
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Wymagania wstępne


1. In `gatsby-config.js`, configure `gatsby-transformer-remark` along with `gatsby-source-filesystem` to pull in Markdown files from a source folder. This would be in addition to any previous `gatsby-source-filesystem` entries, such as for images:
1. Do pliku `gatsby-config.js`, dodaj `gatsby-transformer-remark` i `gatsby-source-filesystem` by pobrać dane z plików Markdown znajdujących się w folderze `source`. Będzie to dodatkiem do poprzednich wpisów w `gatsby-source-filesystem` jak na przykład dla obrazków:
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

'by pobrać dane' -> 'aby pobrać dane' sounds better IMO, anyway comma needed.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Before 'jak' also comma needed.

- The [JSON:API module](https://www.drupal.org/project/jsonapi) installed and enabled on the Drupal site
- [Strona Gatsby](/docs/quick-start)
- [Drupal](http://drupal.org)
- [JSON:API moduł](https://www.drupal.org/project/jsonapi) zainstalowany i aktywowany na Drupal
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

rearrange the words ('moduł' first)


```shell
npm install --save gatsby-source-drupal
```

2. Edit your `gatsby-config.js` file to enable the plugin and configure it.
2. Dodaj poniższy kod do pliku `gatsby-config.js` by skonfigurować i aktywować wtyczkę.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Comma ',' needed before 'by/aby'

@@ -567,7 +567,10 @@ module.exports = {
}
```

3. Start the development server with `gatsby develop`, and open the GraphiQL explorer at `http://localhost:8000/___graphql`. Under the Explorer tab, you should see new node types, such as `allBlockBlock` for Drupal blocks, and one for every content type in your Drupal site. For example, if you have a "Page" content type, it will be available as `allNodePage`. To query all "Page" nodes for their title and body, use a query like:
3. Uruchom serwer developerski przy użyciu komendy `gatsby develop`, otwórz eksplorator GraphiQL pod adresem `http://localhost:8000/___graphql`.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Change: developerski

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Change: "i eden dla każdego"

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Twoim -> twoim

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Comma needed; jeśli

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Typo: poniżego


_**Note:** the exact GraphQL schema will depend on your how Drupal instance is structured._
_**Uwaga:** dokładna schema GraphQL będzie zależała od tego jak skonfigurowana jest Twoja instancja Drupal._
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

twoja + comma "," (jak)

@@ -625,10 +628,10 @@ export const query = graphql`
}
```

5. With the development server running, you can view the new page by visiting `http://localhost:8000/drupal`.
5. Mając uruchomiony serwer developerski możesz zobaczyć swoją nową stronę odwiedzając `http://localhost:8000/drupal`
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Change: developerski

@weronikadominiak
Copy link
Author

@mbiesiad Thank you for the great review! Yes of course, it can't have typos! I've replaced "by" with "aby", added a few more missing commas. Changed all Wordpress and Markdown to always use original form.

@mbiesiad
Copy link
Contributor

mbiesiad commented Jun 10, 2021

@weronikadominiak My pleasure! Sounds awesome! 🎉 Your work was great as well! I will take a look ASAP (pm/evening). Let's keep in touch, Best wishes

@weronikadominiak
Copy link
Author

Closing due to #1 (comment)

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants