feat: in stock wait time per link now

Signed-off-by: Jef LeCompte <jeffreylec@gmail.com>
This commit is contained in:
Jef LeCompte
2020-09-25 08:25:58 -04:00
parent d25a643425
commit c7a716f981
2 changed files with 16 additions and 8 deletions
+8 -1
View File
@@ -35,11 +35,18 @@ export const Print = {
},
inStock(link: Link, store: Store, color?: boolean): string {
if (color) {
return chalk.green.bold(`🚀🚨 ${buildProductString(link, store, true)} :: IN STOCK 🚨🚀`);
return chalk.bgGreen.white.bold(`🚀🚨 ${buildProductString(link, store, false)} :: IN STOCK 🚨🚀`);
}
return `🚀🚨 ${buildProductString(link, store)} :: IN STOCK 🚨🚀`;
},
inStockWaiting(link: Link, store: Store, color?: boolean): string {
if (color) {
return ' ' + buildProductString(link, store, true) + ' :: ' + chalk.yellow('IN STOCK, WAITING');
}
return ` ${buildProductString(link, store)} :: IN STOCK, WAITING`;
},
outOfStock(link: Link, store: Store, color?: boolean): string {
if (color) {
return '✖ ' + buildProductString(link, store, true) + ' :: ' + chalk.red('OUT OF STOCK');