"use strict";
/*
 * @poppinss/colors
 *
 * (c) Harminder Virk <virk@adonisjs.com>
 *
 * For the full copyright and license information, please view the LICENSE
 * file that was distributed with this source code.
 */
Object.defineProperty(exports, "__esModule", { value: true });
exports.Raw = exports.FakeColors = exports.Colors = exports.getBest = void 0;
const Raw_1 = require("./src/Raw");
Object.defineProperty(exports, "Raw", { enumerable: true, get: function () { return Raw_1.Raw; } });
const Kleur_1 = require("./src/Kleur");
Object.defineProperty(exports, "Colors", { enumerable: true, get: function () { return Kleur_1.Kleur; } });
const Stringify_1 = require("./src/Stringify");
Object.defineProperty(exports, "FakeColors", { enumerable: true, get: function () { return Stringify_1.Stringify; } });
/**
 * Returns the best colors instance based upon the tty
 * and if in testing mode
 */
function getBest(isTesting) {
    if (isTesting) {
        return new Stringify_1.Stringify();
    }
    if (require('color-support').level > 0) {
        return new Kleur_1.Kleur();
    }
    return new Raw_1.Raw();
}
exports.getBest = getBest;
