Skip to content

feat: Tags!!#707

Open
bmcwilliams96 wants to merge 4 commits into
BLeeEZ:masterfrom
bmcwilliams96:feat/tags
Open

feat: Tags!!#707
bmcwilliams96 wants to merge 4 commits into
BLeeEZ:masterfrom
bmcwilliams96:feat/tags

Conversation

@bmcwilliams96
Copy link
Copy Markdown
Contributor

@bmcwilliams96 bmcwilliams96 commented May 26, 2026

Tag Viewer

Adds a new "View Tags" page accessible from the context menu of each song. This page is only accessible if the given song has tags. Otherwise, the option will not show up.

Screenshot 2026-05-26 at 3 32 00 PM

By default, all tags will show, but the user has the option to filter which tags they want shown. This setting will be persistent amongst songs in the library. If a tag that has not been seen before is present in a song, it will be added to the filter list, and shown by default.

Screenshot 2026-05-26 at 3 34 33 PM

This gives the user an opportunity to have an info screen about the song they are listening to. The main use case would be for a "song credits" type screen, but it is up to the user how they want to use this page.

Screenshot 2026-05-26 at 3 36 01 PM

This new page is only present in-app and is not available in CarPlay.

Artists Tag

In addition to this change, there is also an adjustment to show the "Artists" tag as the artist for a song. Previously, we were only grabbing the first artist available, so a song by Thundercat and Tame Impala would just show "Thundercat". Now, it will show both, separated by a comma.

Screenshot 2026-05-26 at 3 37 51 PM

If the Artists tag is not available, it will fall back to the original parsing we were doing before.

This new comma separated artist shows up in all views (CarPlay, system now playing, song list, and in-app now playing)

Tests

A new test was also added for the new tag viewer page.

Copy link
Copy Markdown
Owner

@BLeeEZ BLeeEZ left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi,
First of all thank you for this PR.
It is always beneficial to store as much information as available for better database search and user experience.

There are two major points that needs to be matched:

  1. Albums artists, artists, genres: all these attributes need to be linked to their DB entity not just string. This is needed to be available for searches and sorting.
  2. The Ampache API needs to be supported as well.

persist()
}

private func persist() {
Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No direct UserDefaults access. Use User Settings that save it.

Comment thread Amperfy.xcodeproj/project.pbxproj Outdated
COPY_PHASE_STRIP = NO;
DEBUG_INFORMATION_FORMAT = dwarf;
DEVELOPMENT_TEAM = U3R6D65S8W;
DEVELOPMENT_TEAM = 8N5BD6J6TY;
Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Remove adjusted DEVELOPMENT_TEAM.

"episode", songBuffer != nil {
// Multi-artist display string
if !collectedArtistNames.isEmpty {
songBuffer?.artistsString = collectedArtistNames.joined(separator: ", ")
Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

why is it save as a String and not referencing the element directly as array. This would improve DB search.

set { managedObject.artistsString = newValue }
}

public var albumArtistsString: String? {
Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[Artist]

set { managedObject.channelCount = newValue }
}

public var samplingRate: Int32 {
Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should only be Int. The wrapper is there to hide the actual size of the DB entry.

@bmcwilliams96
Copy link
Copy Markdown
Contributor Author

Hi,
First of all thank you for this PR.
It is always beneficial to store as much information as available for better database search and user experience.

There are two major points that needs to be matched:

  1. Albums artists, artists, genres: all these attributes need to be linked to their DB entity not just string. This is needed to be available for searches and sorting.
  2. The Ampache API needs to be supported as well.

Sounds good I will get an update pushed out as soon as possible! :)

@bmcwilliams96
Copy link
Copy Markdown
Contributor Author

Comment Status
No direct UserDefaults access — use User Settings ✅ Fixed (TagVisibilityStore now uses PersistentStorage.settings.user.hiddenSongTagKeys)
DEVELOPMENT_TEAM should be reverted to org ID Just fixed — both debug/release configs reverted to U3R6D65S8W
Artists/albumArtists/genres should be [Artist]/[Genre] entity relationships, not strings ✅ Fixed (Core Data v51, new relationships, Song.swift computed wrappers)
samplingRate/channelCount/bpm/bitDepth wrapper should be Int not Int16/Int32 ✅ Fixed
Ampache API needs to be supported ✅ Fixed (SongParserDelegate now handles <albumartist>, multi-<genre>, <rate>, <channels>, <composer>, <comment>, <mbid>)

@bmcwilliams96
Copy link
Copy Markdown
Contributor Author

oops forgot to run tests. Fix for the tests out in a bit

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants