I was recently working on a custom HubSpot quote theme and needed to format the phone number. By default, the number was displayed as a long string of numbers without any parenthesis or number groupings. The code below uses a HubL to display a subset of the full string in the chunks you need it to appear.
<a href="tel:{{ quote.hs_sender_phone }}"> +{{ quote.hs_sender_phone[:1] }}({{ quote.hs_sender_phone[1:4] }}) {{ quote.hs_sender_phone[4:7] }}-{{ quote.hs_sender_phone[7:11] }} </a>