plazbot-cli 0.2.25 → 0.2.26
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.
|
@@ -114,16 +114,19 @@ exports.whatsappConnectCommand = new commander_1.Command('connect')
|
|
|
114
114
|
const expiresAt = linkData.expiresAt ? new Date(linkData.expiresAt).toLocaleDateString('es-ES', { day: 'numeric', month: 'long', year: 'numeric' }) : '';
|
|
115
115
|
spinner.stop();
|
|
116
116
|
// Mostrar link
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
console.log(
|
|
121
|
-
console.log(
|
|
122
|
-
console.log(
|
|
117
|
+
const W = 54;
|
|
118
|
+
const pad = (text) => text + ' '.repeat(Math.max(0, W - text.length));
|
|
119
|
+
const border = chalk_1.default.hex('#25D366');
|
|
120
|
+
console.log(border(' ┌' + '─'.repeat(W) + '┐'));
|
|
121
|
+
console.log(border(' │') + chalk_1.default.bold(pad(' Abre este link en tu navegador:')) + border('│'));
|
|
122
|
+
console.log(border(' │') + ' '.repeat(W) + border('│'));
|
|
123
|
+
console.log(border(' │') + chalk_1.default.hex('#22d3ee')(pad(` ${shortUrl}`)) + border('│'));
|
|
124
|
+
console.log(border(' │') + ' '.repeat(W) + border('│'));
|
|
125
|
+
console.log(border(' │') + chalk_1.default.gray(pad(' Escanea el codigo QR desde tu WhatsApp')) + border('│'));
|
|
123
126
|
if (expiresAt) {
|
|
124
|
-
console.log(
|
|
127
|
+
console.log(border(' │') + chalk_1.default.gray(pad(` Expira: ${expiresAt}`)) + border('│'));
|
|
125
128
|
}
|
|
126
|
-
console.log(
|
|
129
|
+
console.log(border(' └' + '─'.repeat(W) + '┘'));
|
|
127
130
|
console.log();
|
|
128
131
|
// Guardar IDs actuales para detectar nuevos
|
|
129
132
|
const prevIds = new Set(allIntegrations.map((i) => i.id));
|
package/package.json
CHANGED
|
@@ -134,16 +134,20 @@ export const whatsappConnectCommand = new Command('connect')
|
|
|
134
134
|
spinner.stop();
|
|
135
135
|
|
|
136
136
|
// Mostrar link
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
console.log(
|
|
142
|
-
console.log(
|
|
137
|
+
const W = 54;
|
|
138
|
+
const pad = (text: string) => text + ' '.repeat(Math.max(0, W - text.length));
|
|
139
|
+
const border = chalk.hex('#25D366');
|
|
140
|
+
|
|
141
|
+
console.log(border(' ┌' + '─'.repeat(W) + '┐'));
|
|
142
|
+
console.log(border(' │') + chalk.bold(pad(' Abre este link en tu navegador:')) + border('│'));
|
|
143
|
+
console.log(border(' │') + ' '.repeat(W) + border('│'));
|
|
144
|
+
console.log(border(' │') + chalk.hex('#22d3ee')(pad(` ${shortUrl}`)) + border('│'));
|
|
145
|
+
console.log(border(' │') + ' '.repeat(W) + border('│'));
|
|
146
|
+
console.log(border(' │') + chalk.gray(pad(' Escanea el codigo QR desde tu WhatsApp')) + border('│'));
|
|
143
147
|
if (expiresAt) {
|
|
144
|
-
console.log(
|
|
148
|
+
console.log(border(' │') + chalk.gray(pad(` Expira: ${expiresAt}`)) + border('│'));
|
|
145
149
|
}
|
|
146
|
-
console.log(
|
|
150
|
+
console.log(border(' └' + '─'.repeat(W) + '┘'));
|
|
147
151
|
console.log();
|
|
148
152
|
|
|
149
153
|
// Guardar IDs actuales para detectar nuevos
|