In a math paper of MAA(Mathematical Association of America) by Z.Chen, he proved that- "If, inside $∆ ABC$, there is a circular region $ R$ for which the sum of the distances from a point $P$ in $R$ to the three sides of the triangle is independent of the position of $P$, then $∆ABC$ is equilateral."
Why did he mention "circular region $R$"?
Also, I think the theorem is also true for isoceles triangles.
(The Converse of Viviani's Theorem https://maa.org/sites/default/files/Chen-CMJ-2006.pdf)
When it is true, it is true for the whole triangle interior.
The math paper says "circular region $R$" so that the region has a non-empty interior. It would have been sufficient to say "in a zone with a non-empty interior".
Proof 1
Call $\alpha$ and $\beta$ two of the triangle interior angles on vertices.
If the sum of distances from a point $P$ to the sides is independent of $P$'s position inside a zone $Z$ with a non-empty interior, we can move $P$ in each direction orthogonal to the triangle sides without modifying the sum.
Then moving $P$ away from one side, adding distance $x$ to the distance to this side, subtracts distance $x \cos \alpha$ and $x \cos \beta$ to the distances to the other sides. Using that on three directions gives us: $\begin{cases} x - x \cos \alpha - x \cos \beta = 0 \\ x - x \cos \beta - x \cos (\pi - \alpha - \beta) = 0 \\ x - x \cos \alpha - x \cos (\pi - \alpha - \beta) = 0 \end{cases}$
Which is: $\begin{cases} 1 - \cos \alpha - \cos \beta = 0 \quad (1)\\ 1 - \cos \beta + \cos (\alpha + \beta) = 0 \quad (2)\\ 1 - \cos \alpha + \cos (\alpha + \beta) = 0 \quad (3) \end{cases}$
Subtracting $(3)$ from $(2)$ gives $\cos \alpha = \cos \beta$.
Hence $2 \cos \alpha = 1$, $\alpha = \frac {\pi} 3 = \beta$, the triangle is equilateral.
And no, it does not work for isoceles triangles. Which is somewhat intuitive, as isoceles triangles are equilateral triangles elongated on one direction, which breaks the distance sum invariance.
Proof 2 (better in my opinion)
Let $u_1, u_2, u_3$ be the three unit vectors orthogonal to the triangle sides.
Let $v$ be the displacement vector we apply to point $P$.
Sum of distances is modified by $v.(u_1+u_2+u_3)$ (scalar product).
This is $=0$ for $v$ small in any direction, so it implies $u_1+u_2+u_3=0$.
As these three vectors have a null sum, they make a triangle.
As they have equal length ($=1$), this is an equilateral triangle.
So they have internal angles of $\frac {\pi} 3$ between them.
As they are orthogonal to the sides of the initial triangle, this triangle has also internal angles of $\frac {\pi} 3$. Hence it is an equilateral triangle.