flutter_confetti icon indicating copy to clipboard operation
flutter_confetti copied to clipboard

Emitter Position

Open sarpde opened this issue 2 years ago • 2 comments

I wrap my elements with ConfettiWidget which is clean and convenient but I couldn't figure out a way to change emitter position. It is always on topLeft. What I'd like to do is emit particles from top or center of my element (stars in this example) Screen Shot 2021-10-02 at 19 39 40

Is it possible?

sarpde avatar Oct 02 '21 16:10 sarpde

I have the same issue. I fix it with a padding and a blastDirection: pi /2

Junama avatar Oct 27 '21 14:10 Junama

The alignment widget works quite well to position the emitter position.

Align(
  alignment: Alignment.topCenter,
  child: ConfettiWidget(
    ...
  ),
)

Petri-Oosthuizen avatar Feb 23 '22 09:02 Petri-Oosthuizen