Skip to content

Commit c857dde

Browse files
committed
chore: fix allowSyntheticDefaultImports define
ref ant-design/ant-design#26484
1 parent 4924321 commit c857dde

File tree

2 files changed

+3
-15
lines changed

2 files changed

+3
-15
lines changed

src/hooks/useTreeData.ts

Lines changed: 2 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,6 @@
11
import * as React from 'react';
22
import warning from 'rc-util/lib/warning';
3-
import {
4-
DataNode,
5-
InnerDataNode,
6-
SimpleModeConfig,
7-
RawValueType,
8-
} from '../interface';
3+
import { DataNode, InnerDataNode, SimpleModeConfig, RawValueType } from '../interface';
94
import { convertChildrenToData } from '../utils/legacyUtil';
105

116
const MAX_WARNING_TIMES = 10;
@@ -85,10 +80,7 @@ function formatTreeData(
8580
);
8681
}
8782

88-
warning(
89-
!valueSet.has(value),
90-
`Same \`value\` exist in the tree: ${value}`,
91-
);
83+
warning(!valueSet.has(value), `Same \`value\` exist in the tree: ${value}`);
9284
valueSet.add(value);
9385
}
9486

src/interface.ts

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -14,11 +14,7 @@ export interface LabelValueType {
1414
halfChecked?: boolean;
1515
}
1616

17-
export type DefaultValueType =
18-
| RawValueType
19-
| RawValueType[]
20-
| LabelValueType
21-
| LabelValueType[];
17+
export type DefaultValueType = RawValueType | RawValueType[] | LabelValueType | LabelValueType[];
2218

2319
export interface DataNode {
2420
value?: RawValueType;

0 commit comments

Comments
 (0)