Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix #6922: fix input passthrough TS #6938

Merged
merged 1 commit into from
Jul 27, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 4 additions & 3 deletions components/lib/calendar/calendar.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ import * as React from 'react';
import { CSSTransitionProps as ReactCSSTransitionProps } from 'react-transition-group/CSSTransition';
import { ComponentHooks } from '../componentbase/componentbase';
import { CSSTransitionProps } from '../csstransition';
import { InputText, InputTextPassThroughOptions } from '../inputtext/inputtext';
import { PassThroughOptions } from '../passthrough';
import { TooltipOptions } from '../tooltip/tooltipoptions';
import { FormEvent, Nullable } from '../ts-helpers';
Expand Down Expand Up @@ -41,7 +42,7 @@ export interface CalendarPassThroughOptions {
* Uses to pass attributes to the InputText component.
* @see {@link CalendarPassThroughType}
*/
input?: CalendarPassThroughType<React.HTMLAttributes<HTMLInputElement>>;
input?: InputTextPassThroughOptions;
/**
* Uses to pass attributes to the Button component.
* @see {@link CalendarPassThroughType}
Expand Down Expand Up @@ -1079,9 +1080,9 @@ export declare class Calendar extends React.Component<CalendarProps, any> {
public getElement(): HTMLSpanElement;
/**
* Used to get input element.
* @return {HTMLInputElement} Input element
* @return {InputText} Input element
*/
public getInput(): HTMLInputElement;
public getInput(): typeof InputText;
/**
* Used to get overlay element.
* @return {HTMLElement} Overlay element
Expand Down
7 changes: 4 additions & 3 deletions components/lib/cascadeselect/cascadeselect.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ import { CSSTransitionProps as ReactCSSTransitionProps } from 'react-transition-
import { APIOptions } from '../api/api';
import { ComponentHooks } from '../componentbase/componentbase';
import { CSSTransitionProps } from '../csstransition';
import { InputText, InputTextPassThroughOptions } from '../inputtext/inputtext';
import { PassThroughOptions } from '../passthrough';
import { SelectItemOptionsType } from '../selectitem/selectitem';
import { IconType, PassThroughType } from '../utils/utils';
Expand Down Expand Up @@ -77,7 +78,7 @@ export interface CascadeSelectPassThroughOptions {
/**
* Uses to pass attributes to the input's DOM element.
*/
input?: CascadeSelectPassThroughType<React.HTMLAttributes<HTMLInputElement>>;
input?: InputTextPassThroughOptions;
/**
* Uses to pass attributes to the label's DOM element.
*/
Expand Down Expand Up @@ -352,9 +353,9 @@ export declare class CascadeSelect extends React.Component<CascadeSelectProps, a
public getElement(): HTMLDivElement;
/**
* Used to get input element.
* @return {HTMLInputElement} Input element
* @return {InputText} Input element
*/
public getInput(): HTMLInputElement;
public getInput(): typeof InputText;
/**
* Used to get overlay element.
* @return {HTMLElement} Overlay element
Expand Down
5 changes: 2 additions & 3 deletions components/lib/inputotp/inputotp.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,9 @@
*/
import * as React from 'react';
import { ComponentHooks } from '../componentbase/componentbase';
import { KeyFilterType } from '../keyfilter';
import { InputTextPassThroughOptions } from '../inputtext/inputtext';
import { PassThroughOptions } from '../passthrough';
import { TooltipPassThroughOptions } from '../tooltip/tooltip';
import { TooltipOptions } from '../tooltip/tooltipoptions';
import { PassThroughType, TemplateType } from '../utils/utils';

export declare type InputOtpPassThroughType<T> = PassThroughType<T, InputOtpPassThroughMethodOptions>;
Expand All @@ -38,7 +37,7 @@ export interface InputOtpPassThroughOptions {
* Uses to pass attributes to the Tooltip component.
* @see {@link TooltipPassThroughOptions}
*/
input?: InputOtpPassThroughType<React.HTMLAttributes<HTMLInputElement>>;
input?: InputTextPassThroughOptions;
/**
* Used to manage all lifecycle hooks
* @see {@link ComponentHooks}
Expand Down
Loading