Skip to content

Commit 925a7b9

Browse files
authored
Merge pull request #7585 from google/rc/v10.2.2
release: v10.2.2
2 parents ead46e7 + 865c593 commit 925a7b9

File tree

3 files changed

+6
-9
lines changed

3 files changed

+6
-9
lines changed

core/field_colour.ts

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -246,12 +246,9 @@ export class FieldColour extends Field<string> {
246246

247247
const block = this.getSourceBlock() as BlockSvg | null;
248248
if (!block) throw new UnattachedFieldError();
249-
// In general, do *not* let fields control the color of blocks. Having the
250-
// field control the color is unexpected, and could have performance
251-
// impacts.
252-
// Whenever we render, the field may no longer be a full-block-field so
253-
// we need to update the colour.
254-
if (this.getConstants()!.FIELD_COLOUR_FULL_BLOCK) block.applyColour();
249+
// Calling applyColour updates the UI (full-block vs non-full-block) for the
250+
// colour field, and the colour of the field/block.
251+
block.applyColour();
255252
}
256253

257254
/**

package-lock.json

Lines changed: 2 additions & 2 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": "blockly",
3-
"version": "10.2.1",
3+
"version": "10.2.2",
44
"description": "Blockly is a library for building visual programming editors.",
55
"keywords": [
66
"blockly"

0 commit comments

Comments
 (0)