Elegant-Notification icon indicating copy to clipboard operation
Elegant-Notification copied to clipboard

Cannot running with error no named parameter with name 'alignment'

Open MrHafid opened this issue 2 years ago • 13 comments

Screen Shot 2022-10-12 at 15 50 02

I have a problem with this and many other snackbar / Toast packages. When i run the project, I have error in image. Doe anyone have a fix for this?

MrHafid avatar Oct 12 '22 08:10 MrHafid

@MrHafid can you send me other details like the package version you are using ?

koukibadr avatar Oct 12 '22 09:10 koukibadr

@koukibadr I use package Flutter 2.2.3, in SDK 2.12.0, elegant_notification 1.6.4 maybe that ? I did flutter clean but still the result is like that.

MrHafid avatar Oct 12 '22 09:10 MrHafid

can you try with an older version of the package example 1.6.3 I will check this error in the new version update

koukibadr avatar Oct 12 '22 10:10 koukibadr

@koukibadr Yah, I use the version 1.6.3 and after update package i have that error

MrHafid avatar Oct 12 '22 10:10 MrHafid

Okay @MrHafid I will check the new update so thinks for opening this issue

koukibadr avatar Oct 12 '22 14:10 koukibadr

@koukibadr sure, I alwys waiting for update thanks for respond and your welcome

MrHafid avatar Oct 12 '22 14:10 MrHafid

@MrHafid if you are using the attribute alignement in the new version 1.6.4 it's renamed to notificationPosition can you please verify and let me know

koukibadr avatar Oct 12 '22 20:10 koukibadr

@koukibadr no i not using attrbute that, I use the default setting, even though I comment it still can't be run

MrHafid avatar Oct 13 '22 05:10 MrHafid

@MrHafid Okay I will check it and let you know what's the problem exactly

koukibadr avatar Oct 13 '22 08:10 koukibadr

@koukibadr what version your flutter ?, i check error alignment in widget AlertDialog maybe I have a version flutter not same with your package, cause alignment in my AlertDialog not found attribute that

MrHafid avatar Oct 13 '22 08:10 MrHafid

Yes that's the issue but the package needs to be compatible with all version of flutter

koukibadr avatar Oct 16 '22 09:10 koukibadr

@koukibadr ahhh i see, okay i will wait for update, maybe fix the issue. Thanks so much

MrHafid avatar Oct 16 '22 13:10 MrHafid

hey @koukibadr I got a solution for that problem, before I asked permission to change the package, now the solution I made was by changing the AlertDialog with Material, like this.

Screen Shot 2022-10-18 at 11 06 48 Screen Shot 2022-10-18 at 11 10 37 Write the code same the first function. Screen Shot 2022-10-18 at 11 10 44 result

MrHafid avatar Oct 18 '22 04:10 MrHafid