@Raven Scar I understand your point, perhaps I didn't describe it clearly enough. There is a kind of pre-filtered selection of items that can only be dried. That way, only those items appear in the drying rack UI. I mean, something like that already exists in the game. If I have berries, or rather items in my inventory that can potentially be dried, only those can be selected, and all the others are grayed out. So I assume that a filter by item ID or something similar is already in place.
One idea could be to integrate a kind of box / storage box behavior into the drying rack itself, where you can see all the items that can be dried. You could then scroll through them and the number of slots of the box would automatically expand according to the number of available items, which would be a extra treatment for the storage box implementation.
On the other hand, you could perhaps make only the items in the drying rack selectable if there are any in your base, without showing the total number or all stacks. You would have, for example, three fields in the UI, one for blueberries, one for cranberries, and one for food (yes, there are different types), and to prevent the UI from exploding when there are too many items, you could perhaps only display (one) item as long as there are some in your base.
The workbench or the spinning wheel functions similarly, all resources in a radius can be used / selected from the crates, which would also be useful for the drying rack. Perhaps the most sensible approach would be to use icons (if in storage). However, representing food durability could be a problem, because of the single stacks, but that could be solved by always selecting the item that expires first.
While writing this, I read the new comment from @Alynxkia, which sums up a possible idea for displaying the items.