Notice that AD also creates two supplementary angles, BDA and ADE. Let y be the measure of the smaller angle, ADE; then the measure of the larger angle, BDA, is 180° - y.
Since AD bisects angle A, we have by the law of sines
sin(A/2)/x = sin(y)/8
and
sin(A/2)/6 = sin(180° - y)/12
Now,
sin(180° - y) = sin(180°) cos(y) - cos(180°) sin(y) = sin(y)
so that
sin(A/2) = x/8 sin(y)
and
sin(A/2) = 6/12 sin(y) = 1/2 sin(y)
Solve for x :
x/8 sin(y) = 1/2 sin(y)
x/8 = 1/2
x = 8/2
x = 4