"use strict";
/* TODO auto-generated eslint ignore, please fix! */
/* eslint no-undef: "off" */
/**
 * UI Feature Flags
 *
 *  Copyright (C) 2010-2019 R-T Specialty, LLC.
 *
 *  This file is part of the Liza Data Collection Framework
 *
 *  Liza is free software: you can redistribute it and/or modify
 *  it under the terms of the GNU General Public License as published by
 *  the Free Software Foundation, either version 3 of the License, or
 *  (at your option) any later version.
 *
 *  This program is distributed in the hope that it will be useful,
 *  but WITHOUT ANY WARRANTY; without even the implied warranty of
 *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 *  GNU General Public License for more details.
 *
 *  You should have received a copy of the GNU General Public License
 *  along with this program.  If not, see <http://www.gnu.org/licenses/>.
 */
Object.defineProperty(exports, "__esModule", { value: true });
exports.WindowFeatureFlag = void 0;
/**
 * Global feature flag for new UI
 *
 * TODO: replace with a proper feature flag solution
 */
var WindowFeatureFlag = /** @class */ (function () {
    /**
     * Initialize FeatureFlag
     */
    function WindowFeatureFlag() {
    }
    /**
     * Get instance of FeatureFlag
     */
    WindowFeatureFlag.getInstance = function () {
        if (!WindowFeatureFlag.instance) {
            WindowFeatureFlag.instance = new WindowFeatureFlag();
        }
        return WindowFeatureFlag.instance;
    };
    /**
     * Look up a feature flag by key
     *
     * @param key - the key to lookup
     *
     * @return whether or not this feature flag is enabled
     */
    WindowFeatureFlag.prototype.isEnabled = function (key) {
        return !!window[key];
    };
    return WindowFeatureFlag;
}());
exports.WindowFeatureFlag = WindowFeatureFlag;
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiV2luZG93RmVhdHVyZUZsYWcuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyJXaW5kb3dGZWF0dXJlRmxhZy50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiO0FBQUEsb0RBQW9EO0FBQ3BELDRCQUE0QjtBQUM1Qjs7Ozs7Ozs7Ozs7Ozs7Ozs7OztHQW1CRzs7O0FBRUg7Ozs7R0FJRztBQUNIO0lBR0U7O09BRUc7SUFDSDtJQUF1QixDQUFDO0lBRXhCOztPQUVHO0lBQ1csNkJBQVcsR0FBekI7UUFDRSxJQUFJLENBQUMsaUJBQWlCLENBQUMsUUFBUSxFQUFFO1lBQy9CLGlCQUFpQixDQUFDLFFBQVEsR0FBRyxJQUFJLGlCQUFpQixFQUFFLENBQUM7U0FDdEQ7UUFFRCxPQUFPLGlCQUFpQixDQUFDLFFBQVEsQ0FBQztJQUNwQyxDQUFDO0lBRUQ7Ozs7OztPQU1HO0lBQ0gscUNBQVMsR0FBVCxVQUFVLEdBQVc7UUFDbkIsT0FBTyxDQUFDLENBQU8sTUFBTyxDQUFDLEdBQUcsQ0FBQyxDQUFDO0lBQzlCLENBQUM7SUFDSCx3QkFBQztBQUFELENBQUMsQUE3QkQsSUE2QkM7QUE3QlksOENBQWlCIn0=