@tryghost/listr-smart-renderer 0.2.5 → 0.2.7

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/LICENSE CHANGED
@@ -1,6 +1,6 @@
1
1
  MIT License
2
2
 
3
- Copyright (c) 2013-2021 Ghost Foundation
3
+ Copyright (c) 2013-2022 Ghost Foundation
4
4
 
5
5
  Permission is hereby granted, free of charge, to any person obtaining a copy
6
6
  of this software and associated documentation files (the "Software"), to deal
package/README.md CHANGED
@@ -82,4 +82,4 @@ Follow the instructions for the top-level repo.
82
82
 
83
83
  # Copyright & License
84
84
 
85
- Copyright (c) 2013-2021 Ghost Foundation, Sam Verschueren - Released under the [MIT license](LICENSE).
85
+ Copyright (c) 2013-2022 Ghost Foundation, Sam Verschueren - Released under the [MIT license](LICENSE).
@@ -1,10 +1,11 @@
1
1
  'use strict';
2
2
  const logUpdate = require('log-update');
3
3
  const chalk = require('chalk');
4
- const figures = require('figures');
5
4
  const cliTruncate = require('cli-truncate');
6
5
  const stripAnsi = require('strip-ansi');
7
6
  const {indentString, getSymbol, isDefined, taskNumber} = require('./utils');
7
+ const arrowRight = '→';
8
+ const arrowDown = '↓';
8
9
 
9
10
  const dataRenderer = (data, prefix = '') => {
10
11
  if (typeof data === 'string') {
@@ -16,7 +17,7 @@ const dataRenderer = (data, prefix = '') => {
16
17
  }
17
18
 
18
19
  if (isDefined(data)) {
19
- return ` ${chalk.gray(cliTruncate(`${figures.arrowRight} ${prefix} ${data}`, process.stdout.columns - 3))}`;
20
+ return ` ${chalk.gray(cliTruncate(`${arrowRight} ${prefix} ${data}`, process.stdout.columns - 3))}`;
20
21
  }
21
22
  };
22
23
 
@@ -60,7 +61,7 @@ const summaryRenderer = (tasks, options, level = 0) => {
60
61
  states.failed.push(task);
61
62
 
62
63
  if (!task.output && task.hasSubtasks()) {
63
- task.output = `${chalk.red.dim(`Subtask failed ${figures.arrowDown}`)}`;
64
+ task.output = `${chalk.red.dim(`Subtask failed ${arrowDown}`)}`;
64
65
  }
65
66
  output.push(indentString(`${getSymbol(task, options)} ${taskNumber(index, tasks)}: ${task.title} - ${task.output}`, level));
66
67
  } else {
package/lib/utils.js CHANGED
@@ -2,10 +2,9 @@
2
2
  const chalk = require('chalk');
3
3
  const logSymbols = require('log-symbols');
4
4
  const indentString = require('indent-string');
5
- const figures = require('figures');
6
5
  const elegantSpinner = require('elegant-spinner');
7
- const pointer = chalk.yellow(figures.pointer);
8
- const skipped = chalk.yellow(figures.arrowDown);
6
+ const pointer = chalk.yellow('›');
7
+ const skipped = chalk.yellow('↓');
9
8
 
10
9
  exports.isDefined = x => x !== null && x !== undefined;
11
10
 
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@tryghost/listr-smart-renderer",
3
- "version": "0.2.5",
4
- "repository": "https://github.com/TryGhost/migrate/tree/master/packages/listr-smart-renderer",
3
+ "version": "0.2.7",
4
+ "repository": "https://github.com/TryGhost/migrate/tree/main/packages/listr-smart-renderer",
5
5
  "author": "Ghost Foundation",
6
6
  "license": "MIT",
7
7
  "main": "index.js",
@@ -28,11 +28,10 @@
28
28
  "chalk": "4.1.2",
29
29
  "cli-truncate": "^2.0.0",
30
30
  "elegant-spinner": "^2.0.0",
31
- "figures": "3.2.0",
32
31
  "indent-string": "^4.0.0",
33
32
  "log-symbols": "4.1.0",
34
33
  "log-update": "^4.0.0",
35
34
  "strip-ansi": "^6.0.0"
36
35
  },
37
- "gitHead": "7f5133e5ad1c6b6981fc6cd70782aa58a64fba13"
36
+ "gitHead": "6407ac2c624bf34de37bdb3608698ca1b1b27b9a"
38
37
  }