Skip to content

Commit e428083

Browse files
authored
Merge branch 'develop' into greenkeeper/scratch-vm-0.2.0-prerelease.20191018142546
2 parents 98c1846 + 5afd19b commit e428083

Some content is hidden

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

45 files changed

+598
-239
lines changed

.npmignore

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,9 @@
55
/node_modules
66
npm-*
77

8+
# Double copies of all the static assets and tutorial gifs
9+
/src
10+
811
# Testing
912
/.nyc_output
1013
/coverage

.travis.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -57,6 +57,7 @@ deploy:
5757
- master
5858
- develop
5959
- smoke
60+
- hotfix/*
6061
condition: $TRAVIS_EVENT_TYPE != cron
6162
skip_cleanup: true
6263
script: if npm info scratch-gui | grep -q $RELEASE_VERSION; then git tag $RELEASE_VERSION && git push https://${GH_TOKEN}@github.com/${TRAVIS_REPO_SLUG}.git $RELEASE_VERSION; fi

package-lock.json

Lines changed: 20 additions & 20 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@
4444
"babel-loader": "^8.0.4",
4545
"base64-loader": "1.0.0",
4646
"bowser": "1.9.4",
47-
"chromedriver": "77.0.0",
47+
"chromedriver": "78.0.1",
4848
"classnames": "2.2.6",
4949
"computed-style-to-inline-style": "3.0.0",
5050
"copy-webpack-plugin": "^4.5.1",
@@ -108,12 +108,12 @@
108108
"redux-throttle": "0.1.1",
109109
"rimraf": "^2.6.1",
110110
"scratch-audio": "0.1.0-prerelease.20190925183642",
111-
"scratch-l10n": "3.6.20191008224547",
112-
"scratch-blocks": "0.1.0-prerelease.1570730963",
113-
"scratch-paint": "0.2.0-prerelease.20191010161144",
114-
"scratch-render": "0.1.0-prerelease.20191001200908",
111+
"scratch-l10n": "3.6.20191029224007",
112+
"scratch-blocks": "0.1.0-prerelease.1572384380",
113+
"scratch-paint": "0.2.0-prerelease.20191104214909",
114+
"scratch-render": "0.1.0-prerelease.20191104214419",
115115
"scratch-storage": "1.3.2",
116-
"scratch-svg-renderer": "0.2.0-prerelease.20190822202608",
116+
"scratch-svg-renderer": "0.2.0-prerelease.20191104164753",
117117
"scratch-vm": "0.2.0-prerelease.20191018142546",
118118
"selenium-webdriver": "3.6.0",
119119
"startaudiocontext": "1.2.1",

src/components/gui/gui.jsx

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -94,7 +94,6 @@ const GUIComponent = props => {
9494
onLogOut,
9595
onOpenRegistration,
9696
onToggleLoginOpen,
97-
onUpdateProjectTitle,
9897
onActivateCostumesTab,
9998
onActivateSoundsTab,
10099
onActivateTab,
@@ -228,7 +227,6 @@ const GUIComponent = props => {
228227
onSeeCommunity={onSeeCommunity}
229228
onShare={onShare}
230229
onToggleLoginOpen={onToggleLoginOpen}
231-
onUpdateProjectTitle={onUpdateProjectTitle}
232230
/>
233231
<Box className={styles.bodyWrapper}>
234232
<Box className={styles.flexWrapper}>
@@ -406,7 +404,6 @@ GUIComponent.propTypes = {
406404
onTelemetryModalOptIn: PropTypes.func,
407405
onTelemetryModalOptOut: PropTypes.func,
408406
onToggleLoginOpen: PropTypes.func,
409-
onUpdateProjectTitle: PropTypes.func,
410407
renderLogin: PropTypes.func,
411408
showComingSoon: PropTypes.bool,
412409
soundsTabVisible: PropTypes.bool,
@@ -433,7 +430,6 @@ GUIComponent.defaultProps = {
433430
isCreating: false,
434431
isShared: false,
435432
loading: false,
436-
onUpdateProjectTitle: () => {},
437433
showComingSoon: false,
438434
stageSizeMode: STAGE_SIZE_MODES.large
439435
};

src/components/menu-bar/menu-bar.jsx

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -395,7 +395,6 @@ class MenuBar extends React.Component {
395395
<SBFileUploader
396396
canSave={this.props.canSave}
397397
userOwnsProject={this.props.userOwnsProject}
398-
onUpdateProjectTitle={this.props.onUpdateProjectTitle}
399398
>
400399
{(className, renderFileInput, handleLoadProject) => (
401400
<MenuItem
@@ -495,7 +494,6 @@ class MenuBar extends React.Component {
495494
>
496495
<ProjectTitleInput
497496
className={classNames(styles.titleFieldGrowable)}
498-
onUpdateProjectTitle={this.props.onUpdateProjectTitle}
499497
/>
500498
</MenuBarItemTooltip>
501499
</div>
@@ -746,7 +744,6 @@ MenuBar.propTypes = {
746744
onSeeCommunity: PropTypes.func,
747745
onShare: PropTypes.func,
748746
onToggleLoginOpen: PropTypes.func,
749-
onUpdateProjectTitle: PropTypes.func,
750747
projectTitle: PropTypes.string,
751748
renderLogin: PropTypes.func,
752749
sessionExists: PropTypes.bool,

src/components/menu-bar/project-title-input.jsx

Lines changed: 21 additions & 31 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
11
import classNames from 'classnames';
22
import {connect} from 'react-redux';
33
import PropTypes from 'prop-types';
4-
import bindAll from 'lodash.bindall';
54
import React from 'react';
65
import {defineMessages, intlShape, injectIntl} from 'react-intl';
6+
import {setProjectTitle} from '../../reducers/project-title';
77

88
import BufferedInputHOC from '../forms/buffered-input-hoc.jsx';
99
import Input from '../forms/input.jsx';
@@ -19,47 +19,37 @@ const messages = defineMessages({
1919
}
2020
});
2121

22-
class ProjectTitleInput extends React.Component {
23-
constructor (props) {
24-
super(props);
25-
bindAll(this, [
26-
'handleUpdateProjectTitle'
27-
]);
28-
}
29-
// call onUpdateProjectTitle if it is defined (only defined when gui
30-
// is used within scratch-www)
31-
handleUpdateProjectTitle (newTitle) {
32-
if (this.props.onUpdateProjectTitle) {
33-
this.props.onUpdateProjectTitle(newTitle);
34-
}
35-
}
36-
render () {
37-
return (
38-
<BufferedInput
39-
className={classNames(styles.titleField, this.props.className)}
40-
maxLength="100"
41-
placeholder={this.props.intl.formatMessage(messages.projectTitlePlaceholder)}
42-
tabIndex="0"
43-
type="text"
44-
value={this.props.projectTitle}
45-
onSubmit={this.handleUpdateProjectTitle}
46-
/>
47-
);
48-
}
49-
}
22+
const ProjectTitleInput = ({
23+
className,
24+
intl,
25+
onSubmit,
26+
projectTitle
27+
}) => (
28+
<BufferedInput
29+
className={classNames(styles.titleField, className)}
30+
maxLength="100"
31+
placeholder={intl.formatMessage(messages.projectTitlePlaceholder)}
32+
tabIndex="0"
33+
type="text"
34+
value={projectTitle}
35+
onSubmit={onSubmit}
36+
/>
37+
);
5038

5139
ProjectTitleInput.propTypes = {
5240
className: PropTypes.string,
5341
intl: intlShape.isRequired,
54-
onUpdateProjectTitle: PropTypes.func,
42+
onSubmit: PropTypes.func,
5543
projectTitle: PropTypes.string
5644
};
5745

5846
const mapStateToProps = state => ({
5947
projectTitle: state.scratchGui.projectTitle
6048
});
6149

62-
const mapDispatchToProps = () => ({});
50+
const mapDispatchToProps = dispatch => ({
51+
onSubmit: title => dispatch(setProjectTitle(title))
52+
});
6353

6454
export default injectIntl(connect(
6555
mapStateToProps,

src/components/monitor/monitor.css

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,7 @@
4343
margin: 0 5px;
4444
border-radius: calc($space / 2);
4545
padding: 0 2px;
46+
white-space: pre-wrap;
4647
transform: translateZ(0); /* Fixes flickering in Safari */
4748
}
4849

@@ -53,6 +54,7 @@
5354
text-align: center;
5455
color: white;
5556
font-size: 1rem;
57+
white-space: pre-wrap;
5658
transform: translateZ(0); /* Fixes flickering in Safari */
5759
}
5860

@@ -149,7 +151,7 @@
149151
overflow: hidden; /* Don't let long values escape container */
150152
text-overflow: ellipsis;
151153
user-select: text; /* Allow selecting list values for 2.0 compatibility, only relevant in player */
152-
white-space: nowrap;
154+
white-space: pre;
153155
}
154156

155157
.list-input {

0 commit comments

Comments
 (0)