You can view the issue here: https://codepen.io/purplecomet1/pen/WqOZRB
The polygons are defined on lines 9-12 and 21-25 respectively.
If you select 'Intersection' and run it, only a portion of it is highlighted instead of the whole shape.
If you edit certain coordinates slightly, however, it will produce the correct intersection. For example, adding '.0001' to either the x or y coordinate on line 10 will produce the correct intersection. The same is true for removing the last 3 decimal places of the y-coordinate on line 23.