@sushant-kum/ccstatus 0.4.1 → 0.4.2
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.
|
@@ -663,6 +663,23 @@ function Items({ config, setConfig, goHome }) {
|
|
|
663
663
|
// src/screens/menu.tsx
|
|
664
664
|
import { Box as Box6, Text as Text6, useInput as useInput4 } from "ink";
|
|
665
665
|
import { useState as useState4 } from "react";
|
|
666
|
+
|
|
667
|
+
// src/logo-art.ts
|
|
668
|
+
var LOGO_ART = [
|
|
669
|
+
[[null, "#14171c"], ["#14171c", "#14171c"], ["#14171c", "#14171c"], ["#14171c", "#14171c"], ["#14171c", "#14171c"], ["#14171c", "#14171c"], ["#14171c", "#14171c"], ["#14171c", "#14171c"], ["#14171c", "#14171c"], ["#14171c", "#14171c"], ["#14171c", "#14171c"], ["#14171c", "#14171c"], ["#14171c", "#14171c"], ["#14171c", "#14171c"], ["#14171c", "#14171c"], [null, "#14171c"]],
|
|
670
|
+
[["#14171c", "#14171c"], ["#14171c", "#14171c"], ["#14171c", "#14171c"], ["#14171c", "#14171c"], ["#14171c", "#14171c"], ["#14171c", "#14171c"], ["#14171c", "#1a191d"], ["#14171c", "#693a2c"], ["#14171c", "#322422"], ["#14171c", "#14171c"], ["#14171c", "#14171c"], ["#14171c", "#707275"], ["#14171c", "#5d5f63"], ["#14171c", "#14171c"], ["#14171c", "#14171c"], ["#14171c", "#14171c"]],
|
|
671
|
+
[["#14171c", "#14171c"], ["#14171c", "#14171c"], ["#14171c", "#14171c"], ["#14171c", "#14171c"], ["#14171c", "#1a191d"], ["#1a191d", "#924b33"], ["#924b33", "#c15f3c"], ["#c15f3c", "#a15236"], ["#76402e", "#211c1e"], ["#14171c", "#8d8e91"], ["#8d8e91", "#ffffff"], ["#ffffff", "#f0f0f0"], ["#d4d4d5", "#44464a"], ["#14171c", "#14171c"], ["#14171c", "#14171c"], ["#14171c", "#14171c"]],
|
|
672
|
+
[["#14171c", "#14171c"], ["#14171c", "#14171c"], ["#14171c", "#14171c"], ["#1a191d", "#874731"], ["#924b33", "#c15f3c"], ["#c15f3c", "#a15236"], ["#a15236", "#211c1e"], ["#211c1e", "#76787b"], ["#8d8f91", "#ffffff"], ["#ffffff", "#f0f0f0"], ["#f0f0f0", "#44464a"], ["#44464a", "#14171c"], ["#14171c", "#14171c"], ["#14171c", "#14171c"], ["#14171c", "#14171c"], ["#14171c", "#14171c"]],
|
|
673
|
+
[["#14171c", "#14171c"], ["#14171c", "#14171c"], ["#14171c", "#14171c"], ["#874731", "#1a191d"], ["#c15f3c", "#924b33"], ["#a15236", "#c15f3c"], ["#211c1e", "#a15236"], ["#76787b", "#211c1e"], ["#ffffff", "#8d8e91"], ["#f0f0f0", "#ffffff"], ["#44464a", "#f0f0f0"], ["#14171c", "#44464a"], ["#14171c", "#14171c"], ["#14171c", "#14171c"], ["#14171c", "#14171c"], ["#14171c", "#14171c"]],
|
|
674
|
+
[["#14171c", "#14171c"], ["#14171c", "#14171c"], ["#14171c", "#14171c"], ["#14171c", "#14171c"], ["#1a191d", "#14171c"], ["#924b33", "#1a191d"], ["#c15f3c", "#924b33"], ["#a15236", "#c15f3c"], ["#211c1e", "#76402e"], ["#8d8e91", "#14171c"], ["#ffffff", "#8d8e91"], ["#f0f0f0", "#ffffff"], ["#44464a", "#d4d4d5"], ["#14171c", "#14171c"], ["#14171c", "#14171c"], ["#14171c", "#14171c"]],
|
|
675
|
+
[["#14171c", "#14171c"], ["#14171c", "#14171c"], ["#14171c", "#14171c"], ["#14171c", "#14171c"], ["#14171c", "#14171c"], ["#14171c", "#14171c"], ["#1a191d", "#14171c"], ["#693a2c", "#14171c"], ["#332422", "#14171c"], ["#14171c", "#14171c"], ["#14171c", "#14171c"], ["#707275", "#14171c"], ["#5d5f63", "#14171c"], ["#14171c", "#14171c"], ["#14171c", "#14171c"], ["#14171c", "#14171c"]],
|
|
676
|
+
[["#14171c", null], ["#14171c", "#14171c"], ["#14171c", "#14171c"], ["#14171c", "#14171c"], ["#14171c", "#14171c"], ["#14171c", "#14171c"], ["#14171c", "#14171c"], ["#14171c", "#14171c"], ["#14171c", "#14171c"], ["#14171c", "#14171c"], ["#14171c", "#14171c"], ["#14171c", "#14171c"], ["#14171c", "#14171c"], ["#14171c", "#14171c"], ["#14171c", "#14171c"], ["#14171c", null]]
|
|
677
|
+
];
|
|
678
|
+
|
|
679
|
+
// src/version.ts
|
|
680
|
+
var VERSION = "0.4.2";
|
|
681
|
+
|
|
682
|
+
// src/screens/menu.tsx
|
|
666
683
|
import { jsx as jsx5, jsxs as jsxs5 } from "react/jsx-runtime";
|
|
667
684
|
var ITEMS = [
|
|
668
685
|
["items", "Edit items"],
|
|
@@ -676,9 +693,32 @@ var ITEMS = [
|
|
|
676
693
|
["save", "Save & quit"],
|
|
677
694
|
["quit", "Quit without saving"]
|
|
678
695
|
];
|
|
696
|
+
function isTrueColor() {
|
|
697
|
+
const ct = process.env.COLORTERM;
|
|
698
|
+
return ct === "truecolor" || ct === "24bit";
|
|
699
|
+
}
|
|
700
|
+
function Cell({ cell }) {
|
|
701
|
+
const [top, bottom] = cell;
|
|
702
|
+
if (top && bottom) {
|
|
703
|
+
return /* @__PURE__ */ jsx5(Text6, { color: top, backgroundColor: bottom, children: "\u2580" });
|
|
704
|
+
}
|
|
705
|
+
if (top) {
|
|
706
|
+
return /* @__PURE__ */ jsx5(Text6, { color: top, children: "\u2580" });
|
|
707
|
+
}
|
|
708
|
+
if (bottom) {
|
|
709
|
+
return /* @__PURE__ */ jsx5(Text6, { color: bottom, children: "\u2584" });
|
|
710
|
+
}
|
|
711
|
+
return /* @__PURE__ */ jsx5(Text6, { children: " " });
|
|
712
|
+
}
|
|
713
|
+
function Logo() {
|
|
714
|
+
if (!isTrueColor()) {
|
|
715
|
+
return /* @__PURE__ */ jsx5(Text6, { color: "#c15f3c", children: "\u25C0\u25C0" });
|
|
716
|
+
}
|
|
717
|
+
return /* @__PURE__ */ jsx5(Box6, { flexDirection: "column", children: LOGO_ART.map((row, r) => /* @__PURE__ */ jsx5(Box6, { children: row.map((cell, c) => /* @__PURE__ */ jsx5(Cell, { cell }, c)) }, r)) });
|
|
718
|
+
}
|
|
679
719
|
function Menu({ onSelect }) {
|
|
680
720
|
const [i, setI] = useState4(0);
|
|
681
|
-
useInput4((
|
|
721
|
+
useInput4((_input, key) => {
|
|
682
722
|
if (key.upArrow) {
|
|
683
723
|
setI((v) => Math.max(0, v - 1));
|
|
684
724
|
} else if (key.downArrow) {
|
|
@@ -691,7 +731,19 @@ function Menu({ onSelect }) {
|
|
|
691
731
|
}
|
|
692
732
|
});
|
|
693
733
|
return /* @__PURE__ */ jsxs5(Box6, { flexDirection: "column", children: [
|
|
694
|
-
/* @__PURE__ */
|
|
734
|
+
/* @__PURE__ */ jsxs5(Box6, { marginBottom: 1, children: [
|
|
735
|
+
/* @__PURE__ */ jsx5(Logo, {}),
|
|
736
|
+
/* @__PURE__ */ jsxs5(Box6, { flexDirection: "column", marginLeft: 2, children: [
|
|
737
|
+
/* @__PURE__ */ jsxs5(Text6, { children: [
|
|
738
|
+
/* @__PURE__ */ jsx5(Text6, { bold: true, children: "ccstatus" }),
|
|
739
|
+
/* @__PURE__ */ jsxs5(Text6, { dimColor: true, children: [
|
|
740
|
+
" v",
|
|
741
|
+
VERSION
|
|
742
|
+
] })
|
|
743
|
+
] }),
|
|
744
|
+
/* @__PURE__ */ jsx5(Text6, { dimColor: true, children: "configurator" })
|
|
745
|
+
] })
|
|
746
|
+
] }),
|
|
695
747
|
ITEMS.map(([id, label], idx) => /* @__PURE__ */ jsxs5(Text6, { color: idx === i ? "cyan" : void 0, children: [
|
|
696
748
|
idx === i ? "\u25B8 " : " ",
|
|
697
749
|
label
|
package/dist/index.js
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@sushant-kum/ccstatus",
|
|
3
|
-
"version": "0.4.
|
|
3
|
+
"version": "0.4.2",
|
|
4
4
|
"description": "Interactive configurator (npx @sushant-kum/ccstatus) for the ccstatus Claude Code status bar — band, status line, pane, and threshold toasts from one config.",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"author": "Sushant Kumar",
|