8. Let $\alpha, \beta, \gamma \in \mathbf{R}$, and satisfy
$$
\sin \alpha \cdot \cos \beta+|\cos \alpha \cdot \sin \beta|=\sin \alpha \cdot|\cos \alpha|+|\sin \alpha| \cdot \cos \beta \text {. }
$$

Then the minimum value of $(\tan \gamma-\sin \alpha)^{2}-(\cot \gamma-\cos \beta)^{2}$ is . $\qquad$
8. $3-2 \sqrt{2}$.

Given the equation factorizes to
$$
(\sin \alpha-|\sin \beta|)(\cos \beta-|\cos \alpha|)=0 .
$$

Let $x=\sin \alpha, y=\cos \beta$, then
$$
\left(x-\sqrt{1-y^{2}}\right)\left(y-\sqrt{1-x^{2}}\right)=0 .
$$

Thus, $x=\sqrt{1-y^{2}}$ or $y=\sqrt{1-x^{2}}$.
The point $(\tan \gamma, \cot \gamma)$ lies on the hyperbola $x y=1$, so the required value is the square of the minimum distance between the two curves. As shown in Figure 3, clearly, $|A B|^{2}=\left(1-\frac{\sqrt{2}}{2}\right)^{2} \times 2=3-2 \sqrt{2}$ is the answer, where $A(1,1), B\left(\frac{\sqrt{2}}{2}, \frac{\sqrt{2}}{2}\right)$.