
Stack Refill is a utility mod which automatically refills the itemstack in the player's hand if there is any of the same item in the inventory. It works for weapons in combat, tools used on blocks, stacks when placing blocks, eating food, using potions, tossing items on the ground, drinking milk buckets, when breaking a fishing rod and should work with all modded blocks. Thrown items like tridents and splash potions are refilled too. One of my personal favourite quality of life tweaks.
Has to be installed on the server, as that's where the refilling happens. Players don't need it on their client. What gets refilled can be changed in the config, including a blacklist and whitelist for specific items. With /stackrefill every player can also turn it off for themselves.
All available config options:
refillBlocksAndItems default true
Whether the hand is refilled when the last item of a stack is placed, used, eaten or thrown. For example blocks, food, bone meal, eggs and potions.
refillToolsAndWeapons default true
Whether an item with durability is replaced by the same item from the inventory when it breaks or is thrown. For example tools, swords, fishing rods and tridents.
refillAfterDroppingLastItem default true
Whether the main hand is refilled when its last item is dropped with the drop key.
refillBuckets default true
Whether buckets are refilled. When disabled, a bucket that is emptied or filled stays in the hand instead of being swapped for another bucket from the inventory.
refillFromOtherHotbarSlots default false
Whether the other hotbar slots are searched as well. When disabled, only the main inventory is used to refill the hand.
itemBlacklist default ""
A comma separated list of item ids that are never refilled. Use * as a wildcard. An id without a namespace matches items of every mod. For example 'minecraft:totem_of_undying,*shulker_box'.
itemWhitelist default ""
When not empty, only the items in this comma separated list are refilled. Same format as itemBlacklist, for example 'minecraft:*_planks,cobblestone'.
/stackrefill toggle - Turns Stack Refill on or off for yourself.
/stackrefill enable - Turns Stack Refill on for yourself.
/stackrefill disable - Turns Stack Refill off for yourself.
/stackrefill help - Shows the usage of commands.
A sword being replaced during combat:

A shovel being replaced when digging dirt:

Log blocks being replaced while placing them down:

Bread being replaced after consumption:

Potions being replaced after consumption:

Items replaced after being tossed:

A milk bucket being replaced after being consumed:

A fresh fishing rod after its last use:

When using items on (modded) blocks, such as a sieve from Ex Nihilo:

You may freely use this mod in any modpack, as long as the download remains hosted within the CurseForge or Modrinth ecosystem.
Serilum.com contains an overview and more information on all mods available.
Comments are disabled as I'm unable to keep track of them across so many separate mod pages.
For issues, ideas, suggestions or anything else there is the Github repo. Thanks!
