You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I noticed an unusual behavior where category items multiply when the colorScheme changes while the emojiPicker is open in SwiftUI using the .emojiPicker modifier. It appears that these categories multiply each time the colorScheme changes.
Minimal Reproducible Example: XCode Version 14.2 (14C18), iOS 16.2
struct EmojiPickerTest: View {
@State private var isEmojiPickerShown: Bool = false
@State private var emoji: String = "😀"
var body: some View {
Button(emoji, action: { isEmojiPickerShown = true })
.emojiPicker(isPresented: $isEmojiPickerShown,
selectedEmoji: $emoji)
}
}
struct EmojiPickerTest_Previews: PreviewProvider {
static var previews: some View {
EmojiPickerTest()
}
}
There is a workaround for the problem: manually dismiss the emojiPicker when colorScheme is changed using the onChange() modifier like this:
.onChange(of: colorScheme, perform: { _ in
isEmojiPickerShown = false
})
However, I believe the issue is still worth mentioning.
The text was updated successfully, but these errors were encountered:
Same issue I'm having and didn't know was already submitted. This appears to be a application state issue as well; as exiting then reopening the application with the view controller open will cause this issue as well
I noticed an unusual behavior where category items multiply when the
![image](https://private-user-images.githubusercontent.com/78581367/273760773-e6aac933-9f7e-47a4-96ea-11b8906a9459.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MzkzMTg2NjEsIm5iZiI6MTczOTMxODM2MSwicGF0aCI6Ii83ODU4MTM2Ny8yNzM3NjA3NzMtZTZhYWM5MzMtOWY3ZS00N2E0LTk2ZWEtMTFiODkwNmE5NDU5LnBuZz9YLUFtei1BbGdvcml0aG09QVdTNC1ITUFDLVNIQTI1NiZYLUFtei1DcmVkZW50aWFsPUFLSUFWQ09EWUxTQTUzUFFLNFpBJTJGMjAyNTAyMTElMkZ1cy1lYXN0LTElMkZzMyUyRmF3czRfcmVxdWVzdCZYLUFtei1EYXRlPTIwMjUwMjExVDIzNTkyMVomWC1BbXotRXhwaXJlcz0zMDAmWC1BbXotU2lnbmF0dXJlPTVlMTZlYWRlNDVkYjJkZTdiYjYyMGNjY2VjOTUwMDQ4OThmNGY5NmE5NjcyYWJlODY4MjNiNmE3ZDhjZjYyNzgmWC1BbXotU2lnbmVkSGVhZGVycz1ob3N0In0.rrQG-R32uptJWRKbV14AYcI-cPA0kTjAi7W9LLlnO84)
colorScheme
changes while theemojiPicker
is open inSwiftUI
using the.emojiPicker
modifier. It appears that these categories multiply each time thecolorScheme
changes.Minimal Reproducible Example:
XCode Version 14.2 (14C18), iOS 16.2
There is a workaround for the problem: manually dismiss the
emojiPicker
whencolorScheme
is changed using theonChange()
modifier like this:However, I believe the issue is still worth mentioning.
The text was updated successfully, but these errors were encountered: