@threadbase-sh/streamer 1.52.6 → 1.53.0

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.
package/dist/cli.cjs CHANGED
@@ -151891,9 +151891,15 @@ function getSortValue(s3, key) {
151891
151891
  case "projectName":
151892
151892
  return s3.projectName;
151893
151893
  case "status":
151894
- return s3.status;
151894
+ return statusSortValue(s3);
151895
151895
  }
151896
151896
  }
151897
+ function statusSortValue(s3) {
151898
+ const rank = s3.status === "idle" ? 1 : 0;
151899
+ const activeAt = Date.parse(s3.lastActivityAt ?? s3.startedAt);
151900
+ const recency = String(1e15 - (Number.isNaN(activeAt) ? 0 : activeAt)).padStart(16, "0");
151901
+ return `${rank}:${recency}`;
151902
+ }
151897
151903
  function compareValues(a, b2) {
151898
151904
  if (a === void 0 && b2 === void 0) return 0;
151899
151905
  if (a === void 0) return 1;