In today's fajr prayer I was praying in congregation.But in rakat 2 my udhu broke but I still prayed because I feet shy to break my paryer in fornt of people.And I know that my prayer was invaild. So did I commit shrik? Which kind of shrik minor or major?
Shirk means associating partner to Allah. The prophet said Every action is dependant on intention. From your question I could understand that due to shame and embarrassment you have continued to pray despite breaking wudu and this isn't shirk. Although the correct thing to do is to walk out,do wudu and join in again.
The prophet said فَاللَّهُ أَحَقُّ أَنْ يُسْتَحْيَا مِنْهُ "Allah is most deserving of being shy from Him." Tirimidhi Book 43, Hadith 2996
So in future don't continue prayer in that condition as it may mean that you value people more than Allah.. Remeber this hadith next time. After we are humans, we Err and it's perfectly normal to have wudu broken. you are human. It may happen to anyone. Don't feel bad and neither would PPL think bad about you. Make wudu and join back