In the last chapter, we learned how to add image styles for Drupal 8. Let's add a new image style named front_banner
that will scale our recipe images to be no wider than 680 pixels and cropped to 410 pixels in height. We will apply the same to the image field of our Front Banner view. This will create a more consistent look for our rotating banner as it will not change the size from slide to slide:
Open the d8dev site in your browser, click on the Configuration link in the Admin toolbar, and then click on Image styles under the Media link.
We are creating a new Image style. So, click on the +Add Image styles link at the top of the Image styles page.
Enter Front banner as the image style name and click on the Create new style button.
Select Crop as the effect and click on the Add button at the bottom of the page:
Next, Enter
680
as Width and410
as Height, and click on the Add effect button:Now we have to update...