Refs #16946 - Add utility method to convert relative to absolute urls

- Add utility method to truncate text by the number of characters
  without cutting words at the end;
- Add utility method to convert relative urls to absolute urls;
- Add unit tests for methods above.