'use strict';

/**
 * Maps the measure Unit type to the correct char
 *
 * @param {string} unit
 * @return {*}  {string}
 */
const mapUnitToSymbol = (unit) => {
    switch (unit) {
        case 'PERCENTAGE':
            return '%';
        default:
            return '';
    }
};
const setUnitOnValue = (value, unit, brackets = true, prefix = false) => {
    if (unit) {
        const unitValue = brackets ? ` (${unit})` : unit;
        return !prefix ? `${value}${unitValue}` : `${unitValue}${value}`;
    }
    return `${value}`;
};

exports.mapUnitToSymbol = mapUnitToSymbol;
exports.setUnitOnValue = setUnitOnValue;
//# sourceMappingURL=VisualisationUnitHelper.js.map
