Skip to content

Commit b1d4a7d

Browse files
committed
set defaults to play nicely with embed view
1 parent 6caaaf6 commit b1d4a7d

File tree

2 files changed

+9
-2
lines changed

2 files changed

+9
-2
lines changed

src/components/gui/gui.jsx

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -425,7 +425,6 @@ GUIComponent.defaultProps = {
425425
canEditTitle: false,
426426
canManageFiles: true,
427427
canRemix: false,
428-
canSave: false,
429428
canCreateCopy: false,
430429
canShare: false,
431430
canUseCloud: false,

src/lib/cloud-manager-hoc.jsx

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -124,7 +124,7 @@ const cloudManagerHOC = function (WrappedComponent) {
124124
}
125125

126126
CloudManager.propTypes = {
127-
canSave: PropTypes.bool.isRequired,
127+
canSave: PropTypes.bool,
128128
cloudHost: PropTypes.string,
129129
hasCloudPermission: PropTypes.bool,
130130
hasEverEnteredEditor: PropTypes.bool,
@@ -135,6 +135,14 @@ const cloudManagerHOC = function (WrappedComponent) {
135135
vm: PropTypes.instanceOf(VM).isRequired
136136
};
137137

138+
CloudManager.defaultProps = {
139+
canSave: false,
140+
cloudHost: null,
141+
hasCloudPermission: false,
142+
onShowCloudInfo: () => {},
143+
username: null
144+
};
145+
138146
const mapStateToProps = state => {
139147
const loadingState = state.scratchGui.projectState.loadingState;
140148
return {

0 commit comments

Comments
 (0)