/**
 * This file is part of the MedSafe application which is commercial software created by MedVision360 B.V.
 * The source code is proprietary and confidential.
 *
 * Unauthorized copying of this file, via any medium is strictly prohibited.
 *
 * Copyright (c) by MedVision360 B.V. All rights reserved.
 *
 * For the application name: io.medrecord.medsafe
 */
import { __decorate, __extends } from "tslib";
import { Component, Input, ChangeDetectionStrategy } from '@angular/core';
import { TranslationMiddleware } from '@medrecord/frontend-translations-middleware';
var LinearGraphComponent = /** @class */ (function (_super) {
    __extends(LinearGraphComponent, _super);
    function LinearGraphComponent() {
        var _this = _super !== null && _super.apply(this, arguments) || this;
        _this.labels = {
            lowTitle: 'liner_graph.low',
            goodTitle: 'liner_graph.good',
            highTitle: 'liner_graph.concerning'
        };
        return _this;
    }
    LinearGraphComponent.prototype.ngOnInit = function () {
        this.setTranslation('en', {
            liner_graph: {
                low: 'Low',
                good: 'Good',
                concerning: 'Concerning',
            }
        });
        this.setTranslation('nl', {
            liner_graph: {
                low: 'Laag',
                good: 'Goed',
                concerning: 'Aangaande',
            }
        });
    };
    __decorate([
        Input()
    ], LinearGraphComponent.prototype, "data", void 0);
    __decorate([
        Input()
    ], LinearGraphComponent.prototype, "labels", void 0);
    LinearGraphComponent = __decorate([
        Component({
            selector: 'app-linear-graph',
            template: "<div class=\"container\">\n  <div class=\"line\"></div>\n  <div class=\"slider\" [style.left.%]=\"data?.offset\">\n    {{ data?.value }}\n  </div>\n</div>\n\n<div class=\"status-text\">\n  <div class=\"status-line\">\n    {{ labels.lowTitle | translate }}\n  </div>\n  <div class=\"status-line\">\n    {{ labels.goodTitle | translate }}\n  </div>\n  <div class=\"status-line\">\n    {{ labels.highTitle | translate }}\n  </div>\n</div>\n",
            changeDetection: ChangeDetectionStrategy.OnPush,
            styles: ["/*!\n * This file is part of the MedSafe application which is commercial software created by MedVision360 B.V.\n *  The source code is proprietary and confidential.\n *\n *  Unauthorized copying of this file, via any medium is strictly prohibited.\n *\n *  Copyright (c) by MedVision360 B.V. All rights reserved.\n *\n *  For the application name: io.medrecord.medsafe\n */:host{display:block;width:432px}.container{display:flex;align-items:center;position:relative;width:inherit;height:24px}.line{display:block;width:inherit;height:5px;background:linear-gradient(270deg,var(--alert-color) 26%,var(--success-color) 50%,var(--alert-color) 76%);border-radius:5px}.slider{display:flex;justify-content:center;align-items:center;position:absolute;left:0;top:0;border:1px solid var(--geyser-color);border-radius:5px;background:var(--white-color);width:48px;height:24px;font-size:10px;font-weight:700;color:var(--primary-color);overflow:hidden;margin-left:-24px}.status-text{display:flex;justify-content:space-between;width:inherit;margin-top:4px}.status-text .status-line{font-size:10px;font-weight:500;color:var(--boulder-color)}.wrap-liner{padding:3rem!important}"]
        })
    ], LinearGraphComponent);
    return LinearGraphComponent;
}(TranslationMiddleware));
export { LinearGraphComponent };
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoibGluZWFyLWdyYXBoLmNvbXBvbmVudC5qcyIsInNvdXJjZVJvb3QiOiJuZzovL0BtZWRyZWNvcmQvdWktY29tcG9uZW50cy8iLCJzb3VyY2VzIjpbImxpYi9zaGFyZWQvY29tcG9uZW50cy9saW5lYXItZ3JhcGgvbGluZWFyLWdyYXBoLmNvbXBvbmVudC50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUFBQTs7Ozs7Ozs7O0dBU0c7O0FBRUgsT0FBTyxFQUFDLFNBQVMsRUFBRSxLQUFLLEVBQUUsdUJBQXVCLEVBQUMsTUFBTSxlQUFlLENBQUM7QUFLeEUsT0FBTyxFQUFDLHFCQUFxQixFQUFDLE1BQU0sNkNBQTZDLENBQUM7QUFRbEY7SUFBMEMsd0NBQXFCO0lBQS9EO1FBQUEscUVBeUJDO1FBdkJVLFlBQU0sR0FBc0I7WUFDbkMsUUFBUSxFQUFFLGlCQUFpQjtZQUMzQixTQUFTLEVBQUUsa0JBQWtCO1lBQzdCLFNBQVMsRUFBRSx3QkFBd0I7U0FDcEMsQ0FBQzs7SUFtQkosQ0FBQztJQWpCQyx1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