From c98a9b1cf02d9143cc6924f1991d600c0f807411 Mon Sep 17 00:00:00 2001 From: MDN Date: Wed, 30 Jun 2021 00:38:38 +0000 Subject: [CRON] sync translated content --- files/fr/web/css/paint()/index.html | 109 ------------------------------------ 1 file changed, 109 deletions(-) delete mode 100644 files/fr/web/css/paint()/index.html (limited to 'files/fr/web/css/paint()') diff --git a/files/fr/web/css/paint()/index.html b/files/fr/web/css/paint()/index.html deleted file mode 100644 index a7340876f9..0000000000 --- a/files/fr/web/css/paint()/index.html +++ /dev/null @@ -1,109 +0,0 @@ ---- -title: paint() -slug: Web/CSS/paint() -tags: - - CSS - - Fonction - - Houdini - - Reference - - Web -translation_of: Web/CSS/paint() ---- -
{{CSSRef}}{{SeeCompatTable}}
- -

La fonction CSS paint() définit une {{cssxref("<image>")}} dont la valeur est générée par un PaintWorklet.

- -

Syntaxe

- -
paint(workletName, parameters)
- -

Paramètres

- -
-
workletName
-
Le nom du worklet enregistré.
-
parameters
-
Des paramètres supplémentaires optionnels, passés aux paintWorklet.
-
- -

Exemples

- -

Il est possible de passer des arguments supplémentaires grâce à la fonction CSS paint(). Dans cet exemple, on passe deux arguments : le premier indiquant si l'arrière-plan est rempli ou si on utilise juste son contour et le second indiquant la largeur de ce contour :

- - - - - -
li {
-   --boxColor: hsla(55, 90%, 60%, 1.0);
-   background-image: paint(hollowHighlights, stroke, 2px);
-}
-
-li:nth-of-type(3n) {
-   --boxColor: hsla(155, 90%, 60%, 1.0);
-   background-image: paint(hollowHighlights, filled,  3px);
-}
-
-li:nth-of-type(3n+1) {
-   --boxColor: hsla(255, 90%, 60%, 1.0);
-   background-image: paint(hollowHighlights, stroke, 1px);
-}
- -

On a ici ajouté une propriété personnalisée dans le sélecteur du bloc. Ces propriétés personnalisées peuvent être manipulées par le PaintWorklet.

- -

{{EmbedLiveSample("Examples", 300, 300)}}

- -

Spécifications

- - - - - - - - - - - - - - - - -
SpécificationÉtatCommentaires
{{SpecName('CSS Painting API', '#paint-notation', 'Paint Notation')}}{{Spec2('CSS Painting API')}}Définition initiale.
- -

Compatibilité des navigateurs

- -

{{Compat("css.types.image.paint")}}

- -

Voir aussi

- - -- cgit v1.2.3-54-g00ecf