Skip to content

style: Move float CSS property outside mako - #21139

Merged
bors-servo merged 1 commit into
servo:masterfrom
kleinph:move-float-clear-outside-mako
Jul 10, 2018
Merged

bors-servo merged 1 commit into
servo:masterfrom
kleinph:move-float-clear-outside-mako

Conversation

@kleinph

@kleinph kleinph commented Jul 8, 2018 •

Copy link
Copy Markdown
Contributor

Hi, I am fairly new to Rust and this is my first contribution to a Rust project.

  • There are tests for these changes OR
  • These changes do not require tests because _____

I'm not sure if the approach with the two enums is good. Please let me know if this can be improved.
Regarding the tests I'm unsure: tests/wpt/web-platform-tests/css/css-display/display-contents-float-001.html seems to fail already before this PR, (and the cause is maybe not related to the style property definition).

Also I would like to add some docs, is it allowed to use the descriptions from MDN (https://developer.mozilla.org/en-US/docs/Web/CSS/float).


This change is Reviewable

@highfive

highfive commented Jul 8, 2018

Copy link
Copy Markdown

Thanks for the pull request, and welcome! The Servo team is excited to review your changes, and you should hear from @nox (or someone else) soon.

@highfive

highfive commented Jul 8, 2018

Copy link
Copy Markdown

Heads up! This PR modifies the following files:

  • @emilio: components/style/values/specified/box.rs, components/style/values/computed/box.rs, components/style/values/specified/mod.rs, components/style/properties/longhands/box.mako.rs, components/style/values/computed/mod.rs

@highfive highfive added the S-awaiting-review There is new code that needs to be reviewed. label Jul 8, 2018
@highfive

highfive commented Jul 8, 2018

Copy link
Copy Markdown

warning Warning warning

  • These commits modify style code, but no tests are modified. Please consider adding a test!

@emilio emilio left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It looks amazing, thank you!

Let me know if you don't have time for the indentation change, I can do it in a follow-up.

}
}
</%helpers:single_keyword>
${helpers.predefined_type("float", "Float",

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could we use block indentation for here?

${helpers.predefined_type(
    "float",
    "Float",
    "computed::Float::None",
    // ...
)}

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sure

@emilio

emilio commented Jul 9, 2018

Copy link
Copy Markdown
Member

I'm not sure if the approach with the two enums is good. Please let me know if this can be improved.
Regarding the tests I'm unsure: tests/wpt/web-platform-tests/css/css-display/display-contents-float-001.html seems to fail already before this PR, (and the cause is maybe not related to the style property definition).

The two enums is the right approach, given they have different variants. Tests should be unchanged, since this shouldn't introduce any behavior changes.

Pointing at the spec for this should be enough as docs.

@kleinph

kleinph commented Jul 9, 2018

Copy link
Copy Markdown
Contributor Author

It looks amazing, thank you!

Thanks! :)

Let me know if you don't have time for the indentation change, I can do it in a follow-up.

No. I will update the PR today.

I also want to do clear in the same style. Can I add it to this PR (as a second commit) or in its own PR?

@kleinph
kleinph force-pushed the move-float-clear-outside-mako branch from eaeda32 to c787181 Compare July 9, 2018 10:48

@emilio emilio left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I also want to do clear in the same style. Can I add it to this PR (as a second commit) or in its own PR?

I think its own PR would be better for tracking, and also would allow this one to merge sooner.

@emilio

emilio commented Jul 9, 2018

Copy link
Copy Markdown
Member

@bors-servo r+

@bors-servo

Copy link
Copy Markdown
Contributor

📌 Commit c787181 has been approved by emilio

@highfive highfive assigned emilio and unassigned nox Jul 9, 2018
@highfive highfive added S-awaiting-merge The PR is in the process of compiling and running tests on the automated CI. and removed S-awaiting-review There is new code that needs to be reviewed. labels Jul 9, 2018
@bors-servo

Copy link
Copy Markdown
Contributor

⌛ Testing commit c787181 with merge e2a0dba...

bors-servo pushed a commit that referenced this pull request Jul 9, 2018
style: Move `float` CSS property outside mako

Hi, I am fairly new to Rust and this is my first contribution to a Rust project.

- [x] `./mach build -d` does not report any errors
- [x] `./mach test-tidy` does not report any errors
- [x] These changes fix #21130

<!-- Either: -->
- [ ] There are tests for these changes OR
- [ ] These changes do not require tests because _____

I'm not sure if the approach with the two enums is good. Please let me know if this can be improved.
Regarding the tests I'm unsure: `tests/wpt/web-platform-tests/css/css-display/display-contents-float-001.html` seems to fail already before this PR, (and the cause is maybe not related to the style property definition).

Also I would like to add some docs, is it allowed to use the descriptions from MDN (https://developer.mozilla.org/en-US/docs/Web/CSS/float).

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

Copy link
Copy Markdown
Contributor

💔 Test failed - mac-rel-wpt2

@highfive highfive added S-tests-failed The changes caused existing tests to fail. and removed S-awaiting-merge The PR is in the process of compiling and running tests on the automated CI. labels Jul 9, 2018
@emilio

emilio commented Jul 9, 2018

Copy link
Copy Markdown
Member

@bors-servo retry

  • Flaky WebSocket failures

@kleinph kleinph closed this Jul 9, 2018
@kleinph kleinph reopened this Jul 9, 2018
@kleinph

kleinph commented Jul 9, 2018

Copy link
Copy Markdown
Contributor Author

Sorry closed by accident

@emilio

emilio commented Jul 9, 2018

Copy link
Copy Markdown
Member

Hah, np!

@bors-servo r+

@bors-servo

Copy link
Copy Markdown
Contributor

💡 This pull request was already approved, no need to approve it again.

  • This pull request previously failed. You should add more commits to fix the bug, or use retry to trigger a build again.

@bors-servo

Copy link
Copy Markdown
Contributor

📌 Commit c787181 has been approved by emilio

@highfive highfive removed the S-tests-failed The changes caused existing tests to fail. label Jul 9, 2018
@jdm

jdm commented Jul 9, 2018

Copy link
Copy Markdown
Member

@bors-servo retry

@bors-servo

Copy link
Copy Markdown
Contributor

⌛ Testing commit c787181 with merge ee1e23c...

bors-servo pushed a commit that referenced this pull request Jul 9, 2018
style: Move `float` CSS property outside mako

Hi, I am fairly new to Rust and this is my first contribution to a Rust project.

- [x] `./mach build -d` does not report any errors
- [x] `./mach test-tidy` does not report any errors
- [x] These changes fix #21130

<!-- Either: -->
- [ ] There are tests for these changes OR
- [ ] These changes do not require tests because _____

I'm not sure if the approach with the two enums is good. Please let me know if this can be improved.
Regarding the tests I'm unsure: `tests/wpt/web-platform-tests/css/css-display/display-contents-float-001.html` seems to fail already before this PR, (and the cause is maybe not related to the style property definition).

Also I would like to add some docs, is it allowed to use the descriptions from MDN (https://developer.mozilla.org/en-US/docs/Web/CSS/float).

<!-- Reviewable:start -->
---
This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/21139)
<!-- Reviewable:end -->
@highfive highfive added S-awaiting-merge The PR is in the process of compiling and running tests on the automated CI. and removed S-tests-failed The changes caused existing tests to fail. labels Jul 9, 2018
@bors-servo

Copy link
Copy Markdown
Contributor

💔 Test failed - mac-dev-unit

@highfive highfive added S-tests-failed The changes caused existing tests to fail. and removed S-awaiting-merge The PR is in the process of compiling and running tests on the automated CI. labels Jul 9, 2018
@jdm

jdm commented Jul 9, 2018

Copy link
Copy Markdown
Member

@bors-servo retry

  • network problems

@bors-servo

Copy link
Copy Markdown
Contributor

⌛ Testing commit c787181 with merge 2bc70e7...

bors-servo pushed a commit that referenced this pull request Jul 10, 2018
style: Move `float` CSS property outside mako

Hi, I am fairly new to Rust and this is my first contribution to a Rust project.

- [x] `./mach build -d` does not report any errors
- [x] `./mach test-tidy` does not report any errors
- [x] These changes fix #21130

<!-- Either: -->
- [ ] There are tests for these changes OR
- [ ] These changes do not require tests because _____

I'm not sure if the approach with the two enums is good. Please let me know if this can be improved.
Regarding the tests I'm unsure: `tests/wpt/web-platform-tests/css/css-display/display-contents-float-001.html` seems to fail already before this PR, (and the cause is maybe not related to the style property definition).

Also I would like to add some docs, is it allowed to use the descriptions from MDN (https://developer.mozilla.org/en-US/docs/Web/CSS/float).

<!-- Reviewable:start -->
---
This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/21139)
<!-- Reviewable:end -->
@highfive highfive added S-awaiting-merge The PR is in the process of compiling and running tests on the automated CI. and removed S-tests-failed The changes caused existing tests to fail. labels Jul 10, 2018
@bors-servo

Copy link
Copy Markdown
Contributor

☀️ Test successful - android, arm32, arm64, linux-dev, linux-rel-css, linux-rel-wpt, mac-dev-unit, mac-rel-css1, mac-rel-css2, mac-rel-wpt1, mac-rel-wpt2, mac-rel-wpt3, mac-rel-wpt4, windows-msvc-dev
Approved by: emilio
Pushing 2bc70e7 to master...

@bors-servo
bors-servo merged commit c787181 into servo:master Jul 10, 2018
@highfive highfive removed the S-awaiting-merge The PR is in the process of compiling and running tests on the automated CI. label Jul 10, 2018
@kleinph
kleinph deleted the move-float-clear-outside-mako branch July 10, 2018 07:07
bors-servo pushed a commit that referenced this pull request Jul 16, 2018
MozReview-Commit-ID: 3ocJrRB3jeO
moz-v2v-gh pushed a commit to mozilla/gecko-dev that referenced this pull request Jul 16, 2018
Imports servo/servo#21139.
Signed-off-by: Emilio Cobos Álvarez <[email protected]>

MozReview-Commit-ID: EoLK36GMq3d
moz-v2v-gh pushed a commit to mozilla/gecko-dev that referenced this pull request Jul 17, 2018
Imports servo/servo#21139.
Signed-off-by: Emilio Cobos Álvarez <[email protected]>

MozReview-Commit-ID: EoLK36GMq3d
xeonchen pushed a commit to xeonchen/gecko-cinnabar that referenced this pull request Jul 17, 2018
Imports servo/servo#21139.
Signed-off-by: Emilio Cobos Álvarez <[email protected]>

MozReview-Commit-ID: EoLK36GMq3d
xeonchen pushed a commit to xeonchen/gecko-cinnabar that referenced this pull request Jul 17, 2018
Imports servo/servo#21139.
Signed-off-by: Emilio Cobos Álvarez <[email protected]>

MozReview-Commit-ID: EoLK36GMq3d
gecko-dev-updater pushed a commit to marco-c/gecko-dev-comments-removed that referenced this pull request Oct 3, 2019
Imports servo/servo#21139.
Signed-off-by: Emilio Cobos Álvarez <emiliocrisal.io>

MozReview-Commit-ID: EoLK36GMq3d

UltraBlame original commit: a2bb0089cf1d69cf713913250b89c1b828ab1e77
gecko-dev-updater pushed a commit to marco-c/gecko-dev-comments-removed that referenced this pull request Oct 3, 2019
Imports servo/servo#21139.
Signed-off-by: Emilio Cobos Álvarez <emiliocrisal.io>

MozReview-Commit-ID: EoLK36GMq3d

UltraBlame original commit: 0486cd62a807989f85459e360f015bdb1b7a0cf1
gecko-dev-updater pushed a commit to marco-c/gecko-dev-wordified-and-comments-removed that referenced this pull request Oct 3, 2019
Imports servo/servo#21139.
Signed-off-by: Emilio Cobos Álvarez <emiliocrisal.io>

MozReview-Commit-ID: EoLK36GMq3d

UltraBlame original commit: a2bb0089cf1d69cf713913250b89c1b828ab1e77
gecko-dev-updater pushed a commit to marco-c/gecko-dev-wordified-and-comments-removed that referenced this pull request Oct 3, 2019
Imports servo/servo#21139.
Signed-off-by: Emilio Cobos Álvarez <emiliocrisal.io>

MozReview-Commit-ID: EoLK36GMq3d

UltraBlame original commit: 0486cd62a807989f85459e360f015bdb1b7a0cf1
gecko-dev-updater pushed a commit to marco-c/gecko-dev-wordified that referenced this pull request Oct 3, 2019
Imports servo/servo#21139.
Signed-off-by: Emilio Cobos Álvarez <emiliocrisal.io>

MozReview-Commit-ID: EoLK36GMq3d

UltraBlame original commit: a2bb0089cf1d69cf713913250b89c1b828ab1e77
gecko-dev-updater pushed a commit to marco-c/gecko-dev-wordified that referenced this pull request Oct 3, 2019
Imports servo/servo#21139.
Signed-off-by: Emilio Cobos Álvarez <emiliocrisal.io>

MozReview-Commit-ID: EoLK36GMq3d

UltraBlame original commit: 0486cd62a807989f85459e360f015bdb1b7a0cf1
jwidar pushed a commit to jwidar/LatencyZeroGithub that referenced this pull request Sep 16, 2025
Imports servo/servo#21139.
Signed-off-by: Emilio Cobos Álvarez <[email protected]>

MozReview-Commit-ID: EoLK36GMq3d
jwidar pushed a commit to jwidar/LatencyZeroGithub that referenced this pull request Sep 16, 2025
Imports servo/servo#21139.
Signed-off-by: Emilio Cobos Álvarez <[email protected]>

MozReview-Commit-ID: EoLK36GMq3d
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

style: Move float outside mako

6 participants