Scale mock type box according to text

I have one question, if the text does not fit inside the text box (mock type)when typing, how do I adjust it to fit? Like the tutorial below? - he doesn’t explain if the text doesn’t fit - any tutorials I can watch would be much appreciated