@@ -217,14 +217,14 @@ const drawMessage = function (elem, startx, stopx, verticalPos, msg, sequenceInd
217
217
const breaklines = msg . message . split ( / < b r \/ ? > / ig)
218
218
for ( const breakline of breaklines ) {
219
219
textElem = g . append ( 'text' ) // text label for the x axis
220
- . attr ( 'x' , txtCenter )
221
- . attr ( 'y' , verticalPos - 7 + counterBreaklines * breaklineOffset )
222
- . style ( 'text-anchor' , 'middle' )
223
- . attr ( 'class' , 'messageText' )
224
- . text ( breakline . trim ( ) )
220
+ . attr ( 'x' , txtCenter )
221
+ . attr ( 'y' , verticalPos - 7 + counterBreaklines * breaklineOffset )
222
+ . style ( 'text-anchor' , 'middle' )
223
+ . attr ( 'class' , 'messageText' )
224
+ . text ( breakline . trim ( ) )
225
225
counterBreaklines ++
226
226
}
227
- const offsetLineCounter = counterBreaklines - 1
227
+ const offsetLineCounter = counterBreaklines - 1
228
228
const totalOffset = offsetLineCounter * breaklineOffset
229
229
230
230
let textWidth = ( textElem . _groups || textElem ) [ 0 ] [ 0 ] . getBBox ( ) . width
@@ -239,7 +239,7 @@ const drawMessage = function (elem, startx, stopx, verticalPos, msg, sequenceInd
239
239
( verticalPos + 30 + totalOffset ) + ' ' + startx + ',' + ( verticalPos + 20 + totalOffset ) )
240
240
}
241
241
242
- bounds . bumpVerticalPos ( 30 + totalOffset )
242
+ bounds . bumpVerticalPos ( 30 + totalOffset )
243
243
const dx = Math . max ( textWidth / 2 , 100 )
244
244
bounds . insert ( startx - dx , bounds . getVerticalPos ( ) - 10 + totalOffset , stopx + dx , bounds . getVerticalPos ( ) + totalOffset )
245
245
} else {
@@ -248,7 +248,7 @@ const drawMessage = function (elem, startx, stopx, verticalPos, msg, sequenceInd
248
248
line . attr ( 'y1' , verticalPos )
249
249
line . attr ( 'x2' , stopx )
250
250
line . attr ( 'y2' , verticalPos )
251
- bounds . insert ( startx , bounds . getVerticalPos ( ) - 10 + totalOffset , stopx , bounds . getVerticalPos ( ) ) + totalOffset
251
+ bounds . insert ( startx , bounds . getVerticalPos ( ) - 10 + totalOffset , stopx , bounds . getVerticalPos ( ) + totalOffset )
252
252
}
253
253
// Make an SVG Container
254
254
// Draw the line
0 commit comments