Currently YAxisLabels calculates its margin top and margin bottom with textAnchor attribute. That doesn't make sense since textAnchor determines <text> alignment on the horizontal plane.
YAxisLabels should be taking into account alignmentBaseline to determine any vertical overhang.
Issue in screenshot below

The margin bottom should be adjusted to account for alignmentBaseline: hanging.