Skip to content

Commit

Permalink
fix(tab):geeneric id type modified
Browse files Browse the repository at this point in the history
  • Loading branch information
“Tamara committed Feb 2, 2023
1 parent 6895e2e commit 4559441
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/tab/Tab.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -6,14 +6,14 @@ import classNames from "classnames";
import TabHeaderItem from "./header/item/TabHeaderItem";
import List from "../list/List";

export type TabItem<ID = string | number> = {
export type TabItem<ID extends string | number = string | number> = {
id: ID;
content: React.ReactNode;
icon?: React.ReactNode;
isDisabled?: boolean;
};

interface UncontrolledTabProps<ID> {
interface UncontrolledTabProps<ID extends string | number = string | number> {
items: TabItem<ID>[];
children: React.ReactNode[];
testid?: string;
Expand Down

0 comments on commit 4559441

Please sign in to comment.