\(B=\left(\dfrac{2\sqrt{x}+x}{x\sqrt{x}-1}-\dfrac{1}{\sqrt{x}-1}\right)\cdot\left(1-\dfrac{\sqrt{x}+2}{x+\sqrt{x}+1}\right)\)
\(=\left(\dfrac{2\sqrt{x}+x}{\left(\sqrt{x}-1\right)\cdot\left(x+\sqrt{x}+1\right)}-\dfrac{1}{\sqrt{x}-1}\right)\cdot\dfrac{x+\sqrt{x}+1-\left(\sqrt{x}+2\right)}{x+\sqrt{x}+1}\)
\(=\dfrac{2\sqrt{x}+x-\left(x+\sqrt{x}+1\right)}{\left(x+\sqrt{x}+1\right)\cdot\left(\sqrt{x}-1\right)}\cdot\dfrac{x+\sqrt{x}+1-\sqrt{x}-2}{x+\sqrt{x}+1}\)
\(=\dfrac{2\sqrt{x}+x-x-\sqrt{x}-1}{\left(x+\sqrt{x}+1\right)\cdot\left(\sqrt{x}-1\right)}\cdot\dfrac{x-1}{x+\sqrt{x}+1}\)
\(=\dfrac{\sqrt{x}-1}{\left(x+\sqrt{x}+1\right)\cdot\left(\sqrt{x}-1\right)}\cdot\dfrac{x-1}{x+\sqrt{x}+1}\)
\(=\dfrac{1}{x+\sqrt{x}+1}\cdot\dfrac{x-1}{x+\sqrt{x}+1}\)
\(=\dfrac{x-1}{\left(x+\sqrt{x}+1\right)^2}\)