fix(ui): remove extraneous rect in stagingareamodule

This commit is contained in:
psychedelicious
2025-06-27 15:43:14 +10:00
parent 651b80b997
commit df8751b5a1

View File

@@ -48,7 +48,6 @@ export class CanvasStagingAreaModule extends CanvasModuleBase {
group: Konva.Group;
placeholder: {
group: Konva.Group;
rect: Konva.Rect;
badgeBg: Konva.Rect;
text: Konva.Text;
};
@@ -71,8 +70,6 @@ export class CanvasStagingAreaModule extends CanvasModuleBase {
this.log.debug('Creating module');
const { width, height } = this.manager.stateApi.getBbox().rect;
this.konva = {
group: new Konva.Group({
name: `${this.type}:group`,
@@ -84,14 +81,6 @@ export class CanvasStagingAreaModule extends CanvasModuleBase {
listening: false,
visible: false,
}),
rect: new Konva.Rect({
name: `${this.type}:placeholder_rect`,
fill: 'transparent',
width,
height,
listening: false,
perfectDrawEnabled: false,
}),
badgeBg: new Konva.Rect({
name: `${this.type}:placeholder_badge_bg`,
fill: 'hsl(220 12% 10% / 0.8)', // 'base.900' with opacity
@@ -124,7 +113,6 @@ export class CanvasStagingAreaModule extends CanvasModuleBase {
},
};
this.konva.placeholder.group.add(this.konva.placeholder.rect);
this.konva.placeholder.group.add(this.konva.placeholder.badgeBg);
this.konva.placeholder.group.add(this.konva.placeholder.text);
this.konva.group.add(this.konva.placeholder.group);