Then assign an aspect-ratio property with a value of width / height. Set the height and width of the iframe to 100%. We can target iframe elements directly with a few lines of CSS to preserve their dimensions in responsive layouts, without the need for a wrapper element. Le contenu de frame et de la page web, sur laquelle on est situé, sont indépendants l’un de l’autre, mais ils peuvent interagir via JavaScript. The CSS aspect-ratio property tells browsers to preserve a specific aspect ratio on an element when scaling the size of it up or down. Master cross-browser compliant, responsive iframes using the aspect-ratio property in CSS. Le tag
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |