{"version":3,"file":"taiga-ui-cdk-directives-element.mjs","sources":["../../../projects/cdk/directives/element/element.directive.ts","../../../projects/cdk/directives/element/taiga-ui-cdk-directives-element.ts"],"sourcesContent":["import {Directive, ElementRef} from '@angular/core';\nimport {tuiInjectElement} from '@taiga-ui/cdk/utils/dom';\n\n@Directive({\n    selector: '[tuiElement]',\n    exportAs: 'elementRef',\n})\nexport class TuiElement<T extends Element = HTMLElement> implements ElementRef<T> {\n    public nativeElement = tuiInjectElement<T>();\n\n    constructor() {\n        /**\n         * @note:\n         * Typically, when your constructor is invoked with new,\n         * an object is created, its constructor is assigned to\n         * the invoked constructor and the object is then assigned\n         * to this before executing any operations specified\n         * in your constructor method.\n         *\n         * ERROR TypeError: Class constructor ElementRef cannot be invoked without 'new'\n         * https://github.com/taiga-family/taiga-ui/issues/3072\n         *\n         * This way we can instantiate object creation\n         * without additional prototype chain for possible fix bug.\n         */\n        return new ElementRef(this.nativeElement);\n    }\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;MAOa,UAAU,CAAA;AAGnB,IAAA,WAAA,GAAA;QAFO,IAAA,CAAA,aAAa,GAAG,gBAAgB,EAAK;AAGxC;;;;;;;;;;;;;AAaG;AACH,QAAA,OAAO,IAAI,UAAU,CAAC,IAAI,CAAC,aAAa,CAAC;IAC7C;+GAnBS,UAAU,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA,CAAA;mGAAV,UAAU,EAAA,YAAA,EAAA,IAAA,EAAA,QAAA,EAAA,cAAA,EAAA,QAAA,EAAA,CAAA,YAAA,CAAA,EAAA,QAAA,EAAA,EAAA,EAAA,CAAA,CAAA;;4FAAV,UAAU,EAAA,UAAA,EAAA,CAAA;kBAJtB,SAAS;AAAC,YAAA,IAAA,EAAA,CAAA;AACP,oBAAA,QAAQ,EAAE,cAAc;AACxB,oBAAA,QAAQ,EAAE,YAAY;AACzB,iBAAA;;;ACND;;AAEG;;;;"}