Skip to content

Commit

Permalink
Refactoring
Browse files Browse the repository at this point in the history
  • Loading branch information
ehmicky committed Sep 5, 2021
1 parent 260d077 commit 27248d8
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/run/preview/update/actions.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,12 +7,13 @@ export const getActions = function (actions, leftWidth) {
return ''
}

const actionsStr = actions.map(getAction).join(noteColor(', '))
const actionsStr = actions.map(getAction).join(noteColor(ACTION_SEPARATOR))
return `${ACTIONS_LABEL.padEnd(leftWidth)}${actionsStr}`
}

const getAction = function ({ key, explanation }) {
return `${goodColor(key)} ${noteColor(`(${explanation})`)}`
}

const ACTION_SEPARATOR = ', '
export const ACTIONS_LABEL = 'Actions'

0 comments on commit 27248d8

Please sign in to comment.