var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
    var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
    if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
    else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
    return c > 3 && r && Object.defineProperty(target, key, r), r;
};
import { html, css } from 'lit';
import { property } from 'lit/decorators.js';
import { classMap } from 'lit/directives/class-map.js';
import { TiniElement, partMap, VaryGroups, generateColorVaries, generateGradientVaries, generateScaleVaries } from 'tinijs';
export class IconControllerComponent extends TiniElement {
    static { this.defaultTagName = 'icon-controller'; }
    static { this.componentName = 'icon'; }
    static { this.styles = css `:host{--icon-width:var(--scale-md-2x);--icon-height:var(--scale-md-2x);--icon-scheme:none;--icon-image:url('data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIGZpbGw9ImN1cnJlbnRDb2xvciIgY2xhc3M9ImJpIGJpLWNvbnRyb2xsZXIiIHZpZXdCb3g9IjAgMCAxNiAxNiI+PHBhdGggZD0iTTExLjUgNi4wMjdhLjUuNSAwIDEgMS0xIDAgLjUuNSAwIDAgMSAxIDBtLTEuNSAxLjVhLjUuNSAwIDEgMCAwLTEgLjUuNSAwIDAgMCAwIDFtMi41LS41YS41LjUgMCAxIDEtMSAwIC41LjUgMCAwIDEgMSAwbS0xLjUgMS41YS41LjUgMCAxIDAgMC0xIC41LjUgMCAwIDAgMCAxbS02LjUtM2gxdjFoMXYxaC0xdjFoLTF2LTFoLTF2LTFoMXYtMSIvPjxwYXRoIGQ9Ik0zLjA1MSAzLjI2YS41LjUgMCAwIDEgLjM1NC0uNjEzbDEuOTMyLS41MThhLjUuNSAwIDAgMSAuNjIuMzljLjY1NS0uMDc5IDEuMzUtLjExNyAyLjA0My0uMTE3L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5IDIuNDA2Yy0uMDIyLjc1NS4wNjIgMS4zNjguMjQzIDEuNzc2YS40Mi40MiAwIDAgMCAuNDI2LjI0Yy4zMjctLjAzNC42MS0uMTk5LjkyOS0uNTAyLjIxMi0uMjAyLjQtLjQyMy42MTUtLjY3NC4xMzMtLjE1Ni4yNzYtLjMyMy40NC0uNTA0QzQuODYxIDkuOTY5IDUuOTc4IDkuMDI3IDggOS4wMjdzMy4xMzkuOTQyIDMuOTY1IDEuODU1Yy4xNjQuMTgxLjMwNy4zNDguNDQuNTA0LjIxNC4yNTEuNDAzLjQ3Mi42MTUuNjc0LjMxOC4zMDMuNjAxLjQ2OC45MjkuNTAzYS40Mi40MiAwIDAgMCAuNDI2LS4yNDFjLjE4LS40MDguMjY1LTEuMDIuMjQzLTEuNzc2YTEyLjM1NCAxMi4zNTQgMCAwIDAtLjMzOS0yLjQwNiAxMy43NTMgMTMuNzUzIDAgMCAwLS43NDgtMi4yOTVjLS4yOTgtLjY4Mi0uNjEtMS4xOS0uODg1LTEuNDY1LS4yNjQtLjI2NS0uODU2LS41MjMtMS43MzMtLjcwOC0uODUtLjE3OS0xLjg3Ny0uMjctMi45MTMtLjI3LTEuMDM2IDAtMi4wNjMuMDkxLTIuOTEzLjI3eiIvPjwvc3ZnPg==');display:inline-block}i{display:flex;align-items:center;justify-content:center;background-image:var(--icon-image);background-repeat:no-repeat;background-size:contain;background-position:center;width:var(--icon-width);height:var(--icon-height)}.scheme{background:var(--icon-scheme);-webkit-mask-image:var(--icon-image);-webkit-mask-size:var(--icon-width) var(--icon-height);-webkit-mask-repeat:no-repeat;-webkit-mask-position:center;mask-image:var(--icon-image);mask-size:var(--icon-width) var(--icon-height);mask-repeat:no-repeat;mask-position:center}${generateColorVaries(({ fullName, color }) => `.${fullName} {--icon-scheme: ${color};}`)}${generateGradientVaries(({ fullName, gradient }) => `.${fullName} {--icon-scheme: ${gradient};}`)}${generateScaleVaries(({ name, fullName }) => `.${fullName} {--icon-width: var(--scale-${name}-2x);--icon-height: var(--scale-${name}-2x);}`)}`; }
    willUpdate() { this.extendRootClasses({ raw: { scheme: !!this.scheme }, overridable: { [VaryGroups.Scale]: this.scale, [VaryGroups.Scheme]: this.scheme } }); }
    render() { return html `<i class=${classMap(this.rootClasses)} part=${partMap(this.rootClasses)}></i>`; }
}
__decorate([
    property({ type: String, reflect: true })
], IconControllerComponent.prototype, "scale", void 0);
__decorate([
    property({ type: String, reflect: true })
], IconControllerComponent.prototype, "scheme", void 0);
//# sourceMappingURL=controller.js.map