d031d798424e55aaa74ca85b206a53422ea788ad4d07c07fada5761fe6acf35f8517182b7c40c6699adc1f465489fc8d66bf0432388be92c2bdaaed38c8d97 470 B

1234567891011121314151617181920
  1. 'use strict';
  2. const chalk = require('chalk');
  3. const isSupported = process.platform !== 'win32' || process.env.CI || process.env.TERM === 'xterm-256color';
  4. const main = {
  5. info: chalk.blue('ℹ'),
  6. success: chalk.green('✔'),
  7. warning: chalk.yellow('⚠'),
  8. error: chalk.red('✖')
  9. };
  10. const fallbacks = {
  11. info: chalk.blue('i'),
  12. success: chalk.green('√'),
  13. warning: chalk.yellow('‼'),
  14. error: chalk.red('×')
  15. };
  16. module.exports = isSupported ? main : fallbacks;