This repository was archived by the owner on Dec 5, 2024. It is now read-only.
Commit dcdb3bd 1 parent b1bd45f commit dcdb3bd Copy full SHA for dcdb3bd
File tree 3 files changed +19
-5
lines changed
3 files changed +19
-5
lines changed Original file line number Diff line number Diff line change @@ -191,8 +191,11 @@ export const slides = [props => <>
191
191
<div>
192
192
<p>{\`out\`}</p>
193
193
<div className=\\"foo\\">
194
- <p>{\`in
195
- in\`}</p>
194
+ <p>{\`in\`}</p>
195
+ <div className=\\"foo bar baz\\">
196
+ <p>{\`core\`}</p>
197
+ </div>
198
+ <p>{\`in\`}</p>
196
199
</div>
197
200
<p>{\`out\`}</p>
198
201
</div>
@@ -217,8 +220,15 @@ export default function MDXContent({
217
220
{
218
221
/* block-start: foo */
219
222
}
220
- <p>{\`in
221
- in\`}</p>
223
+ <p>{\`in\`}</p>
224
+ {
225
+ /* block-start:foo,bar, baz */
226
+ }
227
+ <p>{\`core\`}</p>
228
+ {
229
+ /* block-end */
230
+ }
231
+ <p>{\`in\`}</p>
222
232
{
223
233
/* block-end */
224
234
}
Original file line number Diff line number Diff line change @@ -159,6 +159,9 @@ second
159
159
out
160
160
<!-- block-start: foo -->
161
161
in
162
+ <!-- block-start:foo,bar, baz -->
163
+ core
164
+ <!-- block-end -->
162
165
in
163
166
<!-- block-end -->
164
167
out
Original file line number Diff line number Diff line change @@ -160,7 +160,8 @@ function mdxPlugin() {
160
160
161
161
for ( const pos of matches ) {
162
162
const [ , className ] = pos ;
163
- const div = className ? `<div className="${ className . trim ( ) } ">` : '<div>' ;
163
+ const formattedClassName = commentParser ( `0:${ className } ` ) . valueStr . replace ( / , / g, ' ' ) ;
164
+ const div = className ? `<div className="${ formattedClassName } ">` : '<div>' ;
164
165
165
166
mdxJSX = mdxJSX . replace ( / { \s .+ \/ \* b l o c k - s t a r t : ? ( .* ?) \* \/ \s .+ } / m, div ) ;
166
167
}
You can’t perform that action at this time.
0 commit comments