import { AfterViewInit, DoCheck, OnDestroy, OnInit, SimpleChanges, OnChanges } from '@angular/core';
import { PoTableColumnSpacing } from '../../po-table';
import { PoLookupBaseComponent } from './po-lookup-base.component';
import { PoHelperComponent } from '../../po-helper';
/**
* @docsExtends PoLookupBaseComponent
*
* @description
*
* Quando existe muitos dados o po-lookup por padrão traz apenas 10 itens na tabela e os demais são carregados por demanda através do
* botão 'Carregar mais resultados'. Para que funcione corretamente, é importante que o serviço siga o
* [Guia de implementação das APIs TOTVS](https://po-ui.io/guides/api).
*
* Importante:
*
* - Caso o po-lookup contenha o [(ngModel)] sem o atributo name, ocorrerá um erro de angular.
* Então será necessário informar o atributo name ou o atributo [ngModelOptions]="{standalone: true}".
* ```
*
*
* ```
*
* #### Tokens customizáveis
*
* É possível alterar o estilo do componente usando os seguintes tokens (CSS):
*
* > Para maiores informações, acesse o guia [Personalizando o Tema Padrão com Tokens CSS](https://po-ui.io/guides/theme-customization).
*
* | Propriedade | Descrição | Valor Padrão |
* |----------------------------------------|-------------------------------------------------------|--------------------------------------------------|
* | **Default Values** | | |
* | `--font-family` | Família tipográfica usada | `var(--font-family-theme)` |
* | `--font-size` | Tamanho da fonte | `var(--font-size-default)` |
* | `--text-color-placeholder` | Cor do texto no placeholder | `var(--color-neutral-light-30)` |
* | `--color` | Cor principal do lookup | `var(--color-neutral-dark-70)` |
* | `--border-radius` | Contém o valor do raio dos cantos do elemento | `var(--border-radius-md)` |
* | `--background` | Cor de background | `var(--color-neutral-light-05)` |
* | `--text-color` | Cor do texto | `var(--color-neutral-dark-90)` |
* | `--color-clear` | Cor principal do icone clear | `var(--color-action-default)` |
* | **Icon** | | |
* | `--color-icon` | Cor principal do icone pesquisar | `var(--color-action-default)` |
* | **Hover** | | |
* | `--color-hover` | Cor principal no estado hover | `var(--color-brand-01-dark)` |
* | `--background-hover` | Cor de background no estado hover | `var(--color-brand-01-lightest)` |
* | **Focused** | | |
* | `--color-focused` | Cor principal no estado de focus | `var(--color-action-default)` |
* | `--outline-color-focused` | Cor do outline do estado de focus | `var(--color-action-focus)` |
* | **Disabled** | | |
* | `--color-disabled` | Cor principal no estado disabled | `var(--color-action-disabled)` |
* | `--background-disabled` | Cor de background no estado disabled | `var(--color-neutral-light-20)` |
* | `--text-color-disabled` | Cor do texto quando campo está desabilitado | `var(--color-action-disabled)` |
* | **Error** | | |
* | `--color-error` | Cor de background no estado de requerido | `var(--color-feedback-negative-base)` |
*
* @example
*
*
*
*
*
*
*
*
*
*
*
*
*
*
*
*
*
*
*
*
*
*
*
*
*
*
*
*
*
*
*
*
*
*
*
*/
export declare class PoLookupComponent extends PoLookupBaseComponent implements AfterViewInit, OnDestroy, OnInit, DoCheck, OnChanges {
private readonly renderer;
private readonly cd;
private readonly el;
helperEl?: PoHelperComponent;
initialized: boolean;
timeoutResize: any;
visibleElement: boolean;
heightGroupButtons: number;
disclaimers: any[];
visibleDisclaimers: any[];
id: string;
private modalSubscription;
private isCalculateVisibleItems;
get autocomplete(): "off" | "on";
constructor();
ngAfterViewInit(): void;
ngDoCheck(): void;
ngOnDestroy(): void;
ngOnInit(): void;
ngOnChanges(changes: SimpleChanges): void;
/**
* Função que atribui foco ao componente.
*
* Para utilizá-la é necessário ter a instância do componente no DOM, podendo ser utilizado o ViewChild da seguinte forma:
*
* ```
* import { PoLookupComponent } from '@po-ui/ng-components';
*
* ...
*
* @ViewChild(PoLookupComponent, { static: true }) lookup: PoLookupComponent;
*
* focusLookup() {
* this.lookup.focus();
* }
* ```
*/
focus(): void;
emitAdditionalHelp(): void;
getAdditionalHelpTooltip(): string;
openLookup(): void;
checkSelectedItems(): any;
setDisclaimers(selectedOptions: Array): void;
setViewValue(value: any, object: any): void;
getViewValue(): string;
getErrorPattern(): string;
hasInvalidClass(): any;
onBlur(): void;
searchEvent(): void;
closeDisclaimer(value: any): void;
updateVisibleItems(): void;
debounceResize(): void;
debounce(func: () => void, delay: number): void;
getInputWidth(): number;
getDisclaimersWidth(): any[];
calculateVisibleItems(): void;
onKeyDown(event: KeyboardEvent): void;
/**
*
* Método que exibe `p-helper` ou executa a ação definida em `p-helper{eventOnClick}` ou em `p-additionalHelp`.
* Para isso, será necessário configurar uma tecla de atalho utilizando o evento `p-keydown`.
*
* > Exibe ou oculta o conteúdo do componente `po-helper` quando o componente estiver com foco.
*
* ```
* // Exemplo com p-label e p-helper
*
* ```
* ```
* ...
* onKeyDown(event: KeyboardEvent, inp: PoLookupComponent): void {
* if (event.code === 'F9') {
* inp.showAdditionalHelp();
* }
* }
* ```
*/
showAdditionalHelp(): boolean;
setHelper(label?: string, additionalHelpTooltip?: string): {
hideAdditionalHelp: boolean;
helperSettings?: any;
};
protected getDefaultSpacing(): PoTableColumnSpacing;
private isAdditionalHelpEventTriggered;
private isAllowedOpenModal;
private formatFields;
private setInputValueWipoieldFormat;
private initializeListeners;
}