Skip to content

Commit 33f98a6

Browse files
committed
merge in latest master
2 parents bfe905d + dd2094f commit 33f98a6

File tree

142 files changed

+23005
-29982
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

142 files changed

+23005
-29982
lines changed

.babelrc

Lines changed: 81 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,88 @@
11
{
2-
"presets": ["react", "env", "stage-0"],
2+
"presets": [
3+
"@babel/preset-react",
4+
"@babel/preset-env"
5+
],
36
"env": {
47
"production": {
58
"plugins": [
69
"transform-react-remove-prop-types",
7-
"transform-react-constant-elements",
8-
"transform-react-inline-elements"
10+
"@babel/plugin-transform-react-constant-elements",
11+
"@babel/plugin-transform-react-inline-elements",
12+
"@babel/plugin-syntax-dynamic-import",
13+
"@babel/plugin-syntax-import-meta",
14+
[
15+
"@babel/plugin-proposal-decorators",
16+
{
17+
"legacy": true
18+
}
19+
],
20+
[
21+
"@babel/plugin-proposal-class-properties",
22+
{
23+
"loose": true
24+
}
25+
],
26+
"@babel/plugin-proposal-json-strings",
27+
"@babel/plugin-proposal-function-sent",
28+
"@babel/plugin-proposal-export-namespace-from",
29+
"@babel/plugin-proposal-numeric-separator",
30+
"@babel/plugin-proposal-throw-expressions",
31+
"@babel/plugin-proposal-export-default-from",
32+
"@babel/plugin-proposal-logical-assignment-operators",
33+
"@babel/plugin-proposal-optional-chaining",
34+
[
35+
"@babel/plugin-proposal-pipeline-operator",
36+
{
37+
"proposal": "minimal"
38+
}
39+
],
40+
"@babel/plugin-proposal-nullish-coalescing-operator",
41+
"@babel/plugin-proposal-do-expressions",
42+
"@babel/plugin-proposal-function-bind"
943
],
10-
"presets": ["env", "react", "react-optimize", "stage-0"]
44+
"presets": [
45+
"@babel/preset-env",
46+
"@babel/preset-react"
47+
]
48+
},
49+
"development": {
50+
"plugins": [
51+
"react-hot-loader/babel"
52+
]
1153
}
12-
}
13-
}
54+
},
55+
"plugins": [
56+
"@babel/plugin-syntax-dynamic-import",
57+
"@babel/plugin-syntax-import-meta",
58+
[
59+
"@babel/plugin-proposal-decorators",
60+
{
61+
"legacy": true
62+
}
63+
],
64+
[
65+
"@babel/plugin-proposal-class-properties",
66+
{
67+
"loose": true
68+
}
69+
],
70+
"@babel/plugin-proposal-json-strings",
71+
"@babel/plugin-proposal-function-sent",
72+
"@babel/plugin-proposal-export-namespace-from",
73+
"@babel/plugin-proposal-numeric-separator",
74+
"@babel/plugin-proposal-throw-expressions",
75+
"@babel/plugin-proposal-export-default-from",
76+
"@babel/plugin-proposal-logical-assignment-operators",
77+
"@babel/plugin-proposal-optional-chaining",
78+
[
79+
"@babel/plugin-proposal-pipeline-operator",
80+
{
81+
"proposal": "minimal"
82+
}
83+
],
84+
"@babel/plugin-proposal-nullish-coalescing-operator",
85+
"@babel/plugin-proposal-do-expressions",
86+
"@babel/plugin-proposal-function-bind"
87+
]
88+
}

.env.example

