General idea is to allow solids (and stray, due to bugs/debug-adding, liquids) to be put back into containers. You already can 'U’nload them into your inventory, so cases to do reverse below:
[ul][li]Uncontained liquids: choose a watertight container to put liquid in.[/li]
[li]Contained liquids: choose a watertight container to put liquid in, doesn’t provide option of pouring liquid on the ground, unlike 'U’nload.[/li]
[li]Uncontained solids: choose a container to put solid in, could be watertight, could be not. Non-watertight options are currently kinda limited.[/li]
[li]Contained solids: choose a container to put solid in, as opposed to inventory (what 'U’nload does). Cancelling doesn’t put it in inventory.[/li]
[li]Ammunition: choose an item valid to be charged with selected ammo. [/li][/ul]
For example, thread, ‘p’, choose between sewing kit, wooden needle, and bone needle. Salt, choose between various cardboard boxes, paper wrappers and plastic bags (non-watertight container options are kinda limited…), etc.
Containers should be impossible to put into containers, to avoid funky logic and recursion.
EDIT: Pick-up logic and filled container view: filled with a solid containers never stack on the ground (‘e’ and ‘g’), even if contents are identical. Using amount-pickup (input a number, mark the item for picking up) plucks items straight out of container instead of picking up container itself. Normal marking, without amount, still should pick up entire container. Empty containers should stack.
For example, you have a sack of 50 apples on the ground and want to take five. You input 5 (number’s still not visible btw), press right-arrow, enter. You pick up 5 apples, you now have +5 apples in your inventory, while sack now has 45 apples.