fix(build): [date-picker] type prop error in web-types.json (#15376)

This commit is contained in:
btea 2024-01-05 20:26:38 +08:00 committed by GitHub
parent 838bad208c
commit f8c2510705
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -80,7 +80,6 @@ const reAttribute: ReAttribute = (value, key) => {
} else if (key === 'Type') { } else if (key === 'Type') {
return rewriteType(str) return rewriteType(str)
.replaceAll(/\bfunction(\(.*\))?(:\s*\w+)?\b/gi, 'Function') .replaceAll(/\bfunction(\(.*\))?(:\s*\w+)?\b/gi, 'Function')
.replaceAll(/\bdate\b/g, 'Date')
.replaceAll(/\([^)]*\)(?!\s*=>)/g, '') .replaceAll(/\([^)]*\)(?!\s*=>)/g, '')
.replaceAll(/(<[^>]*>|\{[^}]*}|\([^)]*\))/g, (item) => { .replaceAll(/(<[^>]*>|\{[^}]*}|\([^)]*\))/g, (item) => {
return item.replaceAll(/(\/|\|)/g, '=_0!') return item.replaceAll(/(\/|\|)/g, '=_0!')