/**
 *
 * @ai-apps/angular v2.147.1-next.0 | icon-content-switcher-option.directive.js
 *
 * Copyright 2014, 2022 IBM
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *   http://www.apache.org/licenses/LICENSE-2.0

 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT 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 { Directive, HostBinding, Input } from '@angular/core';
import { ContentSwitcherOption } from 'carbon-components-angular';
import * as i0 from "@angular/core";
/**
 * selector: `aiIconContentOption`
 */
export class IconContentSwitcherOption extends ContentSwitcherOption {
    constructor() {
        super(...arguments);
        this.mainClass = `iot--icon-switch
    bx--btn
    bx--btn--secondary
    bx--tooltip--hidden
    bx--btn--icon-only
    bx--tooltip__trigger
    bx--tooltip--a11y
    bx--btn--icon-only--top
    bx--tooltip--align-center`;
        this.selectedClass = false;
        this.size = 'md';
        this.theme = 'dark';
    }
    get unselectedClass() {
        return !this.selectedClass;
    }
    get isDefaultSize() {
        return this.size === 'md';
    }
    get isSmallSize() {
        return this.size === 'sm';
    }
    get isLargeSize() {
        return this.size === 'lg';
    }
    get isLight() {
        return this.theme === 'light';
    }
    get isUnselectedLight() {
        return this.isLight && !this.selectedClass;
    }
}
IconContentSwitcherOption.ɵfac = function IconContentSwitcherOption_Factory(t) { return ɵIconContentSwitcherOption_BaseFactory(t || IconContentSwitcherOption); };
IconContentSwitcherOption.ɵdir = i0.ɵɵdefineDirective({ type: IconContentSwitcherOption, selectors: [["", "aiIconContentOption", ""]], hostVars: 18, hostBindings: function IconContentSwitcherOption_HostBindings(rf, ctx) { if (rf & 2) {
        i0.ɵɵclassMap(ctx.mainClass);
        i0.ɵɵclassProp("iot--icon-switch--selected", ctx.selectedClass)("bx--content-switcher--selected", ctx.selectedClass)("iot--icon-switch--unselected", ctx.unselectedClass)("iot--icon-switch--default", ctx.isDefaultSize)("iot--icon-switch--small", ctx.isSmallSize)("iot--icon-switch--large", ctx.isLargeSize)("iot--icon-switch--light", ctx.isLight)("iot--icon-switch--unselected--light", ctx.isUnselectedLight);
    } }, inputs: { size: "size", theme: "theme" }, exportAs: ["aiIconContentOption"], features: [i0.ɵɵInheritDefinitionFeature] });
const ɵIconContentSwitcherOption_BaseFactory = /*@__PURE__*/ i0.ɵɵgetInheritedFactory(IconContentSwitcherOption);
(function () { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(IconContentSwitcherOption, [{
        type: Directive,
        args: [{
                selector: '[aiIconContentOption]',
                exportAs: 'aiIconContentOption',
            }]
    }], null, { mainClass: [{
            type: HostBinding,
            args: ['class']
        }], selectedClass: [{
            type: HostBinding,
            args: ['class.iot--icon-switch--selected']
        }, {
            type: HostBinding,
            args: ['class.bx--content-switcher--selected']
        }], unselectedClass: [{
            type: HostBinding,
            args: ['class.iot--icon-switch--unselected']
        }], isDefaultSize: [{
            type: HostBinding,
            args: ['class.iot--icon-switch--default']
        }], isSmallSize: [{
            type: HostBinding,
            args: ['class.iot--icon-switch--small']
        }], isLargeSize: [{
            type: HostBinding,
            args: ['class.iot--icon-switch--large']
        }], isLight: [{
            type: HostBinding,
            args: ['class.iot--icon-switch--light']
        }], isUnselectedLight: [{
            type: HostBinding,
            args: ['class.iot--icon-switch--unselected--light']
        }], size: [{
            type: Input
        }], theme: [{
            type: Input
        }] }); })();
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiaWNvbi1jb250ZW50LXN3aXRjaGVyLW9wdGlvbi5kaXJlY3RpdmUuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi9zcmMvaWNvbi1jb250ZW50LXN3aXRjaGVyL2ljb24tY29udGVudC1zd2l0Y2hlci1vcHRpb24uZGlyZWN0aXZlLnRzIl0sIm5hbWVzIjpbXSwibWFwcGlu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