Responsive Design

Walt Haas's picture

Updated: 

21/05/2018 - 12:16

SASS

It is well worth the time to learn to use SASS for CSS. The notation is more readable than plain CSS and allows you to avoid repetition. Conversion of existing CSS files is easy - just rename filename.css to filename.scss, then convert the file contents to the SASS notation in convenient increments, testing each step of the conversion.

Image Size

Images uploaded to Drupal are stored and retrieved with width and height attributes. These attributes prevent the browser from resizing the image to adapt to the size of the device viewport. You can override the stored attributes with the following CSS:

img { height: auto !important; width: auto !important; }