@staff0rd/assist 0.180.1 → 0.181.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.
Files changed (2) hide show
  1. package/dist/index.js +5 -4
  2. package/package.json +1 -1
package/dist/index.js CHANGED
@@ -6,7 +6,7 @@ import { Command } from "commander";
6
6
  // package.json
7
7
  var package_default = {
8
8
  name: "@staff0rd/assist",
9
- version: "0.180.1",
9
+ version: "0.181.0",
10
10
  type: "module",
11
11
  main: "dist/index.js",
12
12
  bin: {
@@ -3643,7 +3643,7 @@ async function notify() {
3643
3643
  // src/commands/activity/activityChart.ts
3644
3644
  import blessed from "blessed";
3645
3645
  import contrib from "blessed-contrib";
3646
- function activityChart(data) {
3646
+ function activityChart(data, range) {
3647
3647
  const screen = blessed.screen({
3648
3648
  smartCSR: true,
3649
3649
  title: "Commit Activity"
@@ -3652,7 +3652,7 @@ function activityChart(data) {
3652
3652
  const labels = data.map((d) => d.date.slice(5));
3653
3653
  const values = data.map((d) => d.count);
3654
3654
  const line = grid.set(0, 0, 1, 1, contrib.line, {
3655
- label: " Commits per week (press q to close) ",
3655
+ label: ` Commits per week \xB7 ${range.since} \u2192 ${range.until} (press q to close) `,
3656
3656
  showLegend: true,
3657
3657
  legend: { width: 12 },
3658
3658
  xLabelPadding: 3,
@@ -3727,7 +3727,8 @@ async function activity(options2) {
3727
3727
  weekly.set(weekStart, (weekly.get(weekStart) ?? 0) + count);
3728
3728
  }
3729
3729
  const weeklyData = [...weekly.entries()].map(([date, count]) => ({ date, count })).sort((a, b) => a.date.localeCompare(b.date));
3730
- activityChart(weeklyData);
3730
+ const until = data[data.length - 1].date;
3731
+ activityChart(weeklyData, { since, until });
3731
3732
  }
3732
3733
 
3733
3734
  // src/commands/registerActivity.ts
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@staff0rd/assist",
3
- "version": "0.180.1",
3
+ "version": "0.181.0",
4
4
  "type": "module",
5
5
  "main": "dist/index.js",
6
6
  "bin": {