From 6cc38f51c5f4a595d0b847c3c5a2b1eea0b97651 Mon Sep 17 00:00:00 2001 From: Farhan Yahya Date: Fri, 7 Aug 2020 08:58:08 +0000 Subject: [PATCH 01/71] update translation URL Changing the translation guide URL from an obsolete one to an updated one --- src/views/about/about.jsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/views/about/about.jsx b/src/views/about/about.jsx index 68d700e4d..de59d6271 100644 --- a/src/views/about/about.jsx +++ b/src/views/about/about.jsx @@ -64,7 +64,7 @@ const About = () => ( id="about.aroundTheWorldDescription" values={{ translationLink: ( - + ) From c3accb0111aed7380d13b2f499a630f81afc5af8 Mon Sep 17 00:00:00 2001 From: Karishma Chadha Date: Mon, 9 Nov 2020 10:20:11 -0500 Subject: [PATCH 02/71] Add link to annual report from about page --- src/views/about/about.jsx | 3 +++ src/views/about/l10n.json | 1 + 2 files changed, 4 insertions(+) diff --git a/src/views/about/about.jsx b/src/views/about/about.jsx index 68d700e4d..267c86512 100644 --- a/src/views/about/about.jsx +++ b/src/views/about/about.jsx @@ -149,6 +149,9 @@ const About = () => (
  • +
  • + +
  • diff --git a/src/views/about/l10n.json b/src/views/about/l10n.json index 35f4e7dc9..bbf3dbf6d 100644 --- a/src/views/about/l10n.json +++ b/src/views/about/l10n.json @@ -17,6 +17,7 @@ "about.learnMoreFaq": "Frequently Asked Questions", "about.learnMoreParents": "Information for Parents", "about.learnMoreCredits": "Credits", + "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", From f89d1313e0ba1d3d776f4221f8447dcabbd4f5e8 Mon Sep 17 00:00:00 2001 From: Karishma Chadha Date: Mon, 9 Nov 2020 11:31:47 -0500 Subject: [PATCH 03/71] Break out supporters lists into json file and dynamically create lists of supporters. --- src/views/annual-report/annual-report.jsx | 212 ++++------------------ src/views/annual-report/supporters.json | 154 ++++++++++++++++ 2 files changed, 186 insertions(+), 180 deletions(-) create mode 100644 src/views/annual-report/supporters.json diff --git a/src/views/annual-report/annual-report.jsx b/src/views/annual-report/annual-report.jsx index caa7ad1da..d0d461071 100644 --- a/src/views/annual-report/annual-report.jsx +++ b/src/views/annual-report/annual-report.jsx @@ -22,6 +22,7 @@ const PeopleGrid = require('../../components/people-grid/people-grid.jsx'); const People = require('./people.json'); const BLMProjects = require('./blm-projects.json'); const VideoPreview = require('../../components/video-preview/video-preview.jsx'); +const Supporters = require('./supporters.json'); require('./annual-report.scss'); @@ -56,6 +57,30 @@ const countryNames = countryKeys.map(key => CountryUsage[key].display); const countryData = countryKeys.map(key => CountryUsage[key].count); const colorIndex = countryKeys.map(key => CountryUsage[key]['log count']); +// Create the div given a list of supporter names, +// this will contain two columns of names either of equal size +// or with the left column containing 1 more item than the right +const createSupportersLists = supportersList => { + const splitIndex = Math.ceil(supportersList.length / 2); + const firstHalf = supportersList.slice(0, splitIndex); + const secondHalf = supportersList.slice(splitIndex); + + return ( +
    +
      + { + firstHalf.map((supporter, index) => (
    • {supporter}
    • )) + } +
    +
      + { + secondHalf.map((supporter, index) => (
    • {supporter}
    • )) + } +
    +
    + ); +}; + class AnnualReport extends React.Component { constructor (props) { super(props); @@ -2021,198 +2046,42 @@ class AnnualReport extends React.Component {
    -
    -
      -
    • Massachusetts Institute of Technology
    • -
    • National Science Foundation
    • -
    -
      -
    • Siegel Family Endowment
    • -
    -
    + {createSupportersLists(Supporters.founding)}

    -
    -
      -
    • Google
    • -
    • LEGO Foundation
    • -
    • Little Bluebridge Foundation
    • -
    -
      -
    • Smilegate Foundation
    • -
    • TAL Education
    • -
    • WarnerMedia
    • -
    -
    + {createSupportersLists(Supporters.creativity)}

    -
    -
      -
    • Mark Dalton
    • -
    • Cindy and Evan Goldberg
    • -
    • Paul T. Jones
    • -
    • BrainPOP
    • -
    -
      -
    • Kahn-Rowe Family Fund
    • -
    • LEGO Education
    • -
    • Morgan Stanley
    • -
    • Two Sigma
    • -
    -
    + {createSupportersLists(Supporters.collaboration)}

    -
    -
      -
    • Alex Ginsburg
    • -
    • James Tomilson Hill
    • -
    • John Overdeck
    • -
    • Mitchel Resnick
    • -
    • David Shaw
    • -
    • David Siegel
    • -
    • Tao Ye
    • -
    • Christos Zoulas
    • -
    • AT&T Aspire
    • -
    • Big Hen Group
    • -
    • Bloomberg Philanthropies
    • -
    • Citibank
    • -
    • Credit Suisse
    • -
    • EPAM
    • -
    -
      -
    • Facebook
    • -
    • Goldman Sachs
    • -
    • Huron Foundation
    • -
    • Intel One-to-One Institute
    • -
    • Piantino Family Foundation
    • -
    • Playmates Toys
    • -
    • Skadden Arps
    • -
    • Societe Generale
    • -
    • Solomon Wilson Family Foundation
    • -
    • Tudor Investments
    • -
    • UBS
    • -
    • Vista Equity Partners
    • -
    • Weill Family Foundation
    • -
    • WestRiver Group
    • -
    -
    + {createSupportersLists(Supporters.imagination)}

    -
    -
      -
    • Erik Anderson
    • -
    • Jon Claerbout
    • -
    • Jonathan Dinu
    • -
    • John Doerr
    • -
    • Dan Huttenlocher
    • -
    • Justin Nadler
    • -
    • Ali-Milan Nekmouche
    • -
    • Edward Schmidt
    • -
    • Hope Smith
    • -
    • Alfred Spector
    • -
    • Ben Stein
    • -
    • Donald Sussman
    • -
    • Glen Whitney
    • -
    • AIG
    • -
    • Amazon
    • -
    -
      -
    • Bank of America
    • -
    • Certified Moving & Storage
    • -
    • Dalio Foundation, Inc.
    • -
    • Dalton Family Foundation
    • -
    • Deutsche Bank
    • -
    • Ernst & Young
    • -
    • Hearst Corporation
    • -
    • HedgeServ
    • -
    • Humble Bundle
    • -
    • Intel Corporation
    • -
    • Jenner & Block LLP
    • -
    • La Vida Feliz Foundation
    • -
    • Silicon Valley Bank
    • -
    • Spin Master
    • -
    • Union Square Ventures
    • -
    -
    + {createSupportersLists(Supporters.inspiration)}

    -
    -
      -
    • Michael Ball
    • -
    • Ken Baron
    • -
    • Craig Barrett
    • -
    • Adam Beder
    • -
    • Mark Bezos
    • -
    • Eric Chen
    • -
    • Michael Cirillo
    • -
    • Eric Dahm
    • -
    • Peter Desmond
    • -
    • Jeremy Deutsch
    • -
    • John Doyle
    • -
    • Kenneth Ehlert
    • -
    • Tim Ettenheim
    • -
    • Alan Eustace
    • -
    • Steve Evans
    • -
    • Catherine Greenspon
    • -
    • Jonathan W. Hitchon
    • -
    • Margaret Honey
    • -
    • Andrew Janian
    • -
    • David Joerg
    • -
    • Mark Loughridge
    • -
    • Carter Lyons
    • -
    • Adam Messinger
    • -
    • Robert and Bethany Millard
    • -
    • Stephen M. Ross
    • -
    • Wray Thorn
    • -
    -
      -
    • Jessica Traynor
    • -
    • Adobe
    • -
    • Anchor Point Foundation
    • -
    • Barclays
    • -
    • Blackstone Charitable Foundation
    • -
    • Blackstone Group
    • -
    • Cisco/Meraki
    • -
    • Citco
    • -
    • Deloitte
    • -
    • Eclipse Contracting
    • -
    • Funny or Die
    • -
    • Hasbro
    • -
    • J.P. Morgan
    • -
    • Mattel
    • -
    • McGraw Hill Education
    • -
    • NHK
    • -
    • Pearson
    • -
    • Pershing Square Foundation
    • -
    • SAP
    • -
    • Scholastic
    • -
    • The Ramsey Family Fund
    • -
    • Thelonious Monk Institute of Jazz
    • -
    • Via Technologies
    • -
    • WilmerHale
    • -
    • Zoshinkai Holdings
    • -
    -
    + {createSupportersLists(Supporters.exploration)}
    @@ -2220,24 +2089,7 @@ class AnnualReport extends React.Component {

    -
    -
      -
    • Fastly
    • -
    • Amazon Web Services
    • -
    • Wilson Sonsini Goodrich & Rosati
    • -
    • New Relic
    • -
    • Adobe
    • -
    • DK
    • -
    -
      -
    • No Starch Press
    • -
    • Github
    • -
    • Travis CI
    • -
    • Sauce Labs
    • -
    • Pingdom
    • -
    • PagerDuty
    • -
    -
    + {createSupportersLists(Supporters.inKind)}
    diff --git a/src/views/annual-report/supporters.json b/src/views/annual-report/supporters.json new file mode 100644 index 000000000..5f3bc5bc0 --- /dev/null +++ b/src/views/annual-report/supporters.json @@ -0,0 +1,154 @@ +{ + "founding": [ + "Massachusetts Institute of Technology", + "National Science Foundation", + "Siegel Family Endowment" + ], + "creativity": [ + "Google", + "LEGO Foundation", + "Little Bluebridge Foundation", + "Smilegate Foundation", + "TAL Education", + "WarnerMedia" + ], + "collaboration": [ + "Mark Dalton", + "Cindy and Evan Goldberg", + "Paul T. Jones", + "BrainPOP", + "Kahn-Rowe Family Fund", + "LEGO Education", + "Morgan Stanley", + "Two Sigma" + ], + "imagination": [ + "Alex Ginsburg", + "James Tomilson Hill", + "John Overdeck", + "Mitchel Resnick", + "David Shaw", + "David Siegel", + "Tao Ye", + "Christos Zoulas", + "AT&T Aspire", + "Big Hen Group", + "Bloomberg Philanthropies", + "Citibank", + "Credit Suisse", + "EPAM", + "Facebook", + "Goldman Sachs", + "Huron Foundation", + "Intel One-to-One Institute", + "Piantino Family Foundation", + "Playmates Toys", + "Skadden Arps", + "Societe Generale", + "Solomon Wilson Family Foundation", + "Tudor Investments", + "UBS", + "Vista Equity Partners", + "Weill Family Foundation", + "WestRiver Group" + ], + "inspiration": [ + "Erik Anderson", + "Jon Claerbout", + "Jonathan Dinu", + "John Doerr", + "Dan Huttenlocher", + "Justin Nadler", + "Ali-Milan Nekmouche", + "Edward Schmidt", + "Hope Smith", + "Alfred Spector", + "Ben Stein", + "Donald Sussman", + "Glen Whitney", + "AIG", + "Amazon", + "Bank of America", + "Certified Moving & Storage", + "Dalio Foundation, Inc.", + "Dalton Family Foundation", + "Deutsche Bank", + "Ernst & Young", + "Hearst Corporation", + "HedgeServ", + "Humble Bundle", + "Intel Corporation", + "Jenner & Block LLP", + "La Vida Feliz Foundation", + "Silicon Valley Bank", + "Spin Master", + "Union Square Ventures" + ], + "exploration": [ + "Michael Ball", + "Ken Baron", + "Craig Barrett", + "Adam Beder", + "Mark Bezos", + "Eric Chen", + "Michael Cirillo", + "Eric Dahm", + "Peter Desmond", + "Jeremy Deutsch", + "John Doyle", + "Kenneth Ehlert", + "Tim Ettenheim", + "Alan Eustace", + "Steve Evans", + "Catherine Greenspon", + "Jonathan W. Hitchon", + "Margaret Honey", + "Andrew Janian", + "David Joerg", + "Mark Loughridge", + "Carter Lyons", + "Adam Messinger", + "Robert and Bethany Millard", + "Stephen M. Ross", + "Wray Thorn", + "Jessica Traynor", + "Adobe", + "Anchor Point Foundation", + "Barclays", + "Blackstone Charitable Foundation", + "Blackstone Group", + "Cisco/Meraki", + "Citco", + "Deloitte", + "Eclipse Contracting", + "Funny or Die", + "Hasbro", + "J.P. Morgan", + "Mattel", + "McGraw Hill Education", + "NHK", + "Pearson", + "Pershing Square Foundation", + "SAP", + "Scholastic", + "The Ramsey Family Fund", + "Thelonious Monk Institute of Jazz", + "Via Technologies", + "WilmerHale", + "Zoshinkai Holdings" + ], + "inKind": [ + "Fastly", + "Amazon Web Services", + "Wilson Sonsini Goodrich & Rosati", + "New Relic", + "Adobe", + "DK", + "No Starch Press", + "Github", + "Travis CI", + "Sauce Labs", + "Pingdom", + "PagerDuty" + ] +} From e14b6d52f3757b4b2d2a63deaf9d133ed849f2f8 Mon Sep 17 00:00:00 2001 From: Karishma Chadha Date: Tue, 10 Nov 2020 14:37:18 -0500 Subject: [PATCH 04/71] Add spinner while video is still loading --- .../video-preview/video-preview.jsx | 32 +++++++++++++------ .../video-preview/video-preview.scss | 17 ++++++++++ src/components/video/video.jsx | 3 ++ 3 files changed, 43 insertions(+), 9 deletions(-) diff --git a/src/components/video-preview/video-preview.jsx b/src/components/video-preview/video-preview.jsx index 2c9efce4c..05dedc82a 100644 --- a/src/components/video-preview/video-preview.jsx +++ b/src/components/video-preview/video-preview.jsx @@ -3,6 +3,7 @@ const PropTypes = require('prop-types'); const React = require('react'); const Video = require('../video/video.jsx'); +const Spinner = require('../spinner/spinner.jsx'); require('./video-preview.scss'); @@ -10,16 +11,25 @@ class VideoPreview extends React.Component { constructor (props) { super(props); bindAll(this, [ - 'handleShowVideo' + 'handleShowVideo', + 'handleVideoLoaded' ]); this.state = { - videoOpen: false + videoOpen: false, + spinnerVisible: false }; } handleShowVideo () { - this.setState({videoOpen: true}); + this.setState({ + videoOpen: true, + spinnerVisible: true + }); + } + + handleVideoLoaded () { + this.setState({spinnerVisible: false}); } render () { @@ -27,12 +37,16 @@ class VideoPreview extends React.Component {
    {this.state.videoOpen ? ( -