create daemon
This commit is contained in:
12
thrower_daemon/node_modules/simple-update-notifier/src/borderedText.ts
generated
vendored
Normal file
12
thrower_daemon/node_modules/simple-update-notifier/src/borderedText.ts
generated
vendored
Normal file
@@ -0,0 +1,12 @@
|
||||
const borderedText = (text: string) => {
|
||||
const lines = text.split('\n');
|
||||
const width = Math.max(...lines.map((l) => l.length));
|
||||
const res = [`┌${'─'.repeat(width + 2)}┐`];
|
||||
for (const line of lines) {
|
||||
res.push(`│ ${line.padEnd(width)} │`);
|
||||
}
|
||||
res.push(`└${'─'.repeat(width + 2)}┘`);
|
||||
return res.join('\n');
|
||||
};
|
||||
|
||||
export default borderedText;
|
||||
Reference in New Issue
Block a user