Scratch 3 style in Blockly

1,316 views
Skip to first unread message

Uwe K

unread,
Mar 14, 2018, 6:17:15 AM3/14/18
to Blockly
Hello,

are there plans to adopt any of the changes that Scratch 3's Blockly fork has made? We'd like to use their visual theme and field widgets in our project, but it looks like they're not compatible with Blockly in some areas.

Erik Pasternak

unread,
Mar 15, 2018, 3:58:28 PM3/15/18
to Blockly
We plan to pull some features back in, but not their overall style. However, Microsoft's MakeCode team agrees with you. Their code is here.

Cheers,
Erik

Uwe K

unread,
Mar 17, 2018, 9:04:56 AM3/17/18
to Blockly
Thanks,
I didn't know about MakeCode. Their approach to mutators with the +/- buttons is great. Looks like they Typescriptified Blockly and put it in a repo with tons of other things. I can't figure out how and where they included the Scratch styling. They have a separate Blockly fork, but that has no style changes.

Uwe

Rachel Fenichel

unread,
Mar 19, 2018, 2:30:49 PM3/19/18
to Blockly
Check out their develop branch.  `block_render_svg.js` has the scratch styling, though it definitely took more than that one file to make it work.

Cheers,
Rachel

Uwe K

unread,
Mar 28, 2018, 12:16:46 PM3/28/18
to Blockly
Thank you, that one works for me. It's more than one file, but all the changes are in one commit, so it's manageable. Do you happen to know what the three color fields per block represent?

Uwe

picklesrus

unread,
Mar 28, 2018, 1:16:09 PM3/28/18
to Blockly
The primary, secondary, and tertiary ones?

They're for different pieces of the block.  e.g. dropdown menus in a block are slightly different than the "primary" color in the surrounding block.
Here's an old discussion that describes them that I believe is still mostly accurate: https://github.com/LLK/scratch-blocks/issues/98

And here's a visual of what they are for the different scratch categories: https://github.com/LLK/scratch-blocks/wiki/Colors
Message has been deleted

Uwe K

unread,
Mar 28, 2018, 3:57:33 PM3/28/18
to Blockly
Yes, that's what I was looking for. Thank you.
Reply all
Reply to author
Forward
0 new messages