Skip to content

Commit 8e9b95f

Browse files
authored
fix: Add class to shadow blocks in Geras (#9564)
* fix: Add class to shadow blocks in Geras * chore: Remove errant logging
1 parent eb42882 commit 8e9b95f

1 file changed

Lines changed: 1 addition & 14 deletions

File tree

core/renderers/geras/path_object.ts

Lines changed: 1 addition & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -81,12 +81,6 @@ export class PathObject extends BasePathObject {
8181
override applyColour(block: BlockSvg) {
8282
this.svgPathLight.style.display = '';
8383
this.svgPathDark.style.display = '';
84-
if (!this.style.colourTertiary) {
85-
throw new Error(
86-
'The renderer did not properly initialize the tertiary colour of ' +
87-
'the block style',
88-
);
89-
}
9084
this.svgPathLight.setAttribute('stroke', this.style.colourTertiary);
9185
this.svgPathDark.setAttribute('fill', this.colourDark);
9286

@@ -111,17 +105,10 @@ export class PathObject extends BasePathObject {
111105
}
112106

113107
override updateShadow_(shadow: boolean) {
108+
super.updateShadow_(shadow);
114109
if (shadow) {
115110
this.svgPathLight.style.display = 'none';
116-
if (!this.style.colourSecondary) {
117-
throw new Error(
118-
'The renderer did not properly initialize the secondary colour ' +
119-
'of the block style block style',
120-
);
121-
}
122111
this.svgPathDark.setAttribute('fill', this.style.colourSecondary);
123-
this.svgPath.setAttribute('stroke', 'none');
124-
this.svgPath.setAttribute('fill', this.style.colourSecondary);
125112
}
126113
}
127114

0 commit comments

Comments
 (0)