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

chore(css): Move CSS examples - Basic shapes, filter effects, module template, paint API #36770

Merged
merged 20 commits into from
Nov 15, 2024

Conversation

bsmth
Copy link
Member

@bsmth bsmth commented Nov 13, 2024

Description

As part of an initiative to reduce repo maintenance & code duplication, this PR moves some external examples into content. This PR converts the following macros to live samples:

{{EmbedGHLiveSample("css-examples/cssom/modify-rule.html", '100%', 120)}}
{{EmbedGHLiveSample("css-examples/houdini/css_painting_api/example-boxbg.html", '100%', 400)}}
{{EmbedGHLiveSample("css-examples/shapes/overview/circle.html", '100%', 720)}}
{{EmbedGHLiveSample("css-examples/shapes/basic-shape/ellipse.html", '100%', 800)}}
{{EmbedGHLiveSample("css-examples/shapes/basic-shape/ellipse-keywords.html", '100%', 800)}}
{{EmbedGHLiveSample("css-examples/flexbox/alignment/intro.html", '100%', 700)}}
{{EmbedGHLiveSample("css-examples/modules/filters.html", '100%', 420)}}
{{EmbedGHLiveSample("css-examples/shapes/overview/circle.html", '100%', 720)}}
{{EmbedGHLiveSample("css-examples/houdini/css_painting_api/example-boxbg.html", '100%', 400)}}

Motivation

Motivation is described in the project issue.

Related issues and pull requests

@bsmth bsmth requested review from a team as code owners November 13, 2024 10:15
@bsmth bsmth requested review from sideshowbarker and estelle and removed request for a team November 13, 2024 10:15
@github-actions github-actions bot added Content:CSS Cascading Style Sheets docs Content:WebAPI Web API docs Content:Meta Content in the meta docs size/l [PR only] 501-1000 LoC changed labels Nov 13, 2024
Copy link
Contributor

github-actions bot commented Nov 13, 2024

@github-actions github-actions bot added the Content:Learn:CSS Learning area CSS docs label Nov 13, 2024
@github-actions github-actions bot added size/xl [PR only] >1000 LoC changed and removed size/l [PR only] 501-1000 LoC changed labels Nov 13, 2024
@sideshowbarker sideshowbarker removed their request for review November 14, 2024 09:03
Copy link
Member

@estelle estelle left a comment

Choose a reason for hiding this comment

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

Until Play supports saving work, for learn pages with examples that build on previous examples, opt to encourage creating and saving files rather than play

files/en-us/learn/css/css_layout/media_queries/index.md Outdated Show resolved Hide resolved
Comment on lines +123 to +128
One November night in the year 1782, so the story runs, two brothers sat over
their winter fire in the little French town of Annonay, watching the grey
smoke-wreaths from the hearth curl up the wide chimney. Their names were
Stephen and Joseph Montgolfier, they were papermakers by trade, and were noted
as possessing thoughtful minds and a deep interest in all scientific knowledge
and new discovery.
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
One November night in the year 1782, so the story runs, two brothers sat over
their winter fire in the little French town of Annonay, watching the grey
smoke-wreaths from the hearth curl up the wide chimney. Their names were
Stephen and Joseph Montgolfier, they were papermakers by trade, and were noted
as possessing thoughtful minds and a deep interest in all scientific knowledge
and new discovery.
One November night in the year 1782, so the story runs, two brothers sat over
their winter fire in the little French town of Annonay, watching the grey
smoke-wreaths from the hearth curl up the wide chimney. Their names were
Stephen and Joseph Montgolfier. They were papermakers by trade and were noted
as possessing thoughtful minds and a deep interest in all scientific knowledge
and new discovery.

Copy link
Member

Choose a reason for hiding this comment

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

same for all the examples everywhere.

Copy link
Member Author

Choose a reason for hiding this comment

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

This is apparently an excerpt from "BALLOONS AIRSHIPS AND FLYING MACHINES"

https://www.gutenberg.org/files/54799/54799-h/54799-h.htm

Should we really alter it?

Copy link
Member

Choose a reason for hiding this comment

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

Too funny. It's old English. 1905. In 1905, in Europe, they did not have hundreds of millions of people, much less in 1782. We should likely come up with a different example, but don't need to do that today. Thanks for finding the reference.

files/en-us/learn/css/css_layout/media_queries/index.md Outdated Show resolved Hide resolved
files/en-us/learn/css/css_layout/media_queries/index.md Outdated Show resolved Hide resolved
files/en-us/web/api/css_painting_api/index.md Outdated Show resolved Hide resolved
files/en-us/web/css/basic-shape/ellipse/index.md Outdated Show resolved Hide resolved
files/en-us/web/css/css_filter_effects/index.md Outdated Show resolved Hide resolved
bsmth and others added 5 commits November 15, 2024 10:06
Co-authored-by: Estelle Weyl <estelle@openwebdocs.org>
Co-authored-by: Estelle Weyl <estelle@openwebdocs.org>
Co-authored-by: Estelle Weyl <estelle@openwebdocs.org>
Co-authored-by: Estelle Weyl <estelle@openwebdocs.org>
@bsmth bsmth requested a review from estelle November 15, 2024 09:55
Copy link
Member

@estelle estelle left a comment

Choose a reason for hiding this comment

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

Thanks! 🎉

@estelle estelle merged commit ca6d4f6 into mdn:main Nov 15, 2024
8 checks passed
@bsmth
Copy link
Member Author

bsmth commented Nov 18, 2024

Thank you!

@bsmth bsmth deleted the css-examples-web-css-5 branch November 18, 2024 08:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Content:CSS Cascading Style Sheets docs Content:Learn:CSS Learning area CSS docs Content:Meta Content in the meta docs Content:WebAPI Web API docs size/xl [PR only] >1000 LoC changed
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants