/*
 * Copyright 2015-2024 Ritense BV, the Netherlands.
 *
 * Licensed under EUPL, Version 1.2 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 * https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" basis,
 * WITHimport { LabelModule } from 'carbon-components-angular';
OUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */
import { Component, EventEmitter, HostBinding, Input, Output } from '@angular/core';
import { CommonModule } from '@angular/common';
import { InputModule } from 'carbon-components-angular';
import * as i0 from "@angular/core";
import * as i1 from "@angular/common";
import * as i2 from "carbon-components-angular";
export class KeyValueComponent {
    constructor() {
        this.fullWidth = false;
        this.disabled = false;
        this.keyColumnFlex = 1;
        this.valueColumnFlex = 1;
        this.valueChange = new EventEmitter();
    }
    onInputChange(type, inputValue) {
        this.valueChange.emit({ value: this.value, inputValue, type });
    }
    static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.12", ngImport: i0, type: KeyValueComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
    static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.3.12", type: KeyValueComponent, isStandalone: true, selector: "valtimo-key-value", inputs: { keyColumnTitle: "keyColumnTitle", valueColumnTitle: "valueColumnTitle", index: "index", value: "value", fullWidth: "fullWidth", disabled: "disabled", keyColumnFlex: "keyColumnFlex", valueColumnFlex: "valueColumnFlex" }, outputs: { valueChange: "valueChange" }, host: { properties: { "class.--full-width": "this.fullWidth" } }, ngImport: i0, template: "<!--\n  ~ Copyright 2015-2024 Ritense BV, the Netherlands.\n  ~\n  ~ Licensed under EUPL, Version 1.2 (the \"License\");\n  ~ you may not use this file except in compliance with the License.\n  ~ You may obtain a copy of the License at\n  ~\n  ~ https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n  ~\n  ~ Unless required by applicable law or agreed to in writing, software\n  ~ distributed under the License is distributed on an \"AS IS\" basis,\n  ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n  ~ See the License for the specific language governing permissions and\n  ~ limitations under the License.\n  -->\n\n<div\n  class=\"v-multi-input__input\"\n  [ngClass]=\"{'--full-width': fullWidth}\"\n  [style.flex]=\"keyColumnFlex\"\n>\n  <cds-label *ngIf=\"index === 0 && keyColumnTitle\">{{ keyColumnTitle }}</cds-label>\n\n  <input\n    cdsText\n    [defaultValue]=\"value.key\"\n    [disabled]=\"disabled\"\n    (input)=\"onInputChange('key', $event.target.value)\"\n  />\n</div>\n\n<div class=\"v-multi-input__separator\"></div>\n\n<div\n  class=\"v-multi-input__input\"\n  [ngClass]=\"{'--full-width': fullWidth}\"\n  [style.flex]=\"valueColumnFlex\"\n>\n  <cds-label *ngIf=\"index === 0 && valueColumnTitle\">{{ valueColumnTitle }}</cds-label>\n\n  <input\n    cdsText\n    [defaultValue]=\"value.value\"\n    [disabled]=\"disabled\"\n    (input)=\"onInputChange('value', $event.target.value)\"\n  />\n</div>\n", styles: [":host{display:flex;flex-direction:row;align-items:flex-end}:host.--full-width{width:100%}\n/*!\n * Copyright 2015-2024 Ritense BV, the Netherlands.\n *\n * Licensed under EUPL, Version 1.2 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" basis,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "ngmodule", type: InputModule }, { kind: "component", type: i2.Label, selector: "cds-label, ibm-label", inputs: ["labelInputID", "disabled", "skeleton", "helperText", "invalidText", "invalid", "warn", "warnText", "ariaLabel"] }, { kind: "directive", type: i2.TextInput, selector: "[cdsText], [ibmText]", inputs: ["theme", "size", "invalid", "warn", "skeleton"] }] }); }
}
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.12", ngImport: i0, type: KeyValueComponent, decorators: [{
            type: Component,
            args: [{ selector: 'valtimo-key-value', standalone: true, imports: [CommonModule, InputModule], template: "<!--\n  ~ Copyright 2015-2024 Ritense BV, the Netherlands.\n  ~\n  ~ Licensed under EUPL, Version 1.2 (the \"License\");\n  ~ you may not use this file except in compliance with the License.\n  ~ You may obtain a copy of the License at\n  ~\n  ~ https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n  ~\n  ~ Unless required by applicable law or agreed to in writing, software\n  ~ distributed under the License is distributed on an \"AS IS\" basis,\n  ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n  ~ See the License for the specific language governing permissions and\n  ~ limitations under the License.\n  -->\n\n<div\n  class=\"v-multi-input__input\"\n  [ngClass]=\"{'--full-width': fullWidth}\"\n  [style.flex]=\"keyColumnFlex\"\n>\n  <cds-label *ngIf=\"index === 0 && keyColumnTitle\">{{ keyColumnTitle }}</cds-label>\n\n  <input\n    cdsText\n    [defaultValue]=\"value.key\"\n    [disabled]=\"disabled\"\n    (input)=\"onInputChange('key', $event.target.value)\"\n  />\n</div>\n\n<div class=\"v-multi-input__separator\"></div>\n\n<div\n  class=\"v-multi-input__input\"\n  [ngClass]=\"{'--full-width': fullWidth}\"\n  [style.flex]=\"valueColumnFlex\"\n>\n  <cds-label *ngIf=\"index === 0 && valueColumnTitle\">{{ valueColumnTitle }}</cds-label>\n\n  <input\n    cdsText\n    [defaultValue]=\"value.value\"\n    [disabled]=\"disabled\"\n    (input)=\"onInputChange('value', $event.target.value)\"\n  />\n</div>\n", styles: [":host{display:flex;flex-direction:row;align-items:flex-end}:host.--full-width{width:100%}\n/*!\n * Copyright 2015-2024 Ritense BV, the Netherlands.\n *\n * Licensed under EUPL, Version 1.2 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" basis,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n"] }]
        }], propDecorators: { keyColumnTitle: [{
                type: Input
            }], valueColumnTitle: [{
                type: Input
            }], index: [{
                type: Input
            }], value: [{
                type: Input
            }], fullWidth: [{
                type: Input
            }, {
                type: HostBinding,
                args: ['class.--full-width']
            }], disabled: [{
                type: Input
            }], keyColumnFlex: [{
                type: Input
            }], valueColumnFlex: [{
                type: Input
            }], valueChange: [{
                type: Output
            }] } });
//# sourceMappingURL=data:application/json;base64, 