[next] feat(NcAvatar): implement custom javascript hook action for the contacts menu#6306
Merged
Conversation
15 tasks
3 tasks
93be05e to
5430086
Compare
a1f860e to
43a72c6
Compare
susnux
reviewed
Apr 7, 2025
Comment on lines
+9
to
+24
| export interface ContactsMenuEntry { | ||
| id: number|string|null, | ||
| fullName: string, | ||
| avatar: string|null, | ||
| topAction: object|null, | ||
| actions: object[], | ||
| lastMessage: '', | ||
| emailAddresses: string[], | ||
| profileTitle: string|null, | ||
| profileUrl: string|null, | ||
| status: string|null, | ||
| statusMessage: null|string, | ||
| statusMessageTimestamp: null|number, | ||
| statusIcon: null|string, | ||
| isUser: boolean, | ||
| uid: null|string, |
Contributor
There was a problem hiding this comment.
Really null? What a mess 🙈
Better would be ´undefinedto haveuid?: string` and similar.
Contributor
There was a problem hiding this comment.
Better would be ´undefined
to haveuid?: string` and similar.
But JSON has no undefined...
So it's either null, or '', or we transform response.
Contributor
There was a problem hiding this comment.
Well simply not defined is undefined: {"foo": 1} would be the same as
{
foo: number
bar?: string
}
Contributor
There was a problem hiding this comment.
This data is deserialized from JSON as is and can be null.
ShGKme
reviewed
Apr 7, 2025
Comment on lines
+9
to
+24
| export interface ContactsMenuEntry { | ||
| id: number|string|null, | ||
| fullName: string, | ||
| avatar: string|null, | ||
| topAction: object|null, | ||
| actions: object[], | ||
| lastMessage: '', | ||
| emailAddresses: string[], | ||
| profileTitle: string|null, | ||
| profileUrl: string|null, | ||
| status: string|null, | ||
| statusMessage: null|string, | ||
| statusMessageTimestamp: null|number, | ||
| statusIcon: null|string, | ||
| isUser: boolean, | ||
| uid: null|string, |
Contributor
There was a problem hiding this comment.
Better would be ´undefined
to haveuid?: string` and similar.
But JSON has no undefined...
So it's either null, or '', or we transform response.
ShGKme
approved these changes
Apr 10, 2025
susnux
approved these changes
Apr 10, 2025
…cts menu Signed-off-by: Richard Steinmetz <richard@steinmetz.cloud>
2b3d91b to
8310da7
Compare
Contributor
|
Rebased to squash both commits. Nothing else changed. |
4 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Backport of #6238
Warning, This backport's changes differ from the original and might be incomplete⚠️
Todo
Learn more about backports at https://docs.nextcloud.com/server/stable/go.php?to=developer-backports.