mathjax / MathJax-src

MathJax source code for version 3 and beyond

Home Page:https://www.mathjax.org/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

develop branch: text content leading space

pkra opened this issue · comments

I was working with the develop branch and ran into this rendering:

image

This came from \sigma(s) := \{ t \in S: s\cdot t \text{ is defined} \}.

with the latest release I get

image

I'm not able to reproduce that. Both branches produce identical results (your latter image) for me. Did you recompile the typescript after changing branches? (And rebuild the components, if you are using those?)

Thanks. I also can't reproduce this with a simpler setup. (Yes, I did compile everything.) Let me see...

Yes, I did compile everything.

I figured, but I sometimes forget.

Let me know what you find out.

I use SRE to enrich things "manually".

<math xmlns="http://www.w3.org/1998/Math/MathML" display="block" data-semantic-type="infixop" data-semantic-role="unknown" data-semantic-id="24" data-semantic-children="23,21" data-semantic-content="4" data-semantic-owns="23 4 21" data-semantic-structure="(24 (23 0 22 (15 1 2 3)) 4 (21 5 (20 (16 6 7 8) 9 (19 (17 10 11 12) 13)) 14))" data-semantic-speech="sigma left parenthesis s right parenthesis colon equals StartSet t element of upper S colon s dot t is defined EndSet"><mrow data-semantic-type="appl" data-semantic-role="simple function" data-semantic-annotation="clearspeak:simple" data-semantic-id="23" data-semantic-children="0,15" data-semantic-content="22,0" data-semantic-parent="24" data-semantic-owns="0 22 15" data-semantic-speech="sigma left parenthesis s right parenthesis"><mi data-semantic-type="identifier" data-semantic-role="simple function" data-semantic-font="italic" data-semantic-annotation="clearspeak:simple;nemeth:number" data-semantic-id="0" data-semantic-parent="23" data-semantic-operator="appl" data-semantic-speech="sigma">σ</mi><mo data-semantic-type="punctuation" data-semantic-role="application" data-semantic-id="22" data-semantic-parent="23" data-semantic-added="true" data-semantic-operator="appl" data-semantic-speech="of">⁡</mo><mrow data-semantic-type="fenced" data-semantic-role="leftright" data-semantic-id="15" data-semantic-children="2" data-semantic-content="1,3" data-semantic-parent="23" data-semantic-owns="1 2 3" data-semantic-speech="left parenthesis s right parenthesis"><mo stretchy="false" data-semantic-type="fence" data-semantic-role="open" data-semantic-id="1" data-semantic-parent="15" data-semantic-operator="fenced" data-semantic-speech="left parenthesis">(</mo><mi data-semantic-type="identifier" data-semantic-role="latinletter" data-semantic-font="italic" data-semantic-annotation="clearspeak:simple;nemeth:number" data-semantic-id="2" data-semantic-parent="15" data-semantic-speech="s">s</mi><mo stretchy="false" data-semantic-type="fence" data-semantic-role="close" data-semantic-id="3" data-semantic-parent="15" data-semantic-operator="fenced" data-semantic-speech="right parenthesis">)</mo></mrow></mrow><mo data-semantic-type="operator" data-semantic-role="unknown" data-semantic-id="4" data-semantic-parent="24" data-semantic-operator="infixop,:=" data-semantic-speech="colon equals">:=</mo><mrow data-semantic-type="fenced" data-semantic-role="set extended" data-semantic-id="21" data-semantic-children="20" data-semantic-content="5,14" data-semantic-parent="24" data-semantic-owns="5 20 14" data-semantic-speech="StartSet t element of upper S colon s dot t is defined EndSet"><mo fence="false" stretchy="false" data-semantic-type="fence" data-semantic-role="open" data-semantic-id="5" data-semantic-parent="21" data-semantic-operator="fenced" data-semantic-speech="left brace">{</mo><mrow data-semantic-type="punctuated" data-semantic-role="sequence" data-semantic-id="20" data-semantic-children="16,9,19" data-semantic-content="9" data-semantic-parent="21" data-semantic-owns="16 9 19" data-semantic-speech="t element of upper S colon s dot t is defined"><mrow data-semantic-type="infixop" data-semantic-role="unknown" data-semantic-id="16" data-semantic-children="6,8" data-semantic-content="7" data-semantic-parent="20" data-semantic-owns="6 7 8" data-semantic-speech="t element of upper S"><mi data-semantic-type="identifier" data-semantic-role="latinletter" data-semantic-font="italic" data-semantic-annotation="clearspeak:simple;nemeth:number" data-semantic-id="6" data-semantic-parent="16" data-semantic-speech="t">t</mi><mo data-semantic-type="operator" data-semantic-role="set extended" data-semantic-id="7" data-semantic-parent="16" data-semantic-operator="infixop,∈" data-semantic-speech="element of">∈</mo><mi data-semantic-type="identifier" data-semantic-role="latinletter" data-semantic-font="italic" data-semantic-annotation="clearspeak:simple" data-semantic-id="8" data-semantic-parent="16" data-semantic-speech="upper S">S</mi></mrow><mo data-semantic-type="punctuation" data-semantic-role="colon" data-semantic-annotation="nemeth:number" data-semantic-id="9" data-semantic-parent="20" data-semantic-operator="punctuated" data-semantic-speech="colon">:</mo><mrow data-semantic-type="punctuated" data-semantic-role="text" data-semantic-id="19" data-semantic-children="17,13" data-semantic-parent="20" data-semantic-collapsed="(19 (c 18) 17 13)" data-semantic-owns="17 13" data-semantic-speech="s dot t is defined"><mrow data-semantic-type="infixop" data-semantic-role="multiplication" data-semantic-id="17" data-semantic-children="10,12" data-semantic-content="11" data-semantic-parent="19" data-semantic-owns="10 11 12" data-semantic-speech="s dot t"><mi data-semantic-type="identifier" data-semantic-role="latinletter" data-semantic-font="italic" data-semantic-annotation="clearspeak:simple;nemeth:number" data-semantic-id="10" data-semantic-parent="17" data-semantic-speech="s">s</mi><mo data-semantic-type="operator" data-semantic-role="multiplication" data-semantic-id="11" data-semantic-parent="17" data-semantic-operator="infixop,⋅" data-semantic-speech="dot">⋅</mo><mi data-semantic-type="identifier" data-semantic-role="latinletter" data-semantic-font="italic" data-semantic-annotation="clearspeak:simple" data-semantic-id="12" data-semantic-parent="17" data-semantic-speech="t">t</mi></mrow><mtext data-semantic-type="text" data-semantic-role="unknown" data-semantic-font="normal" data-semantic-annotation="clearspeak:unit;nemeth:number" data-semantic-id="13" data-semantic-parent="19" data-semantic-speech="is defined"> is defined</mtext></mrow></mrow><mo fence="false" stretchy="false" data-semantic-type="fence" data-semantic-role="close" data-semantic-id="14" data-semantic-parent="21" data-semantic-operator="fenced" data-semantic-speech="right brace">}</mo></mrow></math>
<mjx-container class="MathJax" jax="SVG" display="true"><svg style="vertical-align: -0.566ex" xmlns="http://www.w3.org/2000/svg" width="29.4ex" height="2.262ex" role="img" focusable="false" viewBox="0 -750 12995 1000" xmlns:xlink="http://www.w3.org/1999/xlink"><defs><path id="MJX-1-TEX-I-1D70E" d="M184 -11Q116 -11 74 34T31 147Q31 247 104 333T274 430Q275 431 414 431H552Q553 430 555 429T559 427T562 425T565 422T567 420T569 416T570 412T571 407T572 401Q572 357 507 357Q500 357 490 357T476 358H416L421 348Q439 310 439 263Q439 153 359 71T184 -11ZM361 278Q361 358 276 358Q152 358 115 184Q114 180 114 178Q106 141 106 117Q106 67 131 47T188 26Q242 26 287 73Q316 103 334 153T356 233T361 278Z"></path><path id="MJX-1-TEX-N-2061" d=""></path><path id="MJX-1-TEX-N-28" d="M94 250Q94 319 104 381T127 488T164 576T202 643T244 695T277 729T302 750H315H319Q333 750 333 741Q333 738 316 720T275 667T226 581T184 443T167 250T184 58T225 -81T274 -167T316 -220T333 -241Q333 -250 318 -250H315H302L274 -226Q180 -141 137 -14T94 250Z"></path><path id="MJX-1-TEX-I-1D460" d="M131 289Q131 321 147 354T203 415T300 442Q362 442 390 415T419 355Q419 323 402 308T364 292Q351 292 340 300T328 326Q328 342 337 354T354 372T367 378Q368 378 368 379Q368 382 361 388T336 399T297 405Q249 405 227 379T204 326Q204 301 223 291T278 274T330 259Q396 230 396 163Q396 135 385 107T352 51T289 7T195 -10Q118 -10 86 19T53 87Q53 126 74 143T118 160Q133 160 146 151T160 120Q160 94 142 76T111 58Q109 57 108 57T107 55Q108 52 115 47T146 34T201 27Q237 27 263 38T301 66T318 97T323 122Q323 150 302 164T254 181T195 196T148 231Q131 256 131 289Z"></path><path id="MJX-1-TEX-N-29" d="M60 749L64 750Q69 750 74 750H86L114 726Q208 641 251 514T294 250Q294 182 284 119T261 12T224 -76T186 -143T145 -194T113 -227T90 -246Q87 -249 86 -250H74Q66 -250 63 -250T58 -247T55 -238Q56 -237 66 -225Q221 -64 221 250T66 725Q56 737 55 738Q55 746 60 749Z"></path><path id="MJX-1-TEX-N-3A" d="M78 370Q78 394 95 412T138 430Q162 430 180 414T199 371Q199 346 182 328T139 310T96 327T78 370ZM78 60Q78 84 95 102T138 120Q162 120 180 104T199 61Q199 36 182 18T139 0T96 17T78 60Z"></path><path id="MJX-1-TEX-N-3D" d="M56 347Q56 360 70 367H707Q722 359 722 347Q722 336 708 328L390 327H72Q56 332 56 347ZM56 153Q56 168 72 173H708Q722 163 722 153Q722 140 707 133H70Q56 140 56 153Z"></path><path id="MJX-1-TEX-N-7B" d="M434 -231Q434 -244 428 -250H410Q281 -250 230 -184Q225 -177 222 -172T217 -161T213 -148T211 -133T210 -111T209 -84T209 -47T209 0Q209 21 209 53Q208 142 204 153Q203 154 203 155Q189 191 153 211T82 231Q71 231 68 234T65 250T68 266T82 269Q116 269 152 289T203 345Q208 356 208 377T209 529V579Q209 634 215 656T244 698Q270 724 324 740Q361 748 377 749Q379 749 390 749T408 750H428Q434 744 434 732Q434 719 431 716Q429 713 415 713Q362 710 332 689T296 647Q291 634 291 499V417Q291 370 288 353T271 314Q240 271 184 255L170 250L184 245Q202 239 220 230T262 196T290 137Q291 131 291 1Q291 -134 296 -147Q306 -174 339 -192T415 -213Q429 -213 431 -216Q434 -219 434 -231Z"></path><path id="MJX-1-TEX-I-1D461" d="M26 385Q19 392 19 395Q19 399 22 411T27 425Q29 430 36 430T87 431H140L159 511Q162 522 166 540T173 566T179 586T187 603T197 615T211 624T229 626Q247 625 254 615T261 596Q261 589 252 549T232 470L222 433Q222 431 272 431H323Q330 424 330 420Q330 398 317 385H210L174 240Q135 80 135 68Q135 26 162 26Q197 26 230 60T283 144Q285 150 288 151T303 153H307Q322 153 322 145Q322 142 319 133Q314 117 301 95T267 48T216 6T155 -11Q125 -11 98 4T59 56Q57 64 57 83V101L92 241Q127 382 128 383Q128 385 77 385H26Z"></path><path id="MJX-1-TEX-N-2208" d="M84 250Q84 372 166 450T360 539Q361 539 377 539T419 540T469 540H568Q583 532 583 520Q583 511 570 501L466 500Q355 499 329 494Q280 482 242 458T183 409T147 354T129 306T124 272V270H568Q583 262 583 250T568 230H124V228Q124 207 134 177T167 112T231 48T328 7Q355 1 466 0H570Q583 -10 583 -20Q583 -32 568 -40H471Q464 -40 446 -40T417 -41Q262 -41 172 45Q84 127 84 250Z"></path><path id="MJX-1-TEX-I-1D446" d="M308 24Q367 24 416 76T466 197Q466 260 414 284Q308 311 278 321T236 341Q176 383 176 462Q176 523 208 573T273 648Q302 673 343 688T407 704H418H425Q521 704 564 640Q565 640 577 653T603 682T623 704Q624 704 627 704T632 705Q645 705 645 698T617 577T585 459T569 456Q549 456 549 465Q549 471 550 475Q550 478 551 494T553 520Q553 554 544 579T526 616T501 641Q465 662 419 662Q362 662 313 616T263 510Q263 480 278 458T319 427Q323 425 389 408T456 390Q490 379 522 342T554 242Q554 216 546 186Q541 164 528 137T492 78T426 18T332 -20Q320 -22 298 -22Q199 -22 144 33L134 44L106 13Q83 -14 78 -18T65 -22Q52 -22 52 -14Q52 -11 110 221Q112 227 130 227H143Q149 221 149 216Q149 214 148 207T144 186T142 153Q144 114 160 87T203 47T255 29T308 24Z"></path><path id="MJX-1-TEX-N-22C5" d="M78 250Q78 274 95 292T138 310Q162 310 180 294T199 251Q199 226 182 208T139 190T96 207T78 250Z"></path><path id="MJX-1-TEX-N-69" d="M69 609Q69 637 87 653T131 669Q154 667 171 652T188 609Q188 579 171 564T129 549Q104 549 87 564T69 609ZM247 0Q232 3 143 3Q132 3 106 3T56 1L34 0H26V46H42Q70 46 91 49Q100 53 102 60T104 102V205V293Q104 345 102 359T88 378Q74 385 41 385H30V408Q30 431 32 431L42 432Q52 433 70 434T106 436Q123 437 142 438T171 441T182 442H185V62Q190 52 197 50T232 46H255V0H247Z"></path><path id="MJX-1-TEX-N-73" d="M295 316Q295 356 268 385T190 414Q154 414 128 401Q98 382 98 349Q97 344 98 336T114 312T157 287Q175 282 201 278T245 269T277 256Q294 248 310 236T342 195T359 133Q359 71 321 31T198 -10H190Q138 -10 94 26L86 19L77 10Q71 4 65 -1L54 -11H46H42Q39 -11 33 -5V74V132Q33 153 35 157T45 162H54Q66 162 70 158T75 146T82 119T101 77Q136 26 198 26Q295 26 295 104Q295 133 277 151Q257 175 194 187T111 210Q75 227 54 256T33 318Q33 357 50 384T93 424T143 442T187 447H198Q238 447 268 432L283 424L292 431Q302 440 314 448H322H326Q329 448 335 442V310L329 304H301Q295 310 295 316Z"></path><path id="MJX-1-TEX-N-20" d=""></path><path id="MJX-1-TEX-N-64" d="M376 495Q376 511 376 535T377 568Q377 613 367 624T316 637H298V660Q298 683 300 683L310 684Q320 685 339 686T376 688Q393 689 413 690T443 693T454 694H457V390Q457 84 458 81Q461 61 472 55T517 46H535V0Q533 0 459 -5T380 -11H373V44L365 37Q307 -11 235 -11Q158 -11 96 50T34 215Q34 315 97 378T244 442Q319 442 376 393V495ZM373 342Q328 405 260 405Q211 405 173 369Q146 341 139 305T131 211Q131 155 138 120T173 59Q203 26 251 26Q322 26 373 103V342Z"></path><path id="MJX-1-TEX-N-65" d="M28 218Q28 273 48 318T98 391T163 433T229 448Q282 448 320 430T378 380T406 316T415 245Q415 238 408 231H126V216Q126 68 226 36Q246 30 270 30Q312 30 342 62Q359 79 369 104L379 128Q382 131 395 131H398Q415 131 415 121Q415 117 412 108Q393 53 349 21T250 -11Q155 -11 92 58T28 218ZM333 275Q322 403 238 411H236Q228 411 220 410T195 402T166 381T143 340T127 274V267H333V275Z"></path><path id="MJX-1-TEX-N-66" d="M273 0Q255 3 146 3Q43 3 34 0H26V46H42Q70 46 91 49Q99 52 103 60Q104 62 104 224V385H33V431H104V497L105 564L107 574Q126 639 171 668T266 704Q267 704 275 704T289 705Q330 702 351 679T372 627Q372 604 358 590T321 576T284 590T270 627Q270 647 288 667H284Q280 668 273 668Q245 668 223 647T189 592Q183 572 182 497V431H293V385H185V225Q185 63 186 61T189 57T194 54T199 51T206 49T213 48T222 47T231 47T241 46T251 46H282V0H273Z"></path><path id="MJX-1-TEX-N-6E" d="M41 46H55Q94 46 102 60V68Q102 77 102 91T102 122T103 161T103 203Q103 234 103 269T102 328V351Q99 370 88 376T43 385H25V408Q25 431 27 431L37 432Q47 433 65 434T102 436Q119 437 138 438T167 441T178 442H181V402Q181 364 182 364T187 369T199 384T218 402T247 421T285 437Q305 442 336 442Q450 438 463 329Q464 322 464 190V104Q464 66 466 59T477 49Q498 46 526 46H542V0H534L510 1Q487 2 460 2T422 3Q319 3 310 0H302V46H318Q379 46 379 62Q380 64 380 200Q379 335 378 343Q372 371 358 385T334 402T308 404Q263 404 229 370Q202 343 195 315T187 232V168V108Q187 78 188 68T191 55T200 49Q221 46 249 46H265V0H257L234 1Q210 2 183 2T145 3Q42 3 33 0H25V46H41Z"></path><path id="MJX-1-TEX-N-7D" d="M65 731Q65 745 68 747T88 750Q171 750 216 725T279 670Q288 649 289 635T291 501Q292 362 293 357Q306 312 345 291T417 269Q428 269 431 266T434 250T431 234T417 231Q380 231 345 210T298 157Q293 143 292 121T291 -28V-79Q291 -134 285 -156T256 -198Q202 -250 89 -250Q71 -250 68 -247T65 -230Q65 -224 65 -223T66 -218T69 -214T77 -213Q91 -213 108 -210T146 -200T183 -177T207 -139Q208 -134 209 3L210 139Q223 196 280 230Q315 247 330 250Q305 257 280 270Q225 304 212 352L210 362L209 498Q208 635 207 640Q195 680 154 696T77 713Q68 713 67 716T65 731Z"></path></defs><g stroke="currentColor" fill="currentColor" stroke-width="0" transform="matrix(1 0 0 -1 0 0)"><g data-mml-node="math" data-semantic-type="infixop" data-semantic-role="unknown" data-semantic-id="24" data-semantic-children="23,21" data-semantic-content="4" data-semantic-owns="23 4 21" data-semantic-structure="(24 (23 0 22 (15 1 2 3)) 4 (21 5 (20 (16 6 7 8) 9 (19 (17 10 11 12) 13)) 14))" data-semantic-speech="sigma left parenthesis s right parenthesis colon equals StartSet t element of upper S colon s dot t is defined EndSet"><g data-mml-node="mrow" data-semantic-type="appl" data-semantic-role="simple function" data-semantic-annotation="clearspeak:simple" data-semantic-id="23" data-semantic-children="0,15" data-semantic-content="22,0" data-semantic-parent="24" data-semantic-owns="0 22 15" data-semantic-speech="sigma left parenthesis s right parenthesis"><g data-mml-node="mi" data-semantic-type="identifier" data-semantic-role="simple function" data-semantic-font="italic" data-semantic-annotation="clearspeak:simple;nemeth:number" data-semantic-id="0" data-semantic-parent="23" data-semantic-operator="appl" data-semantic-speech="sigma"><use xlink:href="#MJX-1-TEX-I-1D70E"></use></g><g data-mml-node="mo" data-semantic-type="punctuation" data-semantic-role="application" data-semantic-id="22" data-semantic-parent="23" data-semantic-added="true" data-semantic-operator="appl" data-semantic-speech="of" transform="translate(571, 0)"><use xlink:href="#MJX-1-TEX-N-2061"></use></g><g data-mml-node="mrow" data-semantic-type="fenced" data-semantic-role="leftright" data-semantic-id="15" data-semantic-children="2" data-semantic-content="1,3" data-semantic-parent="23" data-semantic-owns="1 2 3" data-semantic-speech="left parenthesis s right parenthesis" transform="translate(571, 0)"><g data-mml-node="mo" data-semantic-type="fence" data-semantic-role="open" data-semantic-id="1" data-semantic-parent="15" data-semantic-operator="fenced" data-semantic-speech="left parenthesis"><use xlink:href="#MJX-1-TEX-N-28"></use></g><g data-mml-node="mi" data-semantic-type="identifier" data-semantic-role="latinletter" data-semantic-font="italic" data-semantic-annotation="clearspeak:simple;nemeth:number" data-semantic-id="2" data-semantic-parent="15" data-semantic-speech="s" transform="translate(389, 0)"><use xlink:href="#MJX-1-TEX-I-1D460"></use></g><g data-mml-node="mo" data-semantic-type="fence" data-semantic-role="close" data-semantic-id="3" data-semantic-parent="15" data-semantic-operator="fenced" data-semantic-speech="right parenthesis" transform="translate(858, 0)"><use xlink:href="#MJX-1-TEX-N-29"></use></g></g></g><g data-mml-node="mo" data-semantic-type="operator" data-semantic-role="unknown" data-semantic-id="4" data-semantic-parent="24" data-semantic-operator="infixop,:=" data-semantic-speech="colon equals" transform="translate(2040.2, 0)"><use xlink:href="#MJX-1-TEX-N-3A"></use><use xlink:href="#MJX-1-TEX-N-3D" transform="translate(278, 0)"></use></g><g data-mml-node="mrow" data-semantic-type="fenced" data-semantic-role="set extended" data-semantic-id="21" data-semantic-children="20" data-semantic-content="5,14" data-semantic-parent="24" data-semantic-owns="5 20 14" data-semantic-speech="StartSet t element of upper S colon s dot t is defined EndSet" transform="translate(3318.4, 0)"><g data-mml-node="mo" data-semantic-type="fence" data-semantic-role="open" data-semantic-id="5" data-semantic-parent="21" data-semantic-operator="fenced" data-semantic-speech="left brace"><use xlink:href="#MJX-1-TEX-N-7B"></use></g><g data-mml-node="mrow" data-semantic-type="punctuated" data-semantic-role="sequence" data-semantic-id="20" data-semantic-children="16,9,19" data-semantic-content="9" data-semantic-parent="21" data-semantic-owns="16 9 19" data-semantic-speech="t element of upper S colon s dot t is defined" transform="translate(500, 0)"><g data-mml-node="mrow" data-semantic-type="infixop" data-semantic-role="unknown" data-semantic-id="16" data-semantic-children="6,8" data-semantic-content="7" data-semantic-parent="20" data-semantic-owns="6 7 8" data-semantic-speech="t element of upper S"><g data-mml-node="mi" data-semantic-type="identifier" data-semantic-role="latinletter" data-semantic-font="italic" data-semantic-annotation="clearspeak:simple;nemeth:number" data-semantic-id="6" data-semantic-parent="16" data-semantic-speech="t"><use xlink:href="#MJX-1-TEX-I-1D461"></use></g><g data-mml-node="mo" data-semantic-type="operator" data-semantic-role="set extended" data-semantic-id="7" data-semantic-parent="16" data-semantic-operator="infixop,∈" data-semantic-speech="element of" transform="translate(638.8, 0)"><use xlink:href="#MJX-1-TEX-N-2208"></use></g><g data-mml-node="mi" data-semantic-type="identifier" data-semantic-role="latinletter" data-semantic-font="italic" data-semantic-annotation="clearspeak:simple" data-semantic-id="8" data-semantic-parent="16" data-semantic-speech="upper S" transform="translate(1583.6, 0)"><use xlink:href="#MJX-1-TEX-I-1D446"></use></g></g><g data-mml-node="mo" data-semantic-type="punctuation" data-semantic-role="colon" data-semantic-annotation="nemeth:number" data-semantic-id="9" data-semantic-parent="20" data-semantic-operator="punctuated" data-semantic-speech="colon" transform="translate(2506.3, 0)"><use xlink:href="#MJX-1-TEX-N-3A"></use></g><g data-mml-node="mrow" data-semantic-type="punctuated" data-semantic-role="text" data-semantic-id="19" data-semantic-children="17,13" data-semantic-parent="20" data-semantic-collapsed="(19 (c 18) 17 13)" data-semantic-owns="17 13" data-semantic-speech="s dot t is defined" transform="translate(3062.1, 0)"><g data-mml-node="mrow" data-semantic-type="infixop" data-semantic-role="multiplication" data-semantic-id="17" data-semantic-children="10,12" data-semantic-content="11" data-semantic-parent="19" data-semantic-owns="10 11 12" data-semantic-speech="s dot t"><g data-mml-node="mi" data-semantic-type="identifier" data-semantic-role="latinletter" data-semantic-font="italic" data-semantic-annotation="clearspeak:simple;nemeth:number" data-semantic-id="10" data-semantic-parent="17" data-semantic-speech="s"><use xlink:href="#MJX-1-TEX-I-1D460"></use></g><g data-mml-node="mo" data-semantic-type="operator" data-semantic-role="multiplication" data-semantic-id="11" data-semantic-parent="17" data-semantic-operator="infixop,⋅" data-semantic-speech="dot" transform="translate(691.2, 0)"><use xlink:href="#MJX-1-TEX-N-22C5"></use></g><g data-mml-node="mi" data-semantic-type="identifier" data-semantic-role="latinletter" data-semantic-font="italic" data-semantic-annotation="clearspeak:simple" data-semantic-id="12" data-semantic-parent="17" data-semantic-speech="t" transform="translate(1191.4, 0)"><use xlink:href="#MJX-1-TEX-I-1D461"></use></g></g><g data-mml-node="mtext" data-semantic-type="text" data-semantic-role="unknown" data-semantic-font="normal" data-semantic-annotation="clearspeak:unit;nemeth:number" data-semantic-id="13" data-semantic-parent="19" data-semantic-speech="is defined" transform="translate(1552.4, 0)"><use xlink:href="#MJX-1-TEX-N-69"></use><use xlink:href="#MJX-1-TEX-N-73" transform="translate(278, 0)"></use><use xlink:href="#MJX-1-TEX-N-20" transform="translate(672, 0)"></use><use xlink:href="#MJX-1-TEX-N-64" transform="translate(922, 0)"></use><use xlink:href="#MJX-1-TEX-N-65" transform="translate(1478, 0)"></use><use xlink:href="#MJX-1-TEX-N-66" transform="translate(1922, 0)"></use><use xlink:href="#MJX-1-TEX-N-69" transform="translate(2228, 0)"></use><use xlink:href="#MJX-1-TEX-N-6E" transform="translate(2506, 0)"></use><use xlink:href="#MJX-1-TEX-N-65" transform="translate(3062, 0)"></use><use xlink:href="#MJX-1-TEX-N-64" transform="translate(3506, 0)"></use></g></g></g><g data-mml-node="mo" data-semantic-type="fence" data-semantic-role="close" data-semantic-id="14" data-semantic-parent="21" data-semantic-operator="fenced" data-semantic-speech="right brace" transform="translate(9176.6, 0)"><use xlink:href="#MJX-1-TEX-N-7D"></use></g></g></g></g></svg></mjx-container>

