25.06.2018 Views

Full-Stack Vue.js 2 and Laravel 5

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

After you add that code, your listing summaries will look like this:<br />

Figure 7.11. Complete listing summaries being displayed We gave each listing summary a fixed<br />

width/height so that we could display them in a neat grid. Currently, they're displaying in one tall column,<br />

so let's add some CSS flex rules to the HomePage component to get the summaries into rows.<br />

We'll add a class listing-summary-group to the element that wraps the summaries.<br />

We'll also add a class home-container to the root div to constrain the width of the<br />

page <strong>and</strong> center the content.<br />

resources/assets/components/HomePage.vue: <br />

... ... .home-container {<br />

margin: 0 auto; padding: 0 25px; } @media (min-width: 1131px) { .homecontainer<br />

{ width: 1080px; } } .listing-summary-group { padding-bottom: 20px;<br />

} .listing-summaries { display: flex; flex-direction: row; justify-content: spacebetween;<br />

overflow: hidden; } .listing-summaries > .listing-summary { marginright:<br />

15px; }<br />

.listing-summaries > .listing-summary:last-child {

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!