import { TemplateRef } from '@angular/core'; import { PassThroughOption, PassThrough } from 'primeng/api'; import { InputTextPassThrough } from 'primeng/types/inputtext'; /** * Custom pass-through(pt) options. * @template I Type of instance. * * @see {@link InputNumber.pt} * @group Interface */ interface InputNumberPassThroughOptions { /** * Used to pass attributes to the host's DOM element. */ host?: PassThroughOption; /** * Used to pass attributes to the root's DOM element. */ root?: PassThroughOption; /** * Used to pass attributes to the InputText component. */ pcInputText?: InputTextPassThrough; /** * Used to pass attributes to the clear icon's DOM element. */ clearIcon?: PassThroughOption; /** * Used to pass attributes to the button group's DOM element. */ buttonGroup?: PassThroughOption; /** * Used to pass attributes to the increment button's DOM element. */ incrementButton?: PassThroughOption; /** * Used to pass attributes to the decrement button's DOM element. */ decrementButton?: PassThroughOption; /** * Used to pass attributes to the increment button icon's DOM element. */ incrementButtonIcon?: PassThroughOption; /** * Used to pass attributes to the decrement button icon's DOM element. */ decrementButtonIcon?: PassThroughOption; } /** * Defines valid pass-through options in InputNumber component. * @see {@link InputNumberPassThroughOptions} * * @template I Type of instance. */ type InputNumberPassThrough = PassThrough>; /** * Custom InputNumber input event. * @see {@link onInput} * @group Interface */ interface InputNumberInputEvent { /** * Browser event. */ originalEvent: Event; /** * Input value. */ value: number | null; /** * Formatted value. */ formattedValue: string; } /** * Defines valid templates in InputNumber. * @group Templates */ interface InputNumberTemplates { /** * Custom clear icon template. */ clearicon(): TemplateRef; /** * Custom increment button icon template. */ incrementbuttonicon(): TemplateRef; /** * Custom decrement button icon template. */ decrementbuttonicon(): TemplateRef; } export type { InputNumberInputEvent, InputNumberPassThrough, InputNumberPassThroughOptions, InputNumberTemplates };