-
-
Notifications
You must be signed in to change notification settings - Fork 70
playlist user controls #994
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
Open
ajohn723
wants to merge
55
commits into
main
Choose a base branch
from
feature/playlist-user-operations
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from 1 commit
Commits
Show all changes
55 commits
Select commit
Hold shift + click to select a range
f2e73e0
playlist user controls
ajohn723 75523fe
updated users.ts to incorporate async function feedback
ajohn723 a1f9632
starting to build hooks and screen for collaborative playlist feature
ajohn723 b3bf0b7
hook to retrieve lists of users
ajohn723 dd887f8
Merge branch 'main' of https://github.com/Jellify-Music/App into feat…
ajohn723 05bcfa1
logic to get playlist users and server users
ajohn723 f5a1026
changing @/src to ../src
ajohn723 fdb3787
view for playlist collaborator screen
ajohn723 f07b5ff
fullscreen modal, filter out current owner of playlist, callbacks for…
ajohn723 6f5c8ed
adding button to allow share screen to swipe up
ajohn723 00df1b7
Merge branch 'main' of github.com:Jellify-Music/App into feature/play…
anultravioletaurora 3a4a63a
add scaffold for getUserImageUrl
anultravioletaurora 5096bd1
add additional scaffold
anultravioletaurora e9f2868
images for users and fixed navigation for share button
ajohn723 8f73a8c
fix jest
anultravioletaurora 9d0cea5
Merge branch 'main' into feature/playlist-user-operations
anultravioletaurora 4cad4a0
fix imports
anultravioletaurora 0e4f5aa
Merge branch 'feature/playlist-user-operations' of github.com:Jellify…
anultravioletaurora 1748574
update one letter and create unit tests
ajohn723 f6d3fc1
updated unit test
ajohn723 5abeeaf
add playlist as param
ajohn723 e388b44
updating queryClient conventions/types
ajohn723 9199450
inverted conditional statements for playlist user filtering
ajohn723 4c6d675
section header and some formatting
ajohn723 b57096d
updated padding and marginbottom to allow full list of users to be shown
ajohn723 c0290bd
section header
ajohn723 a98595a
enable nestedScrolling
ajohn723 ab607c7
updated more margins, added title
ajohn723 dfdb2a5
Merge branch 'main' into feature/playlist-user-operations
anultravioletaurora fc9cd09
lock file
ajohn723 cc638bc
Merge branch 'main' of github.com:Jellify-Music/App into feature/play…
anultravioletaurora ffd98c5
sorry aria
anultravioletaurora 5c6d750
restrict playlist share button to playlist owner
ajohn723 8c85d0b
fixed typo
ajohn723 d95902a
fix issue where the userId wasn't set when creating a playlist
anultravioletaurora 7ac905d
fix: add playlist users screen presentation
anultravioletaurora 25b0f9b
restore swipe to dismiss on android
anultravioletaurora 25eb334
search bar, baby!
ajohn723 e378f52
unit testing
ajohn723 5c9ec9f
Merge branch 'main' into feature/playlist-user-operations
anultravioletaurora 6be0cc2
add post-merge husky hook
anultravioletaurora e761b03
Merge branch 'main' into feature/playlist-user-operations
anultravioletaurora c25d4ed
Merge branch 'main' into feature/playlist-user-operations
anultravioletaurora 5ca141b
Merge branch 'main' into feature/playlist-user-operations
anultravioletaurora aacae70
Merge branch 'main' into feature/playlist-user-operations
anultravioletaurora 61ed1fe
apply prettier
anultravioletaurora 6543296
Merge branch 'main' of github.com:Jellify-Music/App into feature/play…
anultravioletaurora 2e542f2
Merge branch 'main' into feature/playlist-user-operations
anultravioletaurora efa2bfb
Fix build
anultravioletaurora 70f23b5
Merge branch 'main' into feature/playlist-user-operations
anultravioletaurora 8fbcf7e
Merge branch 'main' into feature/playlist-user-operations
anultravioletaurora 3da8975
Merge branch 'main' into feature/playlist-user-operations
anultravioletaurora c125e8b
Merge branch 'main' into feature/playlist-user-operations
anultravioletaurora 7e35eba
Merge branch 'main' into feature/playlist-user-operations
anultravioletaurora 1a73b87
Merge branch 'main' into feature/playlist-user-operations
anultravioletaurora File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,46 @@ | ||
| //playlist id | ||
|
|
||
| import { getApi, getUser } from '@/src/stores' | ||
| import { getPlaylistsApi } from '@jellyfin/sdk/lib/utils/api' | ||
|
|
||
| //get playlist users | ||
| function getPlaylistUsers(playlistId: string) { | ||
| //use api | ||
| const api = getApi() | ||
| //const user = getUser(); | ||
|
ajohn723 marked this conversation as resolved.
Outdated
|
||
| const playlist = getPlaylistsApi(api!) | ||
|
ajohn723 marked this conversation as resolved.
Outdated
|
||
|
|
||
| return playlist.getPlaylistUsers({ playlistId }) | ||
|
ajohn723 marked this conversation as resolved.
Outdated
|
||
| } | ||
|
|
||
| //also need user id for add and remove user functions | ||
|
|
||
| function addPlaylistUser(playlistId: string, userId: string, CanEdit: boolean) { | ||
|
ajohn723 marked this conversation as resolved.
Outdated
|
||
| //use api | ||
| const api = getApi() | ||
| const playlist = getPlaylistsApi(api!) | ||
|
|
||
| //use dto | ||
| return playlist.updatePlaylist({ | ||
| playlistId, | ||
| updatePlaylistDto: { | ||
| Users: [ | ||
| { | ||
| UserId: userId, | ||
| CanEdit, | ||
| }, | ||
| ], | ||
| }, | ||
| }) | ||
| } | ||
|
|
||
| function removePlaylistUser(playlistId: string, userId: string) { | ||
| //use api | ||
| const api = getApi() | ||
| const playlist = getPlaylistsApi(api!) | ||
|
|
||
| return playlist.removeUserFromPlaylist({ | ||
| playlistId, | ||
| userId, | ||
| }) | ||
| } | ||
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.
Uh oh!
There was an error while loading. Please reload this page.