The Sanction was not the last functional ship. They had other ships available.
ROMAS: Once our freighters are fixed, everything'll be back to normal.
PICARD: No.
T'JON: No?
PICARD: The coils stay here.
ROMAS: What about our freighters?
PICARD: You want to repair them, you'll have to learn to do it yourselves.
T'JON: We can't.
ROMAS: If you don't help us, our ships will soon be inoperable.
PICARD: Quite possibly.
The Prime Directive is for Starfleet, not for civilian ships. So, a Federation civilian has more latitude in how they make contact with a little known or not known at all civilization.
DATA: Mister Ramsey is correct, Counsellor. The Odin was not a starship, which means her crew is not bound by the Prime Directive. If he and the others wish to stay here, there is absolutely nothing we can do about it. ("Angel One")