-
Notifications
You must be signed in to change notification settings - Fork 234
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Local notification with local image #1142
Comments
seems to be well supported at least in theory as long as it is a local file of supported type and within size limits (https://developer.apple.com/documentation/usernotifications/unnotificationattachment#1682051) I assume it works if the file is in the bundle? it's just downloading a local file first then trying to display it that is not working? Adding instrumentation logs here and running from Xcode may be instructive notifee/ios/NotifeeCore/NotifeeCoreUtil.m Line 151 in ae2953b
There is not a lot of logic between the line where files are resolved and content is packaged then sent to the iOS notification center here notifee/ios/NotifeeCore/NotifeeCore.m Line 181 in ae2953b
|
It's failing with a copy from the bundle. If we use the "bundle" via notifee/packages/react-native/src/types/NotificationIOS.ts Lines 616 to 626 in ae2953b
The key part is absolute path meaning the |
Thar we go
The documentation should note or at least specify that a In case anyone is wondering... "expo-notifications" does not work even with the removal of the But this will break on the second usage of the notification with the same URL because the file moves as alluded to by iOS documentation, knew that before hand so just have to tweak the thing a bit |
This makes a clone of the list and strips off the file:// prefix on the URL invertase/notifee#1142
So I have a work around right now where I clone it on behalf of notifiee But it would be nice if notifee itself handles those logistics of copying the files and stripping off |
@trajano that's fantastic you got something working! That's always the first step :-) - I think you're easily the subject matter expert here at the moment, I'd be happy to merge any reasonable PR that improved this area, and the release pipeline has been exercised recently + commit queue is clean so getting it out would be quick |
Hello 👋, to help manage issues we automatically close stale issues. This issue has been automatically marked as stale because it has not had activity for quite some time.Has this issue been fixed, or does it still require attention?
Thank you for your contributions. |
#931 talks about a remote image.
For now I just want to download an image store it in the "cache" folder so the attachment looks like this
I've tried different variants removing values for ID type etc. With no luck
But the thumbnail image is not appearing
requires
approach does work though.Looking at the examples folder you're using a remote image.
Code https://github.com/trajano/expo-experiments/blob/test-expand-idea/packages/my-app/src/stories/Notification.stories.tsx
The text was updated successfully, but these errors were encountered: