UNPKG

carbon-components-angular

Version:
104 lines (100 loc) 3.53 kB
/** * * carbon-angular v0.0.0 | textarea-label.component.d.ts * * Copyright 2014, 2024 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 { AfterViewInit, ElementRef, TemplateRef, ChangeDetectorRef } from "@angular/core"; import { TextArea } from "./text-area.directive"; import * as i0 from "@angular/core"; /** * Get started with importing the module: * * ```typescript * import { InputModule } from 'carbon-components-angular'; * ``` * * ```html * <cds-textarea-label> * Label * <textarea cdsTextArea class="textarea-field"> * </cds-textarea-label> * ``` * * [See demo](../../?path=/story/components-input-text-area--basic) */ export declare class TextareaLabelComponent implements AfterViewInit { protected changeDetectorRef: ChangeDetectorRef; /** * Used to build the id of the input item associated with the `Label`. */ static labelCounter: number; /** * The id of the input item associated with the `Label`. This value is also used to associate the `Label` with * its input counterpart through the 'for' attribute. */ labelInputID: string; /** * Set to `true` for a disabled label. */ disabled: boolean; /** * Set to `true` for a loading label. */ skeleton: boolean; /** * Helper input property for ease of migration * Since we cannot pass ng-content down easily from label component, we will accept the templates */ labelTemplate: TemplateRef<any>; textAreaTemplate: TemplateRef<any>; /** * Optional helper text that appears under the label. */ helperText: string | TemplateRef<any>; /** * Sets the invalid text. */ invalidText: string | TemplateRef<any>; /** * Set to `true` for an invalid label component. */ invalid: boolean; /** * Set to `true` to show a warning (contents set by warningText) */ warn: boolean; /** * Sets the warning text */ warnText: string | TemplateRef<any>; /** * Set the arialabel for label */ ariaLabel: string; wrapper: ElementRef<HTMLDivElement>; textArea: TextArea; labelClass: boolean; /** * Creates an instance of Label. */ constructor(changeDetectorRef: ChangeDetectorRef); /** * Sets the id on the input item associated with the `Label`. */ ngAfterViewInit(): void; isTemplate(value: any): boolean; static ɵfac: i0.ɵɵFactoryDeclaration<TextareaLabelComponent, never>; static ɵcmp: i0.ɵɵComponentDeclaration<TextareaLabelComponent, "cds-textarea-label, ibm-textarea-label", never, { "labelInputID": "labelInputID"; "disabled": "disabled"; "skeleton": "skeleton"; "labelTemplate": "labelTemplate"; "textAreaTemplate": "textAreaTemplate"; "helperText": "helperText"; "invalidText": "invalidText"; "invalid": "invalid"; "warn": "warn"; "warnText": "warnText"; "ariaLabel": "ariaLabel"; }, {}, ["textArea"], ["*", "[cdsTextArea],[ibmTextArea],textarea"], false>; }