File tree Expand file tree Collapse file tree 2 files changed +6
-3
lines changed Expand file tree Collapse file tree 2 files changed +6
-3
lines changed Original file line number Diff line number Diff line change @@ -309,8 +309,11 @@ function serializeNode(
309309 }
310310 if ( needBlock ) {
311311 const { width, height } = ( n as HTMLElement ) . getBoundingClientRect ( ) ;
312- attributes . rr_width = `${ width } px` ;
313- attributes . rr_height = `${ height } px` ;
312+ attributes = {
313+ class : attributes . class ,
314+ rr_width : `${ width } px` ,
315+ rr_height : `${ height } px` ,
316+ } ;
314317 }
315318 return {
316319 type : NodeType . Element ,
Original file line number Diff line number Diff line change @@ -70,7 +70,7 @@ exports[`[html file]: block-element.html 1`] = `
7070 <div class =\\"rr-block big\\" style =\\"width: 50px; height: 50px;\\"></div>
7171 <div>record 2</div>
7272 <div class =\\"rr-block small\\" style =\\"width: 50px; height: 100px;\\"></div>
73- <div class =\\"rr-block\\" style =\\"height: 200px; width: 100px \\"></div>
73+ <div class =\\"rr-block\\" style =\\"width: 100px; height: 200px; \\"></div>
7474 </body></html>"
7575`;
7676
You can’t perform that action at this time.
0 commit comments