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

🐞 - FilterByInputPipe doesn`t allow to pass nullable values #10409

Open
mkozakevich opened this issue Feb 19, 2025 · 0 comments · Fixed by #10408
Open

🐞 - FilterByInputPipe doesn`t allow to pass nullable values #10409

mkozakevich opened this issue Feb 19, 2025 · 0 comments · Fixed by #10408
Assignees

Comments

@mkozakevich
Copy link

Reproduction url

https://stackblitz.com/edit/angular-xc4hv7nk-1grcs782?file=src%2Fapp%2Fapp.template.html

Description

FilterByInputPipe source code contains null handler. But transform method signature allows readonly T[] only for items parameter

Source code

    public transform<T>(items: readonly T[], matcher?: TuiStringMatcher<T>): readonly T[]; // signature
    public transform<T>(
        items: ReadonlyArray<readonly T[]> | readonly T[] | null, // definition

It breaks DataListWrapper logic: you need to pass null to DataListWrapper items input to show the loader. So it becomes impossible to use FilterByInputPipe correctly with async values (see reproduction)

Taiga UI version

4.25.0

Browser Used

Chrome

OS Used

macOS

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging a pull request may close this issue.

3 participants