Hello!
Is there a way to modify the metadata that’s included in the cards view? For instance, it has the Core Title at the top, then a thumbnail with the Core Description next to it. I would like to switch out the Core Description, which I don’t use, with a different metadata field.
Here’s a link for reference: https://localhistory.moorestownlibrary.org/local-history-collection
You can see that in each item, it shows “no description provided” next to the thumbnail.
Thanks for any help you can give.
Joanne
Hi @joannep!
The Cards view is limited in it’s choice of metadata, it always display those three informations in that way. Go to your collection settings and define a new view mode.
You cannot select which metadata are displayed in the following view modes:
But you can choose which to show in:
You do that by setting the metadata option “Display on listing” to “Display by default”. In the case of Records and List, if no value is provided for that metadata nothing will appear.
So I believe what you are looking for will be achieved easily with Records.
Thanks @mateus.m.luna!
I’ll try switching the view mode. On that note, when I switch to Records mode, it shows this strange dot at the top corner of each item. What is it and how can I get rid of it?
Nice! Notice that only title is displaying now, you should go to each desired metadata editing form and tweak their option to display in listings.
That is a CSS conflict… your theme’s CSS is applying the following rule to style list elements:
Which is winning over our own rule:

To be honest I always apply those rules to the parent list element (<ul>
) instead of the children (<li>
), that is odd… but in any case I’ll add extra rules to the plugin in the next version to avoid this. Meanwhile, you could add the following extra css via the customizer menu:
.tainacan-records-container > li {
list-style: none;
}
Thanks! That did the trick.
One other issue I’m running into - in Cards view mode, everything on the collections page looks very consistent, with each “card” being the same size. In Records view, each “record” seems to be sized dynamically based on the dimensions of the thumbnail. How do I get it to look more uniform, the way the card view mode looks?
I tried changing the CSS in a couple of different ways, but I might be running into a conflict with the theme CSS again. Can you help?
“Records” view mode uses a Masonry Javascript script to adapt its columns dynamically to fit the height of the items content. While you could play a bit with CSS to fix the record item height I wouldn’t recommend that… because then you would have to deal with what to with the content when it overflows the size. This view mode is designed for situations where you don’t have certainty of the content that it will receive (images are not cropped and the metadata can be of multiple types and sizes). On the other hand, “Cards” is limited on what it shows in terms of size, quantity and content, thus offering a nice grid. It is a design choice and the type of tradeoff we end up having to deal with when the user is the one in power.
If you are very certain of which metadata you want to display and how you want to display, you can create your own view mode, but that will require some code:
Hi @mateus.m.luna !
Thanks…that looks like the best option. Just to clarify a few things -
In the documentation where it says to create a plugin to register the new view, does that just mean I’m creating a php file with the function to register the new view? And if so, can I just add that to my functions.php file? And where do these files live in my theme?
I think what I really want is the “Thumbnails” view mode. I have it on my admin view but it isn’t an option for the public page. Is there a way to make that a view option if I’m not using the tainacan theme?
Yes, while we demonstrate the path by creating a custom view mode via plugin, you can copy the same content and register it in a theme instead of a plugin. Just double check when you are using __FILE__
or __DIR__
to refer to the proper file location.
If you want to reproduce the same view mode as grid, you my wanna copy part of Tainacan Interface source code. Here are some files that may help you:
But notice that Grid is not one of the view modes where you can display other metadata besides title (it does not have dynamic_metadata
set to true
. Thus it is not that different from cards and Masonry.