working solution for tabs