mirror of
https://gitee.com/ant-design/ant-design.git
synced 2024-11-30 02:59:04 +08:00
chore: fix ts error
This commit is contained in:
parent
9f5a832235
commit
bbdb345542
@ -21,6 +21,9 @@ function ariaConvert(wrapper: CheerIO) {
|
||||
const matches = new Map();
|
||||
|
||||
function process(entry: CheerIOElement) {
|
||||
if (entry.type === 'text') {
|
||||
return;
|
||||
}
|
||||
const { attribs, children } = entry;
|
||||
if (matches.has(entry)) return;
|
||||
matches.set(entry, true);
|
||||
@ -31,7 +34,9 @@ function ariaConvert(wrapper: CheerIO) {
|
||||
}
|
||||
|
||||
// Loop children
|
||||
if (!children) return;
|
||||
if (!children) {
|
||||
return;
|
||||
}
|
||||
(Array.isArray(children) ? children : [children]).forEach(process);
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user