Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

style: Add support to the animation shorthand and fix parsing of animation-name #12118

Merged
merged 4 commits into from Jul 8, 2016

Conversation

@emilio
Copy link
Member

emilio commented Jul 1, 2016


  • ./mach build -d does not report any errors
  • ./mach test-tidy does not report any errors

Part of #11916.

r? @SimonSapin


This change is Reviewable

@highfive
Copy link

highfive commented Jul 1, 2016

Heads up! This PR modifies the following files:

  • @bholley: components/style/properties/longhand/box.mako.rs, components/style/properties/shorthand/box.mako.rs, components/style/properties/helpers.mako.rs
  • @KiChjang: components/script/dom/webidls/CSSStyleDeclaration.webidl
@highfive
Copy link

highfive commented Jul 1, 2016

warning Warning warning

  • These commits modify style and script code, but no tests are modified. Please consider adding a test!
@bors-servo
Copy link
Contributor

bors-servo commented Jul 3, 2016

The latest upstream changes (presumably #11972) made this pull request unmergeable. Please resolve the merge conflicts.

@emilio emilio force-pushed the emilio:animation-shorthand branch from d993344 to 3586da2 Jul 3, 2016
@emilio emilio removed the S-needs-rebase label Jul 3, 2016
@SimonSapin
Copy link
Member

SimonSapin commented Jul 7, 2016

r=me with one change


Reviewed 4 of 4 files at r1, 1 of 1 files at r2, 3 of 3 files at r3, 1 of 1 files at r4.
Review status: all files reviewed at latest revision, 1 unresolved discussion.


components/style/properties/shorthand/box.mako.rs, line 129 [r1] (raw file):

        loop {
            try_parse_one!(input, name, animation_name);

Per https://drafts.csswg.org/css-animations/#typedef-single-animation , name should be last (so that keywords valid for other longhands are not interpreted as names).

Please also add a comment saying so, and that duration needs to be before delay (which it already id) with that URL included in the comment.


Comments from Reviewable

@emilio emilio force-pushed the emilio:animation-shorthand branch from 3586da2 to 1313181 Jul 7, 2016
@emilio
Copy link
Member Author

emilio commented Jul 7, 2016

Thanks for the careful review as always Simon :)

@bors-servo: r=SimonSapin


Review status: all files reviewed at latest revision, 1 unresolved discussion.


components/style/properties/shorthand/box.mako.rs, line 129 [r1] (raw file):

Previously, SimonSapin (Simon Sapin) wrote…

Per https://drafts.csswg.org/css-animations/#typedef-single-animation , name should be last (so that keywords valid for other longhands are not interpreted as names).

Please also add a comment saying so, and that duration needs to be before delay (which it already id) with that URL included in the comment.

Whoops, good catch :)

Done


Comments from Reviewable

@bors-servo
Copy link
Contributor

bors-servo commented Jul 7, 2016

📌 Commit 1313181 has been approved by SimonSapin

@bors-servo
Copy link
Contributor

bors-servo commented Jul 7, 2016

Testing commit 1313181 with merge fe300ae...

bors-servo added a commit that referenced this pull request Jul 7, 2016
style: Add support to the animation shorthand and fix parsing of animation-name

<!-- Please describe your changes on the following line: -->

---
<!-- Thank you for contributing to Servo! Please replace each `[ ]` by `[X]` when the step is complete, and replace `__` with appropriate data: -->
- [x] `./mach build -d` does not report any errors
- [x] `./mach test-tidy` does not report any errors

<!-- Pull requests that do not address these steps are welcome, but they will require additional verification as part of the review process. -->

Part of #11916.

r? @SimonSapin

<!-- Reviewable:start -->
---
This change is [<img src="https://reviewable.io/review_button.svg" height="35" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/12118)
<!-- Reviewable:end -->
@bors-servo
Copy link
Contributor

bors-servo commented Jul 7, 2016

💔 Test failed - linux-rel

@jdm
Copy link
Member

jdm commented Jul 7, 2016

