If the thread was "what one exercise would you choose if you could only choose one", I would pick the squat, with deadlift coming second.
But that's not the question.
Range of motion does not necessarily determine the degree of force that is placed on a muscle/muscle group. Time under tension or power maybe, but not the ability to generate force, ie strength. There is more hip hinge in a conventional deadlift than a squat, but more importantly the load is more forward and well below the hip, meaning there is more torque on the hip than in a squat. It makes perfect sense.
In a deadlift the loading if shifted onto the hammies for the same reason, whereas in squat, the loading shifts more to the quads, due to the more upright position.
But in both instances, the glutes, as a group, are not pushed to nearly the same degree as many other exercises. I feel a 50kg hip thrust in the glutes much more than a 150kg squat. For individual glute muscles the effect is even greater. A 1RM squat will not work your glute medius nearly as much as a clamshell with moderate band tension.