en property

String get en

Returns a string representing the time interval in English.

Implementation

String get en {
  switch (type) {
    case TimeAgoType.justNow:
      return 'just now';
    case TimeAgoType.seconds:
      return '${value.toString().padLeft(2, "0")} seconds ago';
    case TimeAgoType.minutes:
      return '${value.toString().padLeft(2, "0")} minutes ago';
    case TimeAgoType.hours:
      return '${value.toString().padLeft(2, "0")} hours ago';
    case TimeAgoType.days:
      return '${value.toString().padLeft(2, "0")} days ago';
    case TimeAgoType.weeks:
      return '${value.toString().padLeft(2, "0")} weeks ago';
  }
}