You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: src/content/reference/react-dom/components/form.md
+1-1Lines changed: 1 addition & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -30,7 +30,7 @@ Le [composant natif `<form>` du navigateur](https://developer.mozilla.org/fr/doc
30
30
31
31
### `<form>` {/*form*/}
32
32
33
-
Pour créer des formulaires interactifs, utilisez le [composant natif `<input>` du navigateur](https://developer.mozilla.org/fr/docs/Web/HTML/Element/form).
33
+
Pour créer des formulaires interactifs, utilisez le [composant natif `<form>` du navigateur](https://developer.mozilla.org/fr/docs/Web/HTML/Element/form).
Copy file name to clipboardExpand all lines: src/content/reference/react-dom/components/meta.md
+26-26Lines changed: 26 additions & 26 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -5,14 +5,14 @@ canary: true
5
5
6
6
<Canary>
7
7
8
-
React's extensions to `<meta>`are currently only available in React's canary and experimental channels. In stable releases of React `<meta>`works only as a [built-in browser HTML component](https://react.dev/reference/react-dom/components#all-html-components). Learn more about [React's release channels here](/community/versioning-policy#all-release-channels).
8
+
Les extensions de React à `<meta>`ne sont actuellement disponibles que sur les canaux de livraison Canary et Expérimental de React. Dans les versions stables de React,`<meta>`fonctionne comme [le composant HTML natif du navigateur](/reference/react-dom/components#all-html-components). Apprenez-en davantage sur [les canaux de livraison React](/community/versioning-policy#all-release-channels).
9
9
10
10
</Canary>
11
11
12
12
13
13
<Intro>
14
14
15
-
The [built-in browser`<meta>`component](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/meta)lets you add metadata to the document.
15
+
Le [composant natif`<meta>`du navigateur](https://developer.mozilla.org/fr/docs/Web/HTML/Element/meta)vous permet d'ajouter des métadonnées au document ou à des éléments spécifiques.
@@ -24,51 +24,51 @@ The [built-in browser `<meta>` component](https://developer.mozilla.org/en-US/do
24
24
25
25
---
26
26
27
-
## Reference {/*reference*/}
27
+
## Référence {/*reference*/}
28
28
29
29
### `<meta>` {/*meta*/}
30
30
31
-
To add document metadata, render the [built-in browser`<meta>`component](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/meta). You can render`<meta>`from any component and React will always place the corresponding DOM element in the document head.
31
+
Pour ajouter des métadonnées au document, utilisez le [composant natif`<meta>`du navigateur](https://developer.mozilla.org/fr/docs/Web/HTML/Element/meta). Vous pouvez utiliser`<meta>`depuis n'importe quel composant et React placera systématiquement l'élément DOM correspondant dans l'en-tête (`head`) du document.
`<meta>`supports all [common element props.](/reference/react-dom/components/common#props)
41
+
`<meta>`prend en charge toutes les [props communes aux éléments](/reference/react-dom/components/common#props).
42
42
43
-
It should have *exactly one* of the following props: `name`, `httpEquiv`, `charset`, `itemProp`. The `<meta>`component does something different depending on which of these props is specified.
43
+
Il est censé utiliser *une et une seule* des props suivantes : `name`, `httpEquiv`, `charset` ou `itemProp`. Le composant `<meta>`a un comportement distinct selon la prop que vous utilisez.
44
44
45
-
*`name`: a string. Specifies the [kind of metadata](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/meta/name)to be attached to the document.
46
-
*`charset`: a string. Specifies the character set used by the document. The only valid value is`"utf-8"`.
47
-
*`httpEquiv`: a string. Specifies a directive for processing the document.
48
-
*`itemProp`: a string. Specifies metadata about a particular item within the document rather than the document as a whole.
49
-
*`content`: a string. Specifies the metadata to be attached when used with the `name`or`itemProp` props or the behavior of the directive when used with the `httpEquiv`prop.
45
+
*`name` : une chaîne de caractères. Indique le [type de métadonnée](https://developer.mozilla.org/fr/docs/Web/HTML/Element/meta/name)à associer au document.
46
+
*`charset` : une chaîne de caractères. Indique le jeu de caractères à utiliser pour le document. La seule valeur acceptable est`"utf-8"`.
47
+
*`httpEquiv` : une chaîne de caractères. Fournit une directive de traitement du document.
48
+
*`itemProp` : une chaîne de caractères. Associe la métadonnée à un élément spécifique du document plutôt qu'au document dans son ensemble.
49
+
*`content` : une chaîne de caractères. Fournit la valeur de la métadonnée lorsque la prop utilisée est `name`ou`itemProp`, ou le comportement de la directive lorsque la prop `httpEquiv`est utilisée.
50
50
51
-
#### Special rendering behavior {/*special-rendering-behavior*/}
51
+
#### Comportement spécifique de rendu {/*special-rendering-behavior*/}
52
52
53
-
React will always place the DOM element corresponding to the `<meta>`component within the document’s `<head>`, regardless of where in the React tree it is rendered. The`<head>`is the only valid place for `<meta>`to exist within the DOM, yet it’s convenient and keeps things composable if a component representing a specific page can render `<meta>`components itself.
53
+
React placera toujours l'élément DOM correspondant au composant `<meta>`dans le `<head>` du document, peu importe où il figure dans l'arborescence React. Le`<head>`est le seul endroit valide pour un `<link>`dans le DOM, mais il est plus confortable, et préférable en termes de composition, qu'un composant représentant une page donnée puisse produire les composants `<link>`lui-même.
54
54
55
-
There is one exception to this: if `<meta>`has an [`itemProp`](https://developer.mozilla.org/en-US/docs/Web/HTML/Global_attributes/itemprop) prop, there is no special behavior, because in this case it doesn’t represent metadata about the document but rather metadata about a specific part of the page.
55
+
Il y a toutefois une exception : si le `<meta>`a une prop [`itemProp`](https://developer.mozilla.org/docs/Web/HTML/Global_attributes/itemprop), aucun comportement spécifique n'est mis en place, parce que dans un tel cas la métadonnée ne s'applique pas au document mais à une partie spécifique de la page.
56
56
57
57
---
58
58
59
-
## Usage {/*usage*/}
59
+
## Utilisation {/*usage*/}
60
60
61
-
### Annotating the document with metadata {/*annotating-the-document-with-metadata*/}
61
+
### Annoter le document avec des métadonnées {/*annotating-the-document-with-metadata*/}
62
62
63
-
You can annotate the document with metadata such as keywords, a summary, or the author’s name. React will place this metadata within the document `<head>` regardless of where in the React tree it is rendered.
63
+
Vous pouvez annoter le document avec des métadonnées telles que des mots-clés, un résumé, ou encore l'identité de son auteur·e. React placera ces métadonnées dans le `<head>`, peu importe où `<meta>` figure dans l'arborescence React.
<metaname="description"content="API reference for the <meta> component in React DOM" />
68
+
<metaname="description"content="Référence API pour le composant <meta> de React DOM" />
69
69
```
70
70
71
-
You can render the `<meta>`component from any component. React will put a `<meta>` DOM node in the document `<head>`.
71
+
Vous pouvez utiliser le composant `<meta>`depuis n'importe quel emplacement. React injectera toujours le nœud DOM correspodant dans le `<head>` du document.
72
72
73
73
<SandpackWithHTMLOutput>
74
74
@@ -79,8 +79,8 @@ export default function SiteMapPage() {
79
79
return (
80
80
<ShowRenderedHTML>
81
81
<meta name="keywords" content="React"/>
82
-
<meta name="description" content="A site map for the React website"/>
83
-
<h1>Site Map</h1>
82
+
<meta name="description" content="Un plan du site web de React"/>
83
+
<h1>Plan du site</h1>
84
84
<p>...</p>
85
85
</ShowRenderedHTML>
86
86
);
@@ -89,14 +89,14 @@ export default function SiteMapPage() {
89
89
90
90
</SandpackWithHTMLOutput>
91
91
92
-
### Annotating specific items within the document with metadata {/*annotating-specific-items-within-the-document-with-metadata*/}
92
+
### Annoter des éléments spécifiques du document avec des métadonnées {/*annotating-specific-items-within-the-document-with-metadata*/}
93
93
94
-
You can use the `<meta>`component with the`itemProp`prop to annotate specific items within the document with metadata. In this case, React will *not* place these annotations within the document`<head>` but will place them like any other React component.
94
+
Vous pouvez utiliser le composant `<meta>`avec la prop`itemProp`pour annoter des éléments spécifiques avec des métadonnées. Dans de tels cas, React *ne placera pas* ces métadonnées dans le`<head>`, mais les traitera comme n'importe quel autre composant React.
95
95
96
96
```js
97
97
<section itemScope>
98
-
<h3>Annotating specific items</h3>
99
-
<meta itemProp="description" content="API reference for using <meta> with itemProp"/>
98
+
<h3>Annoter des éléments spécifiques</h3>
99
+
<meta itemProp="description" content="Référence API pour l’utilisation de <meta> avec itemProp"/>
0 commit comments