Lines changed: 15 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,22 +1,25 @@
11
API_URL=/api
2-
MONGO_URL=mongodb://localhost:27017/p5js-web-editor
3-
PORT=8000
4-
SESSION_SECRET=whatever_you_want_this_to_be_it_only_matters_for_production
52
AWS_ACCESS_KEY=<your-aws-access-key>
6-
AWS_SECRET_KEY=<your-aws-secret-key>
73
AWS_REGION=<your-aws-region>
8-
S3_BUCKET=<your-s3-bucket>
4+
AWS_SECRET_KEY=<your-aws-secret-key>
5+
EMAIL_SENDER=<transactional-email-sender>
6+
EMAIL_VERIFY_SECRET_TOKEN=whatever_you_want_this_to_be_it_only_matters_for_production
7+
EXAMPLE_USER_EMAIL=examples@p5js.org
8+
EXAMPLE_USER_PASSWORD=hellop5js
9+
GG_EXAMPLES_USERNAME=generativedesign
10+
GG_EXAMPLES_EMAIL=benedikt.gross@generative-gestaltung.de
11+
GG_EXAMPLES_PASS=generativedesign
12+
ML5_EXAMPLES_USERNAME=ml5
13+
ML5_EXAMPLES_EMAIL=examples@ml5js.org
14+
ML5_EXAMPLES_PASS=helloml5
915
GITHUB_ID=<your-github-client-id>
1016
GITHUB_SECRET=<your-github-client-secret>
1117
GOOGLE_ID=<your-google-client-id> (use google+ api)
1218
GOOGLE_SECRET=<your-google-client-secret> (use google+ api)
1319
MAILGUN_DOMAIN=<your-mailgun-domain>
1420
MAILGUN_KEY=<your-mailgun-api-key>
15-
EMAIL_SENDER=<transactional-email-sender>
16-
EMAIL_VERIFY_SECRET_TOKEN=whatever_you_want_this_to_be_it_only_matters_for_production
21+
MONGO_URL=mongodb://localhost:27017/p5js-web-editor
22+
PORT=8000
23+
S3_BUCKET=<your-s3-bucket>
1724
S3_BUCKET_URL_BASE=<alt-for-s3-url>
18-
EXAMPLE_USER_EMAIL=examples@p5js.org
19-
EXAMPLE_USER_PASSWORD=hellop5js
20-
GG_EXAMPLES_USERNAME=generative-design
21-
GG_EXAMPLES_PASS=generativedesign
22-
GG_EXAMPLES_EMAIL=benedikt.gross@generative-gestaltung.de
25+
SESSION_SECRET=whatever_you_want_this_to_be_it_only_matters_for_production