Can you reproduce that by any chance?

OK, I can reproduce when the input is MathML rather than TeX. Looks like the <mtext> element is trimming the text incorrectly in the MathML input jax. During the enrichment, the MathML is serialized to send to SRE, and its result is parsed by the MathML input jax to turn it into the internal form again. That appears to be where the problem is occurring.

I'll check into it.

Are you working with TeX or MathML originally? The TeX \text{ is defined} should produce <mtext>&#xA0;is defined</mtext>, which is processed correctly through MathML input jax and SRE. But <mtext> is defined</mtext> does lose the initial space, as it is supposed to. Can you check if the MathML that you are enhancing has the U+00A0 rather than U+0020 as the first character. (You have given the enhanced MathML not the original MathML, and the space has already been moved by then).

I'm working with TeX originally. Here's what I get in between - seems like I'm missing &#xA0; right away.

\sigma(s) := \{ t \in S: s\cdot t \text{ is defined} \}
<math xmlns="http://www.w3.org/1998/Math/MathML" display="block">
  <mi>&#x3C3;</mi>
  <mo stretchy="false">(</mo>
  <mi>s</mi>
  <mo stretchy="false">)</mo>
  <mo>:=</mo>
  <mo fence="false" stretchy="false">{</mo>
  <mi>t</mi>
  <mo>&#x2208;</mo>
  <mi>S</mi>
  <mo>:</mo>
  <mi>s</mi>
  <mo>&#x22C5;</mo>
  <mi>t</mi>
  <mtext> is defined</mtext>
  <mo fence="false" stretchy="false">}</mo>
