Hello Navtejkalsi,
Thank you for using Apple Support Communities. Based on your post, your iPhone 12 mini Camera app stops responding when using Portrait Mode. We'll do our best to assist.
We'd check for any possible saved settings and return them to default settings to test: Save camera settings on iPhone
Test the normal Photo setting on the front and rear cameras. Does the back camera work as expected?
If you find this may be hardware related, consider bringing it by for an inspection.
This can help to prepare you for the visit: Get your iPhone, iPad, or iPod touch ready for service
Use this link to select your region and search nearby: Find Locations
Due to the current conditions around the world, some stores may have limited hours or appointment times. They also may require specific things to visit them (Such as, scheduling an appointment, wearing a mask, calling to check-in, etc.).
Hoping this helps out, take care.