const calcWidth = require('./calc-text-width.js').Verdana11 const colorPresets = require('./color-presets.js') module.exports = function ({subject, status, color}) { color = colorPresets[color] || color || colorPresets['blue'] const sbRectWidth = calcWidth(subject) + 10 const stRectWidth = calcWidth(status) + 11 const stTextStart = sbRectWidth + 5 const width = sbRectWidth + stRectWidth return ` ${subject} ${subject} ${status} ${status} ` }