Skip to content

Commit 443b39a

Browse files
authored
fix(tdesign): resolver (unplugin#349)
1 parent 76a2a07 commit 443b39a

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

src/core/resolvers/tdesign.ts

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ function getSideEffects(importName: string, options: TDesignResolverOptions): Si
3333

3434
if (fileName.includes('-') && fileName !== 'input-number') {
3535
const prefix = fileName.slice(0, fileName.indexOf('-'))
36-
const container = ['anchor', 'avatar', 'breadcrumb', 'checkbox', 'dropdown', 'form', 'input', 'list', 'menu', 'radio', 'slider', 'steps', 'swiper']
36+
const container = ['anchor', 'avatar', 'breadcrumb', 'checkbox', 'dropdown', 'form', 'input', 'list', 'menu', 'radio', 'slider', 'swiper']
3737

3838
if (container.includes(prefix))
3939
fileName = prefix
@@ -57,12 +57,18 @@ function getSideEffects(importName: string, options: TDesignResolverOptions): Si
5757
if (['tab-nav', 'tab-panel'].includes(fileName))
5858
fileName = 'tabs'
5959

60+
if (fileName === 'step-item')
61+
fileName = 'steps'
62+
6063
if (fileName === 'check-tag')
6164
fileName = 'tag'
6265

6366
if (fileName === 'time-range-picker')
6467
fileName = 'time-picker'
6568

69+
if (fileName === 'date-range-picker')
70+
fileName = 'date-picker'
71+
6672
if (importStyle === 'less')
6773
return `tdesign-${library}/esm/${fileName}/style`
6874

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy