Skip to content

Commit fb9cb56

Browse files
committed
Fix: transformer config prop was not optional
1 parent cfe0f85 commit fb9cb56

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

src/lib/Transformer.svelte

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -30,13 +30,13 @@ Further information: [Konva API docs](https://konvajs.org/api/Konva.Transformer.
3030
import { registerEvents } from '$lib/util/events';
3131
import { getParentContainer, type KonvaParent } from '$lib/util/manageContext';
3232
import { copyExistingKeys } from '$lib/util/object';
33-
import { type Props } from '$lib/util/props';
33+
import { type PropsOptionalConfig } from '$lib/util/props';
3434
3535
let {
3636
config = $bindable({}),
3737
staticConfig = false,
3838
...eventHooks
39-
}: Props<Konva.TransformerConfig | undefined> = $props();
39+
}: PropsOptionalConfig<Konva.TransformerConfig> = $props();
4040
4141
export const handle = new Konva.Transformer(config);
4242

src/routes/examples/transform/Transform.svelte

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -171,7 +171,7 @@
171171
/>
172172

173173
<!-- Position transformer and selection rectagle at the bottom of all components so they are always the topmost elements on the canvas -->
174-
<Transformer config={{}} bind:this={transformer} />
174+
<Transformer bind:this={transformer} />
175175
<!-- The selection rectangle -->
176176
<Rect config={selectionRectangleConfig} bind:this={selectionRectangle} />
177177
</Layer>

0 commit comments

Comments
 (0)