You can physically cut off fuel without pulling the thrust lever to idle, because the two are separate controls.
However, it’s against procedure to do so - even dangerous. Throttle should always be at idle before pulling the cutoff switch, because otherwise excessive pressure can be created in the fuel system.
Essentially this is just a best practice, but there is no interlock between throttle and fuel cut off.
Then I got intrigued by your comment in case the throttle encoder fails. Turns out there is double redundancy on the throttle encoder (if one computer fails, the next one takes over), and if both fail the airplane will run on the last known setting at which point the only possible action that can be taken is to cut off the fuel (or keep it running with the last known throttle level).
In this regard both Boeing and Airbus follow the same implementation and there is no difference whatsoever between them.
Perhaps something they I have learned is that cutting off fuel during max throttle position (take off) may have damaged the fuel system of the Air India airplane because of big pressure in the lines and that may have interfered with the restart of the engines when the fuel valve was opened again.