Answer:
 6 units
Explanation:
In a 30°-60°-90° triangle, the shortest side is half the length of the longest side.
 XY = XZ/2 = 12/2
 XY = 6
__
Alternate solution
The side of interest is opposite the angle. The given side is the hypotenuse. So, the relevant trig relation is ...
 Sin = Opposite/Hypotenuse
 sin(30°) = XY/12
 XY = 12·sin(30°) = 12·(1/2)
 XY = 6