Modular DIN-rail devices