It is important to remember the risks of overheating when working in hot conditions.
There's no law for maximum working temperature, or when it's too hot to work. However, n offices or similar environments, the temperature in workplaces must be reasonable.
When assessing this we look at something called thermal comfort. There are six factors affecting thermal comfort and are both environmental and personal. These factors may be independent of each other, but together contribute to an employee's thermal comfort.
HSE has plenty of guidance on workplace temperature, including: