$y = mx + b$ is a linear equation and represents a straight line. (The direction $m$ is constant.)
$y = x^2 + b$ is quadratic and represents a parabola. (The direction of the tangent is not constant.)
But $y = x^2 = x\cdot x$ in linear form with the first $x$ being the direction and y intercept being $0$ in this case.
So you could say that indeed the direction depends upon $x$.
However, for $x = 1$, $m = 2$ and not $1$ and indeed the derivative of $x^2$ is $2x$.
Why? Where does the $2$ come from?
Since both the terms in the product $\color{blue}{x}*x$ are changing with $x$, you must use the product rule:
$$\color{blue}{x}*x$$
For a small change in $x$'s : $$ (\color{blue}{x+\Delta x})*(x+\Delta x)$$
Take the difference
$$(\color{blue}{x+\Delta x})*(x+\Delta x) - \color{blue}{x}*x$$ Simplifying gives $$\color{blue}{x}*\Delta x + \color{blue}{\Delta x}*x + \color{blue}{\Delta x}\Delta x$$
Divide by $\Delta x$ $$\color{blue}{x} + x + \Delta x$$
Since $\Delta x$ goes to $0$ as the secant approaches the tangent... see where the $2x$ comes from?