Skip to content

Commit 4a1bc0b

Browse files
committed
Further tweak whitespace in keyframes grammar, both to add more places allowed whitespace was missing, and to follow the convention that productions allow whitespace at their end but not their start.
1 parent 97563b3 commit 4a1bc0b

2 files changed

Lines changed: 11 additions & 11 deletions

File tree

css3-animations/Overview.html

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN"
1+
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN"
22
"http://www.w3.org/TR/html4/strict.dtd">
33

44
<html lang=en>
@@ -433,13 +433,13 @@ <h2 id=keyframes><span class=secno>3. </span>Keyframes</h2>
433433
<p> The following is the grammar for the keyframes rule.
434434

435435
<pre>
436-
437-
keyframes-rule: KEYFRAMES_SYM S* IDENT '{' keyframes-blocks '}' S*;
438436

439-
keyframes-blocks: [ S* keyframe-selector '{' S* declaration? [ ';' S* declaration? ]* '}' ]* ;
437+
keyframes-rule: KEYFRAMES_SYM S+ IDENT S* '{' S* keyframes-blocks '}' S*;
438+
439+
keyframes-blocks: [ keyframe-selector '{' S* declaration? [ ';' S* declaration? ]* '}' S* ]* ;
440+
441+
keyframe-selector: [ FROM_SYM | TO_SYM | PERCENTAGE ] S* [ ',' S* [ FROM_SYM | TO_SYM | PERCENTAGE ] S* ]*;
440442

441-
keyframe-selector: [ FROM_SYM | TO_SYM | PERCENTAGE ] [ ',' [ FROM_SYM | TO_SYM | PERCENTAGE ] ]*;
442-
443443
@{K}{E}{Y}{F}{R}{A}{M}{E}{S} {return KEYFRAMES_SYM;}
444444
{F}{R}{O}{M} {return FROM_SYM;}
445445
{T}{O} {return TO_SYM;}

css3-animations/Overview.src.html

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -291,13 +291,13 @@ <h2>Keyframes</h2>
291291
</p>
292292

293293
<pre>
294-
295-
keyframes-rule: KEYFRAMES_SYM S* IDENT '{' keyframes-blocks '}' S*;
296294

297-
keyframes-blocks: [ S* keyframe-selector '{' S* declaration? [ ';' S* declaration? ]* '}' ]* ;
295+
keyframes-rule: KEYFRAMES_SYM S+ IDENT S* '{' S* keyframes-blocks '}' S*;
296+
297+
keyframes-blocks: [ keyframe-selector '{' S* declaration? [ ';' S* declaration? ]* '}' S* ]* ;
298+
299+
keyframe-selector: [ FROM_SYM | TO_SYM | PERCENTAGE ] S* [ ',' S* [ FROM_SYM | TO_SYM | PERCENTAGE ] S* ]*;
298300

299-
keyframe-selector: [ FROM_SYM | TO_SYM | PERCENTAGE ] [ ',' [ FROM_SYM | TO_SYM | PERCENTAGE ] ]*;
300-
301301
@{K}{E}{Y}{F}{R}{A}{M}{E}{S} {return KEYFRAMES_SYM;}
302302
{F}{R}{O}{M} {return FROM_SYM;}
303303
{T}{O} {return TO_SYM;}

0 commit comments

Comments
 (0)