How to set up blueprints for specific file types and show file size

I made a blueprint pdf.yml with accept: mime: application/pdf but when I upload a pdf and I click on the file it says This page has no blueprint setup yet. So my first question is how to set up blueprints for anything else then images.

My main interest is to show the file size for a file download link. The panel shows the size so I guess I could just copy that into a field? Is this the right way to achieve that?

What is in your file blueprint apart from the accept property? Do you actually assign that blueprint to the file in the files section?

But apart from that, since size() is a property of a file, there’s no need to store it in a field?

Hmmm, “assign that blueprint” how is that done?
In my page blueprint:

  type: files

Yes, size() I can use that to make a list of downloads. But is there a way to have the file size displayed when using the file tag (file:)?

In a tag, no, not out of the box. But if you want to show it via a file tag, the user would have to enter the file size manually if you don’t modify the tag. I’d try to avoid that.

Is that a files section? You assign a template by adding the template option:

  type: files
  template: template-name

This filters the file by template and when you upload a file, the template is added to the meta data file.

Ok, so that can be multiple? I just need one for images (got that one) and one for all other kind of files.

Yes enter the file size manually that was I thought.

You can set up as many sections as you need, but one section can only assign one template.

Ic so I have to make another files blueprint for files with a size field to enter the file size.

In my page blueprint:

  type: files
  label: Images
  template: image
files: //another name?
  type: files
  label: Files
  template: file

Yes, each section needs a unique names, same as for fields.

Ok, thanks I will soldier on with this, so to speak.
Btw: thanks for replying so late! I’m calling it a day, wishing you a nice weekend!

For you too!