Damus
Frederik Handberg profile picture
Frederik Handberg
@frederikhandberg
Apparently using `.glassEffect()` on the window background will break the functionality of the `.onDrop()` modifier.

I wanted the Liquid Glass effect on the window background of my app, so I added the `.glassEffect()` modifier which worked, but then I could not drag-and-drop files in the infinite canvas anymore…

Turns out that you need to use the AppKit class called `NSGlassEffectView` instead. Now the `.onDrop()` modifier works again.

https://developer.apple.com/documentation/appkit/nsglasseffectview
2
Frederik Handberg · 5d
I appreciate that Apple provides all the properties you can call on `NSGlassEffectView` like `tintColor`. In my case I applied a black color with 50% opacity - looks really good. Would like to have the same options for `NSVisualEffectView`…