Skip to content

Commit

Permalink
fix: review giulia
Browse files Browse the repository at this point in the history
  • Loading branch information
mamico committed Nov 8, 2023
1 parent 92bae0a commit bd79a3b
Show file tree
Hide file tree
Showing 6 changed files with 9 additions and 7 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ const CardWithSlideUpTextTemplate = (props) => {
</div>
<div className="grid mb-3 mt-5">
{items.map((item, index) => {
const image = getListingImageBackground(item, 'teaser');
const image = getListingImageBackground(item, 'large');
const category = getCategory(item, show_type, show_section, props);
const date = hide_dates
? null
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -53,8 +53,8 @@ const CompleteBlockLinksTemplate = ({
</Row>
)}
<Row className="items">
{items.map((item, index) => {
const image = ListingImage({ item, className: '' });
{items.map((item) => {
const image = ListingImage({ item, className: '', sizes: '60px' });

return (
<Col md="6" lg="3" key={item['@id']} className="col-item">
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,6 @@ const GridGalleryTemplate = ({
{items.map((item, index) => {
let image = ListingImage({
item,
useOriginal: false,
className: '',
});

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,10 @@ const InEvidenceTemplate = (props) => {
const listingText = show_description ? (
<ListingText item={item} />
) : null;
const image = ListingImage({ item });
const image = ListingImage({
item,
sizes: '(max-width:320px) 200px, 300px',
});
const category = getCategory(item, show_type, show_section, props);
const topics = show_topics ? item.tassonomia_argomenti : null;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -353,7 +353,7 @@ const SliderTemplate = ({
const image = ListingImage({
item,
loading: index === 0 ? 'eager' : 'lazy',
maxSize: 1600,
sizes: `max-width(980px) 600px, ${1200 / nSlidesToShow}px`,
critical: true,
});
return (
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ const SmallBlockLinksTemplate = ({
)}
<Row className="items">
{items.map((item, index) => {
const image = ListingImage({ item, maxSize: 200, style: {} });
const image = ListingImage({ item, sizes: '200px', style: {} });

return (
<Col
Expand Down

0 comments on commit bd79a3b

Please sign in to comment.