hedgequantx 2.4.39 → 2.4.41
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/package.json +1 -1
- package/src/app.js +8 -4
- package/src/utils/prompts.js +0 -1
package/package.json
CHANGED
package/src/app.js
CHANGED
|
@@ -115,9 +115,10 @@ const refreshStats = async () => {
|
|
|
115
115
|
|
|
116
116
|
/**
|
|
117
117
|
* Display application banner
|
|
118
|
+
* @param {boolean} [clear=true] - Whether to clear screen first
|
|
118
119
|
*/
|
|
119
|
-
const banner = async () => {
|
|
120
|
-
console.clear();
|
|
120
|
+
const banner = async (clear = true) => {
|
|
121
|
+
if (clear) console.clear();
|
|
121
122
|
|
|
122
123
|
const termWidth = process.stdout.columns || 100;
|
|
123
124
|
const isMobile = termWidth < 60;
|
|
@@ -240,9 +241,10 @@ const run = async () => {
|
|
|
240
241
|
while (true) {
|
|
241
242
|
try {
|
|
242
243
|
prepareStdin();
|
|
243
|
-
await banner();
|
|
244
244
|
|
|
245
245
|
if (!connections.isConnected()) {
|
|
246
|
+
console.clear();
|
|
247
|
+
await banner(false);
|
|
246
248
|
const choice = await mainMenu();
|
|
247
249
|
|
|
248
250
|
if (choice === 'exit') {
|
|
@@ -260,8 +262,10 @@ const run = async () => {
|
|
|
260
262
|
await refreshStats();
|
|
261
263
|
}
|
|
262
264
|
} else {
|
|
263
|
-
// Refresh stats
|
|
265
|
+
// Refresh stats BEFORE clearing screen, so everything displays at once
|
|
264
266
|
await refreshStats();
|
|
267
|
+
console.clear();
|
|
268
|
+
await banner(false);
|
|
265
269
|
|
|
266
270
|
const action = await dashboardMenu(currentService);
|
|
267
271
|
|