X until Y means to do X until Y happens, or that X is true until Y happens or occurs.
With past tenses, it means X was done, but stopped when Y happened.
I walked in the park until the sidewalk ran out.
I walked in the park until the sidewalk would have run out.
is strange - we have a actual past action (walked) limited by a modal-tagged action (would run out) - and that modal makes it unknown whether the second action actually happened or not.
Normally actual actions, when limited with until, can only be limited by things that actually happened. On a strict grammar level it's probably incorrect.
The only way this really works is if the writer/speaker is expecting you to be immersed enough that you can imagine you are the subject of the sentence. Things like this are possible in literary/artistic contexts. Artists/writers will bend the rules and know how/when to get away with it.
She had let her hands rest on his shoulders andleaned her hips against his until he would have done anything— anything — to keep her there.
What's communicated here efficiently with this "error" is that she wants him to keep her there and the would was employed to create excitement. There's a shift from an objective point of view to her point of view in "mid-stream." We know what she wants and we are efficiently kept in suspense whether it has actually happened or not yet.
Over-explaining kills excitement:
She had let her hands rest on his shoulders and leaned her hips against his; what she wanted was for him to do anything to keep her there and she was hoping he would catch her. (sounds like we're writing a romance manual)
As does simply stating what is actually happening:
She had let her hands rest on his shoulders and leaned her hips against his, but he did not yet do anything to keep her there. (sounds like he is rejecting her or playing hard to get)
Since walking in the park is not an exciting thing, the same error doesn't work in my first example.