diff options
Diffstat (limited to 'files/fr/web/css/image-orientation/index.html')
| -rw-r--r-- | files/fr/web/css/image-orientation/index.html | 12 |
1 files changed, 3 insertions, 9 deletions
diff --git a/files/fr/web/css/image-orientation/index.html b/files/fr/web/css/image-orientation/index.html index ae0c2f2f3d..1e5b7e4b90 100644 --- a/files/fr/web/css/image-orientation/index.html +++ b/files/fr/web/css/image-orientation/index.html @@ -13,7 +13,7 @@ translation_of: Web/CSS/image-orientation <p>La propriété <strong><code>image-orientation</code></strong> décrit la façon d'obtenir l'orientation correcte d'une image quelle que soit la disposition du document. Cette propriété ne doit pas être utilisée afin de tourner l'image pour d'autres cas, si besoin, on pourra utiliser la propriété {{cssxref("transform")}} avec la fonction <code>rotate</code>.</p> <div class="warning"> -<p><strong>Attention !</strong> Cette propriété sera vraisemblablement dépréciée prochainement. Les fonctionnalités associées deviendront des propriétés de l'élément {{HTMLElement("img")}} et/ou de l'élément {{HTMLElement("picture")}} (excepté peut-être <code>from-image</code>).</p> +<p><strong>Attention :</strong> Cette propriété sera vraisemblablement dépréciée prochainement. Les fonctionnalités associées deviendront des propriétés de l'élément {{HTMLElement("img")}} et/ou de l'élément {{HTMLElement("picture")}} (excepté peut-être <code>from-image</code>).</p> </div> <pre class="brush:css no-line-numbers">/* Valeurs d'angle */ @@ -72,10 +72,7 @@ image-orientation: unset; } </pre> -<div class="hidden"> -<h3 id="HTML">HTML</h3> - -<pre class="brush: html"><img id="image" src="https://mdn.mozillademos.org/files/12668/MDN.svg" +<pre class="brush: html hidden"><img id="image" src="https://mdn.mozillademos.org/files/12668/MDN.svg" alt="Orientation déterminée à partir de l'image"/> <select id="imageOrientation"> <option value="from-image">from-image</option> @@ -84,14 +81,11 @@ image-orientation: unset; </select> </pre> -<h3 id="JavaScript">JavaScript</h3> - -<pre class="brush: js">var imageOrientation = document.getElementById("imageOrientation"); +<pre class="brush: js hidden">var imageOrientation = document.getElementById("imageOrientation"); imageOrientation.addEventListener("change", function (evt) { document.getElementById("image").style.imageOrientation = evt.target.value; }); </pre> -</div> <h3 id="Résultat">Résultat</h3> |
