File tree Expand file tree Collapse file tree 1 file changed +8
-2
lines changed Expand file tree Collapse file tree 1 file changed +8
-2
lines changed Original file line number Diff line number Diff line change @@ -27,6 +27,12 @@ export interface IduxResolverOptions {
27
27
* import style along with components
28
28
*/
29
29
importStyle ?: 'css' | 'less'
30
+ /**
31
+ * theme for import style
32
+ *
33
+ * @default 'default'
34
+ */
35
+ importStyleTheme ?: string
30
36
}
31
37
32
38
/**
@@ -38,7 +44,7 @@ export function IduxResolver(options: IduxResolverOptions = {}): ComponentResolv
38
44
return {
39
45
type : 'component' ,
40
46
resolve : ( name : string ) => {
41
- const { importStyle, exclude = [ ] } = options
47
+ const { importStyle, importStyleTheme = 'default' , exclude = [ ] } = options
42
48
if ( exclude . includes ( name ) )
43
49
return
44
50
@@ -56,7 +62,7 @@ export function IduxResolver(options: IduxResolverOptions = {}): ComponentResolv
56
62
57
63
let sideEffects : string | undefined
58
64
if ( packageName !== 'cdk' && importStyle )
59
- sideEffects = `${ path } /style/themes/${ importStyle === 'css' ? 'default_css' : 'default' } `
65
+ sideEffects = `${ path } /style/themes/${ importStyle === 'css' ? ` ${ importStyleTheme } _css` : importStyleTheme } `
60
66
61
67
return { name, from : path , sideEffects }
62
68
} ,
You can’t perform that action at this time.
0 commit comments