@bors-servo: retry

  • infra
@bors-servo
Copy link
Contributor

bors-servo commented Jul 7, 2016

Testing commit 1313181 with merge a8ee30f...

bors-servo added a commit that referenced this pull request Jul 7, 2016
style: Add support to the animation shorthand and fix parsing of animation-name

<!-- Please describe your changes on the following line: -->

---
<!-- Thank you for contributing to Servo! Please replace each `[ ]` by `[X]` when the step is complete, and replace `__` with appropriate data: -->
- [x] `./mach build -d` does not report any errors
- [x] `./mach test-tidy` does not report any errors

<!-- Pull requests that do not address these steps are welcome, but they will require additional verification as part of the review process. -->

Part of #11916.

r? @SimonSapin

<!-- Reviewable:start -->
---
This change is [<img src="https://reviewable.io/review_button.svg" height="35" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/12118)
<!-- Reviewable:end -->
@bors-servo
Copy link
Contributor

bors-servo commented Jul 7, 2016

💔 Test failed - mac-rel-css

@jdm
Copy link
Member

jdm commented Jul 7, 2016

  ▶ TIMEOUT [expected PASS] /css-flexbox-1_dev/html/css-flexbox-height-animation-stretch.htm

  ▶ Unexpected subtest result in /css-transitions-1_dev/html/transition-timing-function-001.htm:
  └ PASS [expected FAIL] parse 'steps(3)'
emilio added 2 commits Jul 1, 2016
…ation-name.
Still doesn't work properly (this also happened with transitions).

This is spec'd in:
https://www.w3.org/TR/css3-transitions/#transition-timing-function
emilio added 2 commits Jul 1, 2016
…ist.

The previous behavior is plain wrong, since that array has always at least one
element, so we effectively couldn't specify anything else than "ease" in our
animations.
@emilio emilio force-pushed the emilio:animation-shorthand branch from 1313181 to 3a4539f Jul 7, 2016
@emilio
Copy link
Member Author

emilio commented Jul 7, 2016

Updated the test expectations an opened #12328 regarding the flexbox test, which we rendered incorrectly anyway.

I probably need to dedicate some time to #12120, adding a test refresh mode to the constellation or similar I guess, and enabling some private APIs to allow testing animations à lo mochitest in gecko.

I want approval from @jdm or @SimonSapin for landing that last expectation change, I think it's reasonable but I prefer to double-check.

@SimonSapin
Copy link
Member

SimonSapin commented Jul 8, 2016

Sounds ok to me.

@bors-servo r+

@bors-servo
Copy link
Contributor

bors-servo commented Jul 8, 2016

📌 Commit 3a4539f has been approved by SimonSapin

@bors-servo
Copy link
Contributor

bors-servo commented Jul 8, 2016

Testing commit 3a4539f with merge 1fabfee...

bors-servo added a commit that referenced this pull request Jul 8, 2016
style: Add support to the animation shorthand and fix parsing of animation-name

<!-- Please describe your changes on the following line: -->

---
<!-- Thank you for contributing to Servo! Please replace each `[ ]` by `[X]` when the step is complete, and replace `__` with appropriate data: -->
- [x] `./mach build -d` does not report any errors
- [x] `./mach test-tidy` does not report any errors

<!-- Pull requests that do not address these steps are welcome, but they will require additional verification as part of the review process. -->

Part of #11916.

r? @SimonSapin

<!-- Reviewable:start -->
---
This change is [<img src="https://reviewable.io/review_button.svg" height="35" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/12118)
<!-- Reviewable:end -->
@bors-servo
Copy link
Contributor

bors-servo commented Jul 8, 2016

@bors-servo bors-servo merged commit 3a4539f into servo:master Jul 8, 2016
2 checks passed
2 checks passed
continuous-integration/travis-ci/pr The Travis CI build passed
Details
homu Test successful
Details
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked issues

Successfully merging this pull request may close these issues.

None yet

5 participants
You can’t perform that action at this time.