@pixelvibing/cli 0.13.0 → 0.15.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.
@@ -583,6 +583,12 @@ function createWebApi(fetcher = (input, init2) => fetch(input, init2), base = AP
583
583
  const search = query.toString();
584
584
  return json2(`/projects/${id(projectId)}/assets${search === "" ? "" : `?${search}`}`);
585
585
  },
586
+ /** A page of the project's generations nothing kept came from, newest first (specs/web-editor/ R2.8). */
587
+ undelivered: (projectId, kinds, before = null) => {
588
+ const query = new URLSearchParams({ kinds: kinds.join(",") });
589
+ if (before !== null) query.set("before", before);
590
+ return json2(`/projects/${id(projectId)}/undelivered?${query.toString()}`);
591
+ },
586
592
  /** One of a project's assets, by its id or its name. */
587
593
  asset: (projectId, ref) => json2(`/projects/${id(projectId)}/assets/${id(ref)}`),
588
594
  /** Keep a PNG for the account, answering its id. */
@@ -3683,18 +3689,21 @@ function jobDelay(elapsedMs) {
3683
3689
  return 1e4;
3684
3690
  }
3685
3691
  const jobEnded = (job) => job.state === "done" || job.state === "failed";
3686
- function jobWords(job) {
3692
+ function jobStage(job) {
3693
+ if (job.progress !== void 0) return job.progress.stage;
3687
3694
  switch (job.state) {
3688
3695
  case "queued":
3689
- return job.attempts > 0 ? "waiting to be tried again" : "waiting in line";
3696
+ return job.attempts > 0 ? "waiting" : "queued";
3690
3697
  case "running":
3691
- return "being drawn";
3692
- case "done":
3693
- return "done";
3694
- case "failed":
3695
- return job.reason === null ? "failed" : `failed: ${job.reason}`;
3698
+ return "generating";
3699
+ default:
3700
+ return job.state;
3696
3701
  }
3697
3702
  }
3703
+ function jobWords(job) {
3704
+ const stage = jobStage(job);
3705
+ return stage === "failed" && job.reason !== null ? `failed: ${job.reason}` : stage;
3706
+ }
3698
3707
  function costOf(prices, request) {
3699
3708
  return costIn(prices, request.kind);
3700
3709
  }
@@ -4576,7 +4585,7 @@ const move = {
4576
4585
  );
4577
4586
  }
4578
4587
  };
4579
- const version = "0.13.0";
4588
+ const version = "0.15.0";
4580
4589
  const manifest = {
4581
4590
  version
4582
4591
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pixelvibing/cli",
3
- "version": "0.13.0",
3
+ "version": "0.15.0",
4
4
  "description": "PixelVibing: pixel art game assets from the command line, and the Skills that teach coding assistants to make them.",
5
5
  "license": "MIT",
6
6
  "homepage": "https://pixelvibing.com",