File tree Expand file tree Collapse file tree 1 file changed +9
-5
lines changed Expand file tree Collapse file tree 1 file changed +9
-5
lines changed Original file line number Diff line number Diff line change @@ -132,6 +132,14 @@ async function addConfig(
132132 const themeName =
133133 typeof theme === "string" ? theme : theme . name
134134 const style = `[data-ch-theme="${ themeName } "] \{ ${ rules } \}`
135+
136+ const codeConfig = {
137+ staticMediaQuery : config . staticMediaQuery ,
138+ lineNumbers : config . lineNumbers ,
139+ showCopyButton : config . showCopyButton ,
140+ themeName,
141+ }
142+
135143 tree . children . unshift ( {
136144 type : "mdxJsxFlowElement" ,
137145 name : "style" ,
@@ -202,11 +210,7 @@ async function addConfig(
202210 type : "Identifier" ,
203211 name : CH_CODE_CONFIG_VAR_NAME ,
204212 } ,
205- init : valueToEstree ( {
206- ...config ,
207- themeName,
208- theme : undefined ,
209- } ) ,
213+ init : valueToEstree ( codeConfig ) ,
210214 } ,
211215 ] ,
212216 kind : "const" ,
You can’t perform that action at this time.
0 commit comments