</math> 
<math xmlns="http://www.w3.org/1998/Math/MathML" display="block" data-semantic-type="infixop" data-semantic-role="unknown" data-semantic-id="24" data-semantic-children="23,21" data-semantic-content="4" data-semantic-owns="23 4 21" data-semantic-structure="(24 (23 0 22 (15 1 2 3)) 4 (21 5 (20 (16 6 7 8) 9 (19 (17 10 11 12) 13)) 14))" data-semantic-speech="sigma left parenthesis s right parenthesis colon equals StartSet t element of upper S colon s dot t is defined EndSet"><mrow data-semantic-type="appl" data-semantic-role="simple function" data-semantic-annotation="clearspeak:simple" data-semantic-id="23" data-semantic-children="0,15" data-semantic-content="22,0" data-semantic-parent="24" data-semantic-owns="0 22 15" data-semantic-speech="sigma left parenthesis s right parenthesis"><mi data-semantic-type="identifier" data-semantic-role="simple function" data-semantic-font="italic" data-semantic-annotation="clearspeak:simple;nemeth:number" data-semantic-id="0" data-semantic-parent="23" data-semantic-operator="appl" data-semantic-speech="sigma">σ</mi><mo data-semantic-type="punctuation" data-semantic-role="application" data-semantic-id="22" data-semantic-parent="23" data-semantic-added="true" data-semantic-operator="appl" data-semantic-speech="of">⁡</mo><mrow data-semantic-type="fenced" data-semantic-role="leftright" data-semantic-id="15" data-semantic-children="2" data-semantic-content="1,3" data-semantic-parent="23" data-semantic-owns="1 2 3" data-semantic-speech="left parenthesis s right parenthesis"><mo stretchy="false" data-semantic-type="fence" data-semantic-role="open" data-semantic-id="1" data-semantic-parent="15" data-semantic-operator="fenced" data-semantic-speech="left parenthesis">(</mo><mi data-semantic-type="identifier" data-semantic-role="latinletter" data-semantic-font="italic" data-semantic-annotation="clearspeak:simple;nemeth:number" data-semantic-id="2" data-semantic-parent="15" data-semantic-speech="s">s</mi><mo stretchy="false" data-semantic-type="fence" data-semantic-role="close" data-semantic-id="3" data-semantic-parent="15" data-semantic-operator="fenced" data-semantic-speech="right parenthesis">)</mo></mrow></mrow><mo data-semantic-type="operator" data-semantic-role="unknown" data-semantic-id="4" data-semantic-parent="24" data-semantic-operator="infixop,:=" data-semantic-speech="colon equals">:=</mo><mrow data-semantic-type="fenced" data-semantic-role="set extended" data-semantic-id="21" data-semantic-children="20" data-semantic-content="5,14" data-semantic-parent="24" data-semantic-owns="5 20 14" data-semantic-speech="StartSet t element of upper S colon s dot t is defined EndSet"><mo fence="false" stretchy="false" data-semantic-type="fence" data-semantic-role="open" data-semantic-id="5" data-semantic-parent="21" data-semantic-operator="fenced" data-semantic-speech="left brace">{</mo><mrow data-semantic-type="punctuated" data-semantic-role="sequence" data-semantic-id="20" data-semantic-children="16,9,19" data-semantic-content="9" data-semantic-parent="21" data-semantic-owns="16 9 19" data-semantic-speech="t element of upper S colon s dot t is defined"><mrow data-semantic-type="infixop" data-semantic-role="unknown" data-semantic-id="16" data-semantic-children="6,8" data-semantic-content="7" data-semantic-parent="20" data-semantic-owns="6 7 8" data-semantic-speech="t element of upper S"><mi data-semantic-type="identifier" data-semantic-role="latinletter" data-semantic-font="italic" data-semantic-annotation="clearspeak:simple;nemeth:number" data-semantic-id="6" data-semantic-parent="16" data-semantic-speech="t">t</mi><mo data-semantic-type="operator" data-semantic-role="set extended" data-semantic-id="7" data-semantic-parent="16" data-semantic-operator="infixop,∈" data-semantic-speech="element of">∈</mo><mi data-semantic-type="identifier" data-semantic-role="latinletter" data-semantic-font="italic" data-semantic-annotation="clearspeak:simple" data-semantic-id="8" data-semantic-parent="16" data-semantic-speech="upper S">S</mi></mrow><mo data-semantic-type="punctuation" data-semantic-role="colon" data-semantic-annotation="nemeth:number" data-semantic-id="9" data-semantic-parent="20" data-semantic-operator="punctuated" data-semantic-speech="colon">:</mo><mrow data-semantic-type="punctuated" data-semantic-role="text" data-semantic-id="19" data-semantic-children="17,13" data-semantic-parent="20" data-semantic-collapsed="(19 (c 18) 17 13)" data-semantic-owns="17 13" data-semantic-speech="s dot t is defined"><mrow data-semantic-type="infixop" data-semantic-role="multiplication" data-semantic-id="17" data-semantic-children="10,12" data-semantic-content="11" data-semantic-parent="19" data-semantic-owns="10 11 12" data-semantic-speech="s dot t"><mi data-semantic-type="identifier" data-semantic-role="latinletter" data-semantic-font="italic" data-semantic-annotation="clearspeak:simple;nemeth:number" data-semantic-id="10" data-semantic-parent="17" data-semantic-speech="s">s</mi><mo data-semantic-type="operator" data-semantic-role="multiplication" data-semantic-id="11" data-semantic-parent="17" data-semantic-operator="infixop,⋅" data-semantic-speech="dot">⋅</mo><mi data-semantic-type="identifier" data-semantic-role="latinletter" data-semantic-font="italic" data-semantic-annotation="clearspeak:simple" data-semantic-id="12" data-semantic-parent="17" data-semantic-speech="t">t</mi></mrow><mtext data-semantic-type="text" data-semantic-role="unknown" data-semantic-font="normal" data-semantic-annotation="clearspeak:unit;nemeth:number" data-semantic-id="13" data-semantic-parent="19" data-semantic-speech="is defined"> is defined</mtext></mrow></mrow><mo fence="false" stretchy="false" data-semantic-type="fence" data-semantic-role="close" data-semantic-id="14" data-semantic-parent="21" data-semantic-operator="fenced" data-semantic-speech="right brace">}</mo></mrow></math>
<mjx-container class="MathJax" jax="SVG" display="true"><svg style="vertical-align: -0.566ex;" xmlns="http://www.w3.org/2000/svg" width="29.778ex" height="2.262ex" role="img" focusable="false" viewBox="0 -750 13161.7 1000" xmlns:xlink="http://www.w3.org/1999/xlink"><defs><path id="MJX-1-TEX-I-1D70E" d="M184 -11Q116 -11 74 34T31 147Q31 247 104 333T274 430Q275 431 414 431H552Q553 430 555 429T559 427T562 425T565 422T567 420T569 416T570 412T571 407T572 401Q572 357 507 357Q500 357 490 357T476 358H416L421 348Q439 310 439 263Q439 153 359 71T184 -11ZM361 278Q361 358 276 358Q152 358 115 184Q114 180 114 178Q106 141 106 117Q106 67 131 47T188 26Q242 26 287 73Q316 103 334 153T356 233T361 278Z"></path><path id="MJX-1-TEX-N-2061" d=""></path><path id="MJX-1-TEX-N-28" d="M94 250Q94 319 104 381T127 488T164 576T202 643T244 695T277 729T302 750H315H319Q333 750 333 741Q333 738 316 720T275 667T226 581T184 443T167 250T184 58T225 -81T274 -167T316 -220T333 -241Q333 -250 318 -250H315H302L274 -226Q180 -141 137 -14T94 250Z"></path><path id="MJX-1-TEX-I-1D460" d="M131 289Q131 321 147 354T203 415T300 442Q362 442 390 415T419 355Q419 323 402 308T364 292Q351 292 340 300T328 326Q328 342 337 354T354 372T367 378Q368 378 368 379Q368 382 361 388T336 399T297 405Q249 405 227 379T204 326Q204 301 223 291T278 274T330 259Q396 230 396 163Q396 135 385 107T352 51T289 7T195 -10Q118 -10 86 19T53 87Q53 126 74 143T118 160Q133 160 146 151T160 120Q160 94 142 76T111 58Q109 57 108 57T107 55Q108 52 115 47T146 34T201 27Q237 27 263 38T301 66T318 97T323 122Q323 150 302 164T254 181T195 196T148 231Q131 256 131 289Z"></path><path id="MJX-1-TEX-N-29" d="M60 749L64 750Q69 750 74 750H86L114 726Q208 641 251 514T294 250Q294 182 284 119T261 12T224 -76T186 -143T145 -194T113 -227T90 -246Q87 -249 86 -250H74Q66 -250 63 -250T58 -247T55 -238Q56 -237 66 -225Q221 -64 221 250T66 725Q56 737 55 738Q55 746 60 749Z"></path><path id="MJX-1-TEX-N-3A" d="M78 370Q78 394 95 412T138 430Q162 430 180 414T199 371Q199 346 182 328T139 310T96 327T78 370ZM78 60Q78 84 95 102T138 120Q162 120 180 104T199 61Q199 36 182 18T139 0T96 17T78 60Z"></path><path id="MJX-1-TEX-N-3D" d="M56 347Q56 360 70 367H707Q722 359 722 347Q722 336 708 328L390 327H72Q56 332 56 347ZM56 153Q56 168 72 173H708Q722 163 722 153Q722 140 707 133H70Q56 140 56 153Z"></path><path id="MJX-1-TEX-N-7B" d="M434 -231Q434 -244 428 -250H410Q281 -250 230 -184Q225 -177 222 -172T217 -161T213 -148T211 -133T210 -111T209 -84T209 -47T209 0Q209 21 209 53Q208 142 204 153Q203 154 203 155Q189 191 153 211T82 231Q71 231 68 234T65 250T68 266T82 269Q116 269 152 289T203 345Q208 356 208 377T209 529V579Q209 634 215 656T244 698Q270 724 324 740Q361 748 377 749Q379 749 390 749T408 750H428Q434 744 434 732Q434 719 431 716Q429 713 415 713Q362 710 332 689T296 647Q291 634 291 499V417Q291 370 288 353T271 314Q240 271 184 255L170 250L184 245Q202 239 220 230T262 196T290 137Q291 131 291 1Q291 -134 296 -147Q306 -174 339 -192T415 -213Q429 -213 431 -216Q434 -219 434 -231Z"></path><path id="MJX-1-TEX-I-1D461" d="M26 385Q19 392 19 395Q19 399 22 411T27 425Q29 430 36 430T87 431H140L159 511Q162 522 166 540T173 566T179 586T187 603T197 615T211 624T229 626Q247 625 254 615T261 596Q261 589 252 549T232 470L222 433Q222 431 272 431H323Q330 424 330 420Q330 398 317 385H210L174 240Q135 80 135 68Q135 26 162 26Q197 26 230 60T283 144Q285 150 288 151T303 153H307Q322 153 322 145Q322 142 319 133Q314 117 301 95T267 48T216 6T155 -11Q125 -11 98 4T59 56Q57 64 57 83V101L92 241Q127 382 128 383Q128 385 77 385H26Z"></path><path id="MJX-1-TEX-N-2208" d="M84 250Q84 372 166 450T360 539Q361 539 377 539T419 540T469 540H568Q583 532 583 520Q583 511 570 501L466 500Q355 499 329 494Q280 482 242 458T183 409T147 354T129 306T124 272V270H568Q583 262 583 250T568 230H124V228Q124 207 134 177T167 112T231 48T328 7Q355 1 466 0H570Q583 -10 583 -20Q583 -32 568 -40H471Q464 -40 446 -40T417 -41Q262 -41 172 45Q84 127 84 250Z"></path><path id="MJX-1-TEX-I-1D446" d="M308 24Q367 24 416 76T466 197Q466 260 414 284Q308 311 278 321T236 341Q176 383 176 462Q176 523 208 573T273 648Q302 673 343 688T407 704H418H425Q521 704 564 640Q565 640 577 653T603 682T623 704Q624 704 627 704T632 705Q645 705 645 698T617 577T585 459T569 456Q549 456 549 465Q549 471 550 475Q550 478 551 494T553 520Q553 554 544 579T526 616T501 641Q465 662 419 662Q362 662 313 616T263 510Q263 480 278 458T319 427Q323 425 389 408T456 390Q490 379 522 342T554 242Q554 216 546 186Q541 164 528 137T492 78T426 18T332 -20Q320 -22 298 -22Q199 -22 144 33L134 44L106 13Q83 -14 78 -18T65 -22Q52 -22 52 -14Q52 -11 110 221Q112 227 130 227H143Q149 221 149 216Q149 214 148 207T144 186T142 153Q144 114 160 87T203 47T255 29T308 24Z"></path><path id="MJX-1-TEX-N-22C5" d="M78 250Q78 274 95 292T138 310Q162 310 180 294T199 251Q199 226 182 208T139 190T96 207T78 250Z"></path><path id="MJX-1-TEX-N-69" d="M69 609Q69 637 87 653T131 669Q154 667 171 652T188 609Q188 579 171 564T129 549Q104 549 87 564T69 609ZM247 0Q232 3 143 3Q132 3 106 3T56 1L34 0H26V46H42Q70 46 91 49Q100 53 102 60T104 102V205V293Q104 345 102 359T88 378Q74 385 41 385H30V408Q30 431 32 431L42 432Q52 433 70 434T106 436Q123 437 142 438T171 441T182 442H185V62Q190 52 197 50T232 46H255V0H247Z"></path><path id="MJX-1-TEX-N-73" d="M295 316Q295 356 268 385T190 414Q154 414 128 401Q98 382 98 349Q97 344 98 336T114 312T157 287Q175 282 201 278T245 269T277 256Q294 248 310 236T342 195T359 133Q359 71 321 31T198 -10H190Q138 -10 94 26L86 19L77 10Q71 4 65 -1L54 -11H46H42Q39 -11 33 -5V74V132Q33 153 35 157T45 162H54Q66 162 70 158T75 146T82 119T101 77Q136 26 198 26Q295 26 295 104Q295 133 277 151Q257 175 194 187T111 210Q75 227 54 256T33 318Q33 357 50 384T93 424T143 442T187 447H198Q238 447 268 432L283 424L292 431Q302 440 314 448H322H326Q329 448 335 442V310L329 304H301Q295 310 295 316Z"></path><path id="MJX-1-TEX-N-20" d=""></path><path id="MJX-1-TEX-N-64" d="M376 495Q376 511 376 535T377 568Q377 613 367 624T316 637H298V660Q298 683 300 683L310 684Q320 685 339 686T376 688Q393 689 413 690T443 693T454 694H457V390Q457 84 458 81Q461 61 472 55T517 46H535V0Q533 0 459 -5T380 -11H373V44L365 37Q307 -11 235 -11Q158 -11 96 50T34 215Q34 315 97 378T244 442Q319 442 376 393V495ZM373 342Q328 405 260 405Q211 405 173 369Q146 341 139 305T131 211Q131 155 138 120T173 59Q203 26 251 26Q322 26 373 103V342Z"></path><path id="MJX-1-TEX-N-65" d="M28 218Q28 273 48 318T98 391T163 433T229 448Q282 448 320 430T378 380T406 316T415 245Q415 238 408 231H126V216Q126 68 226 36Q246 30 270 30Q312 30 342 62Q359 79 369 104L379 128Q382 131 395 131H398Q415 131 415 121Q415 117 412 108Q393 53 349 21T250 -11Q155 -11 92 58T28 218ZM333 275Q322 403 238 411H236Q228 411 220 410T195 402T166 381T143 340T127 274V267H333V275Z"></path><path id="MJX-1-TEX-N-66" d="M273 0Q255 3 146 3Q43 3 34 0H26V46H42Q70 46 91 49Q99 52 103 60Q104 62 104 224V385H33V431H104V497L105 564L107 574Q126 639 171 668T266 704Q267 704 275 704T289 705Q330 702 351 679T372 627Q372 604 358 590T321 576T284 590T270 627Q270 647 288 667H284Q280 668 273 668Q245 668 223 647T189 592Q183 572 182 497V431H293V385H185V225Q185 63 186 61T189 57T194 54T199 51T206 49T213 48T222 47T231 47T241 46T251 46H282V0H273Z"></path><path id="MJX-1-TEX-N-6E" d="M41 46H55Q94 46 102 60V68Q102 77 102 91T102 122T103 161T103 203Q103 234 103 269T102 328V351Q99 370 88 376T43 385H25V408Q25 431 27 431L37 432Q47 433 65 434T102 436Q119 437 138 438T167 441T178 442H181V402Q181 364 182 364T187 369T199 384T218 402T247 421T285 437Q305 442 336 442Q450 438 463 329Q464 322 464 190V104Q464 66 466 59T477 49Q498 46 526 46H542V0H534L510 1Q487 2 460 2T422 3Q319 3 310 0H302V46H318Q379 46 379 62Q380 64 380 200Q379 335 378 343Q372 371 358 385T334 402T308 404Q263 404 229 370Q202 343 195 315T187 232V168V108Q187 78 188 68T191 55T200 49Q221 46 249 46H265V0H257L234 1Q210 2 183 2T145 3Q42 3 33 0H25V46H41Z"></path><path id="MJX-1-TEX-N-7D" d="M65 731Q65 745 68 747T88 750Q171 750 216 725T279 670Q288 649 289 635T291 501Q292 362 293 357Q306 312 345 291T417 269Q428 269 431 266T434 250T431 234T417 231Q380 231 345 210T298 157Q293 143 292 121T291 -28V-79Q291 -134 285 -156T256 -198Q202 -250 89 -250Q71 -250 68 -247T65 -230Q65 -224 65 -223T66 -218T69 -214T77 -213Q91 -213 108 -210T146 -200T183 -177T207 -139Q208 -134 209 3L210 139Q223 196 280 230Q315 247 330 250Q305 257 280 270Q225 304 212 352L210 362L209 498Q208 635 207 640Q195 680 154 696T77 713Q68 713 67 716T65 731Z"></path></defs><g stroke="currentColor" fill="currentColor" stroke-width="0" transform="matrix(1 0 0 -1 0 0)"><g data-mml-node="math" data-semantic-type="infixop" data-semantic-role="unknown" data-semantic-id="24" data-semantic-children="23,21" data-semantic-content="4" data-semantic-owns="23 4 21" data-semantic-structure="(24 (23 0 22 (15 1 2 3)) 4 (21 5 (20 (16 6 7 8) 9 (19 (17 10 11 12) 13)) 14))" data-semantic-speech="sigma left parenthesis s right parenthesis colon equals StartSet t element of upper S colon s dot t is defined EndSet"><g data-mml-node="mrow" data-semantic-type="appl" data-semantic-role="simple function" data-semantic-annotation="clearspeak:simple" data-semantic-id="23" data-semantic-children="0,15" data-semantic-content="22,0" data-semantic-parent="24" data-semantic-owns="0 22 15" data-semantic-speech="sigma left parenthesis s right parenthesis"><g data-mml-node="mi" data-semantic-type="identifier" data-semantic-role="simple function" data-semantic-font="italic" data-semantic-annotation="clearspeak:simple;nemeth:number" data-semantic-id="0" data-semantic-parent="23" data-semantic-operator="appl" data-semantic-speech="sigma"><use xlink:href="#MJX-1-TEX-I-1D70E"></use></g><g data-mml-node="mo" data-semantic-type="punctuation" data-semantic-role="application" data-semantic-id="22" data-semantic-parent="23" data-semantic-added="true" data-semantic-operator="appl" data-semantic-speech="of" transform="translate(571, 0)"><use xlink:href="#MJX-1-TEX-N-2061"></use></g><g data-mml-node="mrow" data-semantic-type="fenced" data-semantic-role="leftright" data-semantic-id="15" data-semantic-children="2" data-semantic-content="1,3" data-semantic-parent="23" data-semantic-owns="1 2 3" data-semantic-speech="left parenthesis s right parenthesis" transform="translate(737.7, 0)"><g data-mml-node="mo" data-semantic-type="fence" data-semantic-role="open" data-semantic-id="1" data-semantic-parent="15" data-semantic-operator="fenced" data-semantic-speech="left parenthesis"><use xlink:href="#MJX-1-TEX-N-28"></use></g><g data-mml-node="mi" data-semantic-type="identifier" data-semantic-role="latinletter" data-semantic-font="italic" data-semantic-annotation="clearspeak:simple;nemeth:number" data-semantic-id="2" data-semantic-parent="15" data-semantic-speech="s" transform="translate(389, 0)"><use xlink:href="#MJX-1-TEX-I-1D460"></use></g><g data-mml-node="mo" data-semantic-type="fence" data-semantic-role="close" data-semantic-id="3" data-semantic-parent="15" data-semantic-operator="fenced" data-semantic-speech="right parenthesis" transform="translate(858, 0)"><use xlink:href="#MJX-1-TEX-N-29"></use></g></g></g><g data-mml-node="mo" data-semantic-type="operator" data-semantic-role="unknown" data-semantic-id="4" data-semantic-parent="24" data-semantic-operator="infixop,:=" data-semantic-speech="colon equals" transform="translate(2206.9, 0)"><use xlink:href="#MJX-1-TEX-N-3A"></use><use xlink:href="#MJX-1-TEX-N-3D" transform="translate(278, 0)"></use></g><g data-mml-node="mrow" data-semantic-type="fenced" data-semantic-role="set extended" data-semantic-id="21" data-semantic-children="20" data-semantic-content="5,14" data-semantic-parent="24" data-semantic-owns="5 20 14" data-semantic-speech="StartSet t element of upper S colon s dot t is defined EndSet" transform="translate(3485.1, 0)"><g data-mml-node="mo" data-semantic-type="fence" data-semantic-role="open" data-semantic-id="5" data-semantic-parent="21" data-semantic-operator="fenced" data-semantic-speech="left brace"><use xlink:href="#MJX-1-TEX-N-7B"></use></g><g data-mml-node="mrow" data-semantic-type="punctuated" data-semantic-role="sequence" data-semantic-id="20" data-semantic-children="16,9,19" data-semantic-content="9" data-semantic-parent="21" data-semantic-owns="16 9 19" data-semantic-speech="t element of upper S colon s dot t is defined" transform="translate(500, 0)"><g data-mml-node="mrow" data-semantic-type="infixop" data-semantic-role="unknown" data-semantic-id="16" data-semantic-children="6,8" data-semantic-content="7" data-semantic-parent="20" data-semantic-owns="6 7 8" data-semantic-speech="t element of upper S"><g data-mml-node="mi" data-semantic-type="identifier" data-semantic-role="latinletter" data-semantic-font="italic" data-semantic-annotation="clearspeak:simple;nemeth:number" data-semantic-id="6" data-semantic-parent="16" data-semantic-speech="t"><use xlink:href="#MJX-1-TEX-I-1D461"></use></g><g data-mml-node="mo" data-semantic-type="operator" data-semantic-role="set extended" data-semantic-id="7" data-semantic-parent="16" data-semantic-operator="infixop,∈" data-semantic-speech="element of" transform="translate(638.8, 0)"><use xlink:href="#MJX-1-TEX-N-2208"></use></g><g data-mml-node="mi" data-semantic-type="identifier" data-semantic-role="latinletter" data-semantic-font="italic" data-semantic-annotation="clearspeak:simple" data-semantic-id="8" data-semantic-parent="16" data-semantic-speech="upper S" transform="translate(1583.6, 0)"><use xlink:href="#MJX-1-TEX-I-1D446"></use></g></g><g data-mml-node="mo" data-semantic-type="punctuation" data-semantic-role="colon" data-semantic-annotation="nemeth:number" data-semantic-id="9" data-semantic-parent="20" data-semantic-operator="punctuated" data-semantic-speech="colon" transform="translate(2506.3, 0)"><use xlink:href="#MJX-1-TEX-N-3A"></use></g><g data-mml-node="mrow" data-semantic-type="punctuated" data-semantic-role="text" data-semantic-id="19" data-semantic-children="17,13" data-semantic-parent="20" data-semantic-collapsed="(19 (c 18) 17 13)" data-semantic-owns="17 13" data-semantic-speech="s dot t is defined" transform="translate(3062.1, 0)"><g data-mml-node="mrow" data-semantic-type="infixop" data-semantic-role="multiplication" data-semantic-id="17" data-semantic-children="10,12" data-semantic-content="11" data-semantic-parent="19" data-semantic-owns="10 11 12" data-semantic-speech="s dot t"><g data-mml-node="mi" data-semantic-type="identifier" data-semantic-role="latinletter" data-semantic-font="italic" data-semantic-annotation="clearspeak:simple;nemeth:number" data-semantic-id="10" data-semantic-parent="17" data-semantic-speech="s"><use xlink:href="#MJX-1-TEX-I-1D460"></use></g><g data-mml-node="mo" data-semantic-type="operator" data-semantic-role="multiplication" data-semantic-id="11" data-semantic-parent="17" data-semantic-operator="infixop,⋅" data-semantic-speech="dot" transform="translate(691.2, 0)"><use xlink:href="#MJX-1-TEX-N-22C5"></use></g><g data-mml-node="mi" data-semantic-type="identifier" data-semantic-role="latinletter" data-semantic-font="italic" data-semantic-annotation="clearspeak:simple" data-semantic-id="12" data-semantic-parent="17" data-semantic-speech="t" transform="translate(1191.4, 0)"><use xlink:href="#MJX-1-TEX-I-1D461"></use></g></g><g data-mml-node="mtext" data-semantic-type="text" data-semantic-role="unknown" data-semantic-font="normal" data-semantic-annotation="clearspeak:unit;nemeth:number" data-semantic-id="13" data-semantic-parent="19" data-semantic-speech="is defined" transform="translate(1552.4, 0)"><use xlink:href="#MJX-1-TEX-N-69"></use><use xlink:href="#MJX-1-TEX-N-73" transform="translate(278, 0)"></use><use xlink:href="#MJX-1-TEX-N-20" transform="translate(672, 0)"></use><use xlink:href="#MJX-1-TEX-N-64" transform="translate(922, 0)"></use><use xlink:href="#MJX-1-TEX-N-65" transform="translate(1478, 0)"></use><use xlink:href="#MJX-1-TEX-N-66" transform="translate(1922, 0)"></use><use xlink:href="#MJX-1-TEX-N-69" transform="translate(2228, 0)"></use><use xlink:href="#MJX-1-TEX-N-6E" transform="translate(2506, 0)"></use><use xlink:href="#MJX-1-TEX-N-65" transform="translate(3062, 0)"></use><use xlink:href="#MJX-1-TEX-N-64" transform="translate(3506, 0)"></use></g></g></g><g data-mml-node="mo" data-semantic-type="fence" data-semantic-role="close" data-semantic-id="14" data-semantic-parent="21" data-semantic-operator="fenced" data-semantic-speech="right brace" transform="translate(9176.6, 0)"><use xlink:href="#MJX-1-TEX-N-7D"></use></g></g></g></g></svg></mjx-container>

