Skip to content

Commit

Permalink
[Update] Song Artwork
Browse files Browse the repository at this point in the history
- Updated artwork size from 320px to 500px
  • Loading branch information
kiritokatklian committed Aug 25, 2024
1 parent 1802198 commit 99ecad9
Show file tree
Hide file tree
Showing 6 changed files with 9 additions and 9 deletions.
2 changes: 1 addition & 1 deletion public/js/listen.js.map

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion resources/js/helpers/music.js
Original file line number Diff line number Diff line change
Expand Up @@ -119,7 +119,7 @@ export default class MusicManager {
*
* @returns {string}
*/
getArtworkURL(song, width = 320, height = 320) {
getArtworkURL(song, width = 500, height = 500) {
return MusicKit.formatArtworkURL(song.attributes.artwork, width, height)
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -233,7 +233,7 @@ class="flex flex-nowrap gap-2"
this.bgColor = '#' + this.song.attributes.artwork.bgColor
this.songTitle = this.song.attributes.name
this.artistName = this.song.attributes.artistName
this.artworkURL = musicManager.getArtworkURL(this.song, 320, 320)
this.artworkURL = musicManager.getArtworkURL(this.song, 500, 500)
}
}
}"
Expand Down
2 changes: 1 addition & 1 deletion resources/views/components/lockups/music-lockup.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ class="relative pb-2 w-64 snap-normal snap-center {{ $class }}"
this.bgColor = '#' + this.song.attributes.artwork.bgColor
this.songTitle = this.song.attributes.name
this.artistName = this.song.attributes.artistName
this.artworkURL = musicManager.getArtworkURL(this.song, 320, 320)
this.artworkURL = musicManager.getArtworkURL(this.song, 500, 500)
}
}
}"
Expand Down
6 changes: 3 additions & 3 deletions resources/views/livewire/embeds/song.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -58,9 +58,9 @@ class="aspect-square rounded-lg shadow-md overflow-hidden"
x-on:click="await musicManager.playSong(song)"
>
<img class="object-cover"
alt="{{ $song->title }} Banner" title="{{ $song->title }}"
width="320" height="320"
x-bind:src="musicManager.getArtworkURL(song, 320, 320)"
alt="{{ $song->original_title }} Artwork" title="{{ $song->original_title }}"
width="500" height="500"
x-bind:src="musicManager.getArtworkURL(song, 500, 500)"
x-bind:style="{'background-color': '#' + song.attributes.artwork.bgColor}"
>

Expand Down
4 changes: 2 additions & 2 deletions resources/views/livewire/song/details.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@
window.song = this.song
this.bgColor = '#' + this.song.attributes.artwork.bgColor
this.songTitle = this.song.attributes.name
this.artworkURL = musicManager.getArtworkURL(song, 320, 320)
this.artworkURL = musicManager.getArtworkURL(song, 500, 500)
this.songURL = this.song.attributes.url
}
}
Expand All @@ -55,7 +55,7 @@
<x-picture class="aspect-square rounded-lg shadow-md overflow-hidden">
<img class="w-full h-full object-cover"
alt="{{ $song->original_title }} Artwork" title="{{ $song->original_title }}"
width="320" height="320"
width="500" height="500"
x-bind:title="songTitle"
x-bind:alt="songTitle + ' Artwork'"
x-bind:src="artworkURL"
Expand Down

0 comments on commit 99ecad9

Please sign in to comment.