5831 |
## NOTE: There is an "as if in body" code clone. |
## NOTE: There is an "as if in body" code clone. |
5832 |
$parse_rcdata->(CDATA_CONTENT_MODEL); |
$parse_rcdata->(CDATA_CONTENT_MODEL); |
5833 |
redo B; |
redo B; |
|
} elsif ({ |
|
|
b => 1, big => 1, em => 1, font => 1, i => 1, |
|
|
s => 1, small => 1, strile => 1, |
|
|
strong => 1, tt => 1, u => 1, |
|
|
applet => 1, marquee => 1, object => 1, |
|
|
area => 1, basefont => 1, bgsound => 1, br => 1, |
|
|
embed => 1, img => 1, param => 1, spacer => 1, wbr => 1, |
|
|
image => 1, |
|
|
input => 1, |
|
|
}->{$token->{tag_name}}) { |
|
|
if ($token->{tag_name} eq 'image') { |
|
|
!!!cp ('t384'); |
|
|
!!!parse-error (type => 'image'); |
|
|
$token->{tag_name} = 'img'; |
|
|
} else { |
|
|
!!!cp ('t385'); |
|
|
} |
|
|
|
|
|
## NOTE: There is an "as if <br>" code clone. |
|
|
$reconstruct_active_formatting_elements->($insert_to_current); |
|
|
|
|
|
!!!insert-element-t ($token->{tag_name}, $token->{attributes}); |
|
|
if ({ |
|
|
applet => 1, marquee => 1, object => 1, |
|
|
}->{$token->{tag_name}}) { |
|
|
!!!cp ('t380'); |
|
|
push @$active_formatting_elements, ['#marker', '']; |
|
|
} elsif ({ |
|
|
b => 1, big => 1, em => 1, font => 1, i => 1, |
|
|
s => 1, small => 1, strile => 1, |
|
|
strong => 1, tt => 1, u => 1, |
|
|
}->{$token->{tag_name}}) { |
|
|
!!!cp ('t375'); |
|
|
push @$active_formatting_elements, $self->{open_elements}->[-1]; |
|
|
} elsif ($token->{tag_name} eq 'input') { |
|
|
!!!cp ('t388'); |
|
|
## TODO: associate with $self->{form_element} if defined |
|
|
pop @{$self->{open_elements}}; |
|
|
} else { |
|
|
!!!cp ('t388.1'); |
|
|
pop @{$self->{open_elements}}; |
|
|
} |
|
|
|
|
|
!!!next-token; |
|
|
redo B; |
|
5834 |
} elsif ($token->{tag_name} eq 'isindex') { |
} elsif ($token->{tag_name} eq 'isindex') { |
5835 |
!!!parse-error (type => 'isindex'); |
!!!parse-error (type => 'isindex'); |
5836 |
|
|
5934 |
|
|
5935 |
## ISSUE: An issue on HTML5 new elements in the spec. |
## ISSUE: An issue on HTML5 new elements in the spec. |
5936 |
} else { |
} else { |
5937 |
!!!cp ('t402'); |
if ($token->{tag_name} eq 'image') { |
5938 |
|
!!!cp ('t384'); |
5939 |
|
!!!parse-error (type => 'image'); |
5940 |
|
$token->{tag_name} = 'img'; |
5941 |
|
} else { |
5942 |
|
!!!cp ('t385'); |
5943 |
|
} |
5944 |
|
|
5945 |
|
## NOTE: There is an "as if <br>" code clone. |
5946 |
$reconstruct_active_formatting_elements->($insert_to_current); |
$reconstruct_active_formatting_elements->($insert_to_current); |
5947 |
|
|
5948 |
!!!insert-element-t ($token->{tag_name}, $token->{attributes}); |
!!!insert-element-t ($token->{tag_name}, $token->{attributes}); |
5949 |
|
|
5950 |
if ($token->{tag_name} eq 'select') { |
if ({ |
5951 |
|
applet => 1, marquee => 1, object => 1, |
5952 |
|
}->{$token->{tag_name}}) { |
5953 |
|
!!!cp ('t380'); |
5954 |
|
push @$active_formatting_elements, ['#marker', '']; |
5955 |
|
} elsif ({ |
5956 |
|
b => 1, big => 1, em => 1, font => 1, i => 1, |
5957 |
|
s => 1, small => 1, strile => 1, |
5958 |
|
strong => 1, tt => 1, u => 1, |
5959 |
|
}->{$token->{tag_name}}) { |
5960 |
|
!!!cp ('t375'); |
5961 |
|
push @$active_formatting_elements, $self->{open_elements}->[-1]; |
5962 |
|
} elsif ($token->{tag_name} eq 'input') { |
5963 |
|
!!!cp ('t388'); |
5964 |
|
## TODO: associate with $self->{form_element} if defined |
5965 |
|
pop @{$self->{open_elements}}; |
5966 |
|
} elsif ({ |
5967 |
|
area => 1, basefont => 1, bgsound => 1, br => 1, |
5968 |
|
embed => 1, img => 1, param => 1, spacer => 1, wbr => 1, |
5969 |
|
#image => 1, |
5970 |
|
}->{$token->{tag_name}}) { |
5971 |
|
!!!cp ('t388.1'); |
5972 |
|
pop @{$self->{open_elements}}; |
5973 |
|
} elsif ($token->{tag_name} eq 'select') { |
5974 |
## TODO: associate with $self->{form_element} if defined |
## TODO: associate with $self->{form_element} if defined |
5975 |
|
|
5976 |
if ($self->{insertion_mode} & TABLE_IMS or |
if ($self->{insertion_mode} & TABLE_IMS or |
5982 |
!!!cp ('t400.2'); |
!!!cp ('t400.2'); |
5983 |
$self->{insertion_mode} = IN_SELECT_IM; |
$self->{insertion_mode} = IN_SELECT_IM; |
5984 |
} |
} |
5985 |
|
} else { |
5986 |
|
!!!cp ('t402'); |
5987 |
} |
} |
5988 |
|
|
5989 |
!!!next-token; |
!!!next-token; |