mirror of
https://github.com/scratchfoundation/scratch-www.git
synced 2025-03-31 15:21:34 -04:00
Merge pull request #5126 from LLK/release/2021-03-11
[Master] Release 2021-03-11
This commit is contained in:
commit
03c8ab448b
23 changed files with 457 additions and 1676 deletions
package-lock.jsonpackage.json
src
static/images/about
test
949
package-lock.json
generated
949
package-lock.json
generated
File diff suppressed because it is too large
Load diff
18
package.json
18
package.json
|
@ -45,7 +45,6 @@
|
|||
"@sentry/browser": "4.4.2",
|
||||
"bunyan": "1.7.1",
|
||||
"clipboard-copy": "2.0.1",
|
||||
"compression": "1.6.1",
|
||||
"express": "4.16.1",
|
||||
"express-http-proxy": "1.1.0",
|
||||
"lodash.defaults": "4.0.1",
|
||||
|
@ -57,7 +56,6 @@
|
|||
"@formatjs/intl-locale": "^2.4.13",
|
||||
"@formatjs/intl-pluralrules": "^4.0.6",
|
||||
"@formatjs/intl-relativetimeformat": "^8.0.3",
|
||||
"ajv": "6.4.0",
|
||||
"async": "3.1.0",
|
||||
"autoprefixer": "6.3.6",
|
||||
"babel-cli": "6.26.0",
|
||||
|
@ -69,24 +67,19 @@
|
|||
"babel-preset-es2015": "6.22.0",
|
||||
"babel-preset-react": "6.22.0",
|
||||
"bowser": "1.9.4",
|
||||
"cheerio": "1.0.0-rc.2",
|
||||
"chromedriver": "86.0.0",
|
||||
"chromedriver": "88.0.0",
|
||||
"classnames": "2.2.5",
|
||||
"cookie": "0.4.1",
|
||||
"copy-webpack-plugin": "^4.5.1",
|
||||
"create-react-class": "15.6.2",
|
||||
"css-loader": "0.23.1",
|
||||
"email-validator": "2.0.4",
|
||||
"enzyme": "3.10.0",
|
||||
"enzyme-adapter-react-16": "1.14.0",
|
||||
"eslint": "5.16.0",
|
||||
"eslint-config-scratch": "6.0.0",
|
||||
"eslint-plugin-cypress": "^2.0.1",
|
||||
"eslint-plugin-json": "2.0.1",
|
||||
"eslint-plugin-react": "7.14.2",
|
||||
"exenv": "1.2.0",
|
||||
"fastly": "1.2.1",
|
||||
"file-loader": "4.0.0",
|
||||
"formik": "1.5.4",
|
||||
"formsy-react": "1.1.4",
|
||||
"formsy-react-components": "1.0.0",
|
||||
|
@ -96,24 +89,17 @@
|
|||
"html-webpack-plugin": "^3.2.0",
|
||||
"iso-3166-2": "0.4.0",
|
||||
"jest": "^23.6.0",
|
||||
"json-loader": "0.5.2",
|
||||
"json2po-stream": "1.0.3",
|
||||
"keymirror": "0.1.1",
|
||||
"lodash.bindall": "4.4.0",
|
||||
"lodash.clone": "3.0.3",
|
||||
"lodash.defaultsdeep": "4.6.1",
|
||||
"lodash.isarray": "3.0.4",
|
||||
"lodash.merge": "4.6.2",
|
||||
"lodash.mergewith": "4.6.2",
|
||||
"lodash.omit": "3.1.0",
|
||||
"lodash.range": "3.2.0",
|
||||
"lodash.uniqby": "4.7.0",
|
||||
"minilog": "2.0.8",
|
||||
"node-dir": "0.1.16",
|
||||
"node-sass": "4.14.1",
|
||||
"pako": "0.2.8",
|
||||
"plotly.js": "1.47.4",
|
||||
"po2icu": "0.0.2",
|
||||
"postcss-loader": "2.0.10",
|
||||
"prop-types": "15.6.0",
|
||||
"query-string": "^5.1.1",
|
||||
|
@ -136,11 +122,9 @@
|
|||
"scratch-l10n": "latest",
|
||||
"selenium-webdriver": "3.6.0",
|
||||
"slick-carousel": "1.6.0",
|
||||
"source-map-support": "0.3.2",
|
||||
"style-loader": "0.12.3",
|
||||
"tap": "14.10.8",
|
||||
"url-loader": "2.3.0",
|
||||
"watch": "0.16.0",
|
||||
"webpack": "^4.46.0",
|
||||
"webpack-bundle-analyzer": "^4.4.0",
|
||||
"webpack-cli": "^3.1.0",
|
||||
|
|
|
@ -85,16 +85,22 @@ const Footer = props => (
|
|||
<FormattedMessage id="general.credits" />
|
||||
</a>
|
||||
</dd>
|
||||
<dd>
|
||||
<a href="https://scratchfoundation.org/supporters">
|
||||
<FormattedMessage id="general.donors" />
|
||||
</a>
|
||||
</dd>
|
||||
<dd>
|
||||
<a href="https://www.scratchfoundation.org/opportunities">
|
||||
<FormattedMessage id="general.jobs" />
|
||||
</a>
|
||||
</dd>
|
||||
<dd>
|
||||
<a href="https://www.scratchfoundation.org/media-kit/">
|
||||
<FormattedMessage id="general.press" />
|
||||
<a href="https://secure.donationpay.org/scratchfoundation/">
|
||||
<FormattedMessage id="general.donate" />
|
||||
</a>
|
||||
</dd>
|
||||
|
||||
</dl>
|
||||
<dl>
|
||||
<dt>
|
||||
|
@ -146,16 +152,6 @@ const Footer = props => (
|
|||
<FormattedMessage id="general.contactUs" />
|
||||
</a>
|
||||
</dd>
|
||||
<dd>
|
||||
<a href="/store">
|
||||
<FormattedMessage id="general.scratchStore" />
|
||||
</a>
|
||||
</dd>
|
||||
<dd>
|
||||
<a href="https://secure.donationpay.org/scratchfoundation/">
|
||||
<FormattedMessage id="general.donate" />
|
||||
</a>
|
||||
</dd>
|
||||
</dl>
|
||||
|
||||
<dl>
|
||||
|
@ -208,6 +204,12 @@ const Footer = props => (
|
|||
<FormattedMessage id="general.scratchFoundation" />
|
||||
</a>
|
||||
</dd>
|
||||
<dd>
|
||||
<a href="/store">
|
||||
<FormattedMessage id="general.scratchStore" />
|
||||
</a>
|
||||
</dd>
|
||||
|
||||
</dl>
|
||||
</div>
|
||||
</MediaQuery>
|
||||
|
|
|
@ -12,7 +12,7 @@ const DonorRecognition = () => (
|
|||
values={{
|
||||
donorLink: (
|
||||
<a
|
||||
href="/credits#donors"
|
||||
href="https://www.scratchfoundation.org/supporters"
|
||||
>
|
||||
<FormattedMessage id="footer.donors" />
|
||||
</a>
|
||||
|
@ -26,7 +26,8 @@ const DonorRecognition = () => (
|
|||
values={{
|
||||
donor1: 'Massachusetts Institute of Technology',
|
||||
donor2: 'National Science Foundation',
|
||||
donor3: 'Siegel Family Endowment'
|
||||
donor3: 'Siegel Family Endowment',
|
||||
donor4: 'LEGO Foundation'
|
||||
}}
|
||||
/>
|
||||
</div>
|
||||
|
|
|
@ -22,7 +22,8 @@
|
|||
"general.conferences": "Conferences",
|
||||
"general.country": "Country",
|
||||
"general.create": "Create",
|
||||
"general.credits": "Credits",
|
||||
"general.credits": "Our Team",
|
||||
"general.donors": "Donors",
|
||||
"general.dmca": "DMCA",
|
||||
"general.emailAddress": "Email address",
|
||||
"general.english": "English",
|
||||
|
@ -89,7 +90,7 @@
|
|||
"general.startOver": "Start over",
|
||||
"general.statistics": "Statistics",
|
||||
"general.studios": "Studios",
|
||||
"general.support": "Support",
|
||||
"general.support": "Resources",
|
||||
"general.ideas": "Ideas",
|
||||
"general.tipsWindow": "Tips Window",
|
||||
"general.termsOfUse": "Terms of Use",
|
||||
|
@ -126,9 +127,9 @@
|
|||
|
||||
"footer.discuss": "Discussion Forums",
|
||||
"footer.scratchFamily": "Scratch Family",
|
||||
"footer.donorRecognition": "Scratch is available for free thanks to generous support from our {donorLink}. We are grateful to our Founding Partners:",
|
||||
"footer.donorRecognition": "Scratch is available for free thanks to support from our {donorLink}. We are grateful to our Founding Partners:",
|
||||
"footer.donors": "donors",
|
||||
"footer.donorList": "{donor1}, {donor2}, and {donor3}.",
|
||||
"footer.donorList": "{donor1}, {donor2}, {donor3}, and {donor4}.",
|
||||
|
||||
"form.validationRequired": "This field is required",
|
||||
|
||||
|
|
|
@ -2,6 +2,7 @@ const React = require('react');
|
|||
const FormattedMessage = require('react-intl').FormattedMessage;
|
||||
const render = require('../../lib/render.jsx');
|
||||
|
||||
const Button = require('../../components/forms/button.jsx');
|
||||
const Page = require('../../components/page/www/page.jsx');
|
||||
const Video = require('../../components/video/video.jsx');
|
||||
|
||||
|
@ -65,7 +66,11 @@ const About = () => (
|
|||
values={{
|
||||
languageCount: 60,
|
||||
translationLink: (
|
||||
<a href="https://github.com/LLK/scratch-l10n/wiki/Guide-for-Scratch-Translators">
|
||||
<a
|
||||
href="https://github.com/LLK/scratch-l10n/wiki/Guide-for-Scratch-Translators"
|
||||
rel="noreferrer noopener"
|
||||
target="_blank"
|
||||
>
|
||||
<FormattedMessage id="about.translationLinkText" />
|
||||
</a>
|
||||
)
|
||||
|
@ -81,9 +86,9 @@ const About = () => (
|
|||
<p><FormattedMessage
|
||||
id="about.schoolsDescription"
|
||||
values={{
|
||||
scratchedLink: (
|
||||
<a href="http://scratched.gse.harvard.edu/">
|
||||
<FormattedMessage id="about.scratchedLinkText" />
|
||||
scratchForEducatorsLink: (
|
||||
<a href="/educators">
|
||||
<FormattedMessage id="about.scratchForEducatorsLinkText" />
|
||||
</a>
|
||||
)
|
||||
}}
|
||||
|
@ -126,10 +131,38 @@ const About = () => (
|
|||
<FormattedMessage id="about.spfaLinkText" />
|
||||
</a>
|
||||
),
|
||||
lifelongKindergartenGroupLink: (
|
||||
<a href="https://www.media.mit.edu/groups/lifelong-kindergarten/overview/">
|
||||
<FormattedMessage id="about.lifelongKindergartenGroupLinkText" />
|
||||
</a>
|
||||
),
|
||||
codingAtACrossroadsLink: (
|
||||
<a
|
||||
href="https://cacm.acm.org/magazines/2020/11/248219-coding-at-a-crossroads/fulltext"
|
||||
rel="noreferrer noopener"
|
||||
target="_blank"
|
||||
>
|
||||
<FormattedMessage id="about.codingAtACrossroadsLinkText" />
|
||||
</a>
|
||||
),
|
||||
lifelongKindergartenBookLink: (
|
||||
<a
|
||||
href="https://mitpress.mit.edu/books/lifelong-kindergarten"
|
||||
rel="noreferrer noopener"
|
||||
target="_blank"
|
||||
>
|
||||
<FormattedMessage id="about.lifelongKindergartenBookLinkText" />
|
||||
</a>
|
||||
),
|
||||
statisticsLink: (
|
||||
<a href="/statistics">
|
||||
<FormattedMessage id="about.statisticsLinkText" />
|
||||
</a>
|
||||
),
|
||||
annualReportLink: (
|
||||
<a href="/annual-report">
|
||||
<FormattedMessage id="about.annualReportLinkText" />
|
||||
</a>
|
||||
)
|
||||
}}
|
||||
/></p>
|
||||
|
@ -161,14 +194,26 @@ const About = () => (
|
|||
<p><FormattedMessage
|
||||
id="about.supportDescription"
|
||||
values={{
|
||||
supportersList: 'National Science Foundation, Scratch Foundation, Siegel Family Endowment, Google, LEGO Foundation, Intel, Cartoon Network, Lemann Foundation, MacArthur Foundation', // eslint-disable-line max-len
|
||||
creditsLink: (
|
||||
<a href="/credits">
|
||||
<FormattedMessage id="about.creditsLinkText" />
|
||||
donorsLink: (
|
||||
<a
|
||||
href="https://www.scratchfoundation.org/supporters"
|
||||
rel="noreferrer noopener"
|
||||
target="_blank"
|
||||
>
|
||||
<FormattedMessage id="about.donorsLinkText" />
|
||||
</a>
|
||||
),
|
||||
annualReportLink: (
|
||||
<a href="/annual-report">
|
||||
<FormattedMessage id="about.annualReportLinkText" />
|
||||
</a>
|
||||
),
|
||||
donateLink: (
|
||||
<a href="//secure.donationpay.org/scratchfoundation/">
|
||||
<a
|
||||
href="//secure.donationpay.org/scratchfoundation/"
|
||||
rel="noreferrer noopener"
|
||||
target="_blank"
|
||||
>
|
||||
<FormattedMessage id="about.donateLinkText" />
|
||||
</a>
|
||||
),
|
||||
|
@ -179,6 +224,11 @@ const About = () => (
|
|||
)
|
||||
}}
|
||||
/></p>
|
||||
<a href="//secure.donationpay.org/scratchfoundation/">
|
||||
<Button className="about-button">
|
||||
<FormattedMessage id="about.donateButton" />
|
||||
</Button>
|
||||
</a>
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
|
|
|
@ -72,3 +72,24 @@
|
|||
}
|
||||
}
|
||||
}
|
||||
|
||||
.about-button {
|
||||
margin-right: .75rem;
|
||||
background-color: $ui-blue;
|
||||
color: $ui-white;
|
||||
font-size: 1rem;
|
||||
|
||||
img {
|
||||
margin-right: 1rem;
|
||||
height: 1.5rem;
|
||||
vertical-align: middle;
|
||||
}
|
||||
|
||||
a {
|
||||
color: $ui-white;
|
||||
}
|
||||
|
||||
span {
|
||||
vertical-align: middle;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
{
|
||||
"about.introOne": "With Scratch, you can program your own interactive stories, games, and animations — and share your creations with others in the online community.",
|
||||
"about.introTwo": "Scratch helps young people learn to think creatively, reason systematically, and work collaboratively — essential skills for life in the 21st century.",
|
||||
"about.introThree": "Scratch is a project of the Lifelong Kindergarten Group at the MIT Media Lab. It is provided free of charge.",
|
||||
"about.introThree": "Scratch is designed, developed, and moderated by the Scratch Foundation, a nonprofit organization. It is provided free of charge.",
|
||||
"about.introParents": "Info for parents",
|
||||
"about.introEducators": "Info for educators",
|
||||
"about.whoUsesScratch": "Who Uses Scratch?",
|
||||
|
@ -16,20 +16,26 @@
|
|||
"about.learnMoreHelp": "Ideas Page",
|
||||
"about.learnMoreFaq": "Frequently Asked Questions",
|
||||
"about.learnMoreParents": "Information for Parents",
|
||||
"about.learnMoreCredits": "Credits",
|
||||
"about.learnMoreCredits": "Our Team",
|
||||
"about.learnMoreAnnualReport": "Annual Report 2019",
|
||||
"about.literacy": "Learn to Code, Code to Learn",
|
||||
"about.literacyDescription": "The ability to code computer programs is an important part of literacy in today’s society. When people learn to code in Scratch, they learn important strategies for solving problems, designing projects, and communicating ideas.",
|
||||
"about.schools": "Scratch in Schools",
|
||||
"about.schoolsDescription": "Students are learning with Scratch at all levels (from elementary school to college) and across disciplines (such as math, computer science, language arts, social studies). Educators share stories, exchange resources, ask questions, and find people on the {scratchedLink}.",
|
||||
"about.schoolsDescription": "Students are learning with Scratch at all levels (from elementary school to college) and across disciplines (such as math, computer science, language arts, social studies). Educator resources are available on the {scratchForEducatorsLink} page.",
|
||||
"about.scratchForEducatorsLinkText": "Scratch For Educators",
|
||||
"about.scratchedLinkText": "ScratchEd website",
|
||||
"about.research": "Research",
|
||||
"about.researchDescription": "The MIT Scratch Team and collaborators are researching how people use and learn with Scratch (for an introduction, see {spfaLink}). Find out more about Scratch {researchLink} and {statisticsLink} about Scratch.",
|
||||
"about.researchDescription": "The {lifelongKindergartenGroupLink} and collaborators are researching how young people create, collaborate, and learn with Scratch. For an overview, see the article {codingAtACrossroadsLink} and the book {lifelongKindergartenBookLink}. To find out more about the use of Scratch, see the {statisticsLink} page and the Scratch {annualReportLink}.",
|
||||
"about.spfaLinkText": "Scratch: Programming for All",
|
||||
"about.researchLinkText": "research",
|
||||
"about.statisticsLinkText": "statistics",
|
||||
"about.lifelongKindergartenGroupLinkText": "Lifelong Kindergarten group",
|
||||
"about.codingAtACrossroadsLinkText": "Coding at a Crossroads",
|
||||
"about.lifelongKindergartenBookLinkText": "Lifelong Kindergarten",
|
||||
"about.annualReportLinkText": "Annual Report",
|
||||
"about.support": "Support and Funding",
|
||||
"about.supportDescription": "The Scratch project has received financial support from the following organizations: {supportersList}. See the {creditsLink} for more information. If you'd like to support Scratch, please see the Scratch Foundation {donateLink}, or contact us at {donateemail}.",
|
||||
"about.supportDescription": "Scratch is available for free, thanks to support from our {donorsLink}. For more information, see our {annualReportLink}. You can support Scratch by making a donation.",
|
||||
"about.donorsLinkText": "donors",
|
||||
"about.donateLinkText": "donations page",
|
||||
"about.creditsLinkText": "credits page"
|
||||
"about.donateButton": "Donate"
|
||||
}
|
||||
|
|
|
@ -5,22 +5,15 @@ const injectIntl = require('react-intl').injectIntl;
|
|||
const Page = require('../../components/page/www/page.jsx');
|
||||
const People = require('./people.json');
|
||||
const PeopleGrid = require('../../components/people-grid/people-grid.jsx');
|
||||
const Supporters = require('./supporters.json');
|
||||
const TitleBanner = require('../../components/title-banner/title-banner.jsx');
|
||||
|
||||
require('./credits.scss');
|
||||
|
||||
const Credits = () => (
|
||||
<div className="credits">
|
||||
<TitleBanner className="masthead mod-blue-bg">
|
||||
<h1 className="title-banner-h1">
|
||||
<FormattedMessage id="credits.title" />
|
||||
</h1>
|
||||
</TitleBanner>
|
||||
<div className="content">
|
||||
<div className="people">
|
||||
<div className="mid-header">
|
||||
<h2>MIT Scratch Team</h2>
|
||||
<h2>Our Team</h2>
|
||||
<p>
|
||||
<FormattedMessage id="credits.developers" />
|
||||
</p>
|
||||
|
@ -33,62 +26,109 @@ const Credits = () => (
|
|||
>
|
||||
<div className="mid-header">
|
||||
<h2>
|
||||
<FormattedMessage id="credits.currentSponsors" />
|
||||
<FormattedMessage id="credits.translationsTitle" />
|
||||
</h2>
|
||||
<p>
|
||||
<FormattedMessage id="credits.currentFinancialSupport" />
|
||||
<FormattedMessage
|
||||
id="credits.acknowledgementsTranslators"
|
||||
values={{
|
||||
translatorsLink: (
|
||||
<a
|
||||
href="https://en.scratch-wiki.info/wiki/Translators"
|
||||
rel="noreferrer noopener"
|
||||
target="_blank"
|
||||
>
|
||||
<FormattedMessage id="credits.acknowledgementsTranslatorsLinkText" />
|
||||
</a>
|
||||
)
|
||||
}}
|
||||
/>
|
||||
{' '}
|
||||
<FormattedMessage id="credits.acknowledgementsLanguageOrganizers" />
|
||||
{' '}
|
||||
<span>
|
||||
Brenda Nyaringita (Kiswahili), Hans de Jong (Nederlands),
|
||||
Farshid Meidani (فارسی), Karin Colsman (Gàidhlig).
|
||||
</span>
|
||||
</p>
|
||||
</div>
|
||||
<div className="logo-grid">
|
||||
{Supporters.map((supporter, index) => (
|
||||
<span
|
||||
className="logo"
|
||||
key={`logo-${index}`}
|
||||
>
|
||||
{supporter.logoDestination ? (<a href={supporter.logoDestination}>
|
||||
{supporter.logoSrc ? (
|
||||
<img
|
||||
alt=""
|
||||
src={supporter.logoSrc}
|
||||
width={supporter.width}
|
||||
/>
|
||||
) : (
|
||||
<div className="text-logo">
|
||||
{supporter.textLogo}
|
||||
</div>
|
||||
)}
|
||||
</a>) : (supporter.logoSrc ? (
|
||||
<img
|
||||
alt=""
|
||||
src={supporter.logoSrc}
|
||||
width={supporter.width}
|
||||
/>
|
||||
) : (
|
||||
<div className="text-logo">
|
||||
{supporter.textLogo}
|
||||
</div>
|
||||
))
|
||||
}
|
||||
</span>
|
||||
))}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div
|
||||
className="content"
|
||||
id="acknowledgements"
|
||||
>
|
||||
<div className="acknowledge-content">
|
||||
<h2>
|
||||
<FormattedMessage id="credits.translationsTitle" />
|
||||
<FormattedMessage id="credits.donorsTitle" />
|
||||
</h2>
|
||||
<p>
|
||||
<FormattedMessage
|
||||
id="credits.acknowledgementsTranslators"
|
||||
id="credits.acknowledgementsDonors"
|
||||
values={{
|
||||
translatorsLink: (
|
||||
<a href="https://en.scratch-wiki.info/wiki/Translators">
|
||||
<FormattedMessage id="credits.acknowledgementsTranslatorsLinkText" />
|
||||
donorsLink: (
|
||||
<a
|
||||
href="https://www.scratchfoundation.org/supporters"
|
||||
rel="noreferrer noopener"
|
||||
target="_blank"
|
||||
>
|
||||
<FormattedMessage id="credits.acknowledgementsDonorsLinkText" />
|
||||
</a>
|
||||
)
|
||||
}}
|
||||
/>
|
||||
</p>
|
||||
<h2>
|
||||
<FormattedMessage id="credits.lifelongKindergartenTitle" />
|
||||
</h2>
|
||||
<p>
|
||||
<FormattedMessage
|
||||
id="credits.acknowledgementsLifelongKindergarten"
|
||||
values={{
|
||||
lifelongKindergartenLink: (
|
||||
<a
|
||||
href="https://www.media.mit.edu/groups/lifelong-kindergarten/overview/"
|
||||
rel="noreferrer noopener"
|
||||
target="_blank"
|
||||
>
|
||||
<FormattedMessage id="credits.acknowledgementsLifelongKindergartenLinkText" />
|
||||
</a>
|
||||
),
|
||||
nsfGrantLink: (
|
||||
<a
|
||||
href="https://web.media.mit.edu/~mres/papers/scratch-proposal-handout.pdf"
|
||||
rel="noreferrer noopener"
|
||||
target="_blank"
|
||||
>
|
||||
<FormattedMessage id="credits.acknowledgementsNSFGrantLinkText" />
|
||||
</a>
|
||||
)
|
||||
}}
|
||||
/>
|
||||
</p>
|
||||
<h2>
|
||||
<FormattedMessage id="credits.pastContributors" />
|
||||
</h2>
|
||||
<p>
|
||||
<FormattedMessage id="credits.pastContributorsThanks" />
|
||||
</p>
|
||||
<p>
|
||||
Yusuf Ahmad, Ben Berg, Amos Blanton, Paula Bontá, Karen Brennan,
|
||||
Juanita Buitrago, Leo Burd, Gaia Carini, Kasia Chmielinski,
|
||||
Michelle Chung, Shane Clements, Hannah Cole, Sayamindu Dasgupta,
|
||||
Margarita Dekoli, Manuj Dhariwal, Shruti Dhariwal, Dave Feinberg,
|
||||
Linda Fernsel, Elizabeth Foster, Lily Gabaree, Stephanie Gayle,
|
||||
Chris Graves, Joel Gritter, Megan Haddadi, Kreg Hanning,
|
||||
Sean Hickey, Christina Huang, Cori Hudson, Tony Hwang,
|
||||
Abdulrahman Idlbi, Rupal Jain, Randy Jou, Lily Kim, Tauntaun Kim,
|
||||
Saskia Leggett, John Maloney, Tim Mickel, Amon Millner,
|
||||
Andrés Monroy-Hernández, Marian Muthui, My Nguyen, Lisa O'Brien,
|
||||
Abisola Okuk, Carmelo Presicce, Tina Quach, Mitchel Resnick,
|
||||
Ricarose Roque, Natalie Rusk, Andrea Saxman, Jay Silver,
|
||||
Brian Silverman, Andrew Sliwinski, Tammy Stern, Lis Sylvan,
|
||||
Hanako Tjia, Jaleesa Trapp, Moran Tsur, Claudia Urrea,
|
||||
Julia Zimmerman, Oren Zuckerman.
|
||||
</p>
|
||||
<h2>
|
||||
<FormattedMessage id="credits.illustrationsTitle" />
|
||||
</h2>
|
||||
|
@ -96,8 +136,9 @@ const Credits = () => (
|
|||
<FormattedMessage id="credits.acknowledgementsIllustrations" />
|
||||
</p>
|
||||
<p>
|
||||
Natalie Rosalinda Hall, Wren McDonald, Leigh McG, Andrew Rae, Daria Skrybchenko,
|
||||
Robert Hunter, Alex Eben Meyer, Ding Ding Hu, Owen Davey.
|
||||
Natalie Rosalinda Hall, Wren McDonald, Leigh McG, Andrew Rae, Daria
|
||||
Skrybchenko, Robert Hunter, Alex Eben Meyer, Ding Ding Hu, Owen
|
||||
Davey, Zoë Bentley, DD Liu, Kristin Osiecki, Kathy Wu.
|
||||
</p>
|
||||
<h2>
|
||||
<FormattedMessage id="credits.soundsTitle" />
|
||||
|
@ -114,80 +155,27 @@ const Credits = () => (
|
|||
lonemonk, rhodesmas, sandyrb, themfish, tyops.
|
||||
</p>
|
||||
<h2>
|
||||
<FormattedMessage id="credits.pastContributors" />
|
||||
</h2>
|
||||
<p>
|
||||
<FormattedMessage id="credits.pastContributorsThanks" />
|
||||
</p>
|
||||
<p>
|
||||
<FormattedMessage id="credits.otherContributors" />
|
||||
{' '}
|
||||
Ben Berg, Amos Blanton, Karen Brennan, Juanita Buitrago,
|
||||
Leo Burd, Gaia Carini, Kasia Chmielinski, Michelle Chung,
|
||||
Shane Clements, Hannah Cole, Sayamindu Dasgupta,
|
||||
Margarita Dekoli, Dave Feinberg, Linda Fernsel, Elizabeth Foster,
|
||||
Chris Graves, Joel Gritter, Megan Haddadi, Connor Hudson,
|
||||
Christina Huang, Tony Hwang, Abdulrahman Idlbi, Randy Jou,
|
||||
Lily Kim, Tauntaun Kim, Saskia Leggett, Tim Mickel,
|
||||
Amon Millner, My Nguyen, Lisa O'Brien, Abisola Okuk,
|
||||
Tina Quach, Ricarose Roque, Andrea Saxman, Jay Silver,
|
||||
Andrew Sliwinski, Tammy Stern, Lis Sylvan, Hanako Tjia,
|
||||
Claudia Urrea, Julia Zimmerman, Oren Zuckerman.
|
||||
</p>
|
||||
<p>
|
||||
<FormattedMessage id="credits.partnersBody" />
|
||||
</p>
|
||||
<h2>
|
||||
<FormattedMessage id="credits.researchersTitle" />
|
||||
</h2>
|
||||
<p>
|
||||
<FormattedMessage
|
||||
id="credits.researchersBody"
|
||||
values={{
|
||||
scratchResearchLink: (
|
||||
<a href="https://scratch.mit.edu/info/research/">
|
||||
<FormattedMessage id="credits.researchLinkText" />
|
||||
</a>
|
||||
)
|
||||
}}
|
||||
/>
|
||||
</p>
|
||||
<p>
|
||||
<FormattedMessage
|
||||
id="credits.researchersContributors"
|
||||
values={{
|
||||
nsfLink: (
|
||||
<a href="http://www.nsf.gov/awardsearch/showAward?AWD_ID=0325828">
|
||||
<FormattedMessage id="credits.researchNSFLinkText" />
|
||||
</a>
|
||||
),
|
||||
scratchEdLink: (
|
||||
<a href="http://scratched.gse.harvard.edu/">
|
||||
<FormattedMessage id="credits.researchScratchEdLinkText" />
|
||||
</a>
|
||||
)
|
||||
}}
|
||||
/>
|
||||
</p>
|
||||
<h2>
|
||||
<FormattedMessage id="credits.acknowledgementsTitle" />
|
||||
<FormattedMessage id="credits.acknowledgementsOtherContributors" />
|
||||
</h2>
|
||||
<p>
|
||||
<FormattedMessage id="credits.acknowledgementsContributors" />
|
||||
</p>
|
||||
<p>
|
||||
Susan Abend, Robbie Berg, Lauren Bessen, Keith Braadfladt, Katie Broida,
|
||||
Susan Carillo, Will Denton, Nathan Dinsmore, Catherine Feldman, Rachel Fenichel,
|
||||
Jodi Finch, Ioana Fineberg, Corey Frang, JT Galla, Rachel Garber, Cassy Gibbs,
|
||||
Z Goddard, Brian Harvey, Roland Hebert, Tracy Ho, Benjamin Howe, Kapaya Katongo,
|
||||
Evan Karatzas, Christine Kim, Joren Lauwers, Mike Lee, Jeff Lieberman,
|
||||
Mark Loughridge, Kelly Liu, Anthony Lu, Danny Lutz, David Malan
|
||||
Wayne Marshall, John McIntosh, Paul Medlock-Walton, Dongfang (Tian) Mi,
|
||||
Ximena Miranda, Jens Moenig, Evan Moore, Geetha Narayanan, Kate Nazemi,
|
||||
Liddy Nevile, Wing Ngan, Derek O'Connell, Tim Radvan, Karen Randall,
|
||||
Ian Reynolds, Miriam Ruiz, Boaz Sender, Chinua Shaw, Ed Shems, Cynthia Solomon,
|
||||
Marie Staver, Daniel Strimpel, Kilmer Sweazy, John Henry Thompson, Ubong Ukoh,
|
||||
Vladimir Vuksan, Han Xu.
|
||||
Susan Abend, Robbie Berg, Lauren Bessen, Keith Braadfladt,
|
||||
Katie Broida, Susan Carillo, Will Denton, Nathan Dinsmore,
|
||||
Catherine Feldman, Rachel Fenichel, Jodi Finch, Ioana Fineberg,
|
||||
Corey Frang, JT Galla, Rachel Garber, Cassy Gibbs, Z Goddard,
|
||||
Brian Harvey, Roland Hebert, Tracy Ho, Benjamin Howe,
|
||||
Yasmin Kafai, Kapaya Katongo, Evan Karatzas, Christine Kim,
|
||||
Joren Lauwers, Mike Lee, Jeff Lieberman, Mark Loughridge,
|
||||
Kelly Liu, Anthony Lu, Danny Lutz, David Malan Wayne Marshall,
|
||||
John McIntosh, Paul Medlock-Walton, Dongfang (Tian) Mi,
|
||||
Ximena Miranda, Jens Moenig, Evan Moore, Geetha Narayanan,
|
||||
Kate Nazemi, Liddy Nevile, Wing Ngan, Derek O'Connell,
|
||||
Tim Radvan, Karen Randall, Ian Reynolds, Miriam Ruiz,
|
||||
Boaz Sender, Chinua Shaw, Ed Shems, Cynthia Solomon,
|
||||
Marie Staver, Daniel Strimpel, Kilmer Sweazy,
|
||||
John Henry Thompson, Ubong Ukoh, Vladimir Vuksan, Han Xu.
|
||||
</p>
|
||||
<p>
|
||||
<FormattedMessage id="credits.acknowledgementsInfluencers" />
|
||||
|
|
|
@ -9,6 +9,10 @@
|
|||
.content {
|
||||
padding-top: 40px;
|
||||
}
|
||||
|
||||
#acknowledgements {
|
||||
background-color: rgba(77, 151, 255, 0.15);
|
||||
}
|
||||
|
||||
.avatar-grid {
|
||||
padding: 64px 0;
|
||||
|
@ -61,9 +65,7 @@
|
|||
}
|
||||
|
||||
.supporters {
|
||||
$bg-grey: #f7f6f8;
|
||||
background-color: $bg-grey;
|
||||
padding: 5.25rem 0;
|
||||
padding: 0 0 5.25rem;
|
||||
}
|
||||
|
||||
.logo {
|
||||
|
@ -81,6 +83,11 @@
|
|||
font-size: 2rem;
|
||||
}
|
||||
|
||||
#donors {
|
||||
max-width: 980px;
|
||||
margin-left: auto;
|
||||
margin-right: auto;
|
||||
}
|
||||
}
|
||||
|
||||
@media only screen and (min-width: 477px) and (max-width: 768px) {
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
{
|
||||
"credits.title": "Scratch Credits & Contributors",
|
||||
"credits.developers": "Scratch is designed, developed, and moderated by the Lifelong Kindergarten Group at MIT Media Lab:",
|
||||
"credits.developers": "Scratch is designed, developed, and moderated by the staff of the Scratch Foundation, a nonprofit organization.",
|
||||
"credits.moderators": "The team of Scratch moderators manages, supports, and improves the Scratch online community:",
|
||||
"credits.previousTitle": "Previous MIT Scratch Team Members",
|
||||
"credits.previousBody": "Many important contributions have been made by previous Scratch Team members, including John Maloney (who led software development for the first decade of Scratch) and Andrés Monroy-Hernández (who led the development of the first Scratch community website). Other contributors include:",
|
||||
|
@ -15,7 +15,13 @@
|
|||
"credits.researchScratchEdLinkText" : "ScratchEd project",
|
||||
"credits.acknowledgementsTitle": "Acknowledgements",
|
||||
"credits.acknowledgementsContributors": "The following people have also contributed to the development and support of Scratch over the years:",
|
||||
"credits.acknowledgementsDonors": "The Scratch Foundation is a 501(c)(3) non-profit that relies on tax-deductible donations to support Scratch and keep it free for all. For a list of donors to the Scratch Foundation, please visit the {donorsLink}.",
|
||||
"credits.acknowledgementsDonorsLinkText": "Supporters page",
|
||||
"credits.acknowledgementsLifelongKindergarten": "The {lifelongKindergartenLink} at the MIT Media Lab initiated the Scratch project in 2002, and received a {nsfGrantLink} to support it a year later. The group publicly launched Scratch in 2007 and developed it through 2019, when the Scratch Team moved to the Scratch Foundation. The Lifelong Kindergarten group, led by Professor Mitchel Resnick, continues to collaborate with the Scratch Team to research and support creative learning with Scratch around the world.",
|
||||
"credits.acknowledgementsLifelongKindergartenLinkText": "Lifelong Kindergarten research group",
|
||||
"credits.acknowledgementsNSFGrantLinkText": "National Science Foundation Grant",
|
||||
"credits.acknowledgementsTranslators": "With the help of {translatorsLink} around the world, Scratch is available in many languages.",
|
||||
"credits.acknowledgementsLanguageOrganizers": "Many thanks to the following language organizers for helping to coordinate Scratch translators in their language:",
|
||||
"credits.acknowledgementsTranslatorsLinkText": "Scratch Translators",
|
||||
"credits.acknowledgementsCommunity": "We greatly appreciate all of the contributions by members of the worldwide Scratch community, who have shaped the direction of Scratch by sharing their projects, comments, and ideas.",
|
||||
"credits.acknowledgementsInfluencers": "The ideas of Seymour Papert and Alan Kay have deeply inspired and influenced our work on Scratch.",
|
||||
|
@ -25,12 +31,15 @@
|
|||
"credits.supportersOpenHeader": "Scratch would not be possible without free and open source software, including:",
|
||||
"credits.currentSponsors": "Current Sponsors",
|
||||
"credits.currentFinancialSupport": "The following organizations are providing major financial support for Scratch:",
|
||||
"credits.translationsTitle": "Translations",
|
||||
"credits.donorsTitle": "Donors",
|
||||
"credits.lifelongKindergartenTitle": "Lifelong Kindergarten Group",
|
||||
"credits.translationsTitle": "Translators",
|
||||
"credits.illustrationsTitle": "Illustrations",
|
||||
"credits.acknowledgementsIllustrations": "Many thanks to the following artists for their contributions to the Scratch sprite library:",
|
||||
"credits.soundsTitle": "Sounds",
|
||||
"credits.pastContributors": "Past Contributors",
|
||||
"credits.pastContributorsThanks" : "Many important contributions have been made by previous Scratch Team members, including John Maloney (who led software development for the first decade of Scratch) and Andrés Monroy-Hernández (who led the development of the first Scratch community website).",
|
||||
"credits.pastContributors": "Past Scratch Team Members",
|
||||
"credits.pastContributorsThanks" : "Many important contributions have been made by previous Scratch Team members, including:",
|
||||
"credits.acknowledgementsOtherContributors": "Past Contributors",
|
||||
"credits.otherContributors": "Other contributors include:",
|
||||
"credits.acknowledgementsSounds": "The Scratch sound library uses free sound resources from Adobe.com, Archive.org, FreeMusicArchive.org, FreeSound.org, and Incompetech.com.",
|
||||
"credits.soundsThanks":"Thanks to Nina Paley from Archive.org; Kellee Maize, Peter Rudenko, and Chris Zabriskie from FreeMusicArchive.org; and Kevin MacLeod from Incompetech.com. Thanks to the following freesound.org artists:"
|
||||
|
|
|
@ -1,4 +1,9 @@
|
|||
[
|
||||
{
|
||||
"userName": "cosmosaura",
|
||||
"userId": 61436283,
|
||||
"name": "Achal"
|
||||
},
|
||||
{
|
||||
"userName": "originalwow",
|
||||
"userId": 56182496,
|
||||
|
@ -29,11 +34,6 @@
|
|||
"userId": 3581881,
|
||||
"name": "Carl"
|
||||
},
|
||||
{
|
||||
"userName": "tarmelop",
|
||||
"userId": 2286560,
|
||||
"name": "Carmelo"
|
||||
},
|
||||
{
|
||||
"userName": "Champ99",
|
||||
"userId": 900283,
|
||||
|
@ -69,11 +69,6 @@
|
|||
"userId": 55851826,
|
||||
"name": "Craig"
|
||||
},
|
||||
{
|
||||
"userName": "Harakou",
|
||||
"userId": 373646,
|
||||
"name": "Dalton"
|
||||
},
|
||||
{
|
||||
"userName": "dsquare",
|
||||
"userId": 527836,
|
||||
|
@ -99,16 +94,16 @@
|
|||
"userId": 159139,
|
||||
"name": "Franchette"
|
||||
},
|
||||
{
|
||||
"userName": "starry_sky7",
|
||||
"userId": 61374093,
|
||||
"name": "Iuliia"
|
||||
},
|
||||
{
|
||||
"userName": "pixelmoth",
|
||||
"userId": 2408962,
|
||||
"name": "Jacy"
|
||||
},
|
||||
{
|
||||
"userName": "jaleesa",
|
||||
"userId": 2374106,
|
||||
"name": "Jaleesa"
|
||||
},
|
||||
{
|
||||
"userName": "Mos20",
|
||||
"userId": 52545208,
|
||||
|
@ -149,41 +144,21 @@
|
|||
"userId": 26779669,
|
||||
"name": "Kathy"
|
||||
},
|
||||
{
|
||||
"userName": "khanning",
|
||||
"userId": 1553886,
|
||||
"name": "Kreg"
|
||||
},
|
||||
{
|
||||
"userName": "KayOh",
|
||||
"userId": 3018280,
|
||||
"name": "Kristin"
|
||||
},
|
||||
{
|
||||
"userName": "labdalla",
|
||||
"userId": 35687410,
|
||||
"name": "Lena"
|
||||
},
|
||||
{
|
||||
"userName": "leoburd",
|
||||
"userId": 385,
|
||||
"name": "Leo"
|
||||
},
|
||||
{
|
||||
"userName": "lilyland",
|
||||
"userId": 17184580,
|
||||
"name": "Lily"
|
||||
"userName": "Lamatchalattei",
|
||||
"userId": 61415372,
|
||||
"name": "Lamar"
|
||||
},
|
||||
{
|
||||
"userName": "algorithmar",
|
||||
"userId": 43013126,
|
||||
"name": "Maren"
|
||||
},
|
||||
{
|
||||
"userName": "mwikali",
|
||||
"userId": 24838781,
|
||||
"name": "Marian"
|
||||
},
|
||||
{
|
||||
"userName": "dietbacon",
|
||||
"userId": 24137617,
|
||||
|
@ -194,16 +169,6 @@
|
|||
"userId": 49156,
|
||||
"name": "Mark"
|
||||
},
|
||||
{
|
||||
"userName": "mres",
|
||||
"userId": 167,
|
||||
"name": "Mitchel"
|
||||
},
|
||||
{
|
||||
"userName": "natalie",
|
||||
"userId": 169,
|
||||
"name": "Natalie"
|
||||
},
|
||||
{
|
||||
"userName": "sgcc_",
|
||||
"userId": 21986973,
|
||||
|
@ -214,35 +179,45 @@
|
|||
"userId": 2584924,
|
||||
"name": "Ray"
|
||||
},
|
||||
{
|
||||
"userName": "rtrvmwe",
|
||||
"userId": 61342326,
|
||||
"name": "Retrouvailles"
|
||||
},
|
||||
{
|
||||
"userName": "binnieb",
|
||||
"userId": 53715539,
|
||||
"name": "Robyn"
|
||||
},
|
||||
{
|
||||
"userName": "rupalax",
|
||||
"userId": 58005604,
|
||||
"name": "Rupa"
|
||||
},
|
||||
{
|
||||
"userName": "scmb1",
|
||||
"userId": 246290,
|
||||
"name": "Sarah"
|
||||
},
|
||||
{
|
||||
"userName": "pizzafordessert",
|
||||
"userId": 22183577,
|
||||
"name": "Sean"
|
||||
"userName": "Onyx45",
|
||||
"userId": 63526043,
|
||||
"name": "Shawna"
|
||||
},
|
||||
{
|
||||
"userName": "shruti",
|
||||
"userId": 3714374,
|
||||
"name": "Shruti"
|
||||
"userName": "sgste735",
|
||||
"userId": 69368419,
|
||||
"name": "Stephanie"
|
||||
},
|
||||
{
|
||||
"userName": "Pandatt",
|
||||
"userId": 18417774,
|
||||
"name": "Tracy"
|
||||
"userName": "LT7845",
|
||||
"userId": 68837085,
|
||||
"name": "Tasha"
|
||||
},
|
||||
{
|
||||
"userName": "shaanmasala",
|
||||
"userId": 29995562,
|
||||
"name": "Yusuf"
|
||||
"userName": "Pandatt",
|
||||
"userId": 18417774,
|
||||
"name": "Tracy"
|
||||
},
|
||||
{
|
||||
"userName": "Za-Chary",
|
||||
|
|
|
@ -224,6 +224,12 @@ class ComposeComment extends React.Component {
|
|||
muteStepHeader: 'comment.vulgarity.header',
|
||||
muteStepContent: ['comment.vulgarity.content1', 'comment.vulgarity.content2']
|
||||
},
|
||||
spam: {
|
||||
name: 'spam',
|
||||
commentType: 'comment.type.spam',
|
||||
muteStepHeader: 'comment.spam.header',
|
||||
muteStepContent: ['comment.spam.content1', 'comment.spam.content2']
|
||||
},
|
||||
general: {
|
||||
name: 'general',
|
||||
commentType: 'comment.type.general',
|
||||
|
|
|
@ -61,5 +61,9 @@
|
|||
"comment.type.vulgarity": "Your most recent comment appeared to include a bad word.",
|
||||
"comment.vulgarity.header": "We encourage you to use language that’s appropriate for all ages.",
|
||||
"comment.vulgarity.content1": "It appears that your comment contains a bad word.",
|
||||
"comment.vulgarity.content2": "Scratch has users of all ages, so it’s important to use language that is appropriate for all Scratchers."
|
||||
"comment.vulgarity.content2": "Scratch has users of all ages, so it’s important to use language that is appropriate for all Scratchers.",
|
||||
"comment.type.spam": "Your most recent comment appeared to contain advertising, text art, or a chain message.",
|
||||
"comment.spam.header": "We encourage you not to advertise, copy and paste text art, or ask others to copy comments.",
|
||||
"comment.spam.content1": "Even though advertisements, text art, and chain mail can be fun, they start to fill up the website, and we want to make sure there is room for other comments.",
|
||||
"comment.spam.content2": "Thank you for helping us keep Scratch a friendly, creative community!"
|
||||
}
|
||||
|
|
Binary file not shown.
Before ![]() (image error) Size: 228 KiB After ![]() (image error) Size: 84 KiB ![]() ![]() |
|
@ -1,8 +0,0 @@
|
|||
{
|
||||
"plugins": [
|
||||
"cypress"
|
||||
],
|
||||
"env": {
|
||||
"cypress/globals": true
|
||||
}
|
||||
}
|
|
@ -1,139 +0,0 @@
|
|||
## Cypress tests
|
||||
|
||||
### What is this?
|
||||
Cypress is an end to end testing tool that we are using to do integration tests on Scratch.
|
||||
|
||||
It behaves in some ways like selenium but does not use selenium at all. It is simpler to implement, easier to read and includes features that make debugging easier.
|
||||
### Install cypress
|
||||
To install in the command line you'll need npm installed. Navigate to this folder and run:
|
||||
|
||||
`npm install`
|
||||
|
||||
If you would like to install it in other projects run this:
|
||||
|
||||
`npm install cypress --save-dev`
|
||||
|
||||
Cypress also has a gui client. To get the gui you can download it from cypress.io.
|
||||
|
||||
### Run tests
|
||||
To run all of the tests in chrome from the command line, enter `npm run test-all`. To run headless enter `npm run test-all-headless`. This will run through all of the tests in the smoke-tests folder.
|
||||
|
||||
To run tests directly, without using npm, enter `./node_modules/.bin/cypress run`.
|
||||
|
||||
### Run a single test file
|
||||
Append `-s ./path/to/test/file` (or `-spec ./path/to/test/file`) to the command to run just that one suite of tests. If using `npm run` you must add an add an additional `--` before the arguments in order to pass them in:
|
||||
|
||||
`npm run test-all -- -s ./cypress/smoke-tests/the-test-I-want-to-run`
|
||||
|
||||
###Writing tests
|
||||
Tests are held in functions that take the following form:
|
||||
|
||||
```
|
||||
it('name of test', function(){
|
||||
...
|
||||
...
|
||||
});
|
||||
```
|
||||
Commands that you run in tests almost always start with a `cy` object which contains functions for going to urls, finding objects on the page, etc. Any objects found are returned, so functions can be chained. For preference chaining should be structured like this:
|
||||
|
||||
```
|
||||
cy
|
||||
.visit("");
|
||||
cy
|
||||
.get('.logo a')
|
||||
.click();
|
||||
```
|
||||
|
||||
### get and visit
|
||||
`cy.visit()` is the command used for loading web pages. It takes a url string as an argument.
|
||||
|
||||
`cy.get()` is used to find elements on a page. It uses jquery.
|
||||
|
||||
This is slightly different from how Selenium does it. For more on how to write tests see the documentation on cypress.io. It is pretty good for the most part.
|
||||
|
||||
### Promises
|
||||
Cypress has a built in promise manager and basically already turns every line of code into a promise for you so you can write code like it was synchronous.
|
||||
|
||||
### Assertions
|
||||
There are a few ways to put assertions into tests but mainly we use `should()` which can be put at the end of a chain and takes objects passed in from the chain as the first element to compare. `should()` can take two arguments, a comparison type and what to compare it to, or one argument that is a chainer similar to how it is done using Chai.
|
||||
|
||||
For more information check out the Cypress documentation on these topics.
|
||||
|
||||
Assertions aren't strictly necessary since a test will fail if any step in it fails. They are useful for making sure that you have gotten to the right page.
|
||||
|
||||
### Suites
|
||||
Tests can be organized in suites using describe:
|
||||
|
||||
```
|
||||
describe('name of suite', function(){
|
||||
it('test 1', function(){
|
||||
...
|
||||
});
|
||||
|
||||
it('test 2', function(){
|
||||
...
|
||||
})
|
||||
|
||||
});
|
||||
```
|
||||
|
||||
### Supported Browsers
|
||||
Currently it defaults to running headless in Electron but it also supports Chrome.
|
||||
|
||||
Add `--browser chrome` to the command line when running the tests to run in chrome.
|
||||
|
||||
Firefox is not yet supported as of March 2018 but they are working on it.
|
||||
|
||||
### Environment variables
|
||||
To pass in environment variables, such as USERNAME and PASSWORD for a test user you add them before calling cypress run by adding CYPRESS_ before the variable name.
|
||||
|
||||
It will look like this: `CYPRESS_USERNAME=made-up-name`
|
||||
|
||||
Alternatively you can add to the command `--env USERNAME=made-up-name`, but this is not preferred. If following `npm run` you must add an aditional `--` before adding arguments similar to how it is described in Run a single test (above).
|
||||
|
||||
### configuration (cypress.json)
|
||||
Cypress uses a configuration file `./cypress.json` which contains environment variables and other information.
|
||||
|
||||
To access any variable you put in the configuration file from within your test code type `Cypress.config('property_you_want')`.
|
||||
|
||||
There is a special case for accessing environment variables stored in the `env : {}` object: `Cypress.env('environment_variable_you_want')` This is also how you access any environment variables passed in from the command line.
|
||||
|
||||
### more configuration (cypress.env.json)
|
||||
You can add configuration or environment variables in the same way listed above to another json file called `cypress.env.json`. This file will overwrite whatever is in `cypress.json`. This file is untracked in git, so is useful for information that you don't want shared, such as username and password environment variables.
|
||||
|
||||
### Base URL
|
||||
Cypress hates it when you use a base url as an environment variable. If you try it gives strange results. The base URL is set in `cypress.json` as its own variable `"baseUrl" : "https://scratch.ly"`.
|
||||
|
||||
This is automatically appended to `visit()` command arguments which are used to load webpages. It appends it, so you need to include a string as an argument so you would have to write it as `visit("")` or `visit("/")`.
|
||||
|
||||
To overwrite the baseUrl variable from the command line you need to change it just like it is an environment variable (above): `CYPRESS_baseUrl=https://scratch.mit.ed`.
|
||||
|
||||
Alternatively you could change it like this after calling cypress : `--config baseUrl=https://scratch.mit.edu`
|
||||
|
||||
### .only
|
||||
If you would like to only run one test in a file you can change `it(...)` to `it.only(...)` and it will run just that one test.
|
||||
|
||||
Similarly you can run a suite of tests from a file by adding `.only` to a `describe(...)` function so it looks like this: `describe.only(...)`. This will run all tests in that suite and no others.
|
||||
|
||||
ONLY USE ONE ONLY
|
||||
|
||||
If you use more than one `.only` anywhere in the file it will give you unpredictable results. This includes if you put one on a collection and one on an individual test.
|
||||
|
||||
### .skip
|
||||
If you would like to skip a test in a file you can cahnge the `it(...)` to `it.skip(...)` similarly to how you use only (above).
|
||||
|
||||
Skip can be used on individual tests and on suites:
|
||||
|
||||
`describe.skip(...)`
|
||||
|
||||
You can use any number of skips. If you skip a suite it till skip all of the tests inside.
|
||||
|
||||
### Cookies
|
||||
By default Cypress deletes all cookies between tests. This means that if you want to remain signed in you must manually keep the session data cookie by including this code in a beforeEach() function:
|
||||
|
||||
`Cypress.Cookies.preserveOnce('scratchsessionsid')`
|
||||
|
||||
### The GUI
|
||||
The gui, which can be downloaded at cypress.io, is useful especially if you want to look back through the state of tests after they have been run. If you run in chrome from the command line the browser closes at the end of the tests.
|
||||
|
||||
The gui captures the state of the DOM at each step of each test. You can mouse over a step and it will show you want was happening at that time. If you click on the step you can even inspect elements, which is useful for debugging.
|
|
@ -1,10 +0,0 @@
|
|||
{
|
||||
"baseUrl" : "https://scratch.ly",
|
||||
"chromeWebSecurity" : false,
|
||||
"integrationFolder" : "./cypress/smoke-tests",
|
||||
"env": {
|
||||
"USERNAME" : " ",
|
||||
"PASSWORD" : " "
|
||||
}
|
||||
|
||||
}
|
|
@ -1,298 +0,0 @@
|
|||
const baseUrl = Cypress.config('baseUrl');
|
||||
|
||||
describe('test About links in footer', function () {
|
||||
beforeEach(function (){
|
||||
cy.visit('/');
|
||||
|
||||
});
|
||||
|
||||
after(function (){
|
||||
// this is here to fix the problem with the statistics page causing
|
||||
// the next test to fail. Since it is a before each it makes the rest
|
||||
// of all the tests fail. If it happens in an after, the beforeEach is fine
|
||||
cy.visit('/');
|
||||
});
|
||||
|
||||
it('click About Scratch', function (){
|
||||
cy
|
||||
.get('.lists :first-child :nth-child(2) :first-child :first-child')
|
||||
.click();
|
||||
cy
|
||||
.url()
|
||||
.should('eq', baseUrl + '/about');
|
||||
});
|
||||
|
||||
it('click For Parents', function (){
|
||||
cy
|
||||
.get('.lists :first-child :nth-child(3) :first-child :first-child')
|
||||
.click();
|
||||
cy
|
||||
.url()
|
||||
.should('eq', baseUrl + '/parents/');
|
||||
});
|
||||
|
||||
it('click For Educators', function (){
|
||||
cy
|
||||
.get('.lists :first-child :nth-child(4) :first-child :first-child')
|
||||
.click();
|
||||
|
||||
cy
|
||||
.url()
|
||||
.should('eq', baseUrl + '/educators');
|
||||
});
|
||||
|
||||
it('click For Developers', function (){
|
||||
cy
|
||||
.get('.lists :first-child :nth-child(5) :first-child :first-child')
|
||||
.click();
|
||||
|
||||
cy
|
||||
.url()
|
||||
.should('eq', baseUrl + '/developers');
|
||||
});
|
||||
|
||||
it('click Credits', function (){
|
||||
cy
|
||||
.get('.lists :first-child :nth-child(6) :first-child :first-child')
|
||||
.click();
|
||||
|
||||
cy
|
||||
.url()
|
||||
.should('eq', baseUrl + '/info/credits');
|
||||
});
|
||||
|
||||
it('click Jobs', function (){
|
||||
cy
|
||||
.get('.lists :first-child :nth-child(7) :first-child :first-child')
|
||||
.click();
|
||||
|
||||
cy
|
||||
.url()
|
||||
.should('eq', baseUrl + '/jobs');
|
||||
});
|
||||
|
||||
it.skip('click Press', function (){
|
||||
cy
|
||||
.get('.lists :first-child :nth-child(8) :first-child :first-child')
|
||||
.click();
|
||||
|
||||
cy
|
||||
.url()
|
||||
.should('match', /https:\/\/www\.scratchfoundation\.org\/media-kit\/?$/);
|
||||
});
|
||||
|
||||
});
|
||||
|
||||
describe('test Community links in footer', function () {
|
||||
beforeEach(function (){
|
||||
cy.visit('/');
|
||||
});
|
||||
|
||||
after(function (){
|
||||
cy.visit('/');
|
||||
});
|
||||
|
||||
it('click Community Guidelines', function (){
|
||||
cy
|
||||
.get('.lists :nth-child(2) :nth-child(2) :first-child :first-child')
|
||||
.click();
|
||||
|
||||
cy
|
||||
.url()
|
||||
.should('eq', baseUrl + '/community_guidelines');
|
||||
});
|
||||
|
||||
it('click Discussion Forums', function (){
|
||||
cy
|
||||
.get('.lists :nth-child(2) :nth-child(3) :first-child :first-child')
|
||||
.click();
|
||||
|
||||
cy
|
||||
.url()
|
||||
.should('eq', baseUrl + '/discuss/');
|
||||
});
|
||||
|
||||
it.skip('click Scratch Wiki', function (){
|
||||
cy
|
||||
.get('.lists :nth-child(2) :nth-child(4) :first-child :first-child')
|
||||
.click();
|
||||
|
||||
cy
|
||||
.url()
|
||||
.should('match', /https:\/\/wiki\.scratch\.mit\.edu\/wiki\/Scratch_Wiki_Home\/?$/);
|
||||
});
|
||||
|
||||
it('click Statistics', function (){
|
||||
cy
|
||||
.get('.lists :nth-child(2) :nth-child(5) :first-child :first-child')
|
||||
.click();
|
||||
|
||||
cy
|
||||
.url()
|
||||
.should('eq', baseUrl + '/statistics/');
|
||||
});
|
||||
|
||||
});
|
||||
|
||||
describe('test Support links in footer', function () {
|
||||
beforeEach(function (){
|
||||
cy.visit('/');
|
||||
});
|
||||
|
||||
after(function (){
|
||||
cy.visit('/');
|
||||
});
|
||||
|
||||
it('click Tips', function (){
|
||||
cy
|
||||
.get('.lists :nth-child(3) :nth-child(2) :first-child :first-child')
|
||||
.click();
|
||||
cy
|
||||
.url()
|
||||
.should('eq', baseUrl + '/tips');
|
||||
});
|
||||
|
||||
it('click For FAQ', function (){
|
||||
cy
|
||||
.get('.lists :nth-child(3) :nth-child(3) :first-child :first-child')
|
||||
.click();
|
||||
cy
|
||||
.url()
|
||||
.should('eq', baseUrl + '/info/faq');
|
||||
});
|
||||
|
||||
it('click Offline Editor', function (){
|
||||
cy
|
||||
.get('.lists :nth-child(3) :nth-child(4) :first-child :first-child')
|
||||
.click();
|
||||
|
||||
cy
|
||||
.url()
|
||||
.should('eq', baseUrl + '/download');
|
||||
});
|
||||
|
||||
it('click Contact Us', function (){
|
||||
cy
|
||||
.get('.lists :nth-child(3) :nth-child(5) :first-child :first-child')
|
||||
.click();
|
||||
|
||||
cy
|
||||
.url()
|
||||
.should('eq', baseUrl + '/contact-us/');
|
||||
});
|
||||
|
||||
it('click Scratch Store', function (){
|
||||
cy
|
||||
.get('.lists :nth-child(3) :nth-child(6) :first-child :first-child')
|
||||
.click();
|
||||
|
||||
cy
|
||||
.url()
|
||||
.should('match', /^https:\/\/scratch-foundation\.myshopify\.com\/?$/);
|
||||
});
|
||||
|
||||
it('click Donate', function (){
|
||||
cy
|
||||
.get('.lists :nth-child(3) :nth-child(7) :first-child :first-child')
|
||||
.click();
|
||||
|
||||
cy
|
||||
.url()
|
||||
.should('match', /^https:\/\/secure\.donationpay\.org\/scratchfoundation\/?/);
|
||||
});
|
||||
|
||||
});
|
||||
|
||||
describe('test Legal links in footer', function () {
|
||||
beforeEach(function (){
|
||||
cy.visit('/');
|
||||
});
|
||||
|
||||
after(function (){
|
||||
cy.visit('/');
|
||||
});
|
||||
|
||||
it('click Terms of Use', function (){
|
||||
cy
|
||||
.get('.lists :nth-child(4) :nth-child(2) :first-child :first-child')
|
||||
.click();
|
||||
cy
|
||||
.url()
|
||||
.should('eq', baseUrl + '/terms_of_use');
|
||||
});
|
||||
|
||||
it('click For Privacy Policy', function (){
|
||||
cy
|
||||
.get('.lists :nth-child(4) :nth-child(3) :first-child :first-child')
|
||||
.click();
|
||||
cy
|
||||
.url()
|
||||
.should('eq', baseUrl + '/privacy_policy');
|
||||
});
|
||||
|
||||
it('click DMCA', function (){
|
||||
cy
|
||||
.get('.lists :nth-child(4) :nth-child(4) :first-child :first-child')
|
||||
.click();
|
||||
|
||||
cy
|
||||
.url()
|
||||
.should('eq', baseUrl + '/DMCA');
|
||||
});
|
||||
|
||||
});
|
||||
|
||||
describe('test Scratch Family links in footer', function () {
|
||||
beforeEach(function (){
|
||||
cy.visit('/');
|
||||
});
|
||||
|
||||
it.skip('click ScratchEd', function (){
|
||||
cy
|
||||
.get('.lists :nth-child(5) :nth-child(2) a')
|
||||
.click();
|
||||
cy
|
||||
.url()
|
||||
.should('match', /^http:\/\/scratched\.gse\.harvard\.edu\/?$/);
|
||||
});
|
||||
|
||||
it.skip('click For ScratchJr', function (){
|
||||
cy
|
||||
.get('.lists :nth-child(5) :nth-child(3) a')
|
||||
.click();
|
||||
cy
|
||||
.url()
|
||||
.should('match', /^https:\/\/www\.scratchjr\.org\/?$/);
|
||||
});
|
||||
|
||||
it.skip('click Scratch Day', function (){
|
||||
cy
|
||||
.get('.lists :nth-child(5) :nth-child(4) a')
|
||||
.click();
|
||||
|
||||
cy
|
||||
.url()
|
||||
.should('match', /^https:\/\/day\.scratch\.mit\.edu\/?$/);
|
||||
});
|
||||
|
||||
it('click Scratch Conference', function (){
|
||||
cy
|
||||
.get('.lists :nth-child(5) :nth-child(5) :first-child :first-child')
|
||||
.click();
|
||||
|
||||
cy
|
||||
.url()
|
||||
.should('eq', baseUrl + '/conference');
|
||||
});
|
||||
|
||||
it.skip('click Scratch Foundation', function (){
|
||||
cy
|
||||
.get('.lists :nth-child(5) :nth-child(6) :first-child :first-child')
|
||||
.click();
|
||||
|
||||
cy
|
||||
.url()
|
||||
.should('match', /^https:\/\/www\.scratchfoundation\.org\/?$/);
|
||||
});
|
||||
|
||||
});
|
|
@ -1,188 +0,0 @@
|
|||
const baseUrl = Cypress.config('baseUrl');
|
||||
const username = Cypress.env('USERNAME');
|
||||
const password = Cypress.env('PASSWORD');
|
||||
|
||||
describe('test links in nav bar while signed out', function (){
|
||||
beforeEach(function (){
|
||||
cy.visit('');
|
||||
});
|
||||
|
||||
it('click SCRATCH', function (){
|
||||
cy
|
||||
.get('.logo')
|
||||
.click();
|
||||
cy
|
||||
.url()
|
||||
.should('eq', baseUrl + '/');
|
||||
});
|
||||
|
||||
it('click Create', function (){
|
||||
cy
|
||||
.get('.link.create')
|
||||
.click();
|
||||
cy
|
||||
.url()
|
||||
.should('eq', baseUrl + '/projects/editor/?tutorial=getStarted');
|
||||
});
|
||||
|
||||
it('click Explore', function (){
|
||||
cy
|
||||
.get('.link.explore')
|
||||
.click();
|
||||
cy
|
||||
.url()
|
||||
.should('eq', baseUrl + '/explore/projects/all');
|
||||
});
|
||||
|
||||
it('click Tips', function (){
|
||||
cy
|
||||
.get('.link.tips')
|
||||
.click();
|
||||
cy
|
||||
.url()
|
||||
.should('eq', baseUrl + '/tips');
|
||||
});
|
||||
|
||||
it('click About', function (){
|
||||
cy
|
||||
.get('.link.about')
|
||||
.click();
|
||||
cy
|
||||
.url()
|
||||
.should('eq', baseUrl + '/about');
|
||||
});
|
||||
|
||||
|
||||
it('submit empty Search', function (){
|
||||
cy
|
||||
.get('.search .form')
|
||||
.submit();
|
||||
cy
|
||||
.url()
|
||||
.should('eq', baseUrl + '/search/projects?q=');
|
||||
});
|
||||
|
||||
it('click Join Scratch', function (){
|
||||
cy
|
||||
.get('.link.right.join')
|
||||
.click();
|
||||
cy
|
||||
.get('.modal-content-iframe.mod-registration')
|
||||
.should('be.visible');
|
||||
});
|
||||
|
||||
it('click Sign In', function (){
|
||||
cy
|
||||
.get('.link.right.login-item')
|
||||
.click();
|
||||
cy
|
||||
.get('.login')
|
||||
.should('be.visible');
|
||||
});
|
||||
|
||||
|
||||
});
|
||||
|
||||
describe('test links in nav bar while signed in', function (){
|
||||
before(function (){
|
||||
cy
|
||||
.visit('');
|
||||
cy
|
||||
.get('.link.right.login-item')
|
||||
.click();
|
||||
cy
|
||||
.get('#frc-username-1088')
|
||||
.type(username);
|
||||
cy
|
||||
.get('#frc-password-1088')
|
||||
.type(password);
|
||||
cy
|
||||
.get('.button.submit-button.white')
|
||||
.click();
|
||||
cy
|
||||
.get('.profile-name')
|
||||
.should('be.visible');
|
||||
cy
|
||||
.visit('');
|
||||
});
|
||||
|
||||
beforeEach(function (){
|
||||
Cypress.Cookies.preserveOnce('scratchsessionsid');
|
||||
cy
|
||||
.visit('');
|
||||
});
|
||||
|
||||
it('click SCRATCH', function (){
|
||||
cy
|
||||
.get('.logo')
|
||||
.click();
|
||||
cy
|
||||
.url()
|
||||
.should('eq', baseUrl + '/');
|
||||
});
|
||||
|
||||
it('click Create', function (){
|
||||
cy
|
||||
.get('.link.create')
|
||||
.click();
|
||||
cy
|
||||
.get('.container')
|
||||
.should('be.visible');
|
||||
});
|
||||
|
||||
it('click Explore', function (){
|
||||
cy
|
||||
.get('.link.explore')
|
||||
.click();
|
||||
cy
|
||||
.url()
|
||||
.should('eq', baseUrl + '/explore/projects/all');
|
||||
});
|
||||
|
||||
it('click Tips', function (){
|
||||
cy
|
||||
.get('.link.tips')
|
||||
.click();
|
||||
cy
|
||||
.url()
|
||||
.should('eq', baseUrl + '/tips');
|
||||
});
|
||||
|
||||
it('click About', function (){
|
||||
cy
|
||||
.get('.link.about')
|
||||
.click();
|
||||
cy
|
||||
.url()
|
||||
.should('eq', baseUrl + '/about');
|
||||
});
|
||||
|
||||
|
||||
it('submit empty Search', function (){
|
||||
cy
|
||||
.get('.search .form')
|
||||
.submit();
|
||||
cy
|
||||
.url()
|
||||
.should('eq', baseUrl + '/search/projects?q=');
|
||||
});
|
||||
|
||||
it('click Messages', function (){
|
||||
cy
|
||||
.get('.link.right.messages')
|
||||
.click();
|
||||
cy
|
||||
.url()
|
||||
.should('eq', baseUrl + '/messages/');
|
||||
});
|
||||
|
||||
it('click My Stuff', function (){
|
||||
cy
|
||||
.get('.link.right.mystuff')
|
||||
.click();
|
||||
cy
|
||||
.url()
|
||||
.should('eq', baseUrl + '/mystuff/');
|
||||
});
|
||||
|
||||
});
|
|
@ -1,9 +0,0 @@
|
|||
{
|
||||
"scripts": {
|
||||
"test-all": "cypress run --browser chrome",
|
||||
"test-all-headless": "cypress run"
|
||||
},
|
||||
"devDependencies": {
|
||||
"cypress": "^2.1.0"
|
||||
}
|
||||
}
|
|
@ -16,7 +16,7 @@ let myStuffURL = rootUrl + '/mystuff';
|
|||
if (remote){
|
||||
jest.setTimeout(60000);
|
||||
} else {
|
||||
jest.setTimeout(10000);
|
||||
jest.setTimeout(20000);
|
||||
}
|
||||
|
||||
let driver;
|
||||
|
|
|
@ -18,7 +18,7 @@ let wwwURL = rootUrl;
|
|||
if (remote){
|
||||
jest.setTimeout(60000);
|
||||
} else {
|
||||
jest.setTimeout(10000);
|
||||
jest.setTimeout(20000);
|
||||
}
|
||||
|
||||
let driver;
|
||||
|
|
Loading…
Add table
Reference in a new issue