Most cordless devices have a Lithium-Ion battery in them. For Li-Ion storage you want to keep batteries around 50% charge in a cool environment. This maximizes shelf life. For example a Li-Ion battery stored at room temperature with a full charge loses about 20% capacity per year. At 40% charge (ideal) stored in a cool environment it loses about 5% capacity per year.
If you can remove a Li-Ion battery it's better for storage. Charge to 40% (3.85V measured after resting) and put in a refrigerator. This will put capacity loss under 5% per year. Don't put them in a freezer, that will damage them.
Lead-acid and NiMH batteries have a different ideal storage condition. For 12V lead-acid you want to store them at 100% charge and trickle charge overnight at 13.80V every six months. Store at room temperature. For NiMH you want to charge to full then store at room temperature until needed.