Skip to content

Commit b5a7846

Browse files
committed
Merge branch 'develop-1.8'
2 parents f09c0a3 + d0da255 commit b5a7846

19 files changed

Lines changed: 1527 additions & 358 deletions

.github/workflows/ci.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ jobs:
99
strategy:
1010
matrix:
1111
os: [ubuntu-20.04]
12-
node-version: [14.x, 16.x]
12+
node-version: [16.x, 18.x]
1313
runs-on: ${{ matrix.os }}
1414
env:
1515
CI: true

netlify.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
[build]
2-
environment = { NODE_VERSION = "14" }
2+
environment = { NODE_VERSION = "16" }
33
command = "npm run netlify-build"
44
publish = "build/"

package-lock.json

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

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "c2lc-coding-environment",
3-
"version": "1.7.0",
3+
"version": "1.8.0",
44
"private": true,
55
"dependencies": {
66
"bootstrap": "4.6.1",

src/App.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -149,7 +149,7 @@ export class App extends React.Component<AppProps, AppState> {
149149
constructor(props: any) {
150150
super(props);
151151

152-
this.version = '1.7';
152+
this.version = '1.8';
153153

154154
this.appContext = {
155155
bluetoothApiIsAvailable: FeatureDetection.bluetoothApiIsAvailable()

src/WorldSelector.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -47,6 +47,7 @@ class WorldSelector extends React.Component<WorldSelectorProps, WorldSelectorSta
4747
'Haunted',
4848
'Landmarks',
4949
'Marble',
50+
"MusicBand",
5051
'Savannah',
5152
'Space',
5253
'Sports'

src/WorldSelector.test.js

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -66,11 +66,11 @@ function getDoneButton(wrapper) {
6666

6767
describe('When rendering selector options', () => {
6868
test('All worlds should be displayed as options and only one is checked', () => {
69-
expect.assertions(27);
69+
expect.assertions(29);
7070
const { wrapper } = createMountWorldSelector();
7171
const selectorOptions = getWorldSelectorRadioButton(wrapper);
7272

73-
expect(selectorOptions.length).toBe(13);
73+
expect(selectorOptions.length).toBe(14);
7474

7575
expect(selectorOptions.get(0).props.value).toBe('Sketchpad');
7676
expect(selectorOptions.get(1).props.value).toBe('AmusementPark');
@@ -82,9 +82,10 @@ describe('When rendering selector options', () => {
8282
expect(selectorOptions.get(7).props.value).toBe('Haunted');
8383
expect(selectorOptions.get(8).props.value).toBe('Landmarks');
8484
expect(selectorOptions.get(9).props.value).toBe('Marble');
85-
expect(selectorOptions.get(10).props.value).toBe('Savannah');
86-
expect(selectorOptions.get(11).props.value).toBe('Space');
87-
expect(selectorOptions.get(12).props.value).toBe('Sports');
85+
expect(selectorOptions.get(10).props.value).toBe('MusicBand');
86+
expect(selectorOptions.get(11).props.value).toBe('Savannah');
87+
expect(selectorOptions.get(12).props.value).toBe('Space');
88+
expect(selectorOptions.get(13).props.value).toBe('Sports');
8889

8990
expect(selectorOptions.get(0).props.checked).toBe(true);
9091
for (let i = 1; i < selectorOptions.length; i++) {

src/Worlds.js

Lines changed: 70 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -102,6 +102,18 @@ import { ReactComponent as Marble } from './svg/Marble.svg';
102102
import { ReactComponent as MarbleGray } from './svg/MarbleGray.svg';
103103
import { ReactComponent as MarbleContrast } from './svg/MarbleContrast.svg';
104104

105+
// Music Band
106+
107+
import { ReactComponent as MusicBand } from './svg/MusicBand.svg';
108+
import { ReactComponent as MusicBandGray } from './svg/MusicBandGray.svg';
109+
import { ReactComponent as MusicBandContrast } from './svg/MusicBandContrast.svg';
110+
import { ReactComponent as MusicBandThumbnail } from './svg/MusicBandThumbnail.svg';
111+
import { ReactComponent as MusicBandThumbnailGray } from './svg/MusicBandThumbnailGray.svg';
112+
import { ReactComponent as MusicBandThumbnailContrast } from './svg/MusicBandThumbnailContrast.svg';
113+
import { ReactComponent as MusicBandBaton } from './svg/MusicBandBaton.svg';
114+
import { ReactComponent as MusicBandBatonGray } from './svg/MusicBandBatonGray.svg';
115+
import { ReactComponent as MusicBandBatonContrast } from './svg/MusicBandBatonContrast.svg';
116+
105117
// Savannah
106118
import { ReactComponent as Savannah } from './svg/Savannah.svg';
107119
import { ReactComponent as SavannahGray } from './svg/Savannah-gray.svg';
@@ -172,6 +184,7 @@ const worlds: {|
172184
'Haunted': WorldProperties,
173185
'Landmarks': WorldProperties,
174186
'Marble': WorldProperties,
187+
'MusicBand': WorldProperties,
175188
'Savannah': WorldProperties,
176189
'Sketchpad': WorldProperties,
177190
'Space': WorldProperties,
@@ -846,6 +859,63 @@ const worlds: {|
846859
startingDirection: 2, // East
847860
enableFlipCharacter: false
848861
},
862+
'MusicBand': {
863+
background: MusicBand,
864+
backgroundGray: MusicBandGray,
865+
backgroundContrast: MusicBandContrast,
866+
backgroundInfo : {
867+
B1: 'spotlight',
868+
E1: 'spotlight',
869+
H1: 'spotlight',
870+
K1: 'spotlight',
871+
H2: 'drumKit',
872+
J2: 'saxophone',
873+
K2: 'saxophone',
874+
B3: 'guitar',
875+
C3: 'guitar',
876+
F3: 'drumKit',
877+
G3: 'drumKit',
878+
H3: 'drumKit',
879+
J3: 'saxophone',
880+
K3: 'saxophone',
881+
B4: 'guitar',
882+
C4: 'guitar',
883+
F4: 'drumKit',
884+
G4: 'drumKit',
885+
H4: 'drumKit',
886+
F5: 'drumKit',
887+
G5: 'drumKit',
888+
H5: 'drumKit',
889+
A6: 'tambourine',
890+
F6: 'microphone',
891+
H6: 'synthesizer',
892+
I6: 'synthesizer',
893+
J6: 'synthesizer',
894+
K6: 'synthesizer',
895+
A7: 'loudspeaker',
896+
C7: 'xylophone',
897+
D7: 'xylophone',
898+
F7: 'microphone',
899+
H7: 'synthesizer',
900+
I7: 'synthesizer',
901+
J7: 'synthesizer',
902+
L7: 'loudspeaker',
903+
A8: 'loudspeaker',
904+
F8: 'microphone',
905+
L8: 'loudspeaker'
906+
},
907+
thumbnail: MusicBandThumbnail,
908+
thumbnailDark: MusicBandThumbnail,
909+
thumbnailGray: MusicBandThumbnailGray,
910+
thumbnailContrast: MusicBandThumbnailContrast,
911+
character: MusicBandBaton,
912+
characterGray: MusicBandBatonGray,
913+
characterContrast: MusicBandBatonContrast,
914+
startingX: 1,
915+
startingY: 2,
916+
startingDirection: 2, // East
917+
enableFlipCharacter: true
918+
},
849919
'Savannah': {
850920
background: Savannah,
851921
backgroundGray: SavannahGray,

src/Worlds.scss

Lines changed: 121 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -970,6 +970,127 @@ body.contrast-theme {
970970
}
971971
}
972972

973+
/* Music Band */
974+
975+
.ProgramBlockEditor__character-column-character-container--MusicBand {
976+
background-color: #FBE6CD;
977+
}
978+
979+
.Scene__grid-line--MusicBand {
980+
stroke: #567F88;
981+
}
982+
983+
.Scene__path-line--MusicBand {
984+
stroke: #E5AF5E;
985+
}
986+
987+
.Scene__starting-grid-cell-point--MusicBand {
988+
fill: #E5AF5E;
989+
}
990+
991+
.WorldSelector__option-image--MusicBand:hover {
992+
svg {
993+
.thumbnail-background {
994+
fill: #73A9B0;
995+
}
996+
.thumbnail-purple {
997+
fill: #AA6F9C;
998+
}
999+
.thumbnail-red {
1000+
fill: #EA7362;
1001+
}
1002+
.thumbnail-yellow {
1003+
fill: #F1AE5B;
1004+
}
1005+
.thumbnail-green {
1006+
fill: #4C9990;
1007+
}
1008+
.thumbnail-blue {
1009+
fill: #516D95;
1010+
}
1011+
.thumbnail-note {
1012+
fill: #0B0F14;
1013+
}
1014+
}
1015+
}
1016+
1017+
body.gray-theme {
1018+
.ProgramBlockEditor__character-column-character-container--MusicBand {
1019+
background-color: #FFFFFF;
1020+
}
1021+
1022+
.Scene__grid-line--MusicBand {
1023+
stroke: #7F8898;
1024+
}
1025+
1026+
.Scene__path-line--MusicBand {
1027+
stroke: #FFFFFF;
1028+
}
1029+
1030+
.Scene__starting-grid-cell-point--MusicBand {
1031+
fill: #FFFFFF;
1032+
}
1033+
1034+
.WorldSelector__option-image--MusicBand:hover {
1035+
svg {
1036+
.thumbnail-background {
1037+
fill: #B9BEC6;
1038+
}
1039+
.thumbnail-purple {
1040+
fill: #67717E;
1041+
}
1042+
.thumbnail-red {
1043+
fill: #818A98;
1044+
}
1045+
.thumbnail-yellow {
1046+
fill: #9DA4AF;
1047+
}
1048+
.thumbnail-green {
1049+
fill: #B9BEC6;
1050+
}
1051+
.thumbnail-blue {
1052+
fill: #D5D8DD;
1053+
}
1054+
.thumbnail-note {
1055+
fill: #22262A;
1056+
}
1057+
}
1058+
}
1059+
}
1060+
1061+
body.contrast-theme {
1062+
.ProgramBlockEditor__character-column-character-container--MusicBand {
1063+
background-color: #FFFFFF;
1064+
}
1065+
1066+
.Scene__grid-line--MusicBand {
1067+
stroke: #0078FF;
1068+
}
1069+
1070+
.Scene__path-line--MusicBand {
1071+
stroke: #FF0000;
1072+
}
1073+
1074+
.Scene__starting-grid-cell-point--MusicBand {
1075+
fill: #FF0000;
1076+
}
1077+
1078+
.WorldSelector__option-image--MusicBand:hover {
1079+
svg {
1080+
.thumbnail-background {
1081+
fill: #1E1E1E;
1082+
}
1083+
.thumbnail-stripe {
1084+
fill: #1E1E1E;
1085+
stroke: #FFFFFF;
1086+
}
1087+
.thumbnail-note {
1088+
fill: #FFFFFF;
1089+
}
1090+
}
1091+
}
1092+
}
1093+
9731094
/* Sketchpad */
9741095

9751096
.ProgramBlockEditor__character-column-character-container--Sketchpad {

src/messages.json

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -375,6 +375,18 @@
375375
"Marble.character": "the marble",
376376
"Marble.label": "A maze made of bricks in different colours. Your character in this scene is a marble. There is a path through the maze that starts where your marble is and there are multiple ways to escape the maze.",
377377
"Marble.name": "Marble Run",
378+
"MusicBand.character": "the baton",
379+
"MusicBand.drumKit": "the drum kit",
380+
"MusicBand.guitar": "the guitar",
381+
"MusicBand.label": "A music band scene with musical instruments. The instruments are arranged in 2 rows, with one row in the middle of the scene and one towards the bottom of the scene. In the upper row, there is a guitar, a drum kit, and a saxophone. In the lower row, there is a tambourine, a xylophone with a mallet, a microphone on a stand, and a synthesizer. Across the top of the scene spotlights light the instruments. And in the lower left and right corners there are loudspeakers. Your character in this scene is a conductor's baton.",
382+
"MusicBand.loudspeaker": "a loudspeaker",
383+
"MusicBand.microphone": "the microphone on a stand",
384+
"MusicBand.name": "Music Band",
385+
"MusicBand.saxophone": "the saxophone",
386+
"MusicBand.spotlight": "a spotlight",
387+
"MusicBand.synthesizer": "the synthesizer",
388+
"MusicBand.tambourine": "the tambourine",
389+
"MusicBand.xylophone": "the xylophone with mallet",
378390
"PenDownToggleSwitch.penDown": "Pen down",
379391
"PlayButton.play": "Play",
380392
"PlayButton.pause": "Pause",

0 commit comments

Comments
 (0)