Bug 73113 - From @keyframes rules with the same name, the last rule should be used
Summary: From @keyframes rules with the same name, the last rule should be used
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: CSS (show other bugs)
Version: 528+ (Nightly build)
Hardware: All All
: P2 Normal
Assignee: Roland Steiner
URL:
Keywords:
Depends on:
Blocks: 72462
  Show dependency treegraph
 
Reported: 2011-11-24 23:43 PST by Roland Steiner
Modified: 2011-11-28 20:06 PST (History)
5 users (show)

See Also:


Attachments
Patch (4.42 KB, patch)
2011-11-24 23:48 PST, Roland Steiner
simon.fraser: review+
simon.fraser: commit-queue-
Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Roland Steiner 2011-11-24 23:43:10 PST
http://www.w3.org/TR/css3-animations/ specifies that if there are multiple @keyframes rules with the same name, the last one should be the one used. Currently the first one is used.
Comment 1 Roland Steiner 2011-11-24 23:48:57 PST
Created attachment 116569 [details]
Patch
Comment 2 Simon Fraser (smfr) 2011-11-28 11:50:26 PST
Comment on attachment 116569 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=116569&action=review

> LayoutTests/animations/duplicated-keyframes-name.html:31
> +        -webkit-animation-name: "anim";
> +    }
> +    @-webkit-keyframes "anim" {
> +        from { left: 50px; }
> +        to   { left: 100px; }
> +    }
> +    @-webkit-keyframes "irrelevant" {
> +        from { left: 150px; }
> +        to   { left: 2500px; }
> +    }
> +    @-webkit-keyframes "anim" {
> +        from { left: 200px; }
> +        to   { left: 300px; }
> +    }

Keyframe names are IDENT, not STRING, so should not be quoted.
Comment 3 Roland Steiner 2011-11-28 20:06:41 PST
Committed r101321: <http://trac.webkit.org/changeset/101321>