@@ -704,8 +704,9 @@ def __init__(self, parser, tree):
704
704
("plaintext" ,self .startTagPlaintext ),
705
705
(headingElements , self .startTagHeading ),
706
706
("a" , self .startTagA ),
707
- (("b" , "big" , "em" , "font" , "i" , "nobr" , "s" , "small" , "strike" ,
708
- "strong" , "tt" , "u" ),self .startTagFormatting ),
707
+ (("b" , "big" , "em" , "font" , "i" , "s" , "small" , "strike" , "strong" ,
708
+ "tt" , "u" ),self .startTagFormatting ),
709
+ ("nobr" , self .startTagNobr ),
709
710
("button" , self .startTagButton ),
710
711
(("marquee" , "object" ), self .startTagMarqueeObject ),
711
712
("xmp" , self .startTagXmp ),
@@ -877,6 +878,12 @@ def startTagFormatting(self, name, attributes):
877
878
self .tree .reconstructActiveFormattingElements ()
878
879
self .addFormattingElement (name , attributes )
879
880
881
+ def startTagNobr (self , name , attributes ):
882
+ self .tree .reconstructActiveFormattingElements ()
883
+ if self .tree .elementInScope ("nobr" ):
884
+ self .processEndTag ("nobr" )
885
+ self .addFormattingElement (name , attributes )
886
+
880
887
def startTagButton (self , name , attributes ):
881
888
if self .tree .elementInScope ("button" ):
882
889
self .parser .parseError (_ ("Unexpected start tag (button) implied "
0 commit comments