.eslintrc

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
"env": {
55
"browser": true,
66
"node": true,
7-
"mocha": true
7+
"jest": true
88
},
99
"rules": {
1010
"linebreak-style": 0,
@@ -20,7 +20,7 @@
2020
"no-console": 0,
2121
"no-alert": 0,
2222
"no-underscore-dangle": 0,
23-
"max-len": [1, 120, 2, {ignoreComments: true}],
23+
"max-len": [1, 120, 2, {"ignoreComments": true, "ignoreTemplateLiterals": true}],
2424
"quote-props": [1, "consistent-as-needed"],
2525
"no-unused-vars": [1, {"vars": "local", "args": "none"}],
2626
"consistent-return": ["error", { "treatUndefinedAsUnspecified": true }],

.github/CODE_OF_CONDUCT.md

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,13 +11,14 @@
1111

1212
Use your best judgement. If it will possibly make others uncomfortable, do not post it.
1313

14-
* **Be respectful.** Disagreement is not an opportunity to attack someone else's thoughts or opinions. Although views may differ, remember to approach every situation with patience and care.
15-
* **Be considerate.** Think about how your contribution will affect others in the community.
14+
* **Be respectful.** Disagreement is not an opportunity to attack someone else's thoughts or opinions. Although views may differ, remember to approach every situation with patience and care.
15+
* **Be considerate.** Think about how your contribution will affect others in the community.
1616
* **Be open minded.** Embrace new people and new ideas. Our community is continually evolving and we welcome positive change.
1717

1818
If you believe someone is violating the code of conduct, we ask that you report it by emailing [hello@p5js.org](mailto:hello@p5js.org). Please include your name and a description of the incident, and we will get back to you ASAP.
1919

20-
Participants asked to stop any harassing behavior are expected to comply immediately. If a participant engages in harassing behavior, the p5.js Team may take any action they deem appropriate, up to and including expulsion from all p5.js spaces and identification of the participant as a harasser to other p5.js members or the general public.
20+
Participants asked to stop any harassing behavior are expected to comply immediately. If a participant engages in harassing behavior, the p5.js Team may take any action they deem appropriate, up to and including expulsion from all p5.js spaces and identification of the participant as a harasser to other p5.js members or the general public.
2121

2222
## Also
23+
2324
* You can read our [community statement](http://p5js.org/community/) on our website.

.github/CONTRIBUTING.md

Lines changed: 30 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,22 @@
11
# Contributing to the p5.js Web Editor
22

3-
Hello! We welcome community contributions to the p5.js Web Editor. Contributing takes many forms and doesn't have to be **writing code**, it can be **report bugs**, **proposing new features**, **creating UI/UX designs**, and **updating documentation**.
3+
Hello! We welcome community contributions to the p5.js Web Editor. Contributing takes many forms and doesn't have to be **writing code**, it can be **report bugs**, **proposing new features**, **creating UI/UX designs**, and **updating documentation**.
44

55
Here are links to all the sections in this document:
66

77
<!-- If you change any of the headings in this document, remember to update the table of contents. -->
88

9-
- [Code of Conduct](#code-of-conduct)
10-
- [How Can I Contribute ?](#how-can-i-contribute?)
11-
- [First Timers](#first-timers)
12-
- [Want something more challenging](#want-something-more-challenging)
13-
- [Feature Enhancement](#feature-enhancement)
14-
- [Creating a Pull request](#creating-a-pull-request)
15-
- - [Tips](#tips)
9+
- [Contributing to the p5.js Web Editor](#contributing-to-the-p5js-web-editor)
10+
- [Code of Conduct](#code-of-conduct)
11+
- [How Can I Contribute?](#how-can-i-contribute)
12+
- [First Timers](#first-timers)
13+
- [Milestones](#milestones)
14+
- [Project Ideas](#project-ideas)
15+
- [Issue Search and Tagging](#issue-search-and-tagging)
16+
- [Beginning Work](#beginning-work)
17+
- [Contribution Guides](#contribution-guides)
18+
- [Writing Commit Messages](#writing-commit-messages)
19+
- [Tips](#tips)
1620

1721
## Code of Conduct
1822

@@ -23,21 +27,29 @@ Please follow the guidelines mentioned at [CODE OF CONDUCT.md](https://github.co
2327
### First Timers
2428
For first-time contributors or those who want to start with a small task: [check out our list of good first bugs](https://github.com/processing/p5.js-web-editor/labels/good%20first%20issue). First read the github discussion on that issue and find out if there's currently a person working on that or not. If no one is working on it or if there has was one claimed to but has not been active for a while, ask if it is up for grabs. It's okay to not know how to fix an issue and feel free to ask questions about to approach the problem! We are all just here to learn and make something awesome. Someone from the community would help you out and these are great issues for learning about the web editor, its file structure and its development process.
2529

26-
### Want something more challenging
27-
If you're already familiar with the project or would like take on something a little more challenging, please take a look at the [priority: high](https://github.com/processing/p5.js-web-editor/labels/priority%3Ahigh) issues.
30+
### Milestones
31+
A good place to check for tickets to work on is [milestones](https://github.com/processing/p5.js-web-editor/milestones), as miletones have a due date, and will give you a sense of tickets the tickets that maintainers would like to be completed sooner rather than later.
2832

29-
### Feature Enhancement
30-
If you want to work on building new things, please take a look at [type: feature](https://github.com/processing/p5.js-web-editor/labels/type%3Afeature).
33+
### Project Ideas
34+
If you're looking for inspiration for Google Summer of Code or a bigger project, there's a [project list](https://github.com/processing/processing/wiki/Project-List#p5js-web-editor) maintained on the Processing wiki.
3135

32-
If you'd like to work on a bug, please comment on it to let the maintainers know.
33-
If someone else has already commented and taken up that bug, please refrain from working on it and submitting a PR without asking the maintainers as it leads to unnecessary duplication of effort.
36+
### Issue Search and Tagging
37+
If you're looking for issues to work on, a good place to start is with tickets labeled [high priority](https://github.com/processing/p5.js-web-editor/labels/priority%3Ahigh). You can also look for tickets that are [feature enhancements](https://github.com/processing/p5.js-web-editor/labels/type%3Afeature), [bug fixes](https://github.com/processing/p5.js-web-editor/labels/type%3Abug), and a few other tags.
3438

35-
### Contribution guides
39+
If you feel like an issue is tagged incorrectly (e.g. it's low priority and you think it should be high), please update the issue!
40+
41+
### Beginning Work
42+
43+
If you'd like to work on an issue, please comment on it to let the maintainers know. If someone else has already commented and taken up that issue, please refrain from working on it and submitting a PR without asking the maintainers as it leads to unnecessary duplication of effort.
44+
45+
Then, follow the [installation guide](https://github.com/processing/p5.js-web-editor/blob/master/developer_docs/installation.md) to get the project building and working on your computer.
46+
47+
### Contribution Guides
3648

3749
* [https://guides.github.com/activities/hello-world/](https://guides.github.com/activities/hello-world/)
3850
* [https://guides.github.com/activities/forking/](https://guides.github.com/activities/forking/)
3951

40-
## Writing commit messages
52+
## Writing Commit Messages
4153

4254
Good commit messages serve at least three important purposes:
4355

@@ -69,9 +81,6 @@ Structure your commit message like this:
6981
* Always leave the second line blank.
7082
* Be as descriptive as possible in the description. It helps reasoning about the intention of commits and gives more context about why changes happened.
7183

72-
Tips
73-
----
74-
75-
* If it seems difficult to summarize what your commit does, it may be because it includes several logical changes or bug fixes, and are better split up into several commits using `git add -p`.
76-
84+
## Tips
7785

86+
* If it seems difficult to summarize what your commit does, it may be because it includes several logical changes or bug fixes, and are better split up into several commits using `git add -p`.

.github/ISSUE_TEMPLATE.md

Lines changed: 7 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,23 +1,22 @@
11
<!--
22
Hi there! If you are here to report a bug, or to discuss a feature (new or existing), you can use the below template to get started quickly. Fill out all those parts which you're comfortable with, and delete the remaining ones.
3-
4-
To check any option, replace the "[ ]" with a "[x]". Be sure to check out how it looks in the Preview tab!
5-
6-
Feel free to remove any portion of the template that is not relevant for your issue.
73
-->
84

95
#### Nature of issue?
106

11-
- [ ] Found a bug
12-
- [ ] Existing feature enhancement
13-
- [ ] New feature request
7+
<!-- Select any one issue and delete the other two -->
8+
9+
- Found a bug
10+
- Existing feature enhancement
11+
- New feature request
1412

1513
<!-- If you found a bug, the following information might prove to be helpful for us. Simply remove whatever you can't determine/don't know. -->
1614
#### Details about the bug:
1715

1816
- Web browser and version: <!-- On Chrome/FireFox/Opera you can enter "about:" in the address bar to find out the version -->
1917
- Operating System: <!-- Ex: Windows/MacOSX/Linux along with version -->
20-
- Steps to reproduce this:
18+
- Steps to reproduce this bug:
19+
2120
<!-- Include a simple code snippet that demonstrates the problem, along with any console errors produced. If this isn't possible, then simply describe the issue as best you can! Feel free to link to the web editor or include pictures or a video. -->
2221

2322
<!-- If you want to enhance an existing feature, please describe here, otherwise remove this section -->

.github/PULL_REQUEST_TEMPLATE.md

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,5 @@
1-
Before your pull request is reviewed and merged, please ensure that:
1+
I have verified that this pull request:
22

3-
* [ ] there are no linting errors -- `npm run lint`
4-
* [ ] your code is in a uniquely-named feature branch and has been rebased on top of the latest master. If you're asked to make more changes, make sure you rebase onto master then too!
5-
* [ ] your pull request is descriptively named and links to an issue number, i.e. `Fixes #123`
6-
7-
Thank you!
3+
* [ ] has no linting errors (`npm run lint`)
4+
* [ ] is from a uniquely-named feature branch and has been rebased on top of the latest master. (If I was asked to make more changes, I have made sure to rebase onto master then too)
5+
* [ ] is descriptively named and links to an issue number, i.e. `Fixes #123`

.github/config.yml

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
# Configuration for welcome - https://github.com/behaviorbot/welcome
2+
3+
# Configuration for new-issue-welcome - https://github.com/behaviorbot/new-issue-welcome
4+
5+
# Comment to be posted to on first time issues
6+
newIssueWelcomeComment: >
7+
Welcome! 👋 Thanks for opening your first issue here! And to ensure the community is able to respond to your issue, be sure to follow the issue template if you haven't already.
8+
9+
# Configuration for new-pr-welcome - https://github.com/behaviorbot/new-pr-welcome
10+
11+
# Comment to be posted to on PRs from first time contributors in your repository
12+
newPRWelcomeComment: >
13+
🎉 Thanks for opening this pull request! Please check out our [contributing guidelines](https://github.com/processing/p5.js-web-editor/blob/master/CONTRIBUTING.md) if you haven't already.
14+
15+
# Configuration for first-pr-merge - https://github.com/behaviorbot/first-pr-merge
16+
17+
# Comment to be posted to on pull requests merged by a first time user

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
.DS_Store
22
.env
33
.env.production
4+
.env.staging
45
.vscode/
56
node_modules/
67
npm-debug.log

.travis.yml

Lines changed: 15 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
sudo: required
22
language: node_js
33
node_js:
4-
- "8.11.1"
4+
- "10.15.0"
55

66
cache:
77
directories:
@@ -16,8 +16,14 @@ before_install:
1616

1717
install: true
1818

19-
script:
20-
- docker-compose exec -T app npm run test --verbose
19+
jobs:
20+
include:
21+
- stage: test
22+
name: "Linting"
23+
script: docker-compose exec -T app npm run lint
24+
- # stage name not required, will continue to use `test`
25+
name: "Tests"
26+
script: docker-compose exec -T app npm run test
2127

2228
before_deploy:
2329
- docker-compose stop
@@ -26,14 +32,18 @@ before_deploy:
2632
- gcloud --quiet version
2733
- gcloud --quiet components update
2834
- gcloud --quiet components update kubectl
29-
3035
deploy:
3136
- provider: script
3237
script: ./deploy.sh
3338
skip_cleanup: true
3439
on:
3540
branch: master
41+
- provider: script
42+
script: ./deploy_staging.sh
43+
skip_cleanup: true
44+
on:
45+
branch: feature/public-api
3646

3747
env:
3848
global:
39-
- APP_IMAGE_NAME=p5jswebeditor_app
49+
- APP_IMAGE_NAME=p5js-web-editor_app

0 commit comments

Comments
 (0)