// © 2022 SolarWinds Worldwide, LLC. All rights reserved.
//
// Permission is hereby granted, free of charge, to any person obtaining a copy
//  of this software and associated documentation files (the "Software"), to
//  deal in the Software without restriction, including without limitation the
//  rights to use, copy, modify, merge, publish, distribute, sublicense, and/or
//  sell copies of the Software, and to permit persons to whom the Software is
//  furnished to do so, subject to the following conditions:
//
// The above copyright notice and this permission notice shall be included in
//  all copies or substantial portions of the Software.
//
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
//  IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
//  FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
//  AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
//  LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
//  OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
//  THE SOFTWARE.
import { Component, EventEmitter, Input, Output, ViewEncapsulation, } from "@angular/core";
/**
 * @ignore
 * <example-url>./../examples/index.html#/repeat-item</example-url>
 */
export class RepeatItemComponent {
    constructor() {
        this.clickable = false;
        this.nowrap = false;
        this.selected = false;
        this.selectable = false;
        this.rowClicked = new EventEmitter();
    }
    get role() {
        return this.selectable ? "option" : "listitem";
    }
}
RepeatItemComponent.decorators = [
    { type: Component, args: [{
                selector: "nui-repeat-item",
                template: "<li\n    class=\"nui-repeat-item\"\n    [class.nui-repeat-item--selected]=\"selected\"\n    [class.text-nowrap]=\"nowrap\"\n    [class.nui-repeat-item--clickable]=\"clickable\"\n    (click)=\"clickable ? rowClicked.emit($event) : null\"\n    tabindex=\"-1\"\n>\n    <div class=\"nui-repeat-item__content\">\n        <ng-content></ng-content>\n    </div>\n</li>\n",
                encapsulation: ViewEncapsulation.None,
                host: { "[attr.role]": "role" },
                styles: ["body>nui-repeat-item.cdk-drag-preview .nui-repeat-item{list-style-type:none}body>nui-repeat-item.cdk-drag-preview .nui-repeat-item__controls-drag-handle{display:none}.nui .nui-repeat-item:active,.nui .nui-repeat-item:focus{outline:none}.nui .nui-repeat-item:hover{background-color:var(--nui-color-bg-secondary,#fafafa)}.nui .nui-repeat-item__content{display:flex}.nui .nui-repeat-item__controls-drag-handle{height:16px}.nui .nui-repeat-item__controls-drag-handle .nui-dnd-handle:hover{cursor:move}.nui .nui-repeat-item__controls-container{padding-left:3px}.nui .nui-repeat-item__controls-container .nui-repeat-item__checkbox .nui-checkbox{display:flex;justify-content:center;width:30px;height:30px}.nui .nui-repeat-item__controls-container .nui-repeat-item__checkbox .nui-checkbox__label:hover{background-color:transparent}.nui .nui-repeat-item__controls-container .nui-repeat-item__checkbox .nui-checkbox__transclude{margin-left:0}.nui .nui-repeat-item__content-container{min-height:30px;flex-grow:1;display:flex;align-items:center;margin-left:5px;margin-right:10px;min-width:0}.nui .nui-repeat-item__actions-container{margin-left:5px;display:flex;align-items:flex-start}.nui .nui-repeat-item__actions-container .btn-action:focus{background-color:transparent}.nui .nui-repeat-item.nui-repeat-item--clickable:not(.nui-repeat-item--selected):hover{background-color:var(--nui-color-bg-secondary,#fafafa)}.nui .nui-repeat-item.nui-repeat-item--selected{background-color:var(--nui-color-selected,rgba(0, 196, 210, .1));color:var(--nui-color-text-default,#111)}.nui .nui-repeat-item.nui-repeat-item--selected.nui-repeat-item--clickable:hover{background-color:var(--nui-color-selected-hover,rgba(0, 196, 210, .2))}\n"]
            },] }
];
RepeatItemComponent.propDecorators = {
    clickable: [{ type: Input }],
    nowrap: [{ type: Input }],
    selected: [{ type: Input }],
    selectable: [{ type: Input }],
    rowClicked: [{ type: Output }]
};
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoicmVwZWF0LWl0ZW0uY29tcG9uZW50LmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiLi4vLi4vLi4v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