1

I have TYPO3 10 and want to render the images in specific dimensions. I have a content element with only images, and these pictures are rendered with the dimension 495px x 331px. How can I change that? I've uploaded a much bigger original picture. The preview images are always in these dimensions. If I click on the image to enlarge it, it shows a much bigger picture.

The content element is a pictures only element with two columns. When I set one column, the preview pictures are bigger. How is TYPO3 calculating the dimensions of the pictures?

WhoKnows
  • 9
  • 4
  • 1
    Your question is a bit unclear: Is the uploaded image only of these dimensions and you expect it to be scaled up (or down?)? Which settings have you made in the content element? – Jonas Eberle Mar 21 '21 at 09:07
  • Just edited the question. Should be clearer now. – WhoKnows Mar 21 '21 at 21:19

1 Answers1

0

I assume you want to know how to style the default content type "image".

This content type usually renders a gallery view (grid) of images.

First of all you have these options by default:

editor interface for content type "image"

Selecting "Number of columns: 1" would make the image use a bigger space.

If you want to directly influence the HTML output, here are some pointers:

The default rendering engine of TYPO3 is fluid_styled_content.

Here is a guide how to override templates for a specific content type: https://docs.typo3.org/c/typo3/cms-fluid-styled-content/10.4/en-us/Configuration/OverridingFluidTemplates/Index.html

That specific content type uses a GalleryProcessor:

https://github.com/TYPO3/TYPO3.CMS/blob/10.4/typo3/sysext/fluid_styled_content/Configuration/TypoScript/ContentElement/Image.typoscript

It renders this template:

https://github.com/TYPO3/TYPO3.CMS/blob/10.4/typo3/sysext/fluid_styled_content/Resources/Private/Templates/Image.html

... which uses some partials to render the media.

Media/Gallery sets up the layout for the image grid:

https://github.com/TYPO3/TYPO3.CMS/blob/10.4/typo3/sysext/fluid_styled_content/Resources/Private/Partials/Media/Gallery.html

Media/Rendering/Image finally renders the image. The value of dimension has been calculated by the GalleryProcessor:

https://github.com/TYPO3/TYPO3.CMS/blob/10.4/typo3/sysext/fluid_styled_content/Resources/Private/Partials/Media/Rendering/Image.html

Jonas Eberle
  • 2,835
  • 1
  • 15
  • 25
  • It was due to the extension "Bootstrap package". Thanks. – WhoKnows May 28 '21 at 21:18
  • 1
    I think that is kind of a problem with EXT:bootstrap_package. It changes so much that it is hard for newcomers to guess where which things really happen and how to influence them. – Jonas Eberle May 29 '21 at 09:12