src/components/form/PDFFunctions.js
/**
 * Checks to see if the string surpasses its textarea. If so minimize its font size
 * @param  {String} name        the string name
 * @param  {Number} min_length  the minimum width of the string
 * @param  {Number} max_length  the maximum width of the string
 *
 * @return {Number}             the font size
 */
Checks to see if the string surpasses its textarea. If so minimize its font size
@param  {String} name        the string name
@param  {Number} min_length  the minimum width of the string
@param  {Number} max_length  the maximum width of the string

@return {Number}             the font size
Checks to see if the string surpasses its textarea . If so minimize its font size @param { String } name the string name @param { Number } min_length the minimum width of the string @param { Number } max_length the maximum width of the string @return { Number } the font size
function lengthy_entry(entry, min_length, max_length)
{
    var inputLength = Math.round(measureInputText(entry));
    if(inputLength > min_length && inputLength < max_length)
    {
      var difference = inputLength / 20;
      var diff = Math.abs(font.font_size.DEFAULT_FONT_SIZE - difference);
      return Math.abs(font.font_size.DEFAULT_FONT_SIZE - diff)
    }
    else if(inputLength > max_length)
    {
      return font.font_size.MINIMUM_FONT_SIZE
    }
    else
      return font.font_size.DEFAULT_FONT_SIZE
}
function lengthy_entry ( entry , min_length , max_length ) { var inputLength = Math . round ( measureInputText ( entry ) ) ; if ( inputLength > min_length && inputLength < max_length ) { var difference = inputLength / 20 ; var diff = Math . abs ( font . font_size . DEFAULT_FONT_SIZE - difference ) ; return Math . abs ( font . font_size . DEFAULT_FONT_SIZE - diff ) } else if ( inputLength > max_length ) { return font . font_size . MINIMUM_FONT_SIZE } else return font . font_size . DEFAULT_FONT_SIZE }
Checks to see if the string surpasses its textarea.
Checks to see if the string surpasses its textarea .