The Pharisees were absolutely committed to the law. In 1 Maccabees 2:35-8, we see just how far they would actually go. Under Judas Maccabaeus, they refused to fight on the Sabbath against Antiochus when he sent a detail of men to slaughter them in the caves in the wilderness.
“Let us all die in our innocence; heaven and earth testify for us that you are killing us unjustly.” 38 So they attacked them on the sabbath, and they died, with their wives and children and livestock, to the number of a thousand persons.
Fast forward to Matthew 12:9-14, which ends with the Pharisees (the religious elite) planning to kill Jesus for healing a man on the Sabbath. Jesus was indeed in violation of the law.
he went into their synagogue, 10 and a man with a shriveled hand was there. Looking for a reason to bring charges against Jesus, they asked him, “Is it lawful to heal on the Sabbath?”
11 He said to them, “If any of you has a sheep and it falls into a pit on the Sabbath, will you not take hold of it and lift it out? 12 How much more valuable is a person than a sheep! Therefore it is lawful to do good on the Sabbath.”
13 Then he said to the man, “Stretch out your hand.” So he stretched it out and it was completely restored, just as sound as the other. 14 But the Pharisees went out and plotted how they might kill Jesus.
It was permitted that a man could receive medical treatment to keep him from getting worse on the Sabbath, but he could not be made better. You could apply a bandage, but no ointment or salve. The penalty for breaking the Sabbath was death (Numbers 15:32-36).
Let us be clear, Jesus did not need to heal that man on the Sabbath. His hand was paralyzed and likely had been so for many years. He would be just as sick tomorrow. Jesus could have easily kept the law and healed the man. But in the eyes of Jesus, any law that kept someone from being made whole, any law that kept someone in suffering or extended their pain even for one day was to be ignored. Healing, love, and care always came first.
The dichotomy is clear:
Pharisees would rather see death than see the law broken.
Jesus would rather die under the weight of the law than allow another to suffer needlessly.