ngx-axis-appforge 1.0.20 → 1.0.21

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1796,6 +1796,9 @@ class HowLongPipe {
1796
1796
  transform(date) {
1797
1797
  if (!this.date) {
1798
1798
  if (date) {
1799
+ if (typeof date == "number") {
1800
+ date = new Date(date);
1801
+ }
1799
1802
  this.date = date;
1800
1803
  let offset = (new Date().getTime() - date.getTime()) / 1000;
1801
1804
  let sufix = offset > 0 ? "前" : "后";