Texture change depending on distance to object

Hello everyone!
I want to change texture if it is close to my spline (for example 3 units). How can I do this with shader graph?