Commit Graph
18 Commits
Author SHA1 Message Date
chrisgarrity e1808275c0 remember to export initEmbedded for www 2018-12-04 11:13:26 -05:00
Ben Wheeler ce3efe2f71 export remixProject reducer function 2018-11-16 21:00:04 -05:00
chrisgarrity a99ee8db0a Handle ?tutorial= query in gui
Moved the tutorial id handling into gui so it works when gui is embedded in www as well as standalone.

This seemed better than adding the same query handling to www, in order to pass an id to gui.

Note, the `?tutorial=all` handling remains in app-state-hoc. Currently it’s only needed in standalone mode for Hour of Code. It’s easy to move into the gui container if we do want it in gui by default.
2018-11-14 15:23:02 -05:00
chrisgarrity bc444149d5 export tutorial initialization for www
Export the tutorial card URL query string handling for www.
Also fix typo
2018-11-09 14:03:37 -05:00
Christopher Willis-Ford b83c082bf1 Expose AppStateHOC component
For use from `scratch-desktop` and maybe other places...
2018-09-20 14:11:36 -07:00
chrisgarrity 60a3dc3ad4 Locales cleanup
* updated locales reducer to include current messages and messagesByLocale (the previous all messages)
* moved locales out of gui
* include locales in the things exported by gui (index.js)
2018-06-20 17:08:47 -04:00
chrisgarrity a04554229f Initial version of loading or switching language.
Add `?locale=<localecode>` to load in a new langage.
Add `?enable=language` to enable the language selector
Or combine the two: `?enable=language&locale=<localecode>`
Still accepts a hash, but requires that the hash be a sequence of digits.

Added new locales reducer to gui:
- initializes default  react-intl/localeData
- initializes default locale messages for all locales
- default locale is ‘en’ (can be overridden by URL)

Removed dependency on react-intl-redux, added ConnectedIntlProvider (uses correct locale messages from redux based on current locale)
2018-06-19 15:40:47 -04:00
chrisgarrity a6d9dbb4e0 Address review comments
Move guiMiddleware to `reducers/gui.js`, and use it in `app-state-hoc`
2018-05-21 16:54:20 -04:00
chrisgarrity a3392bcb8d Export new GUI
scratch-gui exports `index.js` instead of just GUI container.
2018-05-21 16:54:19 -04:00
Ray Schamp 7f9d9729c6 Lint: JS -> JSX 2016-10-22 11:07:29 -04:00
Ray Schamp fa52102b77 Container/presentation refactor
Move behavior-related components to "containers", leave presentation components in "components".
2016-10-16 20:18:22 -04:00
Ray Schamp 54548b5c0b Update project on hash change
While doing so:
- Use ProjectLoader for loading projects
- Stop using loadEmptyProject and supply empty project data
- Move project loading to App, GUI now receives data (as a string - the vm should receive an object eventually)
- Add logging
2016-10-12 23:22:15 -04:00
Ray Schamp 4a6e59cf94 Fix lint error 2016-09-28 11:11:42 -04:00
Ray Schamp dc119d0a32 Configure base path for media directory 2016-09-28 11:08:53 -04:00
Ray Schamp 20778d8d05 The playground is the product 2016-09-15 16:50:10 -04:00
Ray Schamp 5badff999e Use ES5 module style
This way we can have a consistent style for Node and web code.
2016-09-15 16:20:37 -04:00
Ray Schamp 882a6107ba Use .js for everything
Thanks to babel-loader and babel-eslint, we can use the same linting everywhere.  This makes our imports easier since we don't need to think about the extension.

Also export things more succinctly in src/index.js
2016-09-15 12:20:00 -04:00
Ray Schamp a173405cc3 Initial commit 2016-09-15 00:50:28 -04:00