Added environment config switching
Added loading of layer preview