@kya-os/cli 0.1.0-beta.13 → 0.1.0-beta.15
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/commands/init.d.ts.map +1 -1
- package/dist/commands/init.js +11 -96
- package/dist/commands/init.js.map +1 -1
- package/dist/components/agent-card.d.ts +14 -0
- package/dist/components/agent-card.d.ts.map +1 -0
- package/dist/components/agent-card.js +170 -0
- package/dist/components/agent-card.js.map +1 -0
- package/dist/components/box.d.ts +14 -0
- package/dist/components/box.d.ts.map +1 -0
- package/dist/components/box.js +222 -0
- package/dist/components/box.js.map +1 -0
- package/dist/components/index.d.ts +12 -0
- package/dist/components/index.d.ts.map +1 -0
- package/dist/components/index.js +13 -0
- package/dist/components/index.js.map +1 -0
- package/dist/components/messages.d.ts +62 -0
- package/dist/components/messages.d.ts.map +1 -0
- package/dist/components/messages.js +146 -0
- package/dist/components/messages.js.map +1 -0
- package/dist/components/types.d.ts +51 -0
- package/dist/components/types.d.ts.map +1 -0
- package/dist/components/types.js +5 -0
- package/dist/components/types.js.map +1 -0
- package/dist/effects/cli-integration.js +3 -3
- package/dist/effects/cli-integration.js.map +1 -1
- package/dist/effects/index.d.ts +9 -12
- package/dist/effects/index.d.ts.map +1 -1
- package/dist/effects/index.js +69 -34
- package/dist/effects/index.js.map +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.js +12 -19
- package/package.json +4 -5
- package/dist/commands/cli-experience-demo-simple.d.ts +0 -14
- package/dist/commands/cli-experience-demo-simple.d.ts.map +0 -1
- package/dist/commands/cli-experience-demo-simple.js +0 -119
- package/dist/commands/cli-experience-demo-simple.js.map +0 -1
- package/dist/commands/cli-experience-demo.d.ts +0 -14
- package/dist/commands/cli-experience-demo.d.ts.map +0 -1
- package/dist/commands/cli-experience-demo.js +0 -172
- package/dist/commands/cli-experience-demo.js.map +0 -1
- package/dist/commands/effects-demo.d.ts +0 -10
- package/dist/commands/effects-demo.d.ts.map +0 -1
- package/dist/commands/effects-demo.js +0 -292
- package/dist/commands/effects-demo.js.map +0 -1
- package/dist/dev.d.ts +0 -7
- package/dist/dev.d.ts.map +0 -1
- package/dist/dev.js +0 -9
- package/dist/dev.js.map +0 -1
- package/dist/effects/__tests__/effects.test.d.ts +0 -5
- package/dist/effects/__tests__/effects.test.d.ts.map +0 -1
- package/dist/effects/__tests__/effects.test.js +0 -206
- package/dist/effects/__tests__/effects.test.js.map +0 -1
- package/dist/effects/implementations/binary-path.d.ts +0 -88
- package/dist/effects/implementations/binary-path.d.ts.map +0 -1
- package/dist/effects/implementations/binary-path.js +0 -296
- package/dist/effects/implementations/binary-path.js.map +0 -1
- package/dist/effects/implementations/test.d.ts +0 -113
- package/dist/effects/implementations/test.d.ts.map +0 -1
- package/dist/effects/implementations/test.js +0 -552
- package/dist/effects/implementations/test.js.map +0 -1
- package/dist/effects/template/effect-template.d.ts +0 -97
- package/dist/effects/template/effect-template.d.ts.map +0 -1
- package/dist/effects/template/effect-template.js +0 -208
- package/dist/effects/template/effect-template.js.map +0 -1
- package/dist/index.d.ts.map +0 -1
- package/dist/index.js.map +0 -1
|
@@ -0,0 +1,222 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Box Drawing Component
|
|
3
|
+
* Creates beautiful boxes for CLI output without dependencies
|
|
4
|
+
*/
|
|
5
|
+
import chalk from "chalk";
|
|
6
|
+
// Predefined box styles
|
|
7
|
+
const BOX_STYLES = {
|
|
8
|
+
single: {
|
|
9
|
+
topLeft: "┌",
|
|
10
|
+
topRight: "┐",
|
|
11
|
+
bottomLeft: "└",
|
|
12
|
+
bottomRight: "┘",
|
|
13
|
+
horizontal: "─",
|
|
14
|
+
vertical: "│",
|
|
15
|
+
topJunction: "┬",
|
|
16
|
+
bottomJunction: "┴",
|
|
17
|
+
leftJunction: "├",
|
|
18
|
+
rightJunction: "┤",
|
|
19
|
+
cross: "┼",
|
|
20
|
+
},
|
|
21
|
+
double: {
|
|
22
|
+
topLeft: "╔",
|
|
23
|
+
topRight: "╗",
|
|
24
|
+
bottomLeft: "╚",
|
|
25
|
+
bottomRight: "╝",
|
|
26
|
+
horizontal: "═",
|
|
27
|
+
vertical: "║",
|
|
28
|
+
topJunction: "╦",
|
|
29
|
+
bottomJunction: "╩",
|
|
30
|
+
leftJunction: "╠",
|
|
31
|
+
rightJunction: "╣",
|
|
32
|
+
cross: "╬",
|
|
33
|
+
},
|
|
34
|
+
round: {
|
|
35
|
+
topLeft: "╭",
|
|
36
|
+
topRight: "╮",
|
|
37
|
+
bottomLeft: "╰",
|
|
38
|
+
bottomRight: "╯",
|
|
39
|
+
horizontal: "─",
|
|
40
|
+
vertical: "│",
|
|
41
|
+
topJunction: "┬",
|
|
42
|
+
bottomJunction: "┴",
|
|
43
|
+
leftJunction: "├",
|
|
44
|
+
rightJunction: "┤",
|
|
45
|
+
cross: "┼",
|
|
46
|
+
},
|
|
47
|
+
heavy: {
|
|
48
|
+
topLeft: "┏",
|
|
49
|
+
topRight: "┓",
|
|
50
|
+
bottomLeft: "┗",
|
|
51
|
+
bottomRight: "┛",
|
|
52
|
+
horizontal: "━",
|
|
53
|
+
vertical: "┃",
|
|
54
|
+
topJunction: "┳",
|
|
55
|
+
bottomJunction: "┻",
|
|
56
|
+
leftJunction: "┣",
|
|
57
|
+
rightJunction: "┫",
|
|
58
|
+
cross: "╋",
|
|
59
|
+
},
|
|
60
|
+
};
|
|
61
|
+
/**
|
|
62
|
+
* Wrap text to fit within a specific width
|
|
63
|
+
*/
|
|
64
|
+
function wrapText(text, width) {
|
|
65
|
+
const words = text.split(" ");
|
|
66
|
+
const lines = [];
|
|
67
|
+
let currentLine = "";
|
|
68
|
+
for (const word of words) {
|
|
69
|
+
if (currentLine.length + word.length + 1 <= width) {
|
|
70
|
+
currentLine += (currentLine ? " " : "") + word;
|
|
71
|
+
}
|
|
72
|
+
else {
|
|
73
|
+
if (currentLine)
|
|
74
|
+
lines.push(currentLine);
|
|
75
|
+
currentLine = word;
|
|
76
|
+
}
|
|
77
|
+
}
|
|
78
|
+
if (currentLine)
|
|
79
|
+
lines.push(currentLine);
|
|
80
|
+
return lines.length > 0 ? lines : [""];
|
|
81
|
+
}
|
|
82
|
+
/**
|
|
83
|
+
* Pad text to center it within a given width
|
|
84
|
+
*/
|
|
85
|
+
function stripAnsi(text) {
|
|
86
|
+
// Simple ANSI code removal - matches most common ANSI escape sequences
|
|
87
|
+
return text.replace(/\x1b\[[0-9;]*m/g, '');
|
|
88
|
+
}
|
|
89
|
+
/**
|
|
90
|
+
* Pad text to center it within a given width
|
|
91
|
+
*/
|
|
92
|
+
function centerText(text, width) {
|
|
93
|
+
const textLength = stripAnsi(text).length;
|
|
94
|
+
if (textLength >= width)
|
|
95
|
+
return text;
|
|
96
|
+
const totalPadding = width - textLength;
|
|
97
|
+
const leftPadding = Math.floor(totalPadding / 2);
|
|
98
|
+
const rightPadding = totalPadding - leftPadding;
|
|
99
|
+
return " ".repeat(leftPadding) + text + " ".repeat(rightPadding);
|
|
100
|
+
}
|
|
101
|
+
/**
|
|
102
|
+
* Pad text to align it within a given width
|
|
103
|
+
*/
|
|
104
|
+
function alignText(text, width, align = 'left') {
|
|
105
|
+
const textLength = stripAnsi(text).length;
|
|
106
|
+
if (textLength >= width)
|
|
107
|
+
return text.substring(0, width);
|
|
108
|
+
switch (align) {
|
|
109
|
+
case 'center':
|
|
110
|
+
return centerText(text, width);
|
|
111
|
+
case 'right':
|
|
112
|
+
return " ".repeat(width - textLength) + text;
|
|
113
|
+
default:
|
|
114
|
+
return text + " ".repeat(width - textLength);
|
|
115
|
+
}
|
|
116
|
+
}
|
|
117
|
+
/**
|
|
118
|
+
* Create a box around content
|
|
119
|
+
*/
|
|
120
|
+
export function createBox(content, options = {}) {
|
|
121
|
+
const { padding = 1, margin = 0, style = "single", width = 72, align = "left", title, titleAlign = "center", borderColor, } = options;
|
|
122
|
+
// Get box style
|
|
123
|
+
const boxStyle = typeof style === "string" ? BOX_STYLES[style] : style;
|
|
124
|
+
if (!boxStyle)
|
|
125
|
+
throw new Error(`Unknown box style: ${style}`);
|
|
126
|
+
// Prepare content lines
|
|
127
|
+
const lines = Array.isArray(content) ? content : content.split("\n");
|
|
128
|
+
const contentWidth = width - 2 - (padding * 2); // Account for borders and padding
|
|
129
|
+
// Wrap and align lines
|
|
130
|
+
const wrappedLines = [];
|
|
131
|
+
for (const line of lines) {
|
|
132
|
+
if (stripAnsi(line).length > contentWidth) {
|
|
133
|
+
wrappedLines.push(...wrapText(line, contentWidth));
|
|
134
|
+
}
|
|
135
|
+
else {
|
|
136
|
+
wrappedLines.push(line);
|
|
137
|
+
}
|
|
138
|
+
}
|
|
139
|
+
// Build the box
|
|
140
|
+
const result = [];
|
|
141
|
+
// Apply margin
|
|
142
|
+
for (let i = 0; i < margin; i++) {
|
|
143
|
+
result.push("");
|
|
144
|
+
}
|
|
145
|
+
// Top border with optional title
|
|
146
|
+
let topBorder = boxStyle.topLeft + boxStyle.horizontal.repeat(width - 2) + boxStyle.topRight;
|
|
147
|
+
if (title) {
|
|
148
|
+
const titleText = ` ${title} `;
|
|
149
|
+
const titleLength = stripAnsi(titleText).length;
|
|
150
|
+
const borderLength = width - 2;
|
|
151
|
+
if (titleLength < borderLength - 4) {
|
|
152
|
+
let titlePosition;
|
|
153
|
+
switch (titleAlign) {
|
|
154
|
+
case 'center':
|
|
155
|
+
titlePosition = Math.floor((borderLength - titleLength) / 2);
|
|
156
|
+
break;
|
|
157
|
+
case 'right':
|
|
158
|
+
titlePosition = borderLength - titleLength - 2;
|
|
159
|
+
break;
|
|
160
|
+
default:
|
|
161
|
+
titlePosition = 2;
|
|
162
|
+
}
|
|
163
|
+
topBorder =
|
|
164
|
+
boxStyle.topLeft +
|
|
165
|
+
boxStyle.horizontal.repeat(titlePosition) +
|
|
166
|
+
titleText +
|
|
167
|
+
boxStyle.horizontal.repeat(borderLength - titlePosition - titleLength) +
|
|
168
|
+
boxStyle.topRight;
|
|
169
|
+
}
|
|
170
|
+
}
|
|
171
|
+
if (borderColor) {
|
|
172
|
+
result.push(chalk.hex(borderColor)(topBorder));
|
|
173
|
+
}
|
|
174
|
+
else {
|
|
175
|
+
result.push(topBorder);
|
|
176
|
+
}
|
|
177
|
+
// Add top padding
|
|
178
|
+
for (let i = 0; i < padding; i++) {
|
|
179
|
+
const paddingLine = boxStyle.vertical + " ".repeat(width - 2) + boxStyle.vertical;
|
|
180
|
+
result.push(borderColor ? chalk.hex(borderColor)(paddingLine) : paddingLine);
|
|
181
|
+
}
|
|
182
|
+
// Add content lines
|
|
183
|
+
for (const line of wrappedLines) {
|
|
184
|
+
const alignedContent = alignText(line, contentWidth, align);
|
|
185
|
+
const paddedContent = " ".repeat(padding) + alignedContent + " ".repeat(padding);
|
|
186
|
+
const contentLine = boxStyle.vertical + paddedContent + boxStyle.vertical;
|
|
187
|
+
if (borderColor) {
|
|
188
|
+
// Color only the borders, not the content
|
|
189
|
+
result.push(chalk.hex(borderColor)(boxStyle.vertical) +
|
|
190
|
+
paddedContent +
|
|
191
|
+
chalk.hex(borderColor)(boxStyle.vertical));
|
|
192
|
+
}
|
|
193
|
+
else {
|
|
194
|
+
result.push(contentLine);
|
|
195
|
+
}
|
|
196
|
+
}
|
|
197
|
+
// Add bottom padding
|
|
198
|
+
for (let i = 0; i < padding; i++) {
|
|
199
|
+
const paddingLine = boxStyle.vertical + " ".repeat(width - 2) + boxStyle.vertical;
|
|
200
|
+
result.push(borderColor ? chalk.hex(borderColor)(paddingLine) : paddingLine);
|
|
201
|
+
}
|
|
202
|
+
// Bottom border
|
|
203
|
+
const bottomBorder = boxStyle.bottomLeft + boxStyle.horizontal.repeat(width - 2) + boxStyle.bottomRight;
|
|
204
|
+
result.push(borderColor ? chalk.hex(borderColor)(bottomBorder) : bottomBorder);
|
|
205
|
+
// Apply margin
|
|
206
|
+
for (let i = 0; i < margin; i++) {
|
|
207
|
+
result.push("");
|
|
208
|
+
}
|
|
209
|
+
return result.join("\n");
|
|
210
|
+
}
|
|
211
|
+
/**
|
|
212
|
+
* Create a divider line
|
|
213
|
+
*/
|
|
214
|
+
export function createDivider(width = 72, style = 'single') {
|
|
215
|
+
const chars = {
|
|
216
|
+
single: "─",
|
|
217
|
+
double: "═",
|
|
218
|
+
heavy: "━",
|
|
219
|
+
};
|
|
220
|
+
return chars[style].repeat(width);
|
|
221
|
+
}
|
|
222
|
+
//# sourceMappingURL=box.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"box.js","sourceRoot":"","sources":["../../src/components/box.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,KAAK,MAAM,OAAO,CAAC;AAG1B,wBAAwB;AACxB,MAAM,UAAU,GAA6B;IAC3C,MAAM,EAAE;QACN,OAAO,EAAE,GAAG;QACZ,QAAQ,EAAE,GAAG;QACb,UAAU,EAAE,GAAG;QACf,WAAW,EAAE,GAAG;QAChB,UAAU,EAAE,GAAG;QACf,QAAQ,EAAE,GAAG;QACb,WAAW,EAAE,GAAG;QAChB,cAAc,EAAE,GAAG;QACnB,YAAY,EAAE,GAAG;QACjB,aAAa,EAAE,GAAG;QAClB,KAAK,EAAE,GAAG;KACX;IACD,MAAM,EAAE;QACN,OAAO,EAAE,GAAG;QACZ,QAAQ,EAAE,GAAG;QACb,UAAU,EAAE,GAAG;QACf,WAAW,EAAE,GAAG;QAChB,UAAU,EAAE,GAAG;QACf,QAAQ,EAAE,GAAG;QACb,WAAW,EAAE,GAAG;QAChB,cAAc,EAAE,GAAG;QACnB,YAAY,EAAE,GAAG;QACjB,aAAa,EAAE,GAAG;QAClB,KAAK,EAAE,GAAG;KACX;IACD,KAAK,EAAE;QACL,OAAO,EAAE,GAAG;QACZ,QAAQ,EAAE,GAAG;QACb,UAAU,EAAE,GAAG;QACf,WAAW,EAAE,GAAG;QAChB,UAAU,EAAE,GAAG;QACf,QAAQ,EAAE,GAAG;QACb,WAAW,EAAE,GAAG;QAChB,cAAc,EAAE,GAAG;QACnB,YAAY,EAAE,GAAG;QACjB,aAA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CAAC,WAAW,CAAC,CAAC,CAAC,CAAC,WAAW,CAAC,CAAC;IAC/E,CAAC;IAED,gBAAgB;IAChB,MAAM,YAAY,GAAG,QAAQ,CAAC,UAAU,GAAG,QAAQ,CAAC,UAAW,CAAC,MAAM,CAAC,KAAK,GAAG,CAAC,CAAC,GAAG,QAAQ,CAAC,WAAW,CAAC;IACzG,MAAM,CAAC,IAAI,CAAC,WAAW,CAAC,CAAC,CAAC,KAAK,CAAC,GAAG,CAAC,WAAW,CAAC,CAAC,YAAY,CAAC,CAAC,CAAC,CAAC,YAAY,CAAC,CAAC;IAE/E,eAAe;IACf,KAAK,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC,GAAG,MAAM,EAAE,CAAC,EAAE,EAAE,CAAC;QAChC,MAAM,CAAC,IAAI,CAAC,EAAE,CAAC,CAAC;IAClB,CAAC;IAED,OAAO,MAAM,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;AAC3B,CAAC;AAED;;GAEG;AACH,MAAM,UAAU,aAAa,CAAC,QAAgB,EAAE,EAAE,QAAuC,QAAQ;IAC/F,MAAM,KAAK,GAAG;QACZ,MAAM,EAAE,GAAG;QACX,MAAM,EAAE,GAAG;QACX,KAAK,EAAE,GAAG;KACX,CAAC;IAEF,OAAO,KAAK,CAAC,KAAK,CAAC,CAAC,MAAM,CAAC,KAAK,CAAC,CAAC;AACpC,CAAC"}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* CLI Components
|
|
3
|
+
* Reusable UI components for beautiful CLI output
|
|
4
|
+
*/
|
|
5
|
+
export * from "./types.js";
|
|
6
|
+
export * from "./box.js";
|
|
7
|
+
export * from "./agent-card.js";
|
|
8
|
+
export * from "./messages.js";
|
|
9
|
+
export { createBox, createDivider, } from "./box.js";
|
|
10
|
+
export { createAgentCard, createCompactAgentCard, } from "./agent-card.js";
|
|
11
|
+
export { createSuccessMessage, createErrorMessage, createWarningMessage, createInfoMessage, createStepIndicator, createProgressBar, createBulletList, createNumberedList, createKeyValueDisplay, createSpinner, } from "./messages.js";
|
|
12
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/components/index.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,cAAc,YAAY,CAAC;AAC3B,cAAc,UAAU,CAAC;AACzB,cAAc,iBAAiB,CAAC;AAChC,cAAc,eAAe,CAAC;AAG9B,OAAO,EACL,SAAS,EACT,aAAa,GACd,MAAM,UAAU,CAAC;AAElB,OAAO,EACL,eAAe,EACf,sBAAsB,GACvB,MAAM,iBAAiB,CAAC;AAEzB,OAAO,EACL,oBAAoB,EACpB,kBAAkB,EAClB,oBAAoB,EACpB,iBAAiB,EACjB,mBAAmB,EACnB,iBAAiB,EACjB,gBAAgB,EAChB,kBAAkB,EAClB,qBAAqB,EACrB,aAAa,GACd,MAAM,eAAe,CAAC"}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* CLI Components
|
|
3
|
+
* Reusable UI components for beautiful CLI output
|
|
4
|
+
*/
|
|
5
|
+
export * from "./types.js";
|
|
6
|
+
export * from "./box.js";
|
|
7
|
+
export * from "./agent-card.js";
|
|
8
|
+
export * from "./messages.js";
|
|
9
|
+
// Re-export commonly used functions for convenience
|
|
10
|
+
export { createBox, createDivider, } from "./box.js";
|
|
11
|
+
export { createAgentCard, createCompactAgentCard, } from "./agent-card.js";
|
|
12
|
+
export { createSuccessMessage, createErrorMessage, createWarningMessage, createInfoMessage, createStepIndicator, createProgressBar, createBulletList, createNumberedList, createKeyValueDisplay, createSpinner, } from "./messages.js";
|
|
13
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/components/index.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,cAAc,YAAY,CAAC;AAC3B,cAAc,UAAU,CAAC;AACzB,cAAc,iBAAiB,CAAC;AAChC,cAAc,eAAe,CAAC;AAE9B,oDAAoD;AACpD,OAAO,EACL,SAAS,EACT,aAAa,GACd,MAAM,UAAU,CAAC;AAElB,OAAO,EACL,eAAe,EACf,sBAAsB,GACvB,MAAM,iBAAiB,CAAC;AAEzB,OAAO,EACL,oBAAoB,EACpB,kBAAkB,EAClB,oBAAoB,EACpB,iBAAiB,EACjB,mBAAmB,EACnB,iBAAiB,EACjB,gBAAgB,EAChB,kBAAkB,EAClB,qBAAqB,EACrB,aAAa,GACd,MAAM,eAAe,CAAC"}
|
|
@@ -0,0 +1,62 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Message Components
|
|
3
|
+
* Reusable components for displaying various types of messages
|
|
4
|
+
*/
|
|
5
|
+
import { MessageOptions } from "./types.js";
|
|
6
|
+
/**
|
|
7
|
+
* Create a success message
|
|
8
|
+
*/
|
|
9
|
+
export declare function createSuccessMessage(message: string, options?: MessageOptions): string;
|
|
10
|
+
/**
|
|
11
|
+
* Create an error message
|
|
12
|
+
*/
|
|
13
|
+
export declare function createErrorMessage(message: string, options?: MessageOptions): string;
|
|
14
|
+
/**
|
|
15
|
+
* Create a warning message
|
|
16
|
+
*/
|
|
17
|
+
export declare function createWarningMessage(message: string, options?: MessageOptions): string;
|
|
18
|
+
/**
|
|
19
|
+
* Create an info message
|
|
20
|
+
*/
|
|
21
|
+
export declare function createInfoMessage(message: string, options?: MessageOptions): string;
|
|
22
|
+
/**
|
|
23
|
+
* Create a step indicator
|
|
24
|
+
*/
|
|
25
|
+
export declare function createStepIndicator(currentStep: number, totalSteps: number, stepName: string, status?: "pending" | "active" | "completed" | "failed"): string;
|
|
26
|
+
/**
|
|
27
|
+
* Create a progress bar
|
|
28
|
+
*/
|
|
29
|
+
export declare function createProgressBar(current: number, total: number, width?: number, options?: {
|
|
30
|
+
showPercentage?: boolean;
|
|
31
|
+
showNumbers?: boolean;
|
|
32
|
+
}): string;
|
|
33
|
+
/**
|
|
34
|
+
* Create a list of items with bullets
|
|
35
|
+
*/
|
|
36
|
+
export declare function createBulletList(items: string[], options?: {
|
|
37
|
+
bullet?: string;
|
|
38
|
+
indent?: number;
|
|
39
|
+
color?: string;
|
|
40
|
+
}): string;
|
|
41
|
+
/**
|
|
42
|
+
* Create a numbered list
|
|
43
|
+
*/
|
|
44
|
+
export declare function createNumberedList(items: string[], options?: {
|
|
45
|
+
startNumber?: number;
|
|
46
|
+
indent?: number;
|
|
47
|
+
color?: string;
|
|
48
|
+
}): string;
|
|
49
|
+
/**
|
|
50
|
+
* Create a key-value display
|
|
51
|
+
*/
|
|
52
|
+
export declare function createKeyValueDisplay(data: Record<string, string | undefined>, options?: {
|
|
53
|
+
separator?: string;
|
|
54
|
+
keyColor?: string;
|
|
55
|
+
valueColor?: string;
|
|
56
|
+
maxKeyLength?: number;
|
|
57
|
+
}): string;
|
|
58
|
+
/**
|
|
59
|
+
* Create a spinner with text (static version for display)
|
|
60
|
+
*/
|
|
61
|
+
export declare function createSpinner(text: string, frame?: number): string;
|
|
62
|
+
//# sourceMappingURL=messages.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"messages.d.ts","sourceRoot":"","sources":["../../src/components/messages.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAIH,OAAO,EAAE,cAAc,EAAE,MAAM,YAAY,CAAC;AAE5C;;GAEG;AACH,wBAAgB,oBAAoB,CAAC,OAAO,EAAE,MAAM,EAAE,OAAO,GAAE,cAAmB,GAAG,MAAM,CAoB1F;AAED;;GAEG;AACH,wBAAgB,kBAAkB,CAAC,OAAO,EAAE,MAAM,EAAE,OAAO,GAAE,cAAmB,GAAG,MAAM,CAmBxF;AAED;;GAEG;AACH,wBAAgB,oBAAoB,CAAC,OAAO,EAAE,MAAM,EAAE,OAAO,GAAE,cAAmB,GAAG,MAAM,CAmB1F;AAED;;GAEG;AACH,wBAAgB,iBAAiB,CAAC,OAAO,EAAE,MAAM,EAAE,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AAE,MAAU,GAAG,MAAM,CAIrE"}
|
|
@@ -0,0 +1,146 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Message Components
|
|
3
|
+
* Reusable components for displaying various types of messages
|
|
4
|
+
*/
|
|
5
|
+
import chalk from "chalk";
|
|
6
|
+
import { createBox } from "./box.js";
|
|
7
|
+
/**
|
|
8
|
+
* Create a success message
|
|
9
|
+
*/
|
|
10
|
+
export function createSuccessMessage(message, options = {}) {
|
|
11
|
+
const { title = "Success", icon = "✅", color = "00ff00", boxStyle = "round", width = 60, } = options;
|
|
12
|
+
return createBox(`${icon} ${message}`, {
|
|
13
|
+
title,
|
|
14
|
+
style: boxStyle,
|
|
15
|
+
borderColor: color,
|
|
16
|
+
width,
|
|
17
|
+
padding: 1,
|
|
18
|
+
align: "center",
|
|
19
|
+
});
|
|
20
|
+
}
|
|
21
|
+
/**
|
|
22
|
+
* Create an error message
|
|
23
|
+
*/
|
|
24
|
+
export function createErrorMessage(message, options = {}) {
|
|
25
|
+
const { title = "Error", icon = "❌", color = "ff0000", boxStyle = "double", width = 60, } = options;
|
|
26
|
+
return createBox(chalk.red(`${icon} ${message}`), {
|
|
27
|
+
title: chalk.red(title),
|
|
28
|
+
style: boxStyle,
|
|
29
|
+
borderColor: color,
|
|
30
|
+
width,
|
|
31
|
+
padding: 1,
|
|
32
|
+
});
|
|
33
|
+
}
|
|
34
|
+
/**
|
|
35
|
+
* Create a warning message
|
|
36
|
+
*/
|
|
37
|
+
export function createWarningMessage(message, options = {}) {
|
|
38
|
+
const { title = "Warning", icon = "⚠️", color = "ffff00", boxStyle = "single", width = 60, } = options;
|
|
39
|
+
return createBox(chalk.yellow(`${icon} ${message}`), {
|
|
40
|
+
title: chalk.yellow(title),
|
|
41
|
+
style: boxStyle,
|
|
42
|
+
borderColor: color,
|
|
43
|
+
width,
|
|
44
|
+
padding: 1,
|
|
45
|
+
});
|
|
46
|
+
}
|
|
47
|
+
/**
|
|
48
|
+
* Create an info message
|
|
49
|
+
*/
|
|
50
|
+
export function createInfoMessage(message, options = {}) {
|
|
51
|
+
const { title = "Info", icon = "ℹ️", color = "00ffff", boxStyle = "single", width = 60, } = options;
|
|
52
|
+
return createBox(chalk.cyan(`${icon} ${message}`), {
|
|
53
|
+
title: chalk.cyan(title),
|
|
54
|
+
style: boxStyle,
|
|
55
|
+
borderColor: color,
|
|
56
|
+
width,
|
|
57
|
+
padding: 1,
|
|
58
|
+
});
|
|
59
|
+
}
|
|
60
|
+
/**
|
|
61
|
+
* Create a step indicator
|
|
62
|
+
*/
|
|
63
|
+
export function createStepIndicator(currentStep, totalSteps, stepName, status = "active") {
|
|
64
|
+
const icons = {
|
|
65
|
+
pending: "○",
|
|
66
|
+
active: "◉",
|
|
67
|
+
completed: "✓",
|
|
68
|
+
failed: "✗",
|
|
69
|
+
};
|
|
70
|
+
const colors = {
|
|
71
|
+
pending: chalk.gray,
|
|
72
|
+
active: chalk.cyan,
|
|
73
|
+
completed: chalk.green,
|
|
74
|
+
failed: chalk.red,
|
|
75
|
+
};
|
|
76
|
+
const icon = icons[status];
|
|
77
|
+
const colorFn = colors[status];
|
|
78
|
+
const progress = `[${currentStep}/${totalSteps}]`;
|
|
79
|
+
return colorFn(`${icon} ${progress} ${stepName}`);
|
|
80
|
+
}
|
|
81
|
+
/**
|
|
82
|
+
* Create a progress bar
|
|
83
|
+
*/
|
|
84
|
+
export function createProgressBar(current, total, width = 30, options = {}) {
|
|
85
|
+
const { showPercentage = true, showNumbers = true } = options;
|
|
86
|
+
const percentage = Math.round((current / total) * 100);
|
|
87
|
+
const filled = Math.round((current / total) * width);
|
|
88
|
+
const empty = width - filled;
|
|
89
|
+
const bar = chalk.green("█".repeat(filled)) + chalk.gray("░".repeat(empty));
|
|
90
|
+
let result = `[${bar}]`;
|
|
91
|
+
if (showPercentage) {
|
|
92
|
+
result += ` ${percentage}%`;
|
|
93
|
+
}
|
|
94
|
+
if (showNumbers) {
|
|
95
|
+
result += ` (${current}/${total})`;
|
|
96
|
+
}
|
|
97
|
+
return result;
|
|
98
|
+
}
|
|
99
|
+
/**
|
|
100
|
+
* Create a list of items with bullets
|
|
101
|
+
*/
|
|
102
|
+
export function createBulletList(items, options = {}) {
|
|
103
|
+
const { bullet = "•", indent = 2, color } = options;
|
|
104
|
+
const colorFn = color ? chalk.hex(color) : (s) => s;
|
|
105
|
+
const indentStr = " ".repeat(indent);
|
|
106
|
+
return items
|
|
107
|
+
.map((item) => `${indentStr}${colorFn(bullet)} ${item}`)
|
|
108
|
+
.join("\n");
|
|
109
|
+
}
|
|
110
|
+
/**
|
|
111
|
+
* Create a numbered list
|
|
112
|
+
*/
|
|
113
|
+
export function createNumberedList(items, options = {}) {
|
|
114
|
+
const { startNumber = 1, indent = 2, color } = options;
|
|
115
|
+
const colorFn = color ? chalk.hex(color) : (s) => s;
|
|
116
|
+
const indentStr = " ".repeat(indent);
|
|
117
|
+
return items
|
|
118
|
+
.map((item, index) => `${indentStr}${colorFn(`${startNumber + index}.`)} ${item}`)
|
|
119
|
+
.join("\n");
|
|
120
|
+
}
|
|
121
|
+
/**
|
|
122
|
+
* Create a key-value display
|
|
123
|
+
*/
|
|
124
|
+
export function createKeyValueDisplay(data, options = {}) {
|
|
125
|
+
const { separator = ": ", keyColor = "00ff00", valueColor = "ffffff", maxKeyLength, } = options;
|
|
126
|
+
const keyColorFn = chalk.hex(keyColor);
|
|
127
|
+
const valueColorFn = chalk.hex(valueColor);
|
|
128
|
+
// Calculate max key length if not provided
|
|
129
|
+
const actualMaxKeyLength = maxKeyLength || Math.max(...Object.keys(data).map((k) => k.length));
|
|
130
|
+
return Object.entries(data)
|
|
131
|
+
.filter(([_, value]) => value !== undefined)
|
|
132
|
+
.map(([key, value]) => {
|
|
133
|
+
const paddedKey = key.padEnd(actualMaxKeyLength);
|
|
134
|
+
return `${keyColorFn(paddedKey)}${separator}${valueColorFn(value)}`;
|
|
135
|
+
})
|
|
136
|
+
.join("\n");
|
|
137
|
+
}
|
|
138
|
+
/**
|
|
139
|
+
* Create a spinner with text (static version for display)
|
|
140
|
+
*/
|
|
141
|
+
export function createSpinner(text, frame = 0) {
|
|
142
|
+
const frames = ["⠋", "⠙", "⠹", "⠸", "⠼", "⠴", "⠦", "⠧", "⠇", "⠏"];
|
|
143
|
+
const spinner = chalk.cyan(frames[frame % frames.length]);
|
|
144
|
+
return `${spinner} ${text}`;
|
|
145
|
+
}
|
|
146
|
+
//# sourceMappingURL=messages.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"messages.js","sourceRoot":"","sources":["../../src/components/messages.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAE,SAAS,EAAE,MAAM,UAAU,CAAC;AAGrC;;GAEG;AACH,MAAM,UAAU,oBAAoB,CAAC,OAAe,EAAE,UAA0B,EAAE;IAChF,MAAM,EACJ,KAAK,GAAG,SAAS,EACjB,IAAI,GAAG,GAAG,EACV,KAAK,GAAG,QAAQ,EAChB,QAAQ,GAAG,OAAO,EAClB,KAAK,GAAG,EAAE,GACX,GAAG,OAAO,CAAC;IAEZ,OAAO,SAAS,CACd,GAAG,IAAI,IAAI,OAAO,EAAE,EACpB;QACE,KAAK;QACL,KAAK,EAAE,QAAQ;QACf,WAAW,EAAE,KAAK;QAClB,KAAK;QACL,OAAO,EAAE,CAAC;QACV,KAAK,EAAE,QAAQ;KAChB,CACF,CAAC;AACJ,CAAC;AAED;;GAEG;AACH,MAAM,UAAU,kBAAkB,CAAC,OAAe,EAAE,UAA0B,EAAE;IAC9E,MAAM,EACJ,KAAK,GAAG,OAAO,EACf,IAAI,GAAG,GAAG,EACV,KAAK,GAAG,QAAQ,EAChB,QAAQ,GAAG,QAAQ,EACnB,KAAK,GAAG,EAAE,GACX,GAAG,OAAO,CAAC;IAEZ,OAAO,SAAS,CACd,KAAK,CAAC,GAAG,CAAC,GAAG,IAAI,IAAI,OAAO,EAAE,CAAC,EAC/B;QACE,KAAK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AAE,GAAG,EAAE,GAAG,EAAE,GAAG,EAAE,GAAG,EAAE,GAAG,EAAE,GAAG,CAAC,CAAC;IAClE,MAAM,OAAO,GAAG,KAAK,CAAC,IAAI,CAAC,MAAM,CAAC,KAAK,GAAG,MAAM,CAAC,MAAM,CAAC,CAAC,CAAC;IAC1D,OAAO,GAAG,OAAO,IAAI,IAAI,EAAE,CAAC;AAC9B,CAAC"}
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Types for CLI UI Components
|
|
3
|
+
*/
|
|
4
|
+
export interface BoxStyle {
|
|
5
|
+
topLeft?: string;
|
|
6
|
+
topRight?: string;
|
|
7
|
+
bottomLeft?: string;
|
|
8
|
+
bottomRight?: string;
|
|
9
|
+
horizontal?: string;
|
|
10
|
+
vertical?: string;
|
|
11
|
+
topJunction?: string;
|
|
12
|
+
bottomJunction?: string;
|
|
13
|
+
leftJunction?: string;
|
|
14
|
+
rightJunction?: string;
|
|
15
|
+
cross?: string;
|
|
16
|
+
}
|
|
17
|
+
export interface BoxOptions {
|
|
18
|
+
padding?: number;
|
|
19
|
+
margin?: number;
|
|
20
|
+
style?: BoxStyle | 'single' | 'double' | 'round' | 'heavy';
|
|
21
|
+
width?: number;
|
|
22
|
+
align?: 'left' | 'center' | 'right';
|
|
23
|
+
title?: string;
|
|
24
|
+
titleAlign?: 'left' | 'center' | 'right';
|
|
25
|
+
borderColor?: string;
|
|
26
|
+
}
|
|
27
|
+
export interface TextOptions {
|
|
28
|
+
color?: string;
|
|
29
|
+
bold?: boolean;
|
|
30
|
+
italic?: boolean;
|
|
31
|
+
underline?: boolean;
|
|
32
|
+
dim?: boolean;
|
|
33
|
+
}
|
|
34
|
+
export interface AgentData {
|
|
35
|
+
name: string;
|
|
36
|
+
description?: string;
|
|
37
|
+
did: string;
|
|
38
|
+
publicKey?: string;
|
|
39
|
+
privateKey?: string;
|
|
40
|
+
agentSlug?: string;
|
|
41
|
+
claimUrl?: string;
|
|
42
|
+
profileUrl?: string;
|
|
43
|
+
}
|
|
44
|
+
export interface MessageOptions {
|
|
45
|
+
title?: string;
|
|
46
|
+
icon?: string;
|
|
47
|
+
color?: string;
|
|
48
|
+
boxStyle?: BoxStyle | 'single' | 'double' | 'round' | 'heavy';
|
|
49
|
+
width?: number;
|
|
50
|
+
}
|
|
51
|
+
//# sourceMappingURL=types.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../src/components/types.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,MAAM,WAAW,QAAQ;IACvB,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,cAAc,CAAC,EAAE,MAAM,CAAC;IACxB,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,KAAK,CAAC,EAAE,MAAM,CAAC;CAChB;AAED,MAAM,WAAW,UAAU;IACzB,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,KAAK,CAAC,EAAE,QAAQ,GAAG,QAAQ,GAAG,QAAQ,GAAG,OAAO,GAAG,OAAO,CAAC;IAC3D,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,KAAK,CAAC,EAAE,MAAM,GAAG,QAAQ,GAAG,OAAO,CAAC;IACpC,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,UAAU,CAAC,EAAE,MAAM,GAAG,QAAQ,GAAG,OAAO,CAAC;IACzC,WAAW,CAAC,EAAE,MAAM,CAAC;CACtB;AAED,MAAM,WAAW,WAAW;IAC1B,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,IAAI,CAAC,EAAE,OAAO,CAAC;IACf,MAAM,CAAC,EAAE,OAAO,CAAC;IACjB,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,GAAG,CAAC,EAAE,OAAO,CAAC;CACf;AAED,MAAM,WAAW,SAAS;IACxB,IAAI,EAAE,MAAM,CAAC;IACb,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,GAAG,EAAE,MAAM,CAAC;IACZ,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,UAAU,CAAC,EAAE,MAAM,CAAC;CACrB;AAED,MAAM,WAAW,cAAc;IAC7B,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,QAAQ,CAAC,EAAE,QAAQ,GAAG,QAAQ,GAAG,QAAQ,GAAG,OAAO,GAAG,OAAO,CAAC;IAC9D,KAAK,CAAC,EAAE,MAAM,CAAC;CAChB"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"types.js","sourceRoot":"","sources":["../../src/components/types.ts"],"names":[],"mappings":"AAAA;;GAEG"}
|
|
@@ -130,7 +130,7 @@ export class CLIEffects {
|
|
|
130
130
|
options?.onComplete?.();
|
|
131
131
|
return;
|
|
132
132
|
}
|
|
133
|
-
const effect = getEffect(triggerConfig.effect);
|
|
133
|
+
const effect = await getEffect(triggerConfig.effect);
|
|
134
134
|
if (!effect) {
|
|
135
135
|
console.log(text);
|
|
136
136
|
options?.onComplete?.();
|
|
@@ -173,7 +173,7 @@ export class CLIEffects {
|
|
|
173
173
|
options?.onComplete?.();
|
|
174
174
|
return;
|
|
175
175
|
}
|
|
176
|
-
const effect = getEffect(effectName);
|
|
176
|
+
const effect = await getEffect(effectName);
|
|
177
177
|
if (!effect) {
|
|
178
178
|
console.log(text);
|
|
179
179
|
options?.onComplete?.();
|
|
@@ -215,7 +215,7 @@ export class CLIEffects {
|
|
|
215
215
|
console.log(text);
|
|
216
216
|
return promise;
|
|
217
217
|
}
|
|
218
|
-
const effect = getEffect("waves");
|
|
218
|
+
const effect = await getEffect("waves");
|
|
219
219
|
if (!effect) {
|
|
220
220
|
console.log(text);
|
|
221
221
|
return promise;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"cli-integration.js","sourceRoot":"","sources":["../../src/effects/cli-integration.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,EAAE,YAAY,EAAE,MAAM,oBAAoB,CAAC;AAClD,OAAO,EAAE,SAAS,EAAE,MAAM,YAAY,CAAC;AACvC,OAAO,EAAE,SAAS,EAAE,MAAM,aAAa,CAAC;AAExC;;GAEG;AACH,MAAM,CAAN,IAAY,aAeX;AAfD,WAAY,aAAa;IACvB,sBAAsB;IACtB,0DAAyC,CAAA;IACzC,gEAA+C,CAAA;IAC/C,8CAA6B,CAAA;IAE7B,sBAAsB;IACtB,gEAA+C,CAAA;IAC/C,kDAAiC,CAAA;IACjC,4DAA2C,CAAA;IAE3C,qBAAqB;IACrB,wDAAuC,CAAA;IACvC,wDAAuC,CAAA;IACvC,oCAAmB,CAAA;AACrB,CAAC,EAfW,aAAa,KAAb,aAAa,QAexB;AAED;;GAEG;AACH,MAAM,eAAe,GAGjB;IACF,CAAC,aAAa,CAAC,kBAAkB,CAAC,EAAE;QAClC,MAAM,EAAE,MAAM;QACd,OAAO,EAAE;YACP,QAAQ,EAAE,IAAI;YACd,UAAU,EAAE,CAAC,QAAQ,EAAE,QAAQ,EAAE,QAAQ,EAAE,QAAQ,EAAE,QAAQ,CAAC;SAC/D;KACF;IACD,CAAC,aAAa,CAAC,qBAAqB,CAAC,EAAE;QACrC,MAAM,EAAE,MAAM;QACd,OAAO,EAAE;YACP,QAAQ,EAA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