AlertToast icon indicating copy to clipboard operation
AlertToast copied to clipboard

Not usable as global modifier when sheet is presented

Open mkubista opened this issue 1 year ago • 7 comments

I tried this in my project, where Im using some views in sheets. I need some global error handling, so I used this on top level view. It cant work, because this implementation uses simple overlay over content view. Unfortunately I didnt look into the source codes before trying to integrate it... 😞

mkubista avatar Mar 29 '23 14:03 mkubista

@mkubista thanks for the heads up. I too would like something to use for a global view. Did you find anything that does work?

gshaw avatar Apr 27 '23 22:04 gshaw

You can use it inside a sheet, you just need to put the modifier inside the sheet too

svenoaks avatar Jun 11 '23 21:06 svenoaks

My fork should fix your issue.

ImTheSquid avatar Aug 06 '23 18:08 ImTheSquid

@ImTheSquid I would like this functionality but your fork gives me the error:

Type 'any View' cannot conform to 'View'

rocketraman avatar Aug 29 '23 03:08 rocketraman

Can you give me a full compiler backtrace so I can see where that's happening? Also make sure you pull the repo again and tell me what version of Swift and iOS you're using.

ImTheSquid avatar Aug 30 '23 02:08 ImTheSquid

Can you give me a full compiler backtrace so I can see where that's happening? Also make sure you pull the repo again and tell me what version of Swift and iOS you're using.

@ImTheSquid I definitely had the latest master. iOS 16.2, Xcode 14.2 (Swift 5.7 I think?). I don't know the compiler backtrace as I ended up switching back to elai950/AlertToast and just adding it to the sheet view as suggested by @svenoaks , and it worked.

rocketraman avatar Aug 30 '23 18:08 rocketraman

any fix on this? The loading animation appears under the sheets

afern247 avatar Nov 27 '23 04:11 afern247