Hmmm. Here's what I get from the on-line web demos:

tex2mml

So something is funny there. Can you check that you also get the &#xA0; in that demo?

Also, without the &#xA0;, the output is correct, as the leading space should be trimmed in that case.

@dpvc I'm on node with the light adaptor.

OK, good point. Let me check that.

Something like

const TeX = require('../mathjax/v3/js/input/tex.js').TeX;
const HTMLDocument = require('../mathjax/v3/js/handlers/html/HTMLDocument.js')
  .HTMLDocument;
const liteAdaptor = require('../mathjax/v3/js/adaptors/liteAdaptor.js')
  .liteAdaptor;
const STATE = require('../mathjax/v3/js/core/MathItem.js').STATE;
const AllPackages = require('../mathjax/v3/js/input/tex/AllPackages.js')
  .AllPackages.filter( x => x!=='bussproofs'); 
const tex = new TeX({ packages: AllPackages });
const html = new HTMLDocument('', liteAdaptor(), { InputJax: tex });
const MmlVisitor = require('../mathjax/v3/js/core/MmlTree/SerializedMmlVisitor.js')
  .SerializedMmlVisitor;
const visitor = new MmlVisitor();
const toMathML = node => visitor.visitTree(node, html);

const tex2mml = (string, display) => {
  return toMathML(
    html.convert(string || '', { display: display, end: STATE.CONVERT })
  );
};

Strange, all the component-based versions in the MathJax-demos-node repository produce the &#xA0;, but not the direct version. Still looking to see what is behind that.

OK, it turns out that it is the new textmode extension, which is included automatically in AllPackages. It is not quoting the initial and trailing spaces properly.

One option would be to remove it from AllPackages as you do the bussproofs package. Another would be to patch textmacros on the fly, if you need that extension to be included. If so, let me know and I can work out the patch.

Ah! Thanks for tracking that down. I can disable the text extension (I wasn't using it).

I've made a PR that resolves the issue. Thanks for the report!

Fixed in v3.1 released today.