I believe this minimal implementation actually over-compensates for pan law because it has a -6dB center. In other words, if you ask this tool for zero panning, it will actually divide the amplitude by 2 (probably not what most people would expect!) In DAWs, -3dB or 0dB center is more common. In a tool like this I would suggest a 0dB center by default, so that zero panning does not change the amplitude. This would be what you second link calls triangular pan law.