Commit sur le PC fixe

This commit is contained in:
2023-11-20 11:39:31 +01:00
parent 064e0b34b0
commit 1651f488a0
291 changed files with 28343 additions and 1 deletions

View 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;