BAP-6592: How to replace inline-javascript with component

 - fixed